of 156 /156
Unica Interact V12.1.1 Rest API

Unica Interact Rest API Guide

  • Author
    others

  • View
    0

  • Download
    0

Embed Size (px)

Text of Unica Interact Rest API Guide

Unica Interact Rest API GuideContents
Chapter 1. Rest API Guide
This contains information about Rest API for Unica Interact Runtime and Unica Interact
Design Time. Interact API has predictable resource-oriented URLs. It accepts form-encoded
request bodies, returns JSON-encoded responses, and uses standard HTTP response
codes, authentication, and verbs.
Interact Design time
To authenticate internal users in client applications, use the Unica Platform login API to
generate secure tokens. You can then invoke any protected APIs by passing the required
parameters in the request header, in addition to the parameters expected by the API itself.
Example
m_user_name string header The internal user's Unica Platform login name.
m_user_password string header The internal user's Unica Platform password in plain
text.
Response
}
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 2
Interact Run time
To enable authentication on Unica Interact Run time API calls, specify the API
Authentication (Affinium|interact|general|API) property to true. When it is enabled,
Unica Interact Run time checks if an incoming API request has a valid authentication token,
else it authenticates with the supplied username and password with Unica Platform or
LDAP. Request is rejected if token is invalid or username or password is invalid. The token is
tied with the session-Id, which is provided during the startSession() API call. So, all other API
calls validate this token before proceeding.
Name Type In Description
m_user_name string header The internal user's Unica Platform login name.
m_user_password string header The internal user's Unica Platform password in plain
text.
Errors
Interact uses conventional HTTP response codes to indicate the success or failure of an
API request. In general, codes in the 2xx range indicate success. Codes in the 4xx range
indicate an error that failed on the basis of the information provided. Codes in the 5xx range
indicate an error with Interact servers (these are rare).
HTTP STATUS CODE SUMMARY
201 - Created Resource is created.
202 -
Accepted
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 3
204 - No
400 - Bad
Request
The request was unacceptable, often due to missing a required parameter
or invalid input to the parameter.
401 -
Unauthorized
404 - Not
500 - Server
Errors
Something went wrong on Interact server’s end. (This is rare.)
Pagination
Requests that return multiple items are paginated to 10 items by default. You can specify
further pages with the page parameter.
Name Type In Description
page number query nth page to retrieve records. Default is 0 (first page).
size number query Number of records per page. Default is 10.
Example
Response
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 4
"hasNext": true,
"hasPrev": true,
"pageNumber": 0,
"size": 10,
"totalElements": 0,
"totalPages": 0
document.
ic Interactive Channel
al Audience Level
aId Audience Id
The following are the abbreviations and symbols used in Objects section.
Abbreviations Description
Cr Create
Up Update
Cp Copy
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 5
Mandatory Parameter
Unica Interact Runtime APIs
The following section includes the Rest APIs for Unica Interact Runtime.
Objects
Parameter Object. See the Abbreviations (on page 4) topic for details on the
abbreviations used.
This can either be string or numeric or datetime object.
Parameter
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 6
Sessions
These APIs are used to start or end the Interact Runtime session.
Start Session
Parameters
ic string query Interactive Channel Name
audienceLevel string query Audience Level
audienceIDField string query Audience ID
Format: Name|Value|Type;Name2|Value2|
Type2
Type:
• string
• numeric
• datetime
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 7
"auIdParams": [
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 8
Name Type In Description
parameters string Query Parameters
Type:
• string
• numeric
• datetime
Offers
These APIs are used to get the offers from the started Interact runtime
session.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 9
Name Type In Description
IPID string query Interaction Point ID
number string query Number of offers requested
parameters string query Parameters
Type:
• string
• numeric
• datetime
Example: UACICachedOffers|1|numeric
RESPONSE (Status Code: 200)
{
}
],
POST/interact/v2/offers/{sessionId}
REQUEST
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 11
"numberRequested": 0,
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 12
"v": {}
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 13
"sessionId": "string",
"statusCode": 0,
"version": "string"
POST/interact/v2/offers/{sessionId}
REQUEST
{
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 15
"defaultString": "string",
"ip": "string",
Events
These APIs are used to post the event to the started Interact Runtime session.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 16
Post Event
eventName string path Event Name
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 17
Profiles
These APIs are used to get the profile data from started Interact Runtime
Session.
parameters string query Parameters
Type
• string
• numeric
• datetime
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 18
"n": "string",
"t": "string",
"v": "string"
Audience
These APIs are used to set the audience data to the existing Interact runtime
session.
audienceLevel string query Audience Level
audienceIDField string query Audience ID
Format: Name|Value|Type;Name2|Value2|
Type2
Type
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 19
• string
• numeric
• datetime
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 20
POST /v2/batch/{sessionID}
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 21
"numberRequested": 0
]
},
}
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 24
"n": "string",
"score": 0,
"treatmentCode": "string"
Deployment
These APIs are used to get the deployment information of interactive
channels.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 25
Name Type In Description
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 26
"icName": "string",
"lastDeploymentTime": "string",
"offerThreshold": 0,
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 27
"parentTableName": "string",
"preLoaded": true,
"tableName": "string"
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 28
"offerId": 0,
"offerName": "offer",
Get API Audit by Session ID
GET/interact/v2/APIhistory/session/{sessionID}?
Parameters
audienceLevel string query Audience Level
startTime number query Start time in millisecond (optional)
Example: 1609439400000
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 29
endTime number query End time in millisecond (optional)
Example: 1609439400000
GET/interact/v2/APIhistory/audience?
Parameters
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 30
Name Type In Description
startTime number query Start time in Millis (Optional)
endTime number query End time in Millis (Optional)
offerArbitration bool query Offer Arbitration information flag
(Optional)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 31
Event Pattern State
These APIs are used to get the states of all event patterns and offer
suppression rules belonging to the specified audience ID.
Get Event Pattern State
This API will return event pattern state from database and cache.
GET /interact/v2/eventpatterns?audienceLevel={al}&audienceIDField={aId}
Parameters
RESPONSE (Status Code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 32
"changed": true,
GET/interact/v2/eventpatterns/cache?
RESPONSE (Status Code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 33
"offerId": "string",
"offerName": "string",
"patternId": 0,
"patternName": "string",
"suppression": "string",
GET/interact/v2/eventpatterns/db?
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 34
Name Type In Description
RESPONSE (Status Code: 200)
]
}
]
}
Get JMX Statistics
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 36
"GetProfileCount": "0",
"SetDebugCount": "0",
"SetAudienceAverage": "0.0",
"LoadOfferSuppressionDuration": "0",
"GetOffersCount": "1",
"LoadOffersBySQLCount": "0",
"LoadOffersBySQLAverage": "0.0",
"GetVersionCount": "0",
"EndSessionAverage": "0.0",
"StartSessionCount": "0",
"RunSegmentationDuration": "0",
"GetVersionAverage": "0.0",
"GetOffersAverage": "0.0"
Get Version
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 37
"statusCode": 0
Unica Interact Design time APIs
The following section includes the Rest APIs for Interact Design time objects.
Interactive Channel
These APIs are used to perform CRUD operations on Interactive Channel.
Objects
Attribute Name Type Description Required
Cr
Required
Up
name string Interactive channel name
description string Description of the interactive
channel
serverGroups string-
policyId number Security policy id x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 38
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
waitingForDeployment number Number of items waiting for
deployment
longestWaitTime string Longest wait time for an item x x
longestWaitDateTime bool Longest wait time available x x
lastDeploymentTime number Last Deployment Date in ms x x
Interactive Channel Object
For details, see the table in Objects (on page 37) topic.
Interactive Channel <interactive-channel-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 39
"updateBy": 0,
"updateDate": 0,
"waitingForDeployment": 0
Name Type In Description
page number query nth page to retrieve records. Default is 0 (first page).
size number query Number of records per page. Default is 10.
Response (Status Code: 200)
38) topic.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 40
Get Interactive Channels
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}
Response (Status Code: 200)
Create Interactive Channels
38) topic.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 41
"status": 201/400/500
REQUEST
RESPONSE (Status Code: 202)
Delete Interactive Channels
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}
RESPONSE (Status Code: 204)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 42
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}/audiencelevels
RESPONSE (Status Code: 200)
REQUEST
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 43
"joinType": 0,
"preLoad": true,
"tableName": "string",
"unmap": true
{
{
],
{
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}/
audienceLevel string query Name of Audience Level
RESPONSE (Status Code: 200)
{
Zone and Interaction Point Wrapper
These APIs are used to perform CRUD operations on zones and interaction
points.
Objects
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 46
Attribute Name Type Description Required
Cr
Required
Up
name string Zone name
interactionPoints array-
percentRandom number Random Percentage
resolve non-uniform learning
this level; inherit setting
• 2: Use Marketer score
• 3: Use Learning score
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 47
learningModelID number Learning Model id
Zone - object
Zone <zone-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 48
Parameters
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
Response (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 49
Name Type In Description
zoneIdOrName string path Zone id or name
RESPONSE (Status Code: 200)
Create Zones
REQUEST
{
}
]
zoneIdOrName string path Zone id or name
REQUEST
RESPONSE (Status Code: 202)
Delete a Zone or Interaction Points
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/zones/
zoneIdOrName string path Zone id or name
onlyIP bool query Flag to delete only interaction points from
zone.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 51
RESPONSE (Status Code: 200)
ids string query comma separated Zone IDs to be deleted.
RESPONSE (Status Code: 200)
These APIs are used to perform CRUD operations on categories.
Objects
Attribute Name Type Description Required
Cr
Required
Up
name string Zone name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 52
systemDefined bool Indicates system defined category x x
Category - Objects
Category<category-object>
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
RESPONSE (Status Code: 200)
{
],
zoneIdOrName string path Zone id or name
RESPONSE (Status Code: 200)
Create Category
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 54
Name Type In Description
REQUEST
{
categoryIdOrName string path Category id or name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 55
REQUEST
RESPONSE (Status Code: 202)
Delete Category
categoryIdOrName string path Category id or name
RESPONSE (Status Code: 200)
ids string query Comma separated Category IDs to be deleted.
RESPONSE (Status Code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 56
Event
These APIs are used to perform CRUD operations on Events.
Objects
Event Object
Cr
Required
Up
Name string Event name
eventType Number Event type
Object
Object
Object
Object
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 57
executeExpression object Predefined Event Action
Object
Object
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
The Predefined Event Action Object
Attribute Name Type Description Required
Cr
Required
Up
conditions array-object List of Event Action Condition Object
The Event Action Condition Object
Attribute Name Type Description Required
Cr
Required
Up
name string Parameter name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 58
value string Parameter Value
Cr
Required
Up
• 6: Event Action Inferred
• 0
• 1
isAsync bool Async event action
executionOrder number Event action execution order
details string Event action details
Event Action Expression Object
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 59
fieldName string Field Name
Cr
Required
Up
description string Description of the zone x x
systemDefined bool Indicates system defined category x x
Events - object
Event <event-object>
"category": <category-object>,
"createBy": 0,
"createDate": 0,
"description": "string",
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 60
"name": "string",
"pattern": null,
"triggerResegmentation": <predefined-event-action-object>,
"updateBy": 0,
"updateDate": 0
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 61
"id": 0,
"name": "string",
"value": "string"
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 62
Parameters
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 63
Name Type In Description
eventIdOrName string path Event id or name
RESPONSE (Status code: 200)
Create Events
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 64
"status": 201/400/500
eventIdOrName string path Event id or name
REQUEST
RESPONSE (Status code: 202)
Delete Events
eventIdOrName string path Event id or name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 65
RESPONSE (Status Code: 200)
ids string query Comma separated Event IDs to be deleted.
RESPONSE (Status Code: 200)
No Content.
Event Pattern
These APIs are used to perform CRUD operations on event patterns.
Objects
Event Pattern Object
Cr
Required
Up
Name string Event name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 66
description string Description of the event
eventType Number Event type
Object
Object
Object
Object
Object
Object
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 67
The Predefined Event Action Object
Attribute Name Type Description Required
Cr
Required
Up
conditions array-object List of Event Action Condition Object
The Event Action Condition Object
Attribute Name Type Description Required
Cr
Required
Up
name string Parameter name
value string Parameter Value
Cr
Required
Up
• 6: Event Action Inferred
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 68
• 0
• 1
isAsync bool Async event action
executionOrder number Event action execution order
details string Event action details
Event Action Expression Object
Cr
Required
Up
Cr
Required
Up
description string Description of the zone x x
systemDefined bool Indicates system defined category x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 69
Pattern Object
• 1: And
• 2: Counter
• 3: Score
async bool Async event pattern
startTime number Start time in Millis
endTime number End time in Millis
timeDuration number Time duration
matchTotal number Number of occurrences of the selected
event when pattern fires
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 70
Event Pattern item Object
Cr
Required
Up
name string Pattern item name
value number Pattern item value
attributes array-object Parameter Object
Cr
Required
Up
name string Parameter name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 71
Reset Pattern Object
Cr
Required
Up
type number Reset pattern type
• 0: None
• 1: Inactivity
• 2: Periodic
eventId number Event id to trigger after reset
Event Pattern - object
Event pattern <event-pattern-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 72
"createDate": 0,
"description": "string",
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 73
"name": "string",
"value": "string"
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 74
"endTime": 0,
{
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
RESPONSE (Status code: 200)
For <event-pattern-object>, see the Event Pattern - object (on page 71)
topic.
{
eventIdOrName string path Event id or name
RESPONSE (Status code: 200)
Create Event Pattern
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 77
Parameters
REQUEST
For <event-pattern-object>, see the Event Pattern - object (on page 71)
topic.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 78
Name Type In Description
REQUEST
RESPONSE (Status code: 202)
Delete Event Pattern
eventIdOrName string path Event id or name
RESPONSE (Status code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 79
icIdOrName string path Interactive Channel id or name
ids string query comma separated Event IDs to be deleted.
RESPONSE (Status code: 200)
Strategy
Description
These APIs are used to perform CRUD operations on the strategy.
Objects
Strategy Object
Cr
Required
Up
Required
Cp
name string Strategy name
strategy
campaignName string Linked campaign
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 80
interactiveChannelName string Interactive channel
createDate number Created date in Millis x x x
updateBy number Updated by user x x x
updateDate number Update date in Millis x x x
ruleCount number Rule count in strategy x x x
lastProdDepTime number Last production
Strategy <strategy-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 81
"updateDate": 0
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
mode string query If value is recent, it returns 5 recently updated
strategies. (Optional)
API are not valid.
more details, check the
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 82
<strategy-object>
strategyIdOrName string path Strategy id or name
RESPONSE (Status code: 200)
Create Strategy
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 83
Strategy - object (on page 80)
RESPONSE (Status code: 201)
Update Strategy
strategyIdOrName string path Strategy id or name
REQUEST
RESPONSE (Status Code: 202)
Delete Strategy
strategyIdOrName string path Strategy id or name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 84
RESPONSE (Status code: 200)
REQUEST
RESPONSE (Status code: 201)
Smart Rule
These APIs are used to perform CRUD operations on the Smart Rules.
Objects
Smart Rule Object
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 85
id number Unique id
segmentId number Segment id
cellId number Cell id
zoneId number Zone id
offerId number Offer id
offerType number Type of offer
• 0: Offer
• 1: OfferList
offerAttrExpressions array-
ruleGroups array-
score number Score
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 86
scorePredicateEnabled bool Enable / Disable score
predicate
eligibilityPredicateEnabled bool Enable / Disable eligibility
predicate
learningMode number Learning mode
• 2: Use Marketer score
• 3: Use Learning score
maxScore number Max Score
suppressCount number Suppression count
Offer Selection Policy Object
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 87
Cr Up
num number Number of offers to return from offer list
opt number Allowed offer selection policy
param string Parameter x x
sort string Sort by x x
Offer Attribute Expression Object
Cr
Required
Up
Smart Rule Group Object
Cr
Required
Up
description string Description of the smart rule group x x
A/B test Branch Object
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 88
branchId number Unique id
enabled bool Enable / Disable A/B testing branch
isDefault bool Indicates A/B testing default branch
samplePercent number Sample percentage for A/B testing
branch
cellId number Cell id
offerId number Offer id
offerAttributes array-
Object
Smart Rule - object
Smart Rule <smart-rule-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 89
"eligibilityPredicateEnabled": true,
"eligibilityPredicateId": 0,
"enabled": true,
"expirationDate": 0,
"groupByOfferName": "string",
"hasABTest": true,
"id": 0,
"learningMode": 0,
"learningModelId": 0,
"lmName": "string",
"maxScore": true,
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 90
"zoneName": "string"
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 92
icIdOrName string path Interactive Channel id or name
strategyIdOrName string path Strategy id or name
page number query nth page to retrieve records. Default is 0
(first page).
size number query Number of records per page. Default is
10.
abtOnly bool query If value is true, it returns smart rules
with A/B testing data. (Optional)
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 93
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName string path Strategy id or name
ruleIdOrName string path Smart rule id or name
RESPONSE (Status code: 200)
Save Smart Rules
POST /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName string query Strategy id or name
REQUEST
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 94
"toDelete": [
0
strategyIdOrName string path Strategy id or name
ids string query comma separated Smart rule IDs to be
deleted.
Description
These APIs are used to perform (un) deploy operations on the strategy.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 95
Objects
Strategy deployment Object
Cr
Required
Up
lastProdDepTime date Last production deployment
time
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 96
lastMarkTime date Last (un) marked for (un)
deployment time
x x
Strategy Deployment - object
Strategy Deployment<strategy-deployment-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 97
icIdOrName string path Interactive Channel id or name
strategyIdOrName string path Strategy id or name
RESPONSE (Status Code: 200)
Mark for (Un) Deployment
PUT /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName string path Strategy id or name
REQUEST
RESPONSE (Status code: 202)
Cancel mark for (Un) Deployment
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 98
strategyIdOrName string path Strategy id or name
REQUEST
RESPONSE (Status Code: 200)
Smart Rule Group
These APIs are used to perform CRUD operations on the Smart Rule Group.
Objects
Smart Rule Group Object
Cr
Required
Up
name string Smart Rule Group name
description string Description of the Smart Rule Group
strategyId number Strategy id x x
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 99
ruleIdList array-number List of Smart rule ids x x
Smart Rule Group - object
Smart Rule Group <smart-rule-group-object>
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 100
strategyIdOrName string query Strategy id or name
page number query nth page to retrieve records. Default is 0
(first page).
size number query Number of records per page. Default is
10.
For <smart-rule-group-object>, see the Smart Rule Group - object (on page
99) topic.
GET /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 101
Name Type In Description
strategyIdOrName string query Strategy id or name
ruleIdOrName string query Smart rule id or name
page number query nth page to retrieve records. Default is 0
(first page).
size number query Number of records per page. Default is
10.
For <smart-rule-group-object>, see the Smart Rule Group - object (on page
99) topic.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 102
POST /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName string query Strategy id or name
REQUEST
RESPONSE (Status Code: 201)
Update Smart Rule Group
PUT /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName String query Strategy id or name
ruleGroupIdOrName String query Smart rule group id or name
REQUEST
RESPONSE (Status Code: 202)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 103
Delete Smart Rule Group
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/strategies/
strategyIdOrName string query Strategy id or name
ruleGroupIdOrName string query Smart rule group id or name
RESPONSE (Status Code: 200)
These APIs are used to perform CRUD operations on FlexOffers.
Objects
FlexOffers Object
Cr
Required
Up
offerMappingName string FlexOffers name
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 104
offerMappingDesc string Description of the FlexOffers
delimiter string Delimiter used to parse csv
fields array-
filterfields array-
override bool Override FlexOffers
serverGroups array-
Object
sourceSG string Source server group name
lastProdDepTime number Last production deployment time in
Millis
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
FlexOffers Attribute Object
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 105
dynamic bool Is attribute dynamic?
relation string Relational operator
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 106
table string Table name specific to Server Group
FlexOffers - object
FlexOffers <flexoffers-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 107
FlexOffers Attribute <flex-offer-attribute-object>
{
icIdOrName string path Interactive Channel id or name
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
RESPONSE (Status code: 200)
{
RESPONSE (Status code: 200)
Create FlexOffers
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 109
POST /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers
RESPONSE (Status code: 201)
POST /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
file multipart-file form-data CSV File
REQUEST
RESPONSE (Status code: 201)
Update FlexOffers
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 110
Name Type In Description
REQUEST
RESPONSE (Status code: 202)
Copy FlexOffers
targetServerGroup string query Target Server Group name
REQUEST
RESPONSE (Status code: 202)
Delete FlexOffers
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 111
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers//
RESPONSE (Status code: 200)
Name Type In Description
all bool query Get all server group flag. (Default: false) (Optional)
RESPONSE (Status code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 112
Name Type In Description
RESPONSE (Status code: 200)
GET /Campaign/api/interact/rest/v2/tables
RESPONSE (Status code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 113
FlexOffers Rules
These APIs are used to perform CRUD operations on FlexOffers rules.
Objects
FlexOffers Rule Object
Cr Up
enabled bool Enable / Disable rule
eligibilityPredicateEnabled bool Enable / Disable eligibility predicate
eligibilityPredicateId number Predicate id for eligibility x
eligibilityPredicate string Predicate to define eligibility
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 114
effectiveDate number Effective date in Millis
expirationDate number Expiration date in Millis
score number Score
scorePredicateId number Predicate id for score x
learningMode number Learning mode
inherit setting
offerAttrExpressions array-
userdefinedFields array-
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 115
Offers Attribute Expression Object
Cr
Required
Up
Offer Mapping Attribute Object
Cr
Up
relation string Relational operator
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 116
type string Data type
FlexOffers Rule<flexoffers-rule-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 117
"offerAttrExpressions": [
<offer-attribute-expression-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 118
"displayName": "string",
"name": "string",
"relation": "EQUAL",
"size": 0,
"type": "STRING",
condition map query Key-Value pair
• Ex. OfferName=eq;OfferA
page number query nth page to retrieve records. Default is 0
(first page).
size number query Number of records per page. Default is
10.
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 119
<flex-offer-rule-object>
flexofferIdOrName string path FlexOffers id or name
ruleIdOrName string path FlexOffers Rule id or name
RESPONSE (Status code: 200)
Save FlexOffer Rules
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 120
Parameters
flexofferIdOrName string path FlexOffers id or name
REQUEST
FlexOffers Rule - object (on page 116) topic.
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 121
DELETE /Campaign/interact/api/v2/channels/{icIdOrName}/flexoffers/
flexofferIdOrName string path FlexOffers id or name
ids string query Comma separated rule IDs to be deleted.
RESPONSE (Status code: 200)
GET /Campaign/interact/api/v2/preview/systemcolumns
116) topic.
}
}
FlexOffers Filters
These APIs are used to perform CRUD operations on FlexOffers filters.
Objects
FlexOffers Filter Object
Cr
Required
Up
name string Filter name
isDefault bool Is default filter?
offerMappingId number Flex Offer id x x
filters array-object List of Flex Offer Attribute Object
createBy number Created by user x x
createDate number Created date in Millis x x
updateBy number Updated by user x x
updateDate number Update date in Millis x x
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 123
FlexOffers Attribute Object
Cr
Required
Up
dynamic bool Is attribute dynamic?
relation string Relational operator
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 124
value object Attribute Value
FlexOffers Filter<flexoffers-filter-object>
}
condition map query Key-Value pair
• Ex. OfferName=eq;OfferA
page number query nth page to retrieve records. Default is 0
(first page).
size number query Number of records per page. Default is
10.
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 126
"size": 0,
"totalElements": 0,
"totalPages": 0
Get FlexOffers Filters
GET/Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
{flexofferIdOrName}/filters/ {filterByIdOrName}
flexofferIdOrName string path FlexOffers id or name
filterByIdOrName string path FlexOffers Filter id or name
RESPONSE (Status code: 200)
Create FlexOffers Filters
POST/Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 127
flexofferIdOrName string path FlexOffers id or name
REQUEST
RESPONSE (Status Code: 200)
Update FlexOffers Filters
PUT/Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
{flexofferIdOrName}/filters/{filterIdOrName}
filterByIdOrName string path Flex Offer Filter id or name
mode[ML1] string query Filter mode (Optional)
• copy
REQUEST
RESPONSE (Status Code: 202)
Delete FlexOffers Filters
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 128
DELETE/Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
{flexofferIdOrName}/filters/{filterIdOrName}
filterByIdOrName string path Flex Offer Filter id or name
RESPONSE (Status Code: 200)
No content
FlexOffers Deployment
These APIs are used to perform CRUD operations on the FlexOffers for
deployment.
Objects
FlexOffers Deployment Object
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 129
• cancelUnDeploy
lastProdDepTime date Last production deployment
time
deployment time
x x
FlexOffers Deployment - object
FlexOffers Deployment <flexoffers-deployment-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 130
"deploymentWaitMessage": "string",
"dirty": true,
"lastMarkTime": "2021-01-01T01:02:03.456Z",
"lastProdDepTime": "2021-01-01T01:02:03.456Z",
"state": 0
RESPONSE (Status Code: 200)
Mark for (Un) Deployment
PUT /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 131
REQUEST
RESPONSE (Status code: 202)
Cancel mark for (Un) Deployment
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flexoffers/
REQUEST
RESPONSE (Status Code: 200)
Gateway
Description
These APIs are used to perform CRUD operations on Gateway.
Objects
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 132
Gateway Object
Cr
Required
Up
Required
Cp
Name string Gateway name
audienceLevel string Audience Level
Type number Gateway type
defaultCellCode string Default Cell Code x x x
contentMapping array-
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 133
templateId string Deliver Template Id
templateName string Deliver Template Name
templateType string Deliver Template Type
appId number Mobile App Id
appName string Mobile App Name
createBy number Created by user x x x
createDate number Created date in Millis x x x
updateBy number Updated by user x x x
updateDate number Update date in Millis x x x
Content Mapping Object
Cr
Required
Up
Required
Cp
• string
• numeric
• datetime
defaultValue object Default Value
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 134
custom bool Is custom attribute?
dateFormat string Date Format
Cr Up Cp
contentMapping array-object List of Content Mapping Object
Gateway - object
Gateway <gateway-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 135
"expirationDate": 0,
"icId": 0,
"id": 0,
"name": "string",
"noOfMessages": 0,
"priority": 0,
"templateId": "string",
"templateName": "string",
"templateType": "string",
"type": 0,
"updateBy": 0,
"updateDate": "2021-05-19T08:19:46.328Z"
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 136
"endpointEvent": "string",
"interactEvent": "string"
typeId number query Gateway type
• 1: Generic Outbound
• 2: Generic Inbound
• Journey Inbound
page number query nth page to retrieve records. Default is 0 (first
page).
size number query Number of records per page. Default is 10.
RESPONSE (Status Code: 200)
{
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 137
"size": 0,
"totalElements": 0,
"totalPages": 0
gatewayId number path Gateway id
RESPONSE (Status Code: 200)
Create Gateway
REQUEST
RESPONSE (Status code: 201)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 138
Gateway - object (on page 134)
Copy Gateway
gatewayId number path Gateway id
REQUEST
RESPONSE (Status code: 201)
Update Gateway
gatewayId number path Gateway id
REQUEST
RESPONSE (Status code: 202)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 139
Gateway - object (on page 134)
Delete Gateway
gatewayId number path Gateway id
RESPONSE (Status code: 200)
Objects
Interactive Channel Deployment Object
Cr
Required
Up
rtUsername string Interact run time username
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 140
rtPassword string Interact run time user password
serverGroup string Server Group name
serverGroupType string Server Group type
• 1: Production
• 2: Test
• 1: Deploy
• 2: Undeploy
includeGlobal bool query Include global data or not in the task.
(Default: true)
REQUEST
}
Interactive Flowchart Process Box
These APIs are used to perform CRUD operations on Interactive flowchart
process box.
Interactive Flowchart Process Box
Cr
Required
Up
notes string Description of the process
box
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 142
processBoxConfiguration object Process Box Configuration
Object
• Interaction
• Decision
• PopulateSeg
• Select
Process Box <process-box-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 143
Process Box Configuration: Decision
},
]
}
{
"selectAllIds": false,
"expression": "Expression is provided in case selectAllIds is false not
otherwise eg: CUSTOMERID < 30"
sessionId number query Session id
RESPONSE (Status Code: 200)
[
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 145
Parameters
sessionId number query Session id
RESPONSE (Status Code: 200)
Create Process Box
sessionId number query Session id
REQUEST
RESPONSE (Status code: 201)
[
]
sessionId number query Session id
REQUEST
RESPONSE (Status code: 200)
Delete Process Box
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 147
pbIds string query Comma separated process box IDs to
be deleted.
RESPONSE (Status code: 200)
No content
Interactive Flowchart
These APIs are used to perform CRUD operations on interactive flowcharts.
Objects
Interactive Flowchart Option
Cr
Required
Up
Interactive Flowchart Response
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 148
displayName string Display name
description string Description of the Flowchart
audienceName string Audience name
sessionId number Session id
sessionName string Session name
retired bool Is retired?
createDate string Created date
Cr
Required
Up
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 149
• 2: MARK_FOR_DEPLOYMENT
• 3: MARK_FOR_UN_DEPLOYMENT
lastProdDepTime date Last production deployment time
lastMarkTime date Last (un) marked for (un) deployment time
Interactive flowchart - object
Interactive Flowchart Option <interactive-flowchart-option-object>
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 150
"fileName": "string",
"flowchartId": 0,
"flowchartName": "string",
"name": "string",
"retired": true,
"sessionId": 0,
"sessionName": "string"
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 151
sessionId number query Session id
REQUEST
RESPONSE (Status code: 200)
Validate Interactive Flowchart
sessionId number query Session id
RESPONSE (Status code: 200)
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 152
flowchartIdOrName string path Interactive Flowchart id or name
sessionId number query Session id
RESPONSE (Status code: 200)
sessionId number query Session id
RESPONSE (Status code: 200)
page 149) topic.
Unica Interact V12.1 Rest API | 1 - Rest API Guide | 153
flowchartIdOrName string path Interactive Flowchart id or name
sessionId number query Session id
REQUEST
page 149) topic.
page 149) topic.
DELETE /Campaign/api/interact/rest/v2/channels/{icIdOrName}/flowcharts/
sessionId number query Session id
RESPONSE (Status code: 200)
Contents
Authentication
Events
Event Pattern State
Statistics
Interactive Channel
Zone and Interaction Point Wrapper
Objects
Delete multiple zones
Event Action Object
Event Action Object
Smart Rule Group
Get Smart Rule Groups by Smart Rule
Create Smart Rule Group
Update Smart Rule Group
Delete Smart Rule Group
Update FlexOffers
Copy FlexOffers
Delete FlexOffers
FlexOffers Rules
FlexOffers Filters
Gateway
Objects