Create, update and list segmentations (the audience rules of an automation), and read the rule types, fields and operations you can use in them.

All endpoints use the base URL https://webapi.mymarketing.co.il and an API key in the Authorization header. New to the API? Start with Get started with the ActiveTrail API.

Endpoints

MethodEndpointWhat it does
GET/api/segmentationGet list of all user's segmentations
POST/api/segmentationCreate a new segmentation
PUT/api/segmentation/{id}Update the given segmentation
GET/api/segmentation/ruleTypesGet the rule categories you can use in a segmentation
GET/api/segmentation/ruleFieldTypesGet the fields you can use in each rule category
GET/api/segmentation/ruleOperationsGet dictionary of rules operations
GET/api/segmentation/ruleTypesMappingGet a full mapping of operations and field types associated to the type of rule

Endpoint details

Get list of all user's segmentations

GET https://webapi.mymarketing.co.il/api/segmentation

No parameters.

Full reference, request and response samples

Create a new segmentation

POST https://webapi.mymarketing.co.il/api/segmentation
ParameterInTypeDescription
rules_segmentbodyApiRulesSegmentContains rules segment
namebodystringSegmentation name

The request body is a JSON object (ApiSegmentationUpdateContainer).

Full reference, request and response samples

Update the given segmentation

PUT https://webapi.mymarketing.co.il/api/segmentation/{id}
ParameterInTypeDescription
idpathintegerSegmentation id Required.
rules_segmentbodyApiRulesSegmentContains rules segment
namebodystringSegmentation name

The request body is a JSON object (ApiSegmentationUpdateContainer).

Full reference, request and response samples

Get the rule categories you can use in a segmentation

GET https://webapi.mymarketing.co.il/api/segmentation/ruleTypes

Get the rule categories you can use in a segmentation: Info, Action, Group, Date, Numeric, OrderDate, OrderNumeric and OrderInfo.

No parameters.

Full reference, request and response samples

Get the fields you can use in each rule category

GET https://webapi.mymarketing.co.il/api/segmentation/ruleFieldTypes

Get the fields you can use in each rule category (for example, for Info: Email, SMS, FirstName and the other contact fields).

No parameters.

Full reference, request and response samples

Get dictionary of rules operations

GET https://webapi.mymarketing.co.il/api/segmentation/ruleOperations

No parameters.

Full reference, request and response samples

Get a full mapping of operations and field types associated to the type of rule

GET https://webapi.mymarketing.co.il/api/segmentation/ruleTypesMapping

No parameters.

Full reference, request and response samples

This reference is based on the ActiveTrail API documentation, where you can also test each endpoint with your own API key.