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
| Method | Endpoint | What it does |
|---|---|---|
GET | /api/ | Get list of all user's segmentations |
POST | /api/ | Create a new segmentation |
PUT | /api/ | Update the given segmentation |
GET | /api/ | Get the rule categories you can use in a segmentation |
GET | /api/ | Get the fields you can use in each rule category |
GET | /api/ | Get dictionary of rules operations |
GET | /api/ | Get 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
| Parameter | In | Type | Description |
|---|---|---|---|
rules_segment | body | ApiRulesSegment | Contains rules segment |
name | body | string | Segmentation 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}
| Parameter | In | Type | Description |
|---|---|---|---|
id | path | integer | Segmentation id Required. |
rules_segment | body | ApiRulesSegment | Contains rules segment |
name | body | string | Segmentation 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.