Introduction

Welcome to the Magento integration guide! Magento is an eCommerce marketplace that integrates digital and physical shopping experiences. They offer many useful add-ons that help you create the perfect, custom eCommerce platform. This guide walks you through how to add the three available Mitto integrations available.

Installation

There are two ways to install. You can use a downloaded archive from the Magento marketplace or you can use composer.

Download an Archive and Install

To install the Mitto integrations with an archive, do the following:

  1. Unpack a downloaded archive inside app/code/Mitto directory relative to your project root.
  2. Execute setup upgrade (php bin/magento setup:upgrade)

Install with Composer

To install the Mitto integrations with composer, do the following:

  1. Execute composer require for the integration you want:
    • composer require mitto-ag/magento2-notifications for Mitto SMS Alerts Notifications Confirmations
    • composer require mitto-ag/magento2-login for Mitto SMS Registration & Login
    • composer require mitto-ag/magento2-bulk for Mitto SMS Marketing
  2. Execute setup upgrade (php bin/magento setup:upgrade)

Configuration

In order to use any of the modules you need to configure Mitto API. After successfully installing the module(s), login to your Magenta admin panel, then in menu choose Stores → Configuration. There you should find Mitto tab which holds configuration sections for all Mitto modules. For API section you need to enter API key and sender name. Contact partnerships@mitto.ch to obtain one. After saving the API credentials you can test them using the Send Test SMS section, simply enter you number and you should receive the test SMS.

Templates

All Mitto modules use a simpler version of Magento 2 email templating system. This means that merchant has maximal flexibility in using the data provided by Magento, depending on context. Main feature of templates are variables, their format is {{var expression}} where expression is changed with appropriate variable name/object method. Store variable is available in every template context.

These are example expressions for store object:

Expression Example value
{{var store.getCode()}} default
{{var store.getName()}} Default Store View
{{var store.getUrl()}} http://magento232.local/
{{var store.getBaseUrl()}} http://magento232.local/
{{var store.getId()}} 1
{{var store.getBaseCurrencyCode()}} USD
{{var store.getDefaultCurrencyCode()}} USD
{{var store.getCurrentCurrencyCode()}} USD
{{var store.getRootCategoryId()}} 2
{{var store.getWebsiteId()}} 1
{{var store.getGroupId()}} 1
{{var store.getStoreGroupId()}} 1
{{var store.getIsActive()}} 1
{{var store.getFrontendName()}} Main Website Store
{{var store.getFormattedAddress()}} Test address
{{var order.getFrontendStatusLabel()}} Pending
{{var order.getStatusLabel()}} Pending
{{var order.getEntityType()}} order
{{var order.getRealOrderId()}} 1
{{var order.getCustomerName()}} Test Test
{{var order.getStoreGroupName()}} Main Website Store
{{var order.getIncrementId()}} 1
{{var order.getBaseCurrencyCode()}} USD
{{var order.getBaseDiscountAmount()}} 0
var order.getBaseGrandTotal()}} 6
{{var order.getBaseDiscountTaxCompensationAmount()}} 0
{{var order.getBaseShippingInclTax()}} 5
{{var order.getBaseShippingTaxAmount()}} 0
{{var order.getBaseSubtotal()}} 1
{{var order.getBaseSubtotalInclTax()}} 1
{{var order.getBaseTaxAmount()}} 0
{{var order.getBaseToGlobalRate()}} 1
{{var order.getBaseToOrderRate()}} 1
{{var order.getBillingAddressId()}} 2
{{var order.getCreatedAt()}} 2019-10-04 17:32:25
{{var order.getCustomerEmail()}} test@example.com
{{var order.getCustomerFirstname()}} Test
{{var order.getCustomerGroupId()}} 0
{{var order.getCustomerIsGuest()}} 1
{{var order.getCustomerLastname()}} Test
{{var order.getCustomerNoteNotify()}} 1
{{var order.getDiscountAmount()}} 0
{{var order.getGlobalCurrencyCode()}} USD
{{var order.getGrandTotal()}} 6
{{var order.getDiscountTaxCompensationAmount()}} 0
{{var order.getIsVirtual()}} 0
{{var order.getOrderCurrencyCode()}} USD
{{var order.getQuoteId()}} 5
{{var order.getRemoteIp()}} 127.0.0.1
{{var order.getShippingAmount()}} 5
{{var order.getShippingDescription()}} Flat Rate – Fixed
{{var order.getShippingDiscountAmount()}} 0
{{var order.getShippingDiscountTaxCompensationAmount()}} 0
{{var order.getShippingInclTax()}} 5
{{var order.getShippingTaxAmount()}} 0
{{var order.getState()}} new
{{var order.getStatus()}} pending
{{var order.getStoreCurrencyCode()}} USD
{{var order.getStoreId()}} 1
{{var order.getStoreName()}} Main Website Main Website Store
{{var order.getStoreToBaseRate()}} 0
{{var order.getStoreToOrderRate()}} 0
{{var order.getSubtotal()}} 1
{{var order.getSubtotalInclTax()}} 1
{{var order.getTaxAmount()}} 0
{{var order.getTotalItemCount()}} 1
{{var order.getTotalQtyOrdered()}} 1
{{var order.getUpdatedAt()}} 2019-10-14 20:35:55
{{var order.getWeight()}} 0

This feature allows you to see all messages sent from your store and their status. It can be found by going to the admin panel and then opening Marketing -> Mitto -> SMS Log.