Vero Destination

Segment makes it easy to send your data to Vero (and lots of other destinations). Once you've tracked your data through our open source libraries we'll translate and route your data to Vero in the format they understand. Learn more about how to use Vero with Segment.

Our Vero destination code is all open-source on GitHub if you want to check it out: Javascript, Server.

Getting Started

Vero helps you send targeted emails to customers based on their behavior. When you toggle on Vero in Segment, this is what happens:

  • Our CDN is updated within 5-10 minutes. Then our snippet will start asynchronously loading Vero’s m.js onto your page. This means you should remove Vero’s snippet from your page.
  • Since Vero only records custom events and custom user data, no events or users will appear in Vero until you start using the API outlined below.

Vero is supported on the client-side, server-side and mobile.


Identify

Client Side

When you call identify on analytics.js, we augment traits to have traits.id set to the userId, and then call Vero’s user with the augmented traits object. You should provide both a traits.email and a userId for Vero to work best.

If no email is attached, the user is created in Vero but cannot be emailed. If you send omit the userId, Vero will use the email as the ID, which is is not recommended. Check out the Vero docs for more information.

A userId is a required value for all types of calls. Be sure you call identify with a userId for subsequent track calls to populate into Vero correctly. For server side calls, you will have to manually pass in the userId at the top level.

Server Side

When you call identify from one of our server-side languages, we’ll call Vero’s REST API and update the traits for the customer with that userId. If your userId is an email, we’ll also set the trait email as your userId in the update call.

Track

When you call track, we’ll send the event to Vero with the event name and properties you provide. Events will be matched to the current user.

You can also unsubscribe users by sending a track event, passing in the user’s ID as a property, like so:

analytics.track('Unsubscribe', {
  id: '12345'
});

Note: If you’d like to explicitly specify a user’s email with track events that is not an event metadata, you can send that under context.traits.email!

Sending Data from Vero

Vero supports sending email events to other tools on the Segment platform. These events will be sent as track calls to the other destinations you’ve turned on.

To enable this feature,

  1. Log into Vero and go to Settings
  2. Then go to Integrations
  3. Hit ‘view’ next to the Segment integration
  4. Enter in your Segment write key at the bottom.

Send email events from Vero

Group

When you call group, the traits included in the call will be set to the current user’s Group property in Vero.

Alias

Our alias method can be used from your server to “re-identify” an existing user identity to a new one.

Most of the time this happens when you identify a visitor by their email address after they opt in, then later re-identify with a database ID when they become registered users.

To connect the two identities you’ll need to alias their current identity to their new one.

Here’s a python example of using alias to update the identity from an email address to a database ID:

analytics.alias('friends@segment.com', '8765309')

Features

Tags

The destination is capable of both adding and removing tags in Vero for a given user. Because tags is not a common property of events, this functionality is invoked via an destination specific option.

To start using this feature, please pass an object called tags with the following properties:

id optionalStringThe user Id to associate tags with. If this is not specified, the destination will simply use the userId from the event itself.
action requiredStringMust be either ‘add’ or ‘remove’. Indicates whether you would like to add or remove the tags for the given user.
values requiredArrayAn array of strings representing the tags to either add or remove.

Here is an example using our Node.js library:

analytics.identify('324LKJF', {
    email: 'friends@segment.com'
}, {
    integrations: {
        Vero: {
            tags: {
                id: '235FAG', // This is optional! If not defined, we default to the event's userId (ie: 324LKJF)
                action: 'add',
                values: ['warriors', 'giants', 'niners']
            }
        }
    }
})

Supported Sources and Connection Modes

WebMobileServer
📱 Device-based
☁️ Cloud-based

To learn more about about Connection Modes and what dictates which we support, see here.

We offer an optional Cloud-based Connection Mode for Web data with Vero. As a reminder, this removes the Vero javascript library from your site, improving performance. However, there are a few disparities between the Cloud-based and Device-based connection modes to keep in mind brefore enabling it in the Segment app. When you enable the Cloud-based destination mode, here’s what happens:

  • Server-side `page` and `group` calls are now supported.
  • Server-side `identify`, and `track` calls now pass `context.userAgent` through to Vero.
  • Server-side `track` calls that include "Unsubscribe" will now unsubscribe the user in Vero. This change makes the server-side integration match that of Vero's JavaScript SDK.
  • All calls will no longer send `platform`, `language`, or `timezone` properties.
  • Vero's JavaScript SDK keeps track of anonymous users and, the first time they're identified, sends a `Visited Site` event to Vero. (If a user clears their cookies or changes devices, `Visited Site` event will be sent again.) If you rely on this exact behavior, you must instrument the event manually.
  • Vero does not support anonymous IDs, instead requiring that a discrete user ID be attached to all events; the Vero JavaScript SDK queues all `page` and `track` calls until an `identify` call is performed. Disabling the SDK will result in these anonymous events being dropped.

Settings

Segment lets you change these destination settings via your Segment dashboard without having to touch any code.

Auth Token

Your auth token allows you to send data to Vero through our server-side libraries. You can find your auth_token on Vero’s account page.

API Key

You can find your API key in your Vero Settings.


If you have any questions or see anywhere we can improve our documentation, please let us know or kick off a conversation in the Segment Community!