Mautic

Send your event data from RudderStack to Mautic.

Mautic is an open-source marketing automation platform. It enables you to segment your contacts based on business requirements, personalize your marketing strategy, and create personalized campaigns for better customer engagement.

RudderStack supports Mautic as a destination where you can seamlessly send your event data.

Connection compatibility

Destination info
  • Status: Generally Available
  • Supported sources: Android, iOS , Web, Unity, AMP , Cloud, React Native , Flutter, Cordova, Warehouse, Shopify
  • Refer to it as MAUTIC in the Integrations object.

Connection modes
SourceCloud modeDevice modeHybrid mode
AMPsupportednot supportednot supported
Androidsupportednot supportednot supported
Cloudsupportednot supportednot supported
Cordovasupportednot supportednot supported
Fluttersupportednot supportednot supported
iOSsupportednot supportednot supported
React Nativesupportednot supportednot supported
Shopifysupportednot supportednot supported
Unitysupportednot supportednot supported
Warehousesupportednot supportednot supported
Websupportednot supportednot supported
Supported message types
SourceIdentifyPageTrackScreenGroupAlias
Cloud mode
Supported sourcessupportednot supportednot supportednot supportedsupportednot supported

Get started

Once you have confirmed that the source platform supports sending events to Mautic, follow these steps:

  1. From your RudderStack dashboard, add a source. Then, from the list of destinations, select Mautic.
  2. Assign a name to the destination and click Continue.

Connection settings

To successfully configure Mautic as a destination, you will need to configure the following settings:

  • Username: Enter the username associated with your Mautic account.
  • Password: Enter the password for the above username.
  • Domain Method: Choose the preferred domain method from Domain or Subdomain. It is recommended to use Domain if you have a self-hosted Mautic instance.
    • Domain Name: Specify the domain name if you have chosen Domain above.
      OR
    • Subdomain Name: Specify the subdomain associated with your Mautic instance if you have chosen SubDomain above. For example, if the root URL of your Mautic instance is customdomain.domain.com, then your subdomain name will be customdomain.
  • Mautic property name to used as lookup field: Enter a unique Mautic user property which RudderStack will use for contact lookup.
info
RudderStack will retrieve this property from the user traits in the event.

Identify

You can use the identify call to create or update a user in Mautic.

A sample identify call is shown below:

rudderanalytics.identify("1hKOmRA4GRlm", {
  state: "Louisiana",
  firstName: "Alex",
  lastName: "Keener",
  title: "Mr",
  zipcode: "90009",
  prospectOrCustomer: "Customer",
  country: "USA",
  website: "www.alex.com",
  subscriptionStatus: "New",
  phone: "12025550146",
});

Supported mappings

The following table lists the mappings between the optional RudderStack and Mautic properties:

RudderStack propertyMautic propertyData type
context.traits.email / traits.email / properties.email/context.externalId.idemailString
traits.title / context.traits.titletitleString
traits.firstName / traits.firstname / traits.first_name / context.traits.firstName / context.traits.firstname / context.traits.first_namefirstnameAny
traits.lastName / traits.lastname / traits.last_name / context.traits.lastName / context.traits.lastname / context.traits.last_namelastnameAny
timestamp / originalTimestamplast_activeTimestamp in ISO 8601 format
phonephone / mobileAny
traits.address.citycityString
traits.address.addressLine1/ context.traits.address.addressLine1address1String
traits.address.addressLine2/ context.traits.address.addressLine2address2String
traits.address/ context.traits.addressaddress1 + address2String
traits.company.employeeCountcompany_sizeInteger
traits.role / context.traits.roleroleString
traits.website / context.traits.website / properties.websitewebsiteString
context.ipIPString
context.timezonetimezoneString
traits.subscriptionStatus / context.traits.subscriptionStatussubscription_statusString
traits.prospectOrCustomer / context.traits.prospectOrCustomerprospect_or_customerString
traits.hasPurchased / context.traits.hasPurchasedhaspurchasedString
traits.state/ context.traits.statestateString
traits.zipcode / context.traits.zipcode / traits.zip / context.traits.zipzipcodeString
traits.country / context.traits.countrycountryString (Starting with a capital letter)

Getting contact details

The easiest way to retrieve contact details of an existing user in Mautic is by specifying the unique user trait in the Mautic property name to used as lookup field dashboard setting. RudderStack will look for this property in the event’s traits or context.traits and use the value for contact lookup.

If the events do not contain the property specified in the above setting, then:

  • RudderStack uses the email property in the event.
  • If email is not present, RudderStack then creates a new contact in Mautic.

Optionally, you can also pass the contact ID in your event’s externalId:

{
  "context": {
    "externalId": [{
      "type": "mauticContactId",
      "id": "1hKOmRA4GRlm"
    }]
  }
}
info
RudderStack checks if externalId.type is set to mauticContactId before using the id field for contact lookup.
warning
The contact ID passed in your event’s externalId takes precedence over the user property specified in the Mautic property name to used as lookup field dashboard setting.

Group

You can use the group call to link or delink a Mautic contact with a segment, campaign, or a company.

A sample group call is shown below:

rudderanalytics.group("group01", {
  "name": "Alex Keener",
  "type": "Segments",
  "operation": "add"
});

RudderStack uses the type trait present in the group call to link or delink a Mautic user to a segment, campaign, or company. You can add or remove a user to a group using the operation trait. If this field is not explicitly set, RudderStack sets it to add by default.

The following table lists the supported group traits:

RudderStack propertyPresenceNotes
traits.typeRequiredYou can set it to Segments, Campaigns, or Companies.
traits.operationOptionalIf not set, RudderStack sets it to add by default.

Similar to the identify call above, RudderStack retrieves the contact ID from the group call in the following order of precedence:

  1. If externalId is present, RudderStack checks if the type is set to mauticContactId. If yes, it uses the id field for the contact lookup.
  2. If you have specified a unique user property in the Mautic property name to used as lookup field dashboard setting, RudderStack will look for this property in the event’s traits or context.traits and use it for the contact lookup.
  3. If the events do not contain the property specified in the above setting, then:
    • RudderStack uses the email property in the event.
    • If email is not present, RudderStack then gives an error.

Supported mappings

The following table lists the mappings between the RudderStack and Mautic properties:

RudderStack propertyMautic property
groupId
traits.groupId
Required
SegmentId
traits.email
context.traits.email
Required, if externalId and lookupField are absent.
email
message.context.externalId[x].id for type mauticContactIdCONTACT_ID
RudderStack propertyMautic property
groupId
traits.groupId
Required
CampaignId
traits.email
context.traits.email
Required, if externalId and lookupField are absent.
email
message.context.externalId[x].id for type mauticContactIdCONTACT_ID
RudderStack propertyMautic property
groupId
traits.groupId
Required
company_id
traits.email
context.traits.email
Required, if externalId and lookupField are absent.
email
message.context.externalId[x].id for type mauticContactIdCONTACT_ID

Questions? Contact us by email or on Slack