0% found this document useful (0 votes)
1K views

En UCS 9.1.x RESTAPI Book

This document provides an overview and reference guide for the Universal Contact Server (UCS) API. It details the RESTful services and methods that can be accessed directly by clients, as well as the ESP services and methods that are accessed via the Genesys PSDK. The guide describes HTTP request formatting, including HTTP verbs, headers, URIs, and message bodies. It explains the methods used in UCS (POST, PUT, GET, DELETE) and how to structure requests for each. Syntax examples are provided for POST and PUT requests. The document also includes a table of contents listing the various UCS services, methods, and other sections covered in the guide.

Uploaded by

Marcos Antonio
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views

En UCS 9.1.x RESTAPI Book

This document provides an overview and reference guide for the Universal Contact Server (UCS) API. It details the RESTful services and methods that can be accessed directly by clients, as well as the ESP services and methods that are accessed via the Genesys PSDK. The guide describes HTTP request formatting, including HTTP verbs, headers, URIs, and message bodies. It explains the methods used in UCS (POST, PUT, GET, DELETE) and how to structure requests for each. Syntax examples are provided for POST and PUT requests. The document also includes a table of contents listing the various UCS services, methods, and other sections covered in the guide.

Uploaded by

Marcos Antonio
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 347

Universal Contact Server API

Guide
Universal Contact Server 9.1.x

3/17/2020
Table of Contents
Universal Contact Server API Reference Guide 6
New/Changed Behaviors in UCS 9.1 9
Deprecated Methods 16
Callback 19
Close 20
Create 21
Update 23
Chat 24
Close 25
Create 26
Update 28
Contact 29
findOrCreate 30
Identify 32
Update 35
Index 37
GetIndexProperties 38
Search 40
Ixn 45
AssignToContact 46
StopProcessing 47
Metadata Web Service Methods 48
ProfileSchemaResource 49
queryProfileSchema 50
ProfileExtensionSchemaResource 54
deleteProfileExtensionSchema 55
queryProfileExtensionSchema 58
IdentificationKeysResource 61
deleteIdKeySchema 62
queryIdKeySchema 64
ProfileExtensionSchemasResource 67
createProfileExtensionsSchema 68
queryProfileExtensionsSchema 72
IdentificationKeysSchemasResource 75
queryIdentificationKeysSchema 76
createIdentificationKeysSchema 78
Metrics 82
GetAll 83
GetCore 85
GetTopTimers 87
OMContacts 89
ContactListGet 90
ContactListGetNextPage 101
ContactListRelease 103
Delete 104
GetAttributes 105
GetContacts 110
GetMergeDetail 113
IdentifyContact 117
Insert 120
MergeContacts 123
MergeListGet 126
MergeListGetNextPage 128
MergeListRelease 130
RemoveAllAttributes 131
UnMergeContacts 133
UpdateAttributes 135
OMFieldCodes 142
RenderFieldCodes 143
RenderMessageContent 147
ValidateFieldCodes 149
OMInteraction 151
Create 152
Update 154
OMInteractions 156
AddDocument 157
AssignInteractionToContact 159
CountInteractions 161
DeleteInteraction 163
FindOrCreatePhoneCall 164
GetAttachment 168
GetCategorizedInteractions 170
GetDocument 173
GetInteractionContent 175
GetInteractionsForContact 178
GetInteractionsWithStatus 184
GetUnCategorizedInteractions 186
InsertInteraction 189
InteractionListGet 200
InteractionListGetNextPage 207
InteractionListRelease 209
RemoveDocument 210
SetInteractionStatus 211
StopInteraction 213
UpdateDocument 215
UpdateInteraction 216
OMResponse 221
CheckForUpdates 223
GetAgentStdRespFavorites 225
GetAllGroups 227
GetAllRegEx 229
GetAllRules 231
GetAllTestMessage 234
GetCategory 236
GetCategoryAttribute 239
GetCategoryAttributes 241
GetDocument 243
GetFieldCode 245
GetFieldCodes 247
GetFieldValue 248
GetFieldValues 250
GetGroup 251
GetGroupContent 254
GetRegEx 256
GetRootCategories 258
GetRule 260
GetScreeningRule 263
GetScreeningRules 265
GetStandardResponse 267
GetStandardResponses 271
GetTestMessage 275
GetUpdates 277
ProfileService Methods 281
CustomerProfileResource 282
deleteCustomerProfile 283
queryCustomerProfile 285
updateCustomerProfile 288
ProfilesResource 292
createProfile 293
identifyProfiles 297
Profile ExtensionsResource 301
insertExtensionRecord 302
UpdateRecordInProfileExtension 305
updateRecordInProfileExtension 306
DeleteRecordInProfileExtension 309
deleteRecordInProfileExtension 310
ProfileService importProfileRecords 313
importProfileRecords 314
ProfileServiceMergeUnmerge 319
mergeProfiles 320
unmergeProfiles 323
unmergeProfilesAsSource 325
System Information 327
GetIdentifier 328
GetServerTime 329
GetSystemSettings 330
GetVersion 334
URS Service 335
UpdateInteraction 336
GetFAQObject 337
Data Segmentation 339
Universal Contact Server API Reference Guide

Universal Contact Server API Reference Guide


This is the UCS 9.1 API Reference Guide.

It details, within the same topic:

• RESTful services and methods, which can be accessed by clients directly.

• ESP services and methods, which are accessed via Genesys PSDK.

Overview

HTTP Requests
An HTTP request needs the following elements:

• An HTTP verb (or method).

• A header

• A URI (Uniform Resource Identifier) which identifies the resource upon which to apply the request

• An optional message body

HTTP Responses
• Responses contain a list of '<key>:<value>' entries in JSON format.

• In the ESP protocol some UCS functions return some <key>:<value> entries in parameters and some others in user
data. When used through HTTP those functions return all <key>:<value> entries in a unique JSON document.

The functions that behave this way are:

• Callback.Create

• Chat.Create

• Contact.findOrCreate

• Contact.Identify

• OMFieldCodes.RenderMessageContent

Methods
In UCS the following methods are used: POST, PUT, GET and DELETE.

The general rule is:

• POST when method creates a new object

Universal Contact Server API Guide 6


Universal Contact Server API Reference Guide

• PUT when the method updates an object

• GET when the method reads object content

• DELETE when the method deletes an object

URI Form
The URI is built as follows:

• POST and PUT methods:

<http|https>://<ucs host>:<port http or https>/<optional base url>/ucs/v1/<ucs service>/<ucs method>

• GET and DELETE methods:

<http|https>://<ucs host>:<port http or https>/<optional base url>/ucs/v1/<ucs service>/<ucs method>?<key1>=<val

The optional base URL corresponds to the value of the option base-url in the http section.

Syntax for POST and PUT


Syntax when using the verbs POST and PUT:

<verb> http://<host>:<port>/<base url>/ucs/v1/<service>/<method>

{
"Parameters": {
"key1": value1,
"key2": value2
...
},
"UserData": {
"key3": value3,
"key4": value4,
...
}
}

where:

• <verb> depends on the type of operation

• <service> is UCS's service name

• <method> is UCS's method name

• "Parameters" contains a JSON document with parameters

• "UserData" contains a JSON document with user data (not used by PSDK but used by ChatServer, URS and
IXNServer.)

And:

• Key-value pairs are separated with comma.

Universal Contact Server API Guide 7


Universal Contact Server API Reference Guide

• Each key is surrounded with "

• Values of type string are surrounded with "

• Values of type integer are not surrounded with "

A value of type binary must be base64 encoded and provided with a key named ‘binary’. Here is an example
using InsertInteraction with a binary content:

POST http://<host>:<port>/<base url>/ucs/v1/OMInteractions/InsertInteraction

{code}
{
"InteractionContent":{
"MimeType":"Base64",
"Content":{
"binary":"SGVsbG8gVW5pdmVyc2UgIQ=="
}
},
"InteractionAttributes":{
"Status":1,
"TenantId":101,
"TypeId":"Internal",
"EntityTypeId":7,
"MediaTypeId":"email"
}
}
{code}

Syntax for GET and DELETE


Syntax when using verb GET and DELETE:

<verb> http://<host>:<port>/<base url>/ucs/v1/<service>/<method>?<key1>=<value1>&<key2>=<value2>...

In this case the request does not have a body, all parameters are provided in the URL. The parameters come after
the character '?'. They are key-value pairs separated with character '&'. The syntax for each parameter is
<key>=<value> except for the following:

• ESQuery (in GetInteractions, InteractionListGet and ContactListGet) must be JSON-formatted. It


should contain an Elasticsearch 5.5-compliant request (documentation is at https://www.elastic.co/guide/en/
elasticsearch/reference/5.5/query-dsl.html).

• OwnerIds in requests GetCategorizedInteraction and GetUnCategorizedInteraction must be JSON-


formatted and the character ':' must be used instead of '='.

• AttributeList (in InteractionListGet or ContactListGet) must be provided as a JSON array—for


example:AttributeList={"AttrName":["Subject","Id"]}

• SearchCriteria (in InteractionListGet or ContactListGet) must be provided as a JSON object—for example:


SearchCriteria={"EQUAL":{"AttrName":"CreatorAppId","AttrValue":169}}

• SortCriteria (in InteractionListGet or ContactListGet) must be provided as a JSON object—for example:


SortCriteria={"StartDate":"ASC"}

Universal Contact Server API Guide 8


New/Changed Behaviors in UCS 9.1

New/Changed Behaviors in UCS 9.1


This topic describes important changes in API behaviors between 8.5 and 9.1.

OMContacts.Insert and OMContacts.UpdateAttributes


OMContacts.Insert and OMContacts.UpdateAttributes no longer allow binary attributes (attributes with a binary
value), though UCS 8 supported them.

OMContacts/IdentifyContact, Contact/Identify, Contact/findOrCreate


By default the minimum attribute set to identify or create a contact is now:

• EmailAddress for media type email.

• PhoneNumber for media type voice.

In UCS 8.5 there was no minimum attribute set for those media.

To configure the same behavior in UCS 9.1.x as UCS 8.5, add the following option in the Annex tab of the media:

• settings/minimum-creation-attributes='' (keep the value empty)

FindOrCreatePhoneCall & Insert/Update Interaction


ParentId and ThreadId are set in OMInteractions.FindOrCreatePhoneCall The algorithm (detailed below) to
set the interaction ParentId and ThreadId for methods:

• OMInteractions.InsertInteraction

• OMInteractions.FindOrCreatePhoneCall

• Chat.Create

Universal Contact Server API Guide 9


New/Changed Behaviors in UCS 9.1

If (providedThreadId==null && providedParentId==null) new_ixn.ThreadId = NEW GENERATED ID

If (providedThreadId!=null && providedParentId==null) new_ixn.ThreadId = providedThreadId

If (providedParentId!=null) { /* if ThreadId is provided as well it is ignored */

if (providedParentId.exists()){
if (providedParentId.CanBeParent==true)
{
new_ixn.ThreadId = providedParent.ThreadId
new_ixn.ParentId = providedParent.Id
}
else{
Return error:
FaultCode=204
FaultString=Incorrect value for parameter 'ParentId', expected 'Parent Interaction with CanBeParent=true' but was 'Interaction '" + pr
}
}else{
Return error:
FaultCode=510
FaultString=Msg: Interaction 'providedParent.Id' not found in database
}
}

OMContacts/UpdateAttributes
OMContacts/UpdateAttributes inserting an attribute specified as primary (index 0 in the request) is now successful even if there is already a primary attribute. The new
attribute is set as primary and the previously primary attribute is kept as secondary. Previously (in 8.5), the request would fail.

OMContactsdon't allow binary attribute (attribute having a binary value) though it was possible with UCS 8.

Universal Contact Server API Guide 10


New/Changed Behaviors in UCS 9.1

OMContact.UpdateInteraction
Where a contact has already an email address, if you use OMContacts.UpdateInteraction to insert an address specified as primary (index 0 in the request) the
request is successful. The former primary adress has IsPrimary set to false and the new email address is the primary one.

UCS 9.1 supports such a request, which in UCS 8.x was rejected.

OMInteractions.InteractionListGet
In UCS 8.5 OMInteractions.InteractionListGet and OMInteractions.GetInteractionsForContact needed the parameters EntityTypeId to search
the tables EmailIn, EmailOut, Callback, Chat, PhoneCall. With no EntityTypeId only the Interaction table could be searched.

In UCS 9.1 the EntityTypeId is no longer needed. This allows queries across several media. For example a query with criteria like StartDate <=
2015-10-21T16:30:00.000Z will search matching interactions in EmailIn and EmailOut. In UCS 8.5, two requests were needed to do this.

Important
Note that it is still possible to filter data by EntityTypeId, thus keeping backward compatibility.

AddDocument method
Previously in UCS 8 there were two modes for the AddDocument method:

• Link creation mode—The required parameters were InteractionId and DocumentId (to link an interaction to an existing document).

• Document creation mode

Universal Contact Server API Guide 11


New/Changed Behaviors in UCS 9.1

In UCS 9.1, link creation mode is no longer present.

Chat.Update/Close

Important
This behavior has not changed in UCS 9.1 but was previously undocumented in UCS 8.

The following mechanism in Chat.Update and Chat.Close prevents two (or more) instances of ChatServer from updating the transcript of the same chat record
simultaneously:

• If VerifyCreatorId = true, UCS includes CreatorId in the condition to update the record.

• If VerifyCreatorId = false UCS uses the condition without CreatorId to update the record.

Attributes in Identification Keys


If an identification key uses two or more attributes, the profile identification request must provide all these attributes. If one attribute is missing the request will fail.

Example
1. Consider the following extension schema:

{
"name": "Subscription",
"type": "multi-valued",

Universal Contact Server API Guide 12


New/Changed Behaviors in UCS 9.1

"attributes": [
{
"name": "title",
"type": "string"
},
{
"name": "duration",
"type": "integer"
},
{
"name": "price",
"type": "double"
},
{
"name": "is_payed",
"type": "boolean"
},
{
"name": "new_offers",
"type": "boolean"
},
{
"name": "category",
"type": "integer"
}
]
}

2. .....and the identification key built on the attributes 'category' and 'new_offers':

{
"source": "Subscription",
"name": "IdSubscription",
"attributes": [
"category",
"new_offers"
]
}

3. The following identification request should be successful:

Universal Contact Server API Guide 13


New/Changed Behaviors in UCS 9.1

GET /profiles?Subscription.category=5?scription.new_offers=true&id_key=IdSubscription∈clude_profile=yes&extensions=Subscription

4. ...but the following request should fail in UCS 9.1 whereas it works in UCS 8 (this is due to a Cassandra limitation):

GET /profiles?Subscription.category=5&id_key=IdSubscription∈clude_profile=yes&extensions=Subscription

5. UCS 9.0 returns the error:

Missing parameter 'Subscription.new_offers'

Note that the following request fails in both UCS 8 and UCS 9.1:

GET /profiles?Subscription.new_offers=true&id_key=IdSubscription∈clude_profile=yes&extensions=Subscription

TenantId Parameter Required in Search for Attributes of Type Date


UCS 9.1 now requires the TenantId parameter to search for attributes of type date.

In UCS 8 it was possible to search for attributes of type date as follows:

Service=Index
Method=Search
Parameters={
IndexName="contact"
Query="CreatedDate:2015*"
}

This syntax is no longer possible with UCS 9.1. The following should be used:

Service=Index
Method=Search
Parameters={

Universal Contact Server API Guide 14


New/Changed Behaviors in UCS 9.1

IndexName="contact"
Query="CreatedDate:[2015-01-01T00:00:00.000Z TO 2015-12-31T23:59:59.000Z]"
TenantId=101
}

Searching for contact attributes of type date without the TenantId parameter will not find any result. Note that if TenantId is provided as part of the Lucene query, UCS will
use it, for example:

Service=Index
Method=Search
Parameters={
IndexName="contact"
Query="TenantId:101 AND LCA_TimeStamp_voice:[2015-01-01T00:00:00.000Z TO 2015-12-31T23:59:59.000Z]"
}

Also, if UCS has only one tenant, this tenant will be used by default.

Universal Contact Server API Guide 15


Deprecated Methods

Deprecated Methods
The following methods that were available in previous releases of UCS are deprecated in release 9.1:

• AddAgentStdResponseFavorite

• AddCategory

• AddCategoryAttribute

• AddCategoryRoot

• AddCategoryStatistics

• AddConfusionMatrix

• AddDocument

• AddEmailClassificationResult

• AddFAQObject

• AddFAQObjectCategories

• AddFieldCode

• AddFieldValue

• AddGlobalStatistics

• AddGroup

• AddModel

• AddRegex

• AddModel

• AddRule

• AddRuleToGroup

• AddScreeningRule

• AddStandardResponse

• AddStdReponseUsage

• AddTestMessage

• AddTestingResult

• AddTrainingDataObject

• AddTrainingEmail

• AddTrainingJob

• CompareAndSwapStatusOfTrainingJob

• CreateStandardResponseRevision

Universal Contact Server API Guide 16


Deprecated Methods

• DeleteAgtStdResponseFavorite

• DeleteCategory

• DeleteCategoryAttribute

• DeleteCategoryRoot

• DeleteCategoryStatistics

• DeleteConfusionMatrix

• DeleteEmailClassificationResult

• DeleteFAQObject

• DeleteFAQObjectCategories

• DeleteFieldCode

• DeleteFieldValue

• DeleteGlobalStatistics

• DeleteGroup

• DeleteModel

• DeleteRegex

• DeleteRule

• DeleteRuleFromGroup

• DeleteScreeningRule

• DeleteStandardResponse

• DeleteTestMessage

• DeleteTestingResult

• DeleteTrainingDataObject

• DeleteTrainingEmail
• DeleteTrainingJob

• MoveCategory

• MoveStandardResponse

• RemoveDocument

• RestoreStandardResponseRevision

• TrainingEmailListRelease

• UpdateCategory

• UpdateCategoryAttribute

• UpdateCategoryStatistics

• UpdateConfusionMatrix

• UpdateEmailClassificationResult

Universal Contact Server API Guide 17


Deprecated Methods

• UpdateFAQObject

• UpdateFAQObjectCategories

• UpdateFieldCode

• UpdateFieldValue

• UpdateGlobalStatistics

• UpdateGroup

• UpdateModel

• UpdateRegex

• UpdateRule

• UpdateRuleFromGroup

• UpdateScreeningRule

• UpdateStandardResponse

• UpdateTestMessage

• UpdateTestingResult

• UpdateTrainingDataObject

• UpdateTrainingEmail

• UpdateTrainingJob

Universal Contact Server API Guide 18


Callback

Callback
• Close

• Create

• Update

Universal Contact Server API Guide 19


Callback Close

Close

Purpose
For Callback

URL
• PUT /Callback/Close/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String true true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique id of
Id String true true
interaction

Universal Contact Server API Guide 20


Callback Create

Create

Purpose
Creates a Callback.

URL
• POST /Callback/Create/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


CreatorId Integer true true
CustomerNumberString true true
StartTime String true true
ExternalId String true true
TenantId Integer true true
Attempt Integer false true 1
Status Integer false true 0
CallResult Integer false true 28
Type Integer false true 0
Subject String false true
DN String false true
Location String false true
EndTime String false true
TimeShift Integer false true
CustomData String false true

Universal Contact Server API Guide 21


Callback Create

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique id for
Id String newly created true true
interaction

Universal Contact Server API Guide 22


Callback Update

Update

Purpose
For Callback

URL
• PUT /Callback/Update/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique id of
Id String interaction to true true
be updated
Attempt Integer false true
Status Integer false true
CallResult Integer false true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique id of
Id String true true
interaction

Universal Contact Server API Guide 23


Chat Update

Chat
• Close

• Create

• Update

Universal Contact Server API Guide 24


Chat Close

Close

Purpose
Closes a Chat record.

URL
• PUT /Chat/Close/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String true true
Transcript String false true
PersonId String false true
EstablishedDate String false true
ReleasedDate String false true
MimeType String false true
Status Integer false true
CreatorId Integer false true
VerifyCreatorId String false true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String false true

Universal Contact Server API Guide 25


Chat Create

Create

Purpose
Creates a Chat record.

URL
• POST /Chat/Create/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Subject String true true
CreatorId Integer true true
TenantId Integer true true
ExternalId String true true
StartDate String true true
TimeZone Integer true true
IdentifyCreateContact
Integer false true
MediaType String false true
Id String false true
ThreadId String false true
EstablishedDate String false true
ParentId String false true
ContactId String false true

UserData

Key ValueType Value Description Mandatory Unique Default


Contact.(ContactAttributeName)
String false false

Universal Contact Server API Guide 26


Chat Create

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String true true
InteractionId String true true
ThreadId String true true
Contact.(ContactAttributeName)
String false false
Present if
ContactId String ContactCreated false true
is true
True if a
contact was
created and
false if this
ContactCreated String true /false true true
interaction
was assigned
to an existing
contact.

Universal Contact Server API Guide 27


Chat Update

Update

Purpose
Updates a Chat record.

URL
• PUT /Chat/Update/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String true true
Transcript String false true
String-coded
PersonId String false true
Integer
EstablishedDate String false true
MimeType String false true
Status Integer false true
CreatorId Integer false true
VerifyCreatorId String false true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String false true

Universal Contact Server API Guide 28


Contact Update

Contact
• findOrCreate

• Identify

• Update

Universal Contact Server API Guide 29


Contact findOrCreate

findOrCreate

Purpose
Find or create a Contact record.

URL
• POST /Contact/findOrCreate/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true

UserData

Key ValueType Value Description Mandatory Unique Default


[ContactAttribute Contact
StringIntegerBinaryKVList false false
name] attribute info

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Number of
ContactsFound Integer matching true true
Contacts

Universal Contact Server API Guide 30


Contact findOrCreate

Key ValueType Value Description Mandatory Unique Default


List of
ContactsList KVList matching false false
Contact Ids
[ContactAttribute Contact
StringIntegerBinaryKVList false false
name] attribute info

Error

Error

FaultCode FaultString Description


TenantId was not provided but is a
201 Missing parameter 'TenantId'
required parameter.
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 31


Contact Identify

Identify

Purpose
This method is intended for identifying a Contact based on user data values. If one or more Contact is found, the
Contact identifiers are returned. If no matching Contact is found, a new Contact may be created.

URL
• POST /Contact/Identify/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


If more than 1
contact is
found, and
ReturnUnique
ReturnUnique String true or false is true, UCS false true false
won't return a
sublist of
found contact
Ids
Get creation
strategy from
Media
CreateContact String true or false false true configuration
if any,
otherwise, use
true
UpdateUserData String false true

Universal Contact Server API Guide 32


Contact Identify

UserData

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Number of
matching
Contacts.
Cannot be
superior to 1 if
"CreateContact"
NumberOfContactsFound
Integer true true
parameter is
true. Cannot
be higher than
the configured
schema/
select-limit.
List of
matching
Contact Ids.
ContactIdList String false false
Contains
(NumberOfContactsFound)
Ids.
true if a
Contact has
ContactCreated String true or false been created true true
as a result of
this call
Id of the
matching
ContactId String false true
Contact if
unique
Agent who
handled
LastCalledAgent_EmployeeID
String false false
previous
interaction
LastCalledAgent_TimeStamp
String false false
PreferredAgent_EmployeeID
String false false
EmailAddress String false false
PhoneNumber String false false

Universal Contact Server API Guide 33


Contact Identify

Key ValueType Value Description Mandatory Unique Default


FirstName String false false
LastName String false false

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 34


Contact Update

Update

Purpose
Update (and insert) primary attributes of a Contact.

URL
• PUT /Contact/Update/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


UseDataFromParameters
String true true

UserData

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
ContactId String true true
EmailAddress String false false
PhoneNumber String false false
FirstName String false false
LastName String false false
DatePattern String false false

Universal Contact Server API Guide 35


Contact Update

Error
FaultCode FaultString Description
TenantId was not provided but is a
201 Missing parameter 'TenantId'
required parameter.
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
ContactId was not provided but is a
201 Missing parameter 'ContactId'
required parameter.
Missing parameter UseDataFromParameters was not
201
'UseDataFromParameters' provided but is a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 36


Index Update

Index
• GetIndexProperties

• Search

Universal Contact Server API Guide 37


Index GetIndexProperties

GetIndexProperties

Purpose
This service aims to return the configured indexes' searchable fields.

URL
• GET /Index/GetIndexProperties/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of
Indexes KVList configured true true
indexes.

Fields KVList

Key ValueType Value Description Mandatory Unique Default


(Index Name)
is the name of
a configured
index.
(Index Name) KVList false true
It is matching
names configured
within UCS
indexing options.

Universal Contact Server API Guide 38


Index GetIndexProperties

(Index Name) KVList

Key ValueType Value Description Mandatory Unique Default


Description String false true
Fields KVList true true

Fields KVList

Key ValueType Value Description Mandatory Unique Default


(Field Name) KVList false true

(Field Name) KVList

Key ValueType Value Description Mandatory Unique Default


Is true if the
field can be
IsSearchable String true or false true true
searched in a
query.
Is true if the
field can be
returned with
a document.
Note: An
index can
contain
different types
IsSorted String true or false of documents. true true
(Example:
Contact,
ContactAttribute).
Therefore, the
entire set of
stored field
might not be
returned.

Universal Contact Server API Guide 39


Index Search

Search

Purpose
A generic interface used for searching UCS indexing service. The Indexing service is configurable to parse and
index content of SRLs, Contacts or Interactions. In this document, those three different types of UCS objects will be
called 'Documents'.

UCS should use event-based indexing (modified properties in documents will be re-indexed). This interface only
reflects the interface used for querying UCS Documents: it does not describe configuration of the indexing service.

URL
• GET /Index/Search/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
object that
needs to be
queried in
UCS indexing
service.
No guaranteed
values, names
IndexName String any are customizable. true true
Possible values
by default in
template:

• srl

• contact

• interaction

Max number
MaxResults Integer of returned false true UCS default
Documents.

Universal Contact Server API Guide 40


Index Search

Key ValueType Value Description Mandatory Unique Default


Mandatory if
subtenant/
TenantId Integer subscriber-id- false true
enabled is
true
Defines the
query to be
processed*.
See Lucene site
Can be set in
Query String true true
for more configuration
information about
Lucene queries:
http://lucene.apache.org/

Default fields
to be
searched for.
This is an
optional
parameter. It
enables
default
querying.These
queries are
identical:
String such as
• Query =
DefaultFields String "FirstName, false true None
"john",
LastName"
DefaultFields
=
"EmailAddress,
FirstName"

• Query =
"EmailAddress:john
OR
FirstName:john",
no
DefaultFields.

**Important**:
Added in 8.5.0
The
subscriber
(i.e. line of
SubscriberId String business) false true
within the
tenant to
which the
contact
belongs

• Query parameter: the way of indexing can change what data is indexed and whether it is indexed, thus changing the
potential results. Refer to UCS indexing configuration for options to be set during indexing process.

Universal Contact Server API Guide 41


Index Search

Sample

IndexName contact
MaxResults 2
Query EmailAddress:hotmail

Success
Other types of Query parameter to set in Search request: ? Contact:
? "kristina" (DefaultFields="FirstName, LastName" optional parameter needs to be set), this is the same query as
"FirstName: kristina+LastName:kristina"
? "FirstName: john AND LastName: castro
? SRL:
? "Body: madam
? "MyCustomAttribute: reference" (some config need to be done to configure analyzer for this field)
? Interaction:
? "StructuredText: contract"
Note: GetIndexProperties provides the key field names that are searchable.

Parameters

Key ValueType Value Description Mandatory Unique Default


Total Count of
FoundDocumentsInteger Documents true true
matching.
Number of
ReturnedDocuments
Integer Documents true true
returned
List of
returned
Documents KVList false true
documents
ordered.

DocumentData KVList

Key ValueType Value Description Mandatory Unique Default


(Document
Index) is a
string
(Document representation
KVList false true
Index) of an integer
index used to
maintain
Documents

Universal Contact Server API Guide 42


Index Search

Key ValueType Value Description Mandatory Unique Default


ordering,
priority

KVList

Key ValueType Value Description Mandatory Unique Default


The list of
(Field Name) String false false
fields.

Sample

FoundDocuments 10
ReturnedDocuments 2
Documents 0 DocumentType Contact
BoostFactor 1.0
Id UCSIDXXXXXXXXXXX
EmailAddress mrs.brown@hotmail.com
...
1 DocumentType Contact
BoostFactor 1.0
Id UCSIDXXXXXXXXXXX
EmailAddress mr.brown@hotmail.com
...
...

Error/Event3rdSeverFault
FaultCode FaultString Description
Indexing is disabled (change
950 Applies only for a given index.
configuration options).
Index searching is disabled (change
951 Applies only for a given index.
configuration options).
Index is not available or not
952 Incorrect IndexName specified: '{0}'.
configured.
953 Unable to parse query: '{0}'.

Universal Contact Server API Guide 43


Index Search

FaultCode FaultString Description


954 Unable to search in index: '{0}'.
Unable to find document '{0}' in index:
955
'{1}'.

Universal Contact Server API Guide 44


Ixn Search

Ixn
• AssignToContact

• StopProcessing

Universal Contact Server API Guide 45


Ixn AssignToContact

AssignToContact

Purpose
For ESJ.

URL
• PUT /Ixn/AssignToContact/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


InteractionId String true true
ContactId String true true
TenantId Integer true true

Universal Contact Server API Guide 46


Ixn StopProcessing

StopProcessing

Purpose
For ESJ.

URL
• PUT /Ixn/StopProcessing/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Delete String false true
Reason String false true

UserData

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
InteractionId String true true

Universal Contact Server API Guide 47


Metadata Web Service Methods StopProcessing

Metadata Web Service Methods


• ProfileSchemaResource

• queryProfileSchema

• ProfileExtensionSchemaResource

• deleteProfileExtensionSchema

• queryProfileExtensionSchema

• IdentificationKeysResource

• deleteIdKeySchema

• queryIdKeySchema

• ProfileExtensionSchemasResource

• createProfileExtensionSchema

• queryProfileExtensionsSchema

• IdentificationKeysSchemasResource

• queryIdentificationKeysSchema

• createIdentificationKeysSchema

Universal Contact Server API Guide 48


Metadata Web Service Methods ProfileSchemaResource

ProfileSchemaResource
• queryProfileSchema

Universal Contact Server API Guide 49


Metadata Web Service Methods ProfileSchemaResource

queryProfileSchema

URL
• GET /metadata/profiles/

Request

HTTP Headers

Value Description Mandatory Unique Default


Integer value of
X-Genesys-TenantId false true
tenant id
Segment value (not
X-Genesys-Segment to be provided by false true
customer)

Responses

Body

Key ValueType Value Description Mandatory Unique Default


Body JsonObjectArray false false

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:
400 Bad Request
• Missing required parameter.

Universal Contact Server API Guide 50


Metadata Web Service Methods ProfileSchemaResource

FaultCode FaultString Description

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter the schema while


403 Forbidden
the server is in Production Mode.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
200 OK
[{"encrypt":false,"name":"PIN","length":256,"type":"string"},
{"encrypt":false,"name":"Title","length":256,"type":"string"},
{"encrypt":false,"name":"CustomerSegment","length":256,"type":"string"},
{"encrypt":false,"name":"LastName","length":256,"type":"string"},
{"encrypt":false,"name":"AccountNumber","length":256,"type":"string"},
{"encrypt":false,"name":"FirstName","length":256,"type":"string"},
{"encrypt":false,"name":"PhoneNumber","length":256,"type":"string"},
{"encrypt":false,"name":"ContactId","length":256,"type":"string"},
{"encrypt":false,"name":"EmailAddress","length":256,"type":"string"},
{"encrypt":false,"name":"Title","length":256,"type":"string"},

Universal Contact Server API Guide 51


Metadata Web Service Methods ProfileSchemaResource

{"encrypt":false,"name":"PIN","length":256,"type":"string"},
{"encrypt":false,"name":"ContactId","length":256,"type":"string"},
{"encrypt":false,"name":"homeaddress","length":256,"type":"string"},
{"encrypt":false,"name":"EmailAddress","length":256,"type":"string"},
{"encrypt":false,"name":"PhoneNumber","length":256,"type":"string"},
{"encrypt":false,"name":"AccountNumber","length":256,"type":"string"},
{"encrypt":false,"name":"LastName","length":256,"type":"string"},
{"encrypt":false,"name":"FirstName","length":256,"type":"string"},
{"encrypt":false,"name":"CustomerSegment","length":256,"type":"string"},
{"encrypt":false,"name":"LastCalledAgent_EmployeeID","length":256,"type":"string"},
{"encrypt":false,"name":"LastCalledAgent_TimeStamp","length":0,"type":"datetime"},
{"encrypt":false,"name":"PreferredAgent_EmployeeID","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_workitem","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_workitem","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_workitem","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_auxwork","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_auxwork","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_auxwork","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_imchat","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_imchat","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_imchat","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_outboundpreview","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_outboundpreview","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_outboundpreview","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_vmail","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_vmail","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_vmail","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_smail","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_smail","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_smail","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_cobrowsing","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_cobrowsing","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_cobrowsing","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_webform","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_webform","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_webform","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_busevent","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_busevent","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_busevent","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_voice","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_voice","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_voice","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_appsharing","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_appsharing","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_appsharing","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_email","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_email","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_email","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_chat","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_chat","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_chat","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_any","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_any","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_any","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_fax","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_fax","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_fax","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_video","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_video","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_video","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_whiteboard","length":256,"type":"string"},

Universal Contact Server API Guide 52


Metadata Web Service Methods ProfileSchemaResource

{"encrypt":false,"name":"LCA_TimeStamp_whiteboard","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_whiteboard","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_alert","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_alert","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_alert","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_voip","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_voip","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_voip","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_sms","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_sms","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_sms","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_EmplID_callback","length":256,"type":"string"},
{"encrypt":false,"name":"LCA_TimeStamp_callback","length":0,"type":"datetime"},
{"encrypt":false,"name":"Pref_EmplID_callback","length":256,"type":"string"}]

Universal Contact Server API Guide 53


Metadata Web Service Methods ProfileExtensionSchemaResource

ProfileExtensionSchemaResource

Universal Contact Server API Guide 54


Metadata Web Service Methods ProfileExtensionSchemaResource

deleteProfileExtensionSchema

URL
• DELETE /metadata/profiles/extensions/{extension_name}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The metadata
extension- extension
extension_name String true true
name name to
delete.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false false
TenantId of tenant id
Segment
X-Genesys- value (not to
String false false
Segment be provided
by customer)

Sample
DELETE /metadata/profiles/extensions/Address

Universal Contact Server API Guide 55


Metadata Web Service Methods ProfileExtensionSchemaResource

Responses

Success

ReturnCode ReturnString Description


The server has fulfilled the request
204 No Content but does not need to return an
*entity-body

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

403 Forbidden • Attempt to alter an existing


schema.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.

Universal Contact Server API Guide 56


Metadata Web Service Methods ProfileExtensionSchemaResource

FaultCode FaultString Description


In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 57


Metadata Web Service Methods ProfileExtensionSchemaResource

queryProfileExtensionSchema

URL
• GET /metadata/profiles/extensions/{extension_name}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The extension
name, if a
extension- specific
extension_name String true true
name extension
should be
returned.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
• GET /metadata/profiles/extensions/Phone

Universal Contact Server API Guide 58


Metadata Web Service Methods ProfileExtensionSchemaResource

Responses

Body

Key ValueType Value Description Mandatory Unique Default


Body JsonObjectArray false false

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter the schema while


403 Forbidden
the server is in Production Mode.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


404 Not Found requested resource (such as a
customer, service, state, task,

Universal Contact Server API Guide 59


Metadata Web Service Methods ProfileExtensionSchemaResource

FaultCode FaultString Description


extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
200 OK
{
"name":"Phone",
"type":"multi-valued",
"attributes": [
{"name":"PhoneType","type":"integer","default":0,"mandatory":"true"},
{"name":"prefix","type":"string","length":"3","default":"555",},
{"name":"PhoneNumber","type":"integer","length":15,"mandatory":"true"},
{"name":"description","type":"string","length":32,"mandatory":"true"},
{"name":"start_availability","type":"datetime"},
{"name":"end_availability","type":"datetime", "mandatory":"false"}
]
}

Universal Contact Server API Guide 60


Metadata Web Service Methods IdentificationKeysResource

IdentificationKeysResource
Handle methods for Identification-Key schema manipulation : Reading ID Key schema, Deleting existing schema

Universal Contact Server API Guide 61


Metadata Web Service Methods IdentificationKeysResource

deleteIdKeySchema

URL
• DELETE /metadata/identification-keys/{key_name}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The name of
key_name String key-name true true
the key.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
DELETE /metadata/identification-keys/idExtension

Responses

Success

ReturnCode ReturnString Description


The server has fulfilled the request
204 No Content but does not need to return an *
entity-body.

Universal Contact Server API Guide 62


Metadata Web Service Methods IdentificationKeysResource

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute.

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter an existing


403 Forbidden
schema.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 63


Metadata Web Service Methods IdentificationKeysResource

queryIdKeySchema

URL
• GET /metadata/identification-keys/{key_name}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The name of
the key. Must
start with a
letter, and can
key_name String key-name true true
be followed
with letters,
numbers, or
underscores.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
GET /metadata/identification-keys/idExtension

Universal Contact Server API Guide 64


Metadata Web Service Methods IdentificationKeysResource

Responses

Body

Key ValueType Value Description Mandatory Unique Default


Body JsonObjectArray false false

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter an existing


403 Forbidden
schema.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.

Universal Contact Server API Guide 65


Metadata Web Service Methods IdentificationKeysResource

FaultCode FaultString Description


Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample

200 OK
{"name": "idExtension", "attributes": ["ext.code","ext.date"], "unique": true}}

Universal Contact Server API Guide 66


Metadata Web Service Methods ProfileExtensionSchemasResource

ProfileExtensionSchemasResource
Handle methods for profile extensions schema manipulation : Reading all schema, creating extension schema.

Universal Contact Server API Guide 67


Metadata Web Service Methods ProfileExtensionSchemasResource

createProfileExtensionsSchema

URL
• POST /metadata/profiles/extensions/

Request

HTTP Headers

Key Value Type Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


The unique,
case-
insensitive
name of the
extension.
The name
must start with
a letter, and
can be
followed with
name String letters, true true
numbers, or
underscores.
The name is
restricted to a
maximum of 26
characters
(Maximum
RDBMS shared
limit on creation
of index).

Universal Contact Server API Guide 68


Metadata Web Service Methods ProfileExtensionSchemasResource

Key ValueType Value Description Mandatory Unique Default


Extensions
come in the
following
forms:

• Single-
valued: a
single
extension
record is
associated
with a
"single-
given
type Token valued" or true true
customer.
"multi-valued"
• Multi-
valued:
multiple
extension
records
can be
associated
with a
given
customer.

Lists attributes
which are
unique in the
scope of a
given
customer. The
customer
profile cannot
include
several
extension
records with
identical
values for
unique StringList false true
these
attributes. For
example, let's
consider a
contact
extension with
the attributes
"phone_num",
"ext",
"time_of_day".
To ensure that
a given
customer
does not have

Universal Contact Server API Guide 69


Metadata Web Service Methods ProfileExtensionSchemasResource

Key ValueType Value Description Mandatory Unique Default


two contact
extensions
with the same
phone
number, set
the following
in the
extension
schema:
unique =
["phone_num",
"ext"]

The array of
attributes JsonArray zero or more false false
attributes.

Sample
POST http://ucsserver.mycompany.com:8080/cms/metadata/profiles/extensions
{
"name":"Address",
"type":"single-valued",
"attributes": [
{"name":"AddressType", "type":"integer", "default":0},
{"name":"Address", "type":"string", "length":256},
{"name":"City", "type":"string", "length":32},
{"name":"County", "type":"string", "length":32},
{"name":"PostCode", "type":"string", "length":10},
{"name":"Country", "type":"string", "length":32}
]
}

Responses

Success

ReturnCode ReturnString Description


The request has been fulfilled and
201 Created resulted in a new resource being
created

Error

FaultCode FaultString Description


General error which can be one of
400 Bad Request
the following reasons:

Universal Contact Server API Guide 70


Metadata Web Service Methods ProfileExtensionSchemasResource

FaultCode FaultString Description

• Missing required parameter.

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter the schema while


403 Forbidden
the server is in Production Mode.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample

201 Created
Content-Location http://ucsserver.mycompany.com:8080/cms/profiles/extensions/Address
{"name":"Address"}

Universal Contact Server API Guide 71


Metadata Web Service Methods ProfileExtensionSchemasResource

queryProfileExtensionsSchema

URL
• GET /metadata/profiles/extensions/

Request

HTTP Headers

Key Value Type Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
GET /metadata/profiles/extensions/Phone

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:
400 Bad Request
• Missing required parameter.

Universal Contact Server API Guide 72


Metadata Web Service Methods ProfileExtensionSchemasResource

FaultCode FaultString Description

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter an existing


403 Forbidden
schema.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
200 OK
[
{
"name":"Phone",
"type":"multi-valued",
"attributes": [
{"name":"PhoneType","type":"integer","default":0,"mandatory":"true"},
{"name":"prefix","type":"string","length":"3","default":"555",},
{"name":"PhoneNumber","type":"integer","length":15,"mandatory":"true"},
{"name":"description","type":"string","length":32,"mandatory":"true"},
{"name":"start_availabilty","type":"datetime"},

Universal Contact Server API Guide 73


Metadata Web Service Methods ProfileExtensionSchemasResource

{"name":"end_availabilty","type":"datetime", "mandatory":"false"}
]
},
{
"name":"Address",
"type":"single-valued",
"attributes": [
{"name":"AddressType","type":"integer","default":0},
{"name":"Address","type":"string","length":256},
{"name":"City","type":"string","length":32},
{"name":"County","type":"string","length":32},
{"name":"PostCode","type":"string", "length":10},
{"name":"Country","type":"string","length":32}
]
} ]

Universal Contact Server API Guide 74


Metadata Web Service Methods IdentificationKeysSchemasResource

IdentificationKeysSchemasResource
Handle methods for ID Keys schema manipulation : Reading all schema, creating ID Keys schema.

Universal Contact Server API Guide 75


Metadata Web Service Methods IdentificationKeysSchemasResource

queryIdentificationKeysSchema

URL
• GET /metadata/identification-keys/

Request

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
GET /metadata/identification-keys

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:
400 Bad Request
• Missing required parameter.

Universal Contact Server API Guide 76


Metadata Web Service Methods IdentificationKeysSchemasResource

FaultCode FaultString Description

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter the schema while


403 Forbidden
the server is in Production Mode.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
[{"name": "idNameBD", "attributes": ["name", " birthdate"]},
{"name": "idExt", "attributes": ["external_id"], "unique": true},
{"name": "idPhone", "attributes": ["phone_number"]}
{"name": "idExtension", "attributes": ["ext.code","ext.date"]}]

Universal Contact Server API Guide 77


Metadata Web Service Methods IdentificationKeysSchemasResource

createIdentificationKeysSchema

Purpose
Creates the key used to identify customers. Your application must define the Identification Key prior to any
customer identification attempt. You can build identification keys as a combination of attributes:

• One or more attributes of the customer profile.

• One or more attributes of an extension.

Important
Your application cannot create Identification keys with a blend of profile attributes and extension
attributes.

The following identification key representation identifies customers based on the phone_number attribute:

{ "name": "idPhone", "attributes": ["phone_number"]}

Imagine that the phone number is part of the "contacts" extension: the corresponding object is:

{ "name": "idPhone", "source": "contacts", "attributes": ["phone_number"]}

This example assumes that one or more customers can share the same phone number, which could apply to
members of a family, for instance, and makes the identification key non-unique across the calling customers. To
make it unique, use the "unique" field of the identification key (see the Identification Key for further details).

URL
• POST /metadata/identification-keys/

Request

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id

Universal Contact Server API Guide 78


Metadata Web Service Methods IdentificationKeysSchemasResource

Key ValueType Value Description Mandatory Unique Default


Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


The unique,
case-
insensitive
name of the
key. The
name must
start with a
letter, and can
be followed
with letters,
name String numbers, or true true
underscores.
The name is
restricted to a
maximum of
26 characters.
(Maximum
RDBMS
shared limit
on creation of
index.)
Can take on
one of the
following
values:

• "profile"
(default
value):
indicates
that the
attributes
specified
source String false true profile
in
parameter
"attribute"
belong to
the core
customer
profile.

• The
unique
name of

Universal Contact Server API Guide 79


Metadata Web Service Methods IdentificationKeysSchemasResource

Key ValueType Value Description Mandatory Unique Default

the given
Profile
Extension,
used to
create the
Identification
Key.

false by
default. Value
true indicates
that the given
unique String attributes of false true
the profile or
extension are
unique across
all customers.
The array
names of one
or more
attributes JsonArray attributes of true false
the extension
or of the
profile.

Sample
POST /metadata/identification-keys
{
"name": "idPhone",
"extension": "contacts",
"attributes": ["phone_number"]
}

Responses
Success

ReturnCode ReturnString Description


The request has been fulfilled and
201 Created resulted in a new resource being
created

Universal Contact Server API Guide 80


Metadata Web Service Methods IdentificationKeysSchemasResource

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:

• Attempt to alter the schema while


403 Forbidden
the server is in Production Mode.

• Attempt to add customer profiles


prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
201 Created
Content-Location http://ucsserver.mycompany.com:8080/cms/profiles/extensions/Address
{"name":"Address"}

Universal Contact Server API Guide 81


Metrics IdentificationKeysSchemasResource

Metrics
• GetAll

• GetCore

• GetTopTimers

Universal Contact Server API Guide 82


Metrics GetAll

GetAll

Purpose
This method retrieve a list of Key Performance Indicators (KPI) to monitor UCS performance and health.

URL
• GET /Metrics/GetAll/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Return all
ReturnGauges String true or false false true true
gauges
Return all
ReturnCounters String true or false false true true
counters
Return all
ReturnHistogramsString true or false false true true
histograms
Return all
ReturnMeters String true or false false true true
meters
Return all
ReturnTimers String true or false false true true
timers
Return all
A parseable timers where
ReturnTimersAbove
String false true "0"
double mean is
above value
Return all
percentiles for
ReturnPercentilesString true or false false true true
Timers and
Histograms
A regular
expression to
A valid regular
RegEx String filter keys, for false true
expression
example
"sys\\.threads.*"

Universal Contact Server API Guide 83


Metrics GetAll

Success
Parameters

Key ValueType Value Description Mandatory Unique Default


Where value
is a list of key/
(KPI Name) KVList value true true
according to
KPI page

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}

Universal Contact Server API Guide 84


Metrics GetCore

GetCore

Purpose
Core metrics is a reduced list of KPIs that represent a summary of UCS performance.

• sys.mem.heap.usage.gge—Memory usage in %: constant increase to values close to 1 can show a memory leak.

• sys.mem.heap.committed.gge—Current size of the memory heap in bytes. Will only grow up to XMX (512MB by
default).

• esp.pending.gge—Number of pending ESP request: increasing value can mean server is not able to cope with
client request.

• TopTimers—The list (2 by default) of longest executing timers. High values can show a bottleneck.

• jmx.ConnectionPoolMain.TotalLeased.gge—Main DB connections in use, values close to 40 means DB


cannot cope with load.

• jmx.ConnectionPoolMain.borrowedConnectionsCount.gge—Same as above but for Oracle RAC. Only one


of the two will be present.

URL
• GET /Metrics/GetCore/

Request

Sample

TenantId 102
Attributes EmailAddress 0 AttrValue john.doe@genesys.com
1 AttrValue alice.doe@genesys.com
LastName 0 AttrValue Doe

Universal Contact Server API Guide 85


Metrics GetCore

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Where value
is a list of key/
(KPI Name) KVList value true true
according to
KPI page

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}

Universal Contact Server API Guide 86


Metrics GetTopTimers

GetTopTimers

Purpose
A list (default 2) of the longest-executing timers.

URL
• GET /Metrics/GetTopTimers/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The number
of timers to
Count Integer return true true
according to
their mean.

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


A string
representation
(KPI Name) String A java double true true
of the mean of
the timer.

Universal Contact Server API Guide 87


Metrics GetTopTimers

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}

Universal Contact Server API Guide 88


OMContacts GetTopTimers

OMContacts
• ContactListGet

• ContactListGetNextPage

• ContactListRelease

• Delete

• GetAttributes

• GetContacts

• GetMergeDetail

• IdentifyContact

• Insert

• MergeContacts

• MergeListGet

• MergeListGetNextPage

• MergeListRelease

• RemoveAllAttributes

• UnMergeContacts

• UpdateAttributes

Universal Contact Server API Guide 89


OMContacts ContactListGet

ContactListGet

Purpose
This method is intended for building a ScrollableList object based on provided constraints. There is no general rule.
Results depend on the filter used, and on the database used. Note also that the data returned by the lookup request
comes from the Contact table only. In the same way, the ordering of the Contacts returned is done using Contact
table data only.

URL
• GET /OMContacts/ContactListGet/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Asks UCS to
return total
count of
matching
Contacts.
ContactCount String Setting this false true false
parameter to true
results in an extra
database query
which will
decrease
performance.

TenantId Integer true true


The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contacts
belong

Universal Contact Server API Guide 90


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default


If no value is
provided,
UCS
configured (schema/
PageMaxSize Integer false true
value select-limit)
(schema/
select-limit) is
used.
Raw Lucene
Query. If
present,
ESQuery String overrides both false true
SearchCriteria
and
SortCriteria.
No filtering if
SearchCriteria KVList false true
not present
No ordering if
SortCriteria KVList false true
not present
If AttributeList
List of KVList is null
sortable or is not
AttributeList KVList false true
attributes to passed, all
return attributes are
returned.

Please refer to www.elastic.co/guide/en/elasticsearch/reference/1.7/query-dsl.html for a description of the ESQuery


possible values

SearchCriteria KVList value SimpleConstraint KVList definition

Key ValueType Value Description Mandatory Unique Default


(Operator) KVList yes yes false false

KVList value detail

Key ValueType Value Description Mandatory Unique Default


The system
name of a
Contact
Attribute as
AttrName String true true
declared in
Configuration
Server
(tenant-

Universal Contact Server API Guide 91


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default


specific
configuration)
Max. length: 256
characters

The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Configuration
Server
(settings/
type). If type
is set to:
AttrValue String String (default):
false true
value must be a
String Max.
length: 256
characters date:
value must be a
String formatted
with the pattern:
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
binary: This is an
error! Binary
values cannot be
used in search
constraints

ComplexConstraint KVList definition

Key ValueType Value Description Mandatory Unique Default


One instance
for NOT
operator.
(Operator) KVList Multiple true false
instances for
AND or OR
operators.

(Operator) = NOT || AND || OR KVList value detail conforms to SimpleConstraint or ComplexConstraint KVList
definition

Universal Contact Server API Guide 92


OMContacts ContactListGet

SortCriteria KVList value

Key ValueType Value Description Mandatory Unique Default


(Sort Index) KVList false true

KVList value

Key ValueType Value Description Mandatory Unique Default


Can have
value of
Operator String true true
"ASC" or
"DSC".
String
represents
either:

• A Contact
object
attribute
name: 'Id',
'TenantId',
'IsExternalResource',
'CreatedDate',
'ModifiedDate',
'MergeId';
or;

• A sortable
Contact
Attribute
system
AttrName String name. true true
Configuration
note—to make a
Contact Attribute
sortable, it is
necessary to
configure this
Contact Attribute
as sortable
(settings/is-
sortable) in
ConfigServer
(EmailAddress,
PhoneNumber,
FirstName &
LastName are
sortable by
default). (Notice
the number of
sortable Contact
Attributes is
limited !) Max.

Universal Contact Server API Guide 93


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default

length: 256
characters

AttributeList KVList

Key ValueType Value Description Mandatory Unique Default


String value
represents
attribute
name.:

• A Contact
object
attribute
name: 'Id',
'TenantId',
'IsExternalResource',
'CreatedDate',
'ModifiedDate',
'MergeId';
or;

• A sortable
Contact
Attribute
system
name.
AttrName String Configuration false false
note—to make a
Contact Attribute
sortable, it is
necessary to
configure this
Contact Attribute
as sortable
(settings/is-
sortable) in
Configuration
Server
(EmailAddress,
PhoneNumber,
FirstName &
LastName are
sortable by
default) (Note that
the number of
sortable Contact
Attributes is
limited.) If
AttributeList
KVList is empty,
all attributes are
returned. Max.

Universal Contact Server API Guide 94


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default

length: 256
characters

Sample

TenantId 102
SearchCriteria AND EQUAL AttrName FirstName
AttrValue John
AND NOT_EQUAL AttrName LastName
AttrValue Doe
SortCriteria 0 Operator ASC AttrName LastName
1 Operator DSC AttrName FirstName
AttributeList AttrName EmailAddress
AttrName PhoneNumber

Sample

TenantId 101
SearchCriteria EQUAL ESQuery FirstName:C*
AttributeList AttrName FirstName
AttrName LastName

Sample

TenantId 101
ESQuery LastName:C*
AttributeList AttrName FirstName
AttrName LastName

Sample

TenantId 101
{"from":0,"size":5,"query":{"query_string":{"query":"+LastName:Cassandra
ESQuery
+FirstName:C*"}},"sort":[{"FirstName":{"order":"asc"}}]}
AttributeList AttrName FirstName
AttrName LastName

Universal Contact Server API Guide 95


OMContacts ContactListGet

Sample

TenantId 101
{"from":0,"size":5,
ESQuery
"query":{"fuzzy":{"LastName":{"value":"Cassandra","fuzziness":2}}},"sort":[{"FirstName":{"order":"desc"}}]}

AttributeList AttrName FirstName


AttrName LastName

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


This id is used
to call
ScrollableList LookupNextPage.
ScrollId String false true
Id Not available
if HasNext is
false
Present only if
TotalCount Integer ContactCount=true
false true
in the request
The number
of Contacts
PageSize Integer true true
available in
this page
Indicates
more records
are available
(using method
LookupNextPage).
If true:
CloseLookup
method is to be
HasNext String true or false true true
called after
iteration If false:
UCS
automatically
closes the list and
there is no need
to call
CloseLookup
method

ContactData KVList false true

Universal Contact Server API Guide 96


OMContacts ContactListGet

ContactData KVList

Key ValueType Value Description Mandatory Unique Default


(Contact
KVList false true
Index)

(Contact Index) is a string representation of an integer index used to maintain Contacts ordering

KVList value

Key ValueType Value Description Mandatory Unique Default


Id String Contact Id true true
If AttributeList
KVList is
empty, all
attributes are
returned.
Attribute "Id"
Attributes KVList false true
is never
delivered with
this list, even
if requested
specifically in
AttributeList.

KVList value

Key ValueType Value Description Mandatory Unique Default


The type
depends on
the Attribute:

• TenantId(Integer),
IsExternalResource(String
true/
false),
CreatedDate(formatted
String with
(AttributeName) String Date true true
pattern),
ModifiedDate(formatted
String with
Date
pattern),
MergeId(String)

• SortableContactAttributes(String,
or

Universal Contact Server API Guide 97


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default

formatted
StringDate
with Date
pattern).
When all
attributes
have been
requested
from the
Contact
table
(input
parameter
AttributeList
was null
or empty),
the
(AttributeName)
key is
equal to
StrAttributeXX
or
DateAttributeXX
if the
column is
not
currently
associated
to a
sortable
ContactAttribute
as
declared
in
ConfigServer.

• Date
values are
returned
as String
with the
pattern"yyyy-
MM-
ddTHH:mm:ss.SSSZ")

The type
depends on
the Attribute:

(AttributeName) Integer • TenantId(Integer),


true true
IsExternalResource(String
true/
false),

Universal Contact Server API Guide 98


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default

CreatedDate(formatted
String with
Date
pattern),
ModifiedDate(formatted
String with
Date
pattern),
MergeId(String)

• SortableContactAttributes(String,
or
formatted
StringDate
with Date
pattern).
When all
attributes
have been
requested
from the
Contact
table
(input
parameter
AttributeList
was null
or empty),
the
(AttributeName)
key is
equal to
StrAttributeXX
or
DateAttributeXX
if the
column is
not
currently
associated
to a
sortable
ContactAttribute
as
declared
in
ConfigServer.

• Date
values are
returned
as String
with the

Universal Contact Server API Guide 99


OMContacts ContactListGet

Key ValueType Value Description Mandatory Unique Default

pattern
"yyyy-
MM-
ddTHH:mm:ss.SSSZ")

(AttributeName) is the system name of the Attribute (as defined in Configuration Server.)

Sample

ScrollId 1234567890123456
PageSize 2
HasNext false
ContactData 0 Id 1234567890123456
Attributes EmailAddress john@rivers.com
PhoneNumber 1257566
1 Id ABCDEFJIOQJDLHDEC
Attributes EmailAddress john@cole.com
PhoneNumber 354535432

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
533 Invalid ES Query Provided ESQuery is malformed
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 100


OMContacts ContactListGetNextPage

ContactListGetNextPage

Purpose
This method is intended for delivering the next portion of the contact objects, previously found by some constraints.
The method provides unidirectional scrolling of selected contacts—there is no backward scrolling or jumping to the
record with arbitrary number.

URL
• GET /OMContacts/ContactListGetNextPage/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
ScrollableList
Existing object for
ScrollId String ScrollableList which true true
Id ScrollableList.next(int
max) method
should be
applied
Max size for
the page of
data,
PageMaxSize Integer calculated as false true
min(PageMaxSize,
UCS internal
limit)

Universal Contact Server API Guide 101


OMContacts ContactListGetNextPage

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The number
Existing
of Contacts
PageSize Integer ScrollableList true true
available in
Id
this page
Indicates
more records
HasNext String true or false are available true true
(using method
ContactListGetNextPage).
See format
description
ContactData KVList false true
OMContacts /
ContactListGet

Error
FaultCode FaultString Description
510 {0} not found in database ScrollableList does not exist

Universal Contact Server API Guide 102


OMContacts ContactListRelease

ContactListRelease

Purpose
This method is intended for releasing of a previously created ScrollableList.

URL
• PUT /OMContacts/ContactListRelease/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
ScrollableList
Existing object for
ScrollId String ScrollableList which true true
Id ScrollableList.close()
method
should be
applied

Error
FaultCode FaultString Description
510 {0} not found in database ScrollableList does not exist

Universal Contact Server API Guide 103


OMContacts Delete

Delete

Purpose
This method is intended for deletion of the contact by its Id.

URL
• DELETE /OMContacts/Delete/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id for the
Any valid contact which
ContactId String true true
contact Id has to be
deleted

Error
FaultCode FaultString Description
Contact with Id=(ContactId) is not
510 {0} not found in database
found in database

Universal Contact Server API Guide 104


OMContacts GetAttributes

GetAttributes

Purpose
This method is intended for obtaining the complete list of contact attributes. This method is used to return all
Contact Attribute objects associated to this Contact. Contact Attribute objects must be declared in Configuration
Server in the Contact Attribute enumerator. This configuration is Tenant specific. By default, existing Contact
Attributes are:

• AccountNumber

• ContactId

• CustomerSegment

• EmailAddress

• FirstName

• LastName

• PhoneNumber

• PIN

• Title.

Contact Attribute objects are stored in the dedicated MCR DB column ContactAttribute.

URL
• GET /OMContacts/GetAttributes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id for the
contact which
Any valid
ContactId String attributes true true
contact Id
were
requested

Universal Contact Server API Guide 105


OMContacts GetAttributes

Key ValueType Value Description Mandatory Unique Default


If this
parameter is
not present or
AttributeList KVList if the KVList is false true
empty, all
ContactAttributes
are returned

AttributeList KVList

Key ValueType Value Description Mandatory Unique Default


String value
represents the
name of a
Contact
Attribute as
defined in
Configuration
AttrName String Server. false false
Max. length: 256
characters If
AttributeList
KVList is empty,
all
ContactAttributes
are returned.

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantID Integer true true
ContactID String true true
"yyyy-MM-
CreatedDate String true true
ddTHH:mm:ss.SSSZ"
"yyyy-MM-
ModifiedDate String true true
ddTHH:mm:ss.SSSZ"
Id of the
contacts that
MergeIDs String were merged false false
into this one.
Not

Universal Contact Server API Guide 106


OMContacts GetAttributes

Key ValueType Value Description Mandatory Unique Default


mandatory
and can have
multiple
values.
List with all
available (or a
subset
depending on
AttributeList
input
Attributes KVList false true
parameter)
attributes for
the contact
with
requested
ContactId

Attributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName)is
the system
name of a
Contact
Attribute as
(AttributeName) KVList declared in false true
Configuration
Server
(Tenant
specific
configuration)

KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
(Attribute Index) == 0
KVList false true
Index) means
primary

KVList

Key ValueType Value Description Mandatory Unique Default


AttrId String Attribute Id true true

Universal Contact Server API Guide 107


OMContacts GetAttributes

Key ValueType Value Description Mandatory Unique Default


The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Config Server
(settings/
AttrValue StringBinary type). If type false true null
is set to:
string(default):
value is a String
date: value is a
String formatted
with the
pattern:"yyyy-MM-
ddTHH:mm:ss.SSSZ"
binary: value is a
byte array

Applicable for
binary
MimeType String false true
contentReturned
only if not null.
This is the
description
that can be
attached to
the contact
attribute.Returned
Description String only if not null. false true
For example,
EmailAddress
can be
described as
"(home)" or
"(office)", etc

Sample

Attributes EmailAddress 0 AttrId JH8BVJH5J48KL59


AttrValue john.doe@genesys.com
Description (home)
1 AttrId JH8BVJH5J48KL58
AttrValue alice.doe@genesys.com
LastName 0 AttrId JH8BVJH5J48KL60
AttrValue Doe

Universal Contact Server API Guide 108


OMContacts GetAttributes

Picture 0 AttrId JH8BVJH5J48KL61


AttrValue (binary)
MimeType image/jpg

Error
FaultCode FaultString Description
Contact with Id=(ContactId) is not
510 {0} not found in database
found in database

Universal Contact Server API Guide 109


OMContacts GetContacts

GetContacts

Purpose
This method is intended for delivering specific range of contacts based on search and sort criteria.

URL
• GET /OMContacts/GetContacts/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Asks UCS to
return total
count of
matching
Contacts.
ContactCount String Setting this false true false
parameter to true
results in an extra
database query
which will
decrease
performance.

TenantId Integer true true


The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contacts
belong.
Index of the
IndexOfFirst Integer first row in false true 0
selection

Universal Contact Server API Guide 110


OMContacts GetContacts

Key ValueType Value Description Mandatory Unique Default


Maximum
number of (schema/
MaxCount Integer false true
rows in select-limit)
selection
No filtering if
not present.
See format
SearchCriteria KVList false true
description in
OMContacts /
ContactListGet.
No ordering if
not present.
See format
SortCriteria KVList false true
description in
OMContacts /
ContactListGet.
List of
attributes to
return. See
AttributeList KVList format false true
description in
OMContacts /
ContactListGet.

Sample

ContactCount true
TenantId 102
IndexOfFirst 2000
MaxCount 2
SearchCriteria AND EQUAL AttrName FirstName
AttrValue John
AND NOT_EQUAL AttrName LastName
AttrValue Doe
SortCriteria 0 Operator ASC AttrName LastName
AttributeList AttrName EmailAddress
AttrName PhoneNumber

Universal Contact Server API Guide 111


OMContacts GetContacts

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Present only if
ContactCount
TotalCount Integer false true
is true in the
request
The number
of Contacts
CurrentCount Integer true true
available in
this response
See format
description in
ContactData KVList false true
OMContacts /
ContactListGet

Sample

TotalCount 800000
CurrentCount 2
ContactData 0 Id 1234567890123456
Attributes EmailAddress john@rivers.com
PhoneNumber 1257566
1 Id ABCDEFJIOQJDLHDEC
Attributes EmailAddress john@cole.com
PhoneNumber 354535432

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS

Universal Contact Server API Guide 112


OMContacts GetMergeDetail

GetMergeDetail

Purpose
Returns details about a previous merge operation.

URL
• GET /OMContacts/GetMergeDetail/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
Existing
MergeId String MergeId for false true
merge Id
which details
are required.
Identifies the
existing
Existing SourceContactId
SourceContactId String false true
merge Id for which
details are
required.

One and only one of MergeId or SourceContactId is mandatory

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Original Id of
SourceContactId String the source true true
contact, the

Universal Contact Server API Guide 113


OMContacts GetMergeDetail

Key ValueType Value Description Mandatory Unique Default


contact that
was deleted
by the merge
Original Id of
the
DestinationContactId
String true true
destination
contact
Id of the agent
who
AgentId Integer true true
performed the
merge
The reason
that was
Reason String true true
provided for
the merge
The
description
Description String that was true true
provided for
the merge
Date of the
merge,
formatted with
MergeDate String true true
the pattern:
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Representation
SourceContact KVList of the source false true
contact
Representation
of the
DestinationContact
KVList false true
destination
contact

SourceContact and DestinationContact

Key ValueType Value Description Mandatory Unique Default


Id of the
ContactId String true true
contact
Id of the
TenantId Integer true true
tenant
"yyyy-MM-
CreatedDate String true true
ddTHH:mm:ss.SSSZ"
"yyyy-MM-
ModifiedDate String true true
ddTHH:mm:ss.SSSZ"

Universal Contact Server API Guide 114


OMContacts GetMergeDetail

Key ValueType Value Description Mandatory Unique Default


Attributes of
Attributes KVList true true
the contact

Attributes KVList value

Key ValueType Value Description Mandatory Unique Default


(Attribute
KVList false true
name)

Attribute name KVList value

Key ValueType Value Description Mandatory Unique Default


Attribute index
(Attribute
KVList 0 is for the false true
index)
primary value

Attribute index KVList value

Key ValueType Value Description Mandatory Unique Default


AttrId String Attribute Id true true
The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Config Server
(settings/
type). If type
is set to:
AttrValue StringBinary false true null
string(default):
value must be a
String Max.
length:
256characters
date: value must
be a String
formatted with the
pattern: "yyyy-
MM-
ddTHH:mm:ss.SSSZ"
binary: value

Universal Contact Server API Guide 115


OMContacts GetMergeDetail

Key ValueType Value Description Mandatory Unique Default

must be a byte
array

Applicable for
binary content
MimeType String false true
Max. length: 256
characters

Description to
be set for this
contact
attributes. For
example,
Description String EmailAddress false true
can be
described as
"(home)" or
"(office)", and
so on.

Universal Contact Server API Guide 116


OMContacts IdentifyContact

IdentifyContact

Purpose
This method is intended for identifying a Contact based on user data values. If one or more Contact is found, the
Contact identifiers are returned. If no matching Contact is found, a new Contact may be created.

URL
• POST /OMContacts/IdentifyContact/

Sample
POST /ucs/v1/OMContacts/IdentifyContact json:{"Parameters": {"TenantId":101,"FirstName":"Constance","MemberId":"

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


If more than 1
contact is
found, and
ReturnUnique
ReturnUnique String true or false is true, UCS false true false
won't return a
sublist of
found contact
Ids
yyyy-MM-
DatePattern String false true
ddTHH:mm:ssZ
Get creation
strategy from
Media
CreateContact String true or false false true configuration
if any,
otherwise, use
true
TenantId Integer true true

Universal Contact Server API Guide 117


OMContacts IdentifyContact

Key ValueType Value Description Mandatory Unique Default


The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contact
belongs
MediaType,
although not
mandatory, is
used by UCS
to apply the
MediaType String false true
contact
identification
strategy
based on
configuration.
Each attribute
of UserData
whose name
corresponds
to a defined
ContactAttributeName
String false true
ContactAttribute
name is used
by UCS for
contact
identification

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Number of
matching
Contacts.
Cannot be
superior to 1 if
NumberOfContacts "CreateContact"
Integer true true
Found parameter is
true. Cannot
be higher than
the configured
schema/
select-limit.

Universal Contact Server API Guide 118


OMContacts IdentifyContact

Key ValueType Value Description Mandatory Unique Default


Id of the
matching
ContactId String Contact if a false true
Contact was
found
List of the
matching
Contact Ids.
ContactIdList String false false
Contains
(NumberOfContactsFound)
Ids.
true if a
Contact has
ContactCreated String true or false been created true true
as a result of
this call
(Primary
If unique
(PrimaryContact Contact
String matching false true
AttributeName) Attribute
contact
Value)

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 119


OMContacts Insert

Insert

Purpose
This method is intended for contact creation. No specific limitations related to "required" attributes are introduced
here but they can be introduced at the client application level.

URL
• POST /OMContacts/Insert/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer Tenant Id true true
The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contact should
belong.
Attributes KVList false true

Attributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName) KVList false true

Universal Contact Server API Guide 120


OMContacts Insert

KVList value

Key ValueType Value Description Mandatory Unique Default


(Attribute
(Attribute Index) == 0
KVList false true
Index) means
primary

KVList value

Key ValueType Value Description Mandatory Unique Default


The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Config
Server(settings
/ type). If type
AttrValue StringBinary is set to: false true null
(default): value
must be a String
date: value must
be a String
formatted with the
pattern: "yyyy-
MM-
ddTHH:mm:ss.SSSZ"
binary: value
must be a byte
array

Applicable for
binary
content,
MimeType String false true
Max. length: 256
characters

Description to
be set for this
contact
attribute. For
example,
Description String false true null
EmailAddress
can be
described as
"(home)" or
"(office)", etc

Universal Contact Server API Guide 121


OMContacts Insert

Sample

TenantId 102
Attributes EmailAddress 0 AttrValue john.doe@genesys.com
1 AttrValue alice.doe@genesys.com
LastName 0 AttrValue Doe

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id for the
ContactId String newly created true true
contact

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 122


OMContacts MergeContacts

MergeContacts

Purpose
This method is intended for merging of two existing contacts.

This service implements the following actions:

• The contact attributes of previous contact are merged into contact attributes of new contact. All primary attributes of
new contact are kept primary while primary attributes of old contact are changed to not primary.

• All the interactions are assigned to the destination contact.

• The source contact is deleted.

• A record is inserted in the table MergedContact, with Id = sourceContactId and MergeId = destinationContactId.

URL
• PUT /OMContacts/MergeContacts/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id of the agent
Existing agent 0 for no Agent
AgentId Integer requesting the false true
Id ID
merge
Id of the
contact that is
Existing to be deleted
SourceContactId String true true
contact Id as the result
of the merge
operation
Id of the
Existing contact that
DestinationContactId
String true true
contact Id remains as
the result of

Universal Contact Server API Guide 123


OMContacts MergeContacts

Key ValueType Value Description Mandatory Unique Default


the merge
operation
Force the
merge in case
of extension
conflicts. Do
not fail and
ForceMerge Boolean false true false
use the
source value
for the
merged
contact.
Reason String false true
Description String false true
TenantId Integer true true
The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contact
belongs

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id of this
successful
MergeId String true true
merge
operation.

Error
FaultCode FaultString Description
(SourceContactId) was not found in
510 (Id) not found in database
database

Universal Contact Server API Guide 124


OMContacts MergeContacts

FaultCode FaultString Description


(DestinationContactId) was not found
510 (Id) not found in database
in database
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter
921 SubscriberId is invalid or not active The provided SubscriberId is not valid

Universal Contact Server API Guide 125


OMContacts MergeListGet

MergeListGet

Purpose
This method is intended for building of UCS-wide MergeList or specific list for particular agent.

This service returns the list of Contacts that have been merged. Results are paginated and the size of the page can
be limited using PageMaxSize parameter. Once the caller has finished iterating the merge list, the list must be
closed with the method MergeListRelease. UCS will use an internal timer to close the list if no activity is detected.

URL
• GET /OMContacts/MergeListGet/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


If present,
returns the
AgentId Integer Id of the agent merges done true true
by this agent
only.
Max size for
(schema/
PageMaxSize Integer the page of false true
select-limit)
data

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
Existing existing
MergeListId String false true
MergeListId MergeList
object for

Universal Contact Server API Guide 126


OMContacts MergeListGet

Key ValueType Value Description Mandatory Unique Default


which
GetMergeListNextPage
method
should be
applied.
Not available if
HasNext is false.

Number of
MergeId
RecordCount Integer records in true true
MergeData
list.
true if more
HasNext Integer true or false records are true true
available
Each merge
data pair is a
sub-list,
MergeData KVList false true
representing
one merge
data record.

MergeData KVList value

Key ValueType Value Description Mandatory Unique Default


A contact id KVList false true

A contact id

Key ValueType Value Description Mandatory Unique Default


Contact id of
the
DestinationContactId
String true true
destination
contact
Date of the
MergeDate String true true
merge
Contact id of
SourceContactId String the source true true
contact

Universal Contact Server API Guide 127


OMContacts MergeListGetNextPage

MergeListGetNextPage

Purpose
This method is intended for delivering the next portion of the merge records from the previously built MergeList.
Method provides unidirectional scrolling of selected records, no backward scrolling or jumping to the record with
arbitrary number.

URL
• GET /OMContacts/MergeListGetNextPage/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
MergeList
object for
Existing
MergeListId String which true true
MergeList Id
GetMergeListNextPage
method
should be
applied
Max size for
(schema/
PageMaxSize Integer the page of false true
select-limit)
data

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Existing Identifies the
MergeListId String false true
MergeListId existing

Universal Contact Server API Guide 128


OMContacts MergeListGetNextPage

Key ValueType Value Description Mandatory Unique Default


MergeList
object for
which
GetMergeListNextPage
method
should be
applied.
Not available if
HasNext is false

Number of
MergeId
RecordCount Integer true true
records in
MergeData list
true if more
HasNext Integer true or false records are true true
available
Each merge
data pair is a
sub-list,
MergeData KVList false true
representing
one merge
data record

MergeData KVList value

Key ValueType Value Description Mandatory Unique Default


A contact id KVList false true

A Contact id KVList value

Key ValueType Value Description Mandatory Unique Default


contact id of
the
DestinationContactId
String true true
destination
contact
date of the
MergeDate String true true
merge
contact id of
SourceContactId String the source true true
contact

Universal Contact Server API Guide 129


OMContacts MergeListRelease

MergeListRelease

Purpose
This method is intended for releasing of previously created MergeList.

URL
• PUT /OMContacts/MergeListRelease/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id of the
Existing
MergeListId String existing true true
MergeList Id
MergeList

Error
FaultCode FaultString Description
510 {0} not found in database ScrollableList does not exist

Universal Contact Server API Guide 130


OMContacts RemoveAllAttributes

RemoveAllAttributes

Purpose
This method is intended for removing all contact attributes.

URL
• PUT /OMContacts/RemoveAllAttributes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id for the
Any valid contact which
ContactId String true true
contact Id attributes will
be deleted
TenantId Integer true true
Important—The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
contact
belongs

Sample

ContactId KHS46XC46GK
TenantId 102

Universal Contact Server API Guide 131


OMContacts RemoveAllAttributes

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
Contact with Id=(ContactId) is not
510 {0} not found in database
found in database
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 132


OMContacts UnMergeContacts

UnMergeContacts

Purpose
This method is intended for rolling back of the previous contact merge.

Note on Contact objects:

• All modifications made to the Contact (new/updated/deleted attributes) after the merge operation are lost.

Note on Interaction objects:

• Interactions created and associated to a Contact before the merge operation are assigned back to this Contact.

URL
• PUT /OMContacts/UnMergeContacts/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id of the
successfully
Existing
ContactId String merged false true
contact Id
contact
destination.
Id of the
Existing successfully
SourceContactId String false true
contact Id merged
contact.

One and only one of MergeId or SourceContactId is mandatory.

Universal Contact Server API Guide 133


OMContacts UnMergeContacts

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Original Id of
the source
contact, the
SourceContactId String contact that true true
was restored
by this
operation.
Original Id of
the
destination
contact, the
DestinationContactId
String true true
contact that
was
unmerged by
this operation.

Error
FaultCode FaultString Description
No merged contact was found with
510 Not found in database
this Id

Universal Contact Server API Guide 134


OMContacts UpdateAttributes

UpdateAttributes

Purpose
This method is intended for updating contact attributes. New attributes can be added or existing attributes can be
updated or removed.

URL
• PUT /OMContacts/UpdateAttributes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Id for the
contact which
Any valid attributes will
ContactId String true true
contact Id be created,
updated, or
deleted
TenantId Integer true true
The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
contact
belongs
List with
attributes
InsertAttributes KVList false true
which have to
be inserted
List with
attributes
UpdateAttributes KVList false true
which have to
be updated

Universal Contact Server API Guide 135


OMContacts UpdateAttributes

Key ValueType Value Description Mandatory Unique Default


List with
attributes
DeleteAttributes KVList false true
which have to
be removed

InsertAttributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName) KVList false true

KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
(Attribute Index) == 0
KVList false true
Index) means
primary

KVList

Key ValueType Value Description Mandatory Unique Default


The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Config
Server(settings
/ type). If type
AttrValue StringBinary is set to: false true null
string (default):
value must be a
String date: value
must be a String
formatted with the
pattern: "yyyy-
MM-
ddTHH:mm:ss.SSSZ"
binary: value
must be a byte
array

Universal Contact Server API Guide 136


OMContacts UpdateAttributes

Key ValueType Value Description Mandatory Unique Default


Applicable for
binary
content,
MimeType String false true null
Max. length: 256
characters

Description to
be set for this
contact
attribute. For
example,
Description String false true null
EmailAddress
can be
described as
"(home)" or
"(office)", etc),

UpdateAttributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName) KVList false true

KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
(Attribute Index) = 0
KVList false true
Index) means
primary)

KVList

Key ValueType Value Description Mandatory Unique Default


AttrId String Attribute Id true true
The value
type of this
parameter
AttrValue StringBinary depends on false true null
the Contact
Attribute type
declared in

Universal Contact Server API Guide 137


OMContacts UpdateAttributes

Key ValueType Value Description Mandatory Unique Default


Config Server
(settings/
type). If type
is set to:
string(default):
value must be a
String Max.
length:
256characters
date: value must
be a String
formatted with the
pattern: "yyyy-
MM-
ddTHH:mm:ss.SSSZ"
binary: value
must be a byte
array

Applicable for
binary content
MimeType String false true
Max. length: 256
characters

Description to
be set for this
contact
attributes. For
example,
Description String false true
EmailAddress
can be
described as
"(home)" or
"(office)", etc

DeleteAttributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName)
is the system
name of a
Contact
Attribute as
(AttributeName) KVList declared in false true
Configuration
Serve
r(Tenant
specific
configuration)

Universal Contact Server API Guide 138


OMContacts UpdateAttributes

KVList

Key ValueType Value Description Mandatory Unique Default


AttrId String Attribute Id false false

Sample

ContactId KHS46XC46GK
TenantId 102
InsertAttributes EmailAddress 0 AttrValue alice.doe@genesys.com
LastName 0 AttrValue Doe
UpdateAttributes EmailAddress 1 AttrId JH8BVJH5J48KL59
AttrValue john.doe@genesys.com
DeleteAttributes EmailAddress AttrId SDF3S5435SDF5S3
AttrId GD6H5D4D6DF562X

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List with all
available (or a
subset
depending on
AttributeList
input
Attributes KVList false true
parameter)
attributes for
the contact
with
requested
ContactId

Attributes KVList

Key ValueType Value Description Mandatory Unique Default


(AttributeName)
(AttributeName) KVList false true
is the system

Universal Contact Server API Guide 139


OMContacts UpdateAttributes

Key ValueType Value Description Mandatory Unique Default


name of a
Contact
Attribute as
declared in
Configuration
Server(Tenant
specific
configuration)

KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
(Attribute Index) == 0
KVList false true
Index) means
primary

KVList

Key ValueType Value Description Mandatory Unique Default


AttrId String Attribute Id true true
The value
type of this
parameter
depends on
the Contact
Attribute type
declared in
Config Server
(settings/
AttrValue StringBinary type). If type false true null
is set to:
string(default):
value is a String
date: value is a
String formatted
with the pattern:
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
binary: value is a
byte array

Applicable for
binary
MimeType String false true
contentReturned
only if not null.

Universal Contact Server API Guide 140


OMContacts UpdateAttributes

Key ValueType Value Description Mandatory Unique Default


This is the
description
that can be
attached to
the contact
attribute.
Returned only
Description String false true
if not null. For
example,
EmailAddress
can be
described as
"(home)" or
"(office)", etc

Error
FaultCode FaultString Description
Contact with Id=(ContactId) is not
510 {0} not found in database
found in database
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 141


OMFieldCodes UpdateAttributes

OMFieldCodes
• RenderFieldCodes

• RenderMessageContent

• ValidateFieldCodes

Universal Contact Server API Guide 142


OMFieldCodes RenderFieldCodes

RenderFieldCodes

Purpose
The purpose is to replace the field codes with the current values in a template text.

URL
• POST /OMFieldCodes/RenderFieldCodes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Text String Text to parse true true
Interaction KVList false true
Contact KVList false true
Agent KVList false true
CustomPropertiesKVList false true

Interaction KVList

Key ValueType Value Description Mandatory Unique Default


Id String false true
Subject String false true
Formatted
with the
StartDate String pattern: "yyyy- false true
MM-
ddTHH:mm:ss.SSSZ"
TimeZone String false true
ToAddress String false true
FromAddress String false true

Universal Contact Server API Guide 143


OMFieldCodes RenderFieldCodes

Key ValueType Value Description Mandatory Unique Default


AttachedData KVList false false
OtherProperty KVList false false

Contact KVList

Key ValueType Value Description Mandatory Unique Default


Id String false true
FirstName String false true
LastName String false true
FullName String false true
Title String false true
PrimaryEmailAddress
String false true
PrimaryPhoneNumber
String false true
OtherProperty KVList false false

Agent KVList

Key ValueType Value Description Mandatory Unique Default


FirstName String false true
LastName String false true
FullName String false true
Signature String false true
OtherProperty KVList false false

CustomProperties KVList

Key ValueType Value Description Mandatory Unique Default


OtherProperty KVList false false

Universal Contact Server API Guide 144


OMFieldCodes RenderFieldCodes

OtherProperty and AttachedData KVList

Key ValueType Value Description Mandatory Unique Default


The name
should be
unique among
all "Property"
KVLists
(within all
Interaction
Name String Property true true
KVLists for
example,
there should
be one
"DateCreated"
key at
maximum)
Value String false false

Sample

Text Text to render


Interaction Subject MySubject
DateCreated 04/14/08 17:07:05
AttachedData Name Adata_1
Value Value_1
AttachedData Name Adata_2
Value Value2
OtherProperty Name Udata_1
Value Value_1
OtherProperty Name UData_2
Value Value_2
Contact PrimaryEmailAddress john@doe.com
OtherProperty Name UData_1
Value Value_1

Universal Contact Server API Guide 145


OMFieldCodes RenderFieldCodes

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Text String Result text false false
Is true if the
text was
Success String true or false false false
rendered
without errors

Universal Contact Server API Guide 146


OMFieldCodes RenderMessageContent

RenderMessageContent

Purpose
Renders the message content.

URL
• POST /OMFieldCodes/RenderMessageContent/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


One of
StandardResponseId,
TextMessageKeys
StandardResponseId
String false true
or
TextMessages
is mandatory
One of
StandardResponseId,
TextMessageKeys
TextMessageKeysString false true
or
TextMessages
is mandatory
One of
StandardResponseId,
TextMessageKeys
TextMessages KVList false true
or
TextMessages
is mandatory
FieldCodes KVList false true
FieldcodeFormatLocale
String false true

Universal Contact Server API Guide 147


OMFieldCodes RenderMessageContent

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


(Rendered
(TextMessageKey)
String false false
text)
If there was a
GEM_Failure Integer 1 rendering false false
error
If there was a
Rendering
GEM_FailureMsgString rendering false false
error
error
Semicolon-
separated list
containing the
TextMessageKeys
GEM_FailureArgsString false false
of the texts
that were not
rendered
correctly

Universal Contact Server API Guide 148


OMFieldCodes ValidateFieldCodes

ValidateFieldCodes

Purpose
Validates the specified stencil.

URL
• POST /OMFieldCodes/ValidateFieldCodes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The text that
needs
Text String validation (can true true
contain field
codes).

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Error
Errors KVList false false
message(s)

Universal Contact Server API Guide 149


OMFieldCodes ValidateFieldCodes

Errors KVList

Key ValueType Value Description Mandatory Unique Default


Line number
where the
StartLine Integer false false
error starts
(zero based).
Column
number where
StartColumn Integer the error false false
starts (zero
based).
Line number
where the
EndLine Integer false false
error ends
(zero based).
Column
number where
the error
EndColumn Integer false false
ends, plus
one (zero
based).
The character
position where
StartIndex Integer the problem false false
starts in the
source text.
The character
position where
the problem
EndIndex Integer false false
ends in the
source text,
plus one.
Human-
readable
Description String false false
string for this
exception.

Universal Contact Server API Guide 150


OMInteraction ValidateFieldCodes

OMInteraction
• Create

• Update

Universal Contact Server API Guide 151


OMInteraction Create

Create

Purpose
For OpenMedia Services (GIS/MIL/IRD).

URL
• POST /OMInteraction/Create/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


IdentifyCreateContact
String false true false
CanBeParent String false true true
DoNotThread String false true false
Text String false true
TextKey String false true
StructuredText String false true
StructuredTextKey
String false true
StructuredTextMimeType
String false true
ContentBinary Binary false true
ContentKey String false true
ContentMimeTypeString false true
Status Integer false true 2
Lang String false true
TimeShift Integer false true
EntityTypeId Integer false true 7

Universal Contact Server API Guide 152


OMInteraction Create

UserData

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
InteractionId String false true
ParentId String false true
ThreadId String false true
MediaType String false true
InteractionType String false true
InteractionSubtype
String false true
SubmittedBy String false true
ReceivedAt String false true
SubmittedAt String false true
ExternalId String false true
CategoryId String false true
Subject String false true

Universal Contact Server API Guide 153


OMInteraction Update

Update

Purpose
For OpenMedia Services (GIS/MIL/IRD).

URL
• PUT /OMInteraction/Update/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Text String false true
TextKey String false true
StructuredText String false true
StructuredTextKey
String false true
StructuredTextMimeType
String false true
ContentBinary Binary false true
ContentMimeTypeString false true
ThreadId String false true

UserData

Key ValueType Value Description Mandatory Unique Default


InteractionId String true true
ParentId String false true
ThreadId String false true
InteractionType String false true
InteractionSubtype
String false true

Universal Contact Server API Guide 154


OMInteraction Update

Key ValueType Value Description Mandatory Unique Default


ExternalId String false true
CategoryId String false true
Subject String false true

Universal Contact Server API Guide 155


OMInteractions Update

OMInteractions
• AddDocument

• AssignInteractionToContact

• CountInteractions

• DeleteInteraction

• FindOrCreatePhoneCall

• GetAttachment

• GetCategorizedInteractions

• GetDocument

• GetInteractionContent

• GetInteractionsForContact

• GetInteractionsWithStatus

• GetUnCategorizedInteractions

• InsertInteraction

• InteractionListGet

• InteractionListGetNextPage

• InteractionListRelease

• RemoveDocument

• SetInteractionStatus

• StopInteraction

• UpdateDocument
• UpdateInteraction

Universal Contact Server API Guide 156


OMInteractions AddDocument

AddDocument

Purpose
This method is intended to add a document to an Interaction. This method can be used in 2 modes:

• Link creation mode—UCS only creates an Attachment record to associate an existing Interaction(defined by the
InteractionId parameter)to an existing Document(defined by the DocumentId parameter).

• Document creation mode—UCS creates an Attachment record and a Document record and associates them to an
existing Interaction (defined by the InteractionId parameter) .

The Document record is created using the parameters MimeType, TheName, Description, TheSize, Content. UCS
returns the DocumentId in response.

UCS automatically works in "Link creation mode" when a parameter "DocumentId" is present in the request.

URL
• POST /OMInteractions/AddDocument/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Max. length:
InteractionId String true true
16 characters
Max. length:
16 characters
DocumentId String false true
Mandatory in link
creation mode

Max. length:
256
characters
MimeType String false true
Mandatory in link
creation mode

Universal Contact Server API Guide 157


OMInteractions AddDocument

Key ValueType Value Description Mandatory Unique Default


Max. length:
256
characters
TheName String false true
Mandatory in
document
creation mode

Max. length:
Description String 256 false true
characters
Optional, if not
populated it
will be
TheSize Integer false true
calculated
from content
size
Content Binary false true

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Mandatory in
DocumentId String document false true
creation mode

Universal Contact Server API Guide 158


OMInteractions AssignInteractionToContact

AssignInteractionToContact

Purpose
This method is intended for assigning a thread of Interactions to a Contact.

The indicated interaction will be set as the root parent interaction, and all children will be assigned to the same
thread and same ContactId.

URL
• PUT /OMInteractions/AssignInteractionToContact/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


InteractionId String Interaction Id true true
ContactId String Contact Id true true
TenantId Integer Tenant Id true true
The
subscriber
(line of
business)
within the
SubscriberId String false true
tenant to
which the
interaction
and contact
belongs
Specify if
ContactId
needs to be
NullAttributes String false true
reset for
example value
"ContactId"

Universal Contact Server API Guide 159


OMInteractions AssignInteractionToContact

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
The provided contactId doesn't match
510 Contact not found in database an existing contact within the
subtenant.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 160


OMInteractions CountInteractions

CountInteractions

Purpose
Counts the number of interactions. Search Criteria are the same as for InteractionListGet.

URL
• GET /OMInteractions/CountInteractions/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
interactions
belong
No filtering if
SearchCriteria KVList false true
not present
DataSource String Ignored in 9.0 false false

Universal Contact Server API Guide 161


OMInteractions CountInteractions

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Total Count of
TotalCount Integer false true
Interactions

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 162


OMInteractions DeleteInteraction

DeleteInteraction

Purpose
Deletes interactions from UCS.

URL
• DELETE /OMInteractions/DeleteInteraction/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
interaction Id
InteractionId String true true
Max length: 16
characters

Universal Contact Server API Guide 163


OMInteractions FindOrCreatePhoneCall

FindOrCreatePhoneCall

Purpose
Finds an existing PhoneCall object or, if no matching record is found, creates a new one.

URL
• POST /OMInteractions/FindOrCreatePhoneCall/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Phone Call
identifier,
UCS
Id String false true
Max length: 16 generated Id
characters

Duration Integer false true


Max. length:
OutCome String 100 false true
characters
Max. length:
PhoneNumber String false true
30 characters
Max. length:
TConnectionId String true true
16 characters
OwnerId Integer true true
TenantId Integer Tenant value true true
The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
interaction
should belong

Universal Contact Server API Guide 164


OMInteractions FindOrCreatePhoneCall

Key ValueType Value Description Mandatory Unique Default


This attribute
is mandatory
in MCR DB
but UCS
CanBeParent String false true true
provides a
default value if
no value is
provided
This attribute
is mandatory
in MCR DB
but UCS
CreatorAppId Integer false true UCS DBID
provides a
default value if
no value is
provided
Interaction
Type value
(must be
declared in
TypeId String true true
ConfigServer)
Max length: 32
characters

Formatted
String using
Date pattern
(in format
"yyyy-MM-
ddTHH:mm:ss.SSSZ") Current UCS
StartDate String false true
date
This attribute is
mandatory in
MCR DB but UCS
provides a default
value if no value
is provided

Must be one
of 0 (NEW), 1
Status Integer (PENDING), 2 true true
(IN_PROCESS),
3 (STOPPED)
Timeshift Integer false true
Max. length:
CategoryId String false true
16 characters
Interaction
Sub Type
SubtypeId String value (must false true
be declared in
ConfigServer)

Universal Contact Server API Guide 165


OMInteractions FindOrCreatePhoneCall

Key ValueType Value Description Mandatory Unique Default

Max length: 32
characters

Max length:
ExternalId String 256 false true
characters
Max length:
ThreadId String false true
16 characters
Max length:
Subject String 512 false true
characters
Value can be
IsCategoryApproved
String false true
true or false
Max. length:
StoppedReason String false true
64 characters
Max. length:
ContactId String false true
16 characters
Max. length:
ParentId String false true
16 characters
Max. length:
Lang String false true
64 characters
Max. length:
QueueName String false true
64 characters
Value can be
IsSpam String false true
true or false
Max. length:
WebSafeEmailStatus
String false true
32 characters
TheComment String false true
Formatted
String using
Date pattern
EndDate String false true
(in format
"yyyy-MM-
ddTHH:mm:ss.SSSZ")
User data key/
AllAttributes KVList false true
value pairs

Universal Contact Server API Guide 166


OMInteractions FindOrCreatePhoneCall

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String PhoneCall Id false true
true if a
Phone Call
record has
IsCreated String true or false been created false true
as a result of
this call, false
otherwise

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 167


OMInteractions GetAttachment

GetAttachment

Purpose
This method is intended for delivering the binary content of a document. It is identical to GetDocument but with a
different name. This is needed for PSDK because PSDK cannot have two messages with the same name, even in
different services.

URL
• GET /OMInteractions/GetAttachment/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
document Id
DocumentId String true true
Max. length: 16
characters

If set to true,
Content is
returned.
Otherwise,
IncludeBinaryContent
String true or false Content is not false true true
returned to
save IO and
memory
consumption.

Universal Contact Server API Guide 168


OMInteractions GetAttachment

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


MimeType String true true
TheName String true true
Description String false true
TheSize Integer true true
Content Binary false true

Error
FaultCode FaultString Description
Document with Id=(DocumentId) is
510 {0} not found in database
not found in database

Universal Contact Server API Guide 169


OMInteractions GetCategorizedInteractions

GetCategorizedInteractions

URL
• GET /OMInteractions/GetCategorizedInteractions/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer The TenantId true true
The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
interactions
belong
The start
period date in
StartPeriod String true true
ISO8601 Date
Format
The start
period date in
EndPeriod String true true
ISO8601 Date
Format
Maximum
PageMaxSize Integer scroll page false true 2147483647
size
KVList of
Strings (must
be long or int)
OwnerIds KVList representing false true
DBIds of the
optional
owners
Media type as
MediaType String defined in false true
configuration

Universal Contact Server API Guide 170


OMInteractions GetCategorizedInteractions

Key ValueType Value Description Mandatory Unique Default


(like email,
sms, chat and
so on).
Passing the
special value
$all$ will
return all
interaction
types. Note
that due to
legacy
compatibility,
not passing
the
MediaType
has the same
effect as
passing $all$.

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


If true it
means a
cursor has
been opened
HasNext String true or false true true
to allow call to
InteractionListGetNextPage
and
InteractionListRelease.
If
HasNext=true,
the Id of the
scrollable
ScrollId String cursor. To be false true
used with
InteractionListGetNextPage
and
InteractionListRelease.
The keys are
integers
starting from
InteractionData KVList 0, values are false true
KVList like
below where
Id is

Universal Contact Server API Guide 171


OMInteractions GetCategorizedInteractions

Key ValueType Value Description Mandatory Unique Default


interaction Id.
Subject and
OwnerId are
not returned if
corresponding
interaction
fields are null.
InteractionData={
0={
Attributes={
Text=My text
0 CategoryId
=
00001a8VG06Q003T
StartDate =
2013 - 06 -
12T08:54:29.000Z
Subject = My
email inbound
OwnerId=2301
} Id =
0002Ha8UNN5G0013
} 1={
Attributes={
Text=My text
1 CategoryId
=
00001a8VG06Q003S
StartDate =
2013 - 04 -
14T08:51:29.000Z
OwnerId =
2301 } Id =
0002Ha8UNN5G0015
} }

Number of
element
PageSize Integer true true
returned in the
page

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 172


OMInteractions GetDocument

GetDocument

Purpose
This method is intended for delivering the binary content of a document. In 9.0 the Datasource parameter is
ignored.

URL
• GET /OMInteractions/GetDocument/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
document Id
DocumentId String true true
Max. length: 16
characters

If set to true,
Content is
returned.
Otherwise,
IncludeBinaryContent
String true or false Content is not false true true
returned to
save IO and
memory
consumption.
DataSource String Ignored in 9.0 false false

Universal Contact Server API Guide 173


OMInteractions GetDocument

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


MimeType String true true
TheName String true true
Description String false true
TheSize Integer true true
Content Binary false true

Error
FaultCode FaultString Description
Document with Id=(DocumentId) is
510 {0} not found in database
not found in database

Universal Contact Server API Guide 174


OMInteractions GetInteractionContent

GetInteractionContent

Purpose
This method is intended for delivering the binary content of the interaction.

URL
• GET /OMInteractions/GetInteractionContent/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
interaction Id
InteractionId String true true
Max. length: 16
characters

If set to true,
Content &
MimeType are
returned.
Otherwise,
IncludeBinaryContent
String true or false Content & false true false
MimeType are
not returned
to save IO
and memory
consumption.
If set to true,
Attachments
are returned.
Otherwise,
IncludeAttachments
String true or false false true false
Attachments
are not
returned to
save IO and

Universal Contact Server API Guide 175


OMInteractions GetInteractionContent

Key ValueType Value Description Mandatory Unique Default


memory
consumption.
DataSource String Ignored in 9.0 false false

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The list of
attributes and
their values.
InteractionAttributes
KVList true true
KVList format
described in
InsertInteraction.
The list of
attributes and
their values.
KVList format
described in
InsertInteraction.The
list of
EntityAttributes KVList attributes false true
depends on
the
EntityTypeId
Mandatory if
EntityTypeId = 0,
1, 2, 3, 5or 6,

Binary
content.
KVList format
described in
InsertInteraction.
InteractionContentKVList Binary content false true
is only
returned if
IncludeBinaryContent
parameter is
set to true.
Attachments
are only
returned if
Attachments KVList false true
IncludeAttachments
parameter is
set to true.

Universal Contact Server API Guide 176


OMInteractions GetInteractionContent

Attachments KVList

Key ValueType Value Description Mandatory Unique Default


DocumentId is
the unique
(DocumentId) KVList false true
identifier of a
Document

(DocumentId) KVList

Key ValueType Value Description Mandatory Unique Default


MimeType String true true
TheName String true true
Description String false true
TheSize Integer true true
Only if
Content Binary IncludeBinaryContent
false true
set to true

Error
FaultCode FaultString Description
Interaction with Id=(InteractionId) is
510 {0} not found in database
not found in database

Universal Contact Server API Guide 177


OMInteractions GetInteractionsForContact

GetInteractionsForContact

Purpose
This method is intended for delivering of all of or some (depending on the filtering) of the interactions for the contact
in question.The aim of this method is to provide the Interaction history.

It returns only attributes from the Interaction table. This is because it is not possible to get MediaServer specific
attributes (which are scattered in multiple tables) in one request. Specific MediaServer attributes can be retrieved
individually by calling the GetInteractionContent method.

URL
• GET /OMInteractions/GetInteractionsForContact/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
contact Id,
whose
interactions
ContactId String true true
requested
Max length: 16
characters

DataSource String Ignored in 9.0 false false


No filtering if
SearchCriteria KVList false true
not present
No ordering if
SortCriteria KVList false true
not present
The list of
attributes,
AttributeList KVList false true
which have to
be delivered

Universal Contact Server API Guide 178


OMInteractions GetInteractionsForContact

Key ValueType Value Description Mandatory Unique Default


with each
interaction
The Tenant of
Contact
the Contact
TenantId Integer false true Tenant if not
and its
specified
Interactions
Important—The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
contact
belongs

SimpleConstraint KVList

Key ValueType Value Description Mandatory Unique Default


(Operator) KVList true true

(Operator) = EQUAL, NOT_EQUAL, GREATER, GREATER_OR_EQUAL, LESSER, LESSER_OR_EQUAL or LIKE

KVList

Key ValueType Value Description Mandatory Unique Default


The name of a
searchable
AttrName String true true
Interaction
Attribute.
The value
type of the
"AttrName"
parameter
AttrValue StringInteger false true
depends on
the
searchable
attribute.

Universal Contact Server API Guide 179


OMInteractions GetInteractionsForContact

ComplexConstraint KVList

Key ValueType Value Description Mandatory Unique Default


One instance
for NOT
operator,
(Operator) KVList more than one true false
instances for
AND or OR
operators

(Operator) = NOT, AND or OR KVList value detail is conform to SimpleConstraint or ComplexConstraint KVList
definition

SortCriteria KVList

Key ValueType Value Description Mandatory Unique Default


(Sort Index) KVList false true

KVList

Key ValueType Value Description Mandatory Unique Default


Can have
value of
Operator String true true
"ASC" or
"DSC".
The name of a
searchable
AttrName String true true
Interaction
Attribute.

AttributeList KVList

Key ValueType Value Description Mandatory Unique Default


String value
represents
attribute
name. The
name of an
AttrName String false false
Interaction
Attribute. If no
AttrName
parameter is
specified, only

Universal Contact Server API Guide 180


OMInteractions GetInteractionsForContact

Key ValueType Value Description Mandatory Unique Default


default
AttributeList is
returned.

Sample

ContactId KHS46XC46GK
AttributeList AttrName Id
AttrName TypeId
AttrName SubtypeId
SearchCriteria AND EQUAL AttrName Status
AttrValue 2
AND NOT_EQUAL AttrName ThreadId
AttrValue WX345SBGA34TFGGS
SortCriteria 0 Operator ASC
AttrName StartDate

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of
interactions,
ContactInteractions
KVList related to false true
contact in
question

ContactInteractions KVList

Key ValueType Value Description Mandatory Unique Default


(Interaction
Index) is a
(Interaction string
KVList false true
Index) representation
of an integer
index used to

Universal Contact Server API Guide 181


OMInteractions GetInteractionsForContact

Key ValueType Value Description Mandatory Unique Default


maintain
Interactions
ordering,
starts with 0

KVList

Key ValueType Value Description Mandatory Unique Default


Id String Interaction Id true true
The list of
interaction
attributes.
Attribute "Id"
is never
Attributes KVList false false
delivered with
this list even if
requested
directly in
AttributeList.

Attributes KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
Name) is the
name of the
attribute as
specified in
(Attribute the request.
StringIntegerBinaryKVList false true
Name)
The value type
depends on
attribute as
described in
OMInteractions /
InsertInteraction.

Sample

ContactInteractions 0 Id (InteractionId-1)
Attributes (AttributeName-1) AttributeValue1
(AttributeName-2) AttributeValue2

Universal Contact Server API Guide 182


OMInteractions GetInteractionsForContact

1 Id (InteractionId-2)
Attributes (AttributeName-1) AttributeValue
(AttributeName-2); AttributeValue2

Universal Contact Server API Guide 183


OMInteractions GetInteractionsWithStatus

GetInteractionsWithStatus

Purpose
This method is intended for delivering the set of interactions with requested status.

URL
• GET /OMInteractions/GetInteractionsWithStatus/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Mandatory
Status Integer true true
parameter
configuration
declared
Media Type
MediaType String true true
Max length: 32
characters

Configuration
declared
Interaction
InteractionType String Type true true
Max length: 32
characters

Configuration
declared
Interaction
InteractionSubtype
String SubType false true
Max length: 32
characters

Application
SubmittedBy String name as false true
specified in

Universal Contact Server API Guide 184


OMInteractions GetInteractionsWithStatus

Key ValueType Value Description Mandatory Unique Default


Configuration
Server

UserData

Key ValueType Value Description Mandatory Unique Default


MediaType String false true
InteractionType String false true
InteractionSubtype
String false true
SubmittedBy String false true

Success/Request3rdServerResponse

Parameters

Key ValueType Value Description Mandatory Unique Default


The list of Ids
IdList KVList of matching false true
Interactions.

IdList KVList

Key ValueType Value Description Mandatory Unique Default


String value
Id String represents false false
interaction id

Sample

IdList Id ABCDEFJIOQJDLHDE
Id LKJ3456987SDFGLD
Id KJ870345LKJHFVLK

Universal Contact Server API Guide 185


OMInteractions GetUnCategorizedInteractions

GetUnCategorizedInteractions

URL
• GET /OMInteractions/GetUnCategorizedInteractions/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer The TenantId true true
The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
interactions
belong
The start
period date in
StartPeriod String true true
Iso8601 Date
Format
The start
period date in
EndPeriod String true true
Iso8601 Date
Format
Maximum
PageMaxSize Integer scroll page false true 2147483647
size
KVList of
Strings (must
be long or int)
OwnerIds KVList representing false true
DBIds of the
optional
owners

Universal Contact Server API Guide 186


OMInteractions GetUnCategorizedInteractions

Key ValueType Value Description Mandatory Unique Default


Media type as
defined in
configuration
(like email,
sms, chat ...).
Passing the
special value
$all$ will
return all
interaction
MediaType String types. Note false true
that due to
legacy
compatibility,
not passing
the
MediaType
has the same
effect as
passing
"email".

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


If true it
means a
cursor has
been opened
HasNext String true or false true true
to allow call to
InteractionListGetNextPage
and
InteractionListRelease.
If
HasNext=true,
the Id of the
scrollable
ScrollId String cursor. To be false true
used with
InteractionListGetNextPage
and
InteractionListRelease.
The keys are
integers
InteractionData KVList false true
starting from
0, values are

Universal Contact Server API Guide 187


OMInteractions GetUnCategorizedInteractions

Key ValueType Value Description Mandatory Unique Default


KVList like
below where
Id is
interaction Id.
Subject and
OwnerId are
not returned if
corresponding
interaction
fields are null.
InteractionData={
0={ Attributes={
Text=My text 0
StartDate = 2013
- 06 -
14T08:51:29.000Z
Subject = My
email inbound
OwnerId=2301 }
Id =
0002Ha8UNN5G0013
} 1={ Attributes={
Text=My text 1
StartDate = 2013
- 04 -
14T08:51:29.000Z
Subject = My
email inbound
OwnerId=2301 }
Id =
0002Ha8UNN5G0015
}}

Number of
element
PageSize Integer true true
returned in the
page

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 188


OMInteractions InsertInteraction

InsertInteraction

Purpose
This method is intended for the creation of new interactions in UCS.

URL
• POST /OMInteractions/InsertInteraction/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The list of
InteractionAttributes
KVList attributes and true true
their values.
The list of
Entity specific
attributes and
their values.
The list of
attributes
EntityAttributes KVList depends on false true
the
EntityTypeId
mandatory if
EntityTypeId=0, 1,
2, 3, 5, or 6

InteractionContentKVList Content. false true


Important—Supports
specifically
InteractionContentSentReceived
KVList false true
ESJ MIME
Customization
Important—(For
DeleteAllAttachmentsBefore
String false true false
ESJ only)

Universal Contact Server API Guide 189


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


Introduced to
support ESJ
insert
interaction
with
attachments,
delete all
previous
attachments
before adding
new ones.
Important—(For
ESJ only)
Introduced to
support ESJ
insert
interaction
Attachments KVList false true
with
attachments.
The list of
attachments
for this
interaction.

InteractionAttributes

Key ValueType Value Description Mandatory Unique Default


TenantId Integer Tenant value true true
Important—The
subscriber
(line of
business)
SubscriberId String within the false true
tenant to
which the
interaction
belongs
Media Type
value (must
be declared in
Configuration
MediaTypeId String true true
Server).
Max length: 32
characters

This attribute
is mandatory
CanBeParent String false true true
in MCR DB
but UCS

Universal Contact Server API Guide 190


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


provides a
default value if
no value is
provided
This attribute
is mandatory
in MCR DB
but UCS
CreatorAppId Integer false true UCS DBID
provides a
default value if
no value is
provided
Interaction
Type value
(must be
declared in
TypeId String Configuration true true
Server)
Max length: 32
characters

Formatted
String using
Date pattern
(in format
"yyyy-MM-
ddTHH:mm:ss.SSSZ") Current UCS
StartDate String false true
date
This attribute is
mandatory in
MCR DB but UCS
provides a default
value if no value
is provided

Must be one
of 0 (NEW), 1
Status Integer (PENDING), 2 true true
(IN_PROCESS),
3 (STOPPED)
Max. length: UCS
Id String false true
16 characters generated Id
Timeshift Integer false true null
Max. length:
CategoryId String false true
16 characters
Max. length:
SubtypeId String false true
32 characters
Max. length:
ExternalId String 256 false true
characters

Universal Contact Server API Guide 191


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


Max. length:
ThreadId String false true
16 characters
Max. length:
Subject String 512 false true
characters
Value can be
IsCategoryApproved
String false true
true or false
Max. length:
StoppedReason String false true
64 characters
Max. length:
ContactId String false true
16 characters
Max. length:
ParentId String false true
16 characters
Max. length:
Lang String false true
64 characters
Max. length:
QueueName String false true
64 characters
Value can be
IsSpam String false true
true or false
Max. length:
WebSafeEmailStatus
String false true
32 characters
OwnerId Integer false true
TheComment String false true
Formatted
String using
Date pattern
EndDate String false true
(in format
"yyyy-MM-
ddTHH:mm:ss.SSSZ")
User data key/
AllAttributes KVList false true
value pairs
Possible
values are:
0:EmailIn
1:EmailOut
2:Chat
3:PhoneCall
5:Callback
6:CoBrowse
EntityTypeId Integer (deprecated) false true 7
7:Interaction If
EntityTypeId is
not equal to 7,
then specific
parameters might
be required(see
XxxAttributes
KVList details).

Universal Contact Server API Guide 192


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


Important—Comma-
separated
attributes
names as
NullAttributes String described false true
above); for
example,
"Text,
StructuredText"

EntityAttributes KVList (EntityTypeId = 0)

Key ValueType Value Description Mandatory Unique Default


Must conform
to RFC
FromAddress String false true
Max length: 256
characters

Must conform
to RFC
FromPersonal String false true
Max length: 256
characters

Must conform
to RFC
ReplyToAddress String false true
Max length: 256
characters

Must conform
ToAddresses String false true
to RFC
Must conform
CcAddresses String false true
to RFC
Must conform
BccAddresses String false true
to RFC
Formatted
with pattern
SentDate String false true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Max. length:
Mailbox String 256 true true
characters
Max. length:
WhichRuleMatched
String false true
16 characters
Max. length:
EmailOutId String false true
16 characters

Universal Contact Server API Guide 193


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


Important—Applies
also to
GetInteractionContent
Header Binary false true
if
EntityTypeId=0
EmailIn
Important—Comma-
separated
attributes
names as
NullAttributes String described false true
above; for
example,
"Text,
StructuredText"

EntityAttributes KVList (EntityTypeId = 1)

Key ValueType Value Description Mandatory Unique Default


Must conform
FromAddress String false true
to RFC
Must conform
FromPersonal String false true
to RFC
Must conform
ReplyToAddress String false true
to RFC
Must conform
ToAddresses String false true
to RFC
Must conform
CcAddresses String false true
to RFC
Must conform
BccAddresses String false true
to RFC
Formatted
with pattern
SentDate String false true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Forward Integer true true
Max. length:
ReferenceId String 255 false true
characters
ReviewerId Integer false true
Max. length:
StandardResponseId
String false true
16 characters
Important—Comma-
NullAttributes String false true
separated

Universal Contact Server API Guide 194


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


attributes
names as
described
above; for
example,
"Text,
StructuredText"

EntityAttributes KVList (EntityTypeId = 2)

Key ValueType Value Description Mandatory Unique Default


Formatted
with pattern
EstablishedDate String false true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Formatted
with pattern
ReleasedDate String false true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Important—Comma-
separated
attributes
names as
NullAttributes String described false true
above; for
example,
"Text,
StructuredText"

EntityAttributes KVList (EntityTypeId = 3)

Key ValueType Value Description Mandatory Unique Default


Duration Integer false true
Max. length:
Outcome String 100 false true
characters
Max. length:
PhoneNumber String false true
30 characters
Max. length:
TConnectionId String false true
16 characters
Important—Comma-
NullAttributes String separated false true
attributes

Universal Contact Server API Guide 195


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


names as
described
above; for
example,
"Text,
StructuredText"

EntityAttributes KVList (EntityTypeId = 5)

Key ValueType Value Description Mandatory Unique Default


CallBackStatus Integer false true
DetailedDescription
String false true
CustomData String false true
DesiredResponseType
Integer true true
Formatted
with pattern
StartTime String true true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Formatted
with pattern
EndTime String false true
"yyyy-MM-
ddTHH:mm:ss.SSSZ"
Max. length:
CustomerNumberString true true
32 characters
Attempts Integer true true
Max. length:
DN String false true
32 characters
Max. length:
Location String false true
32 characters
Max. length:
CallbackServerIDString 256 false true
characters
CallResult Integer false true
TheType Integer false true
Comma-
separated
attributes
names as
NullAttributes String false true
described
above, such
as "Text,
StructuredText"

Universal Contact Server API Guide 196


OMInteractions InsertInteraction

EntityAttributes KVList (EntityTypeId = 6)

Key ValueType Value Description Mandatory Unique Default


The String
value
formatted with
pattern "yyyy-
MM-
ddTHH:mm:ss.SSSZ"
(Visited URL) String false false
is the Visited
Date
(Visited URL)
Max length: 255
characters

Comma-
separated
attributes
names as
NullAttributes String false true
described
above, such
as "Text,
StructuredText"

InteractionContent

Key ValueType Value Description Mandatory Unique Default


Text String false true
StructuredText String false true
Max. length:
StructTextMimeType
String 256 false true
characters
If not null, a
record is
Content Binary created in false true
IxnContent
table
This
parameter is
mandatory if
Content is not
MimeType String false true
null
Max length: 256
characters

Comma-
NullAttributes String separated false true
attributes

Universal Contact Server API Guide 197


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default


names as
described
above, such
as "Text,
StructuredText"

InteractionContentSentReceived KVList

Key ValueType Value Description Mandatory Unique Default


If not null, a
record is
Content Binary created in true true
IxnContentSentReceived
table
Max. length:
MimeType String 256 true true
characters

8.1.1

Attachments KVList

Key ValueType Value Description Mandatory Unique Default


(Index) KVList false true

8.1.1, ESJ only

KVList

Key ValueType Value Description Mandatory Unique Default


Mandatory in
link creation
mode
DocumentId String false true
If not null, attach
this document ID
to this interaction

Mandatory in
document
creation mode
MimeType String false true
Max. length: 256
characters

Mandatory in
TheName String document false true
creation mode

Universal Contact Server API Guide 198


OMInteractions InsertInteraction

Key ValueType Value Description Mandatory Unique Default

Max. length: 256


characters

Max. length:
Description String 256 false true
characters
TheSize Integer false true
Mandatory in
Content Binary document false true
creation mode

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique id for
InteractionId String newly created true true
interaction

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
Contact with Id={0} and The provided contactId doesn't match
510 SubscriberId={1} not found in an existing contact within the
database subtenant.
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 199


OMInteractions InteractionListGet

InteractionListGet

Purpose
This method provides a ScrollableList of interactions, filtered by constraints and sorted using criteria.

URL
• GET /OMInteractions/InteractionListGet/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
The
subscriber
(i.e. line of
business)
SubscriberId String within the false true
tenant to
which the
interactions
belong
If no value is
provided,
UCS
configured (schema/
PageMaxSize Integer false true
value select-limit)
(schema/
select-limit) is
used.
DataSource String Ignored in 9.0 false false
Possible 7: Open
values are: 0: Media
EmailIn, 1: Interaction
EntityTypeId Integer false true
EmailOut, 2:
If no set, entity
Chat, 3: specific
PhoneCall, 5:

Universal Contact Server API Guide 200


OMInteractions InteractionListGet

Key ValueType Value Description Mandatory Unique Default


Callback, 6:
CoBrowse information
cannot be
(deprecated), searched, but it is
7: Interaction returned.
(default)
Raw Lucene
Query. If
present,
ESQuery String overrides both false true
SearchCriteria
and
SortCriteria.
No filtering if
SearchCriteria KVList false true
not present
No ordering if
SortCriteria KVList false true
not present
The list of
attributes,
which have to
AttributeList KVList false true
be delivered
with each
interaction

Please refer to www.elastic.co/guide/en/elasticsearch/reference/1.7/query-dsl.html for a description of the ESQuery


possible values

SearchCriteria KVList. SimpleConstraint KVList

Key ValueType Value Description Mandatory Unique Default


(Operator) KVList true true

(Operator) = EQUAL, NOT_EQUAL, GREATER, GREATER_OR_EQUAL, LESSER, LESSER_OR_EQUAL or LIKE

KVList

Key ValueType Value Description Mandatory Unique Default


The name of a
searchable
AttrName String true true
Interaction
Attribute.
The value
type of the
"AttrName"
parameter
AttrValue String false true
depends on
the
searchable
attribute.

Universal Contact Server API Guide 201


OMInteractions InteractionListGet

SearchCriteria KVList. ComplexConstraint KVList

Key ValueType Value Description Mandatory Unique Default


One instance
for NOT
operator,
(Operator) KVList more than one true false
instances for
AND or OR
operators

(Operator) = NOT, AND or OR KVList value detail is conform to SimpleConstraint or ComplexConstraint KVList
definition

SortCriteria KVList

Key ValueType Value Description Mandatory Unique Default


(Sort Index) KVList false true

KVList

Key ValueType Value Description Mandatory Unique Default


Can have
value of
Operator String true true
"ASC" or
"DSC".
The name of a
searchable
AttrName String true true
Interaction
Attribute.

AttributeList KVList

Key ValueType Value Description Mandatory Unique Default


String value
represents
`the name of
an Interaction
AttrName String false false
Attribute.
If no AttrName
parameter is

Universal Contact Server API Guide 202


OMInteractions InteractionListGet

Key ValueType Value Description Mandatory Unique Default

specified, only
default
"AttributeList" is
returned.

Sample

TenantId 102
SearchCriteria AND EQUAL AttrName Status
AttrValue 2
AND NOT_EQUAL AttrName ThreadId
AttrValue WX345SBGA34TFGGS
SortCriteria 0 Operator ASC
AttrName StartDate
AttributeList AttrName Id
AttrName TypeId
AttrName SubtypeId

Sample

TenantId 102
Segment Airbnb
SearchCriteria EQUAL AttrName ESQuery
+ThreadId:WX345SBGA34TFGGS
AttrValue
+Status:2
AttributeList AttrName Id
AttrName TypeId
AttrName SubtypeId

Sample

TenantId 102
Segment Airbnb
+ThreadId:WX345SBGA34TFGGS
ESQuery
+Status:2
AttributeList AttrName Id
AttrName TypeId

Universal Contact Server API Guide 203


OMInteractions InteractionListGet

AttrName SubtypeId

Sample

TenantId 102
Segment Airbnb
{ "query" : { "bool" : {"must" : { "term" :
{ "ThreadId" :
ESQuery "WX345SBGA34TFGGS" }
},"must_not" : { "range" : { "Status" : {
"from" : 1, "to" : 3 } }} } }
AttributeList AttrName Id
AttrName TypeId
AttrName SubtypeId

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


This id is used
to call
ScrollableList LookupNextPage.
ScrollId String false true
Id
not available if
HasNext is false

The number
of Contacts
PageSize Integer true true
available in
this page
Indicates
more records
are available
(using method
LookupNextPage).
If true:
CloseLookup
method is to be
HasNext String true or false true true
called after
iteration If false:
UCS
automatically
closes the list and
there is no need
to call
CloseLookup
method

Universal Contact Server API Guide 204


OMInteractions InteractionListGet

Key ValueType Value Description Mandatory Unique Default


InteractionData KVList false true

InteractionData KVList

Key ValueType Value Description Mandatory Unique Default


(Interaction
Index) is a
String
representation
(Interaction
KVList of an integer false true
Index)
index used to
maintain
Interactions
ordering

KVList

Key ValueType Value Description Mandatory Unique Default


Id String Interaction Id false true
The list of
interaction
attributes.
Attribute "Id"
is never
Attributes KVList false true
delivered with
this list even if
requested
directly in
AttributeList.

KVList

Key ValueType Value Description Mandatory Unique Default


(Attribute
Name) is the
name of the
(AttributeName) StringInteger true true
attribute as
specified in
the request.

Universal Contact Server API Guide 205


OMInteractions InteractionListGet

Error
FaultCode FaultString Description
SubscriberId was not provided but is
201 Missing parameter 'SubscriberId'
a required parameter.
533 Invalid ES Query Provided ESQuery is malformed
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS
SubscriberId '{0}' is invalid or not The provided SubscriberId is not
921
active. valid.

Universal Contact Server API Guide 206


OMInteractions InteractionListGetNextPage

InteractionListGetNextPage

Purpose
This method allow to scroll through next page of interactions previously found using InteractionListGet.

URL
• GET /OMInteractions/InteractionListGetNextPage/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
ScrollableList
Existing object for
ScrollId String ScrollableList which true true
Id ScrollableList.next(int
max) method
should be
applied
Max size for
the page of
data,
PageMaxSize Integer calculated as false true
min(PageMaxSize,
UCS internal
limit)

Universal Contact Server API Guide 207


OMInteractions InteractionListGetNextPage

Success
Parameters

Key ValueType Value Description Mandatory Unique Default


The number
Existing
of Contacts
PageSize Integer ScrollableList true true
available in
Id
this page
Indicates
more records
HasNext String true or false are available true true
(using method
InteractionListGetNextPage).
See
InteractionListGet
InteractionData KVList method for false true
InteractionData
format

Error
FaultCode FaultString Description
510 {0} not found in database ScrollableList does not exist

Universal Contact Server API Guide 208


OMInteractions InteractionListRelease

InteractionListRelease

Purpose
This method will release a previously created ScrollableList from InteractionGet.

URL
• PUT /OMInteractions/InteractionListRelease/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Identifies the
existing
ScrollableList
Existing object for
ScrollId String ScrollableList which true true
Id ScrollableList.close()
method
should be
applied

Error
FaultCode FaultString Description
510 {0} not found in database ScrollableList does not exist

Universal Contact Server API Guide 209


OMInteractions RemoveDocument

RemoveDocument

Purpose
This method is intended to remove a document. If the related Document is no more referenced by any Attachment
(no more associated to any Interaction or StandardResponse), the Document record is also removed from
database.

URL
• DELETE /OMInteractions/RemoveDocument/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The
Document
Max. length:
DocumentId String which will be true true
16 characters
removed from
database
If InteractionId
parameter is
available, all
links from this
Interaction to
the specified
Document are
Max. length: removed.
InteractionId String false true
16 characters
Otherwise, all
links from all
Interactions to
this Document
are removed, and
the Document
itself is also
removed.

Universal Contact Server API Guide 210


OMInteractions SetInteractionStatus

SetInteractionStatus

Purpose
This method is intended for changing interaction status.

URL
• PUT /OMInteractions/SetInteractionStatus/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Unique
interaction id
InteractionId String true true
Max length: 16
characters

TenantId Integer true true


Status:
New:0
Status Integer Pending(IxnSvr):1 true true
InProcess(IxnSvr):2
Stopped:3

Reason for
status change
StoppedReason String false true No change
Max length: 64
characters

Universal Contact Server API Guide 211


OMInteractions SetInteractionStatus

Error
FaultCode FaultString Description
Interaction with Id=(InteractionId) is
510 {0} not found in database
not found in database
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS

Universal Contact Server API Guide 212


OMInteractions StopInteraction

StopInteraction

Purpose
This method is intended for stopping an interaction.

URL
• PUT /OMInteractions/StopInteraction/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Reason for
Reason String the Stop false true
Processing
If true and if
the Interaction
Delete String true or false false true false
has no child, it
will be deleted
InteractionId String Interaction Id true true
InteractionType String false true
MediaType String false true
TenantId Integer true true
User data are
saved in
database
except:

• InteractionId
(other user
StringIntegerKVList • ParentId false false
data)
• ExternalId

• MediaType

• Type

Universal Contact Server API Guide 213


OMInteractions StopInteraction

Key ValueType Value Description Mandatory Unique Default

• Subtype

• State

• StagingArea

• SubmittedBy

• TenantId

• ReceivedAt

• SubmittedAt

• DeliveredAt

• PlacedInQueueAt

• WorkbinAgentId

• WorkbinAgentGroupId

• WorkbinPlaceId

• WorkbinPlaceGroupId

• Queue

Universal Contact Server API Guide 214


OMInteractions UpdateDocument

UpdateDocument

Purpose
This method is intended to update a document.

URL
• PUT /OMInteractions/UpdateDocument/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Max. length:
DocumentId String true true
16 characters
Max. length:
Cannot be null
MimeType String 256 false true
if present
characters
Max. length:
Cannot be null
TheName String 256 false true
if present
characters
Max. length:
Description String 256 false true
characters
Cannot be null
TheSize Integer false true
if present
Content Binary false true

Universal Contact Server API Guide 215


OMInteractions UpdateInteraction

UpdateInteraction

Purpose
This method is intended for updating of interaction attributes and binary content.

URL
• PUT /OMInteractions/UpdateInteraction/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The list of
attributes and
their values,
which have to
be updated.
KVList format
described in
OMInteractions
/
InsertInteraction.
If
MediaServer
specific
InteractionAttributes
KVList parameters true true
must be
updated, then
EntityTypeId
is also
required.
Attributes
which are
declared as
mandatory in
InsertInteraction
method
description
and attributes

Universal Contact Server API Guide 216


OMInteractions UpdateInteraction

Key ValueType Value Description Mandatory Unique Default


CanBeParent,
CreatorAppId,
StartDate
must have a
not null value
if passed in
UpdateInteraction.
Id and
TenantId are
mandatory
attributes.
EntityTypeId is
required if
MediaServer
specific
parameters are
updated. Id,
TenantId,
SubscriberId,
MediaTypeId and
EntityTypeId are
immutable
attributes. They
should never be
set to a new
value.

The list of
Entity specific
attributes and
their values,
which have to
be updated.
KVList format
described in
OMInteractions
/
InsertInteraction.
Attributes
which are
EntityAttributes KVList false true
declared as
mandatory in
InsertInteraction
method
description
must have a
not null value
if passed in
UpdateInteraction.
Mandatory if
EntityTypeId =
0, 1, 2, 3, 5, or
6.
Information to
InteractionContentKVList update binary false true
content.

Universal Contact Server API Guide 217


OMInteractions UpdateInteraction

Key ValueType Value Description Mandatory Unique Default


KVList format
described in
OMInteractions
/
InsertInteraction.
Attributes
which are
declared as
mandatory in
InsertInteraction
method
description
must have a
not null value
if passed in
UpdateInteraction.
Important—Introduced
to support
specifically
ESJ MIME
Customization.
InteractionContentSentReceived
KVList false true
KVList format
described in
OMInteractions
/
InsertInteraction.
Important—(For
ESJ only)
Introduced to
support ESJ
insert
interaction
DeleteAllAttachmentsBefore
String with false true false
attachments,
delete all
previous
attachments
before adding
new ones.
Important—(For
ESJ only)
Introduced to
support ESJ
insert
interaction
Attachments KVList false true
with
attachments.
The list of
attachments
for this
interaction.

Universal Contact Server API Guide 218


OMInteractions UpdateInteraction

Key ValueType Value Description Mandatory Unique Default


**Deprecated**
(was
Action String applicable to false true
CoBrowse
records)

[RG]UCS will distinguish between:(AttributeName) key not present (meaning no update required for this
attribute)and (AttributeName)= null(meaning this attribute must be updated with a null value-the attribute must be
nullable!)

InteractionAttributes

Key ValueType Value Description Mandatory Unique Default


Interaction
Type value
(must be
declared in
TypeId String false true
ConfigServer)
Max.length: 32
characters

Formatted
String using
Date pattern Current UCS
StartDate String false true
(in format date
"yyyy-MM-
ddTHH:mm:ss.SSSZ")
Formatted
String using
Date pattern
EndDate String false true
(in format
"yyyy-MM-
ddTHH:mm:ss.SSSZ")
TheComment String false true
Subject String false true
CanBeParent String false true
ContactId String false true
CreatorAppId Integer false true
Must be one
of 0 (NEW), 1
Status Integer (PENDING), 2 false true
(IN_PROCESS),
3 (STOPPED)
Timeshift Integer false true
Max. length:
CategoryId String false true
16 characters

Universal Contact Server API Guide 219


OMInteractions UpdateInteraction

Key ValueType Value Description Mandatory Unique Default


Max. length:
SubtypeId String false true
32 characters
Max. length:
ExternalId String 256 false true
characters
Max. length:
ThreadId String false true
16 characters
Value can be
IsCategoryApproved
String false true
true or false
Max. length:
StoppedReason String false true
64 characters
Max. length:
Lang String false true
64 characters
Max. length:
QueueName String false true
64 characters
Value can be
IsSpam String false true
true or false
Max. length:
WebSafeEmailStatus
String false true
32 characters
OwnerId Integer false true
User data key/
AllAttributes KVList false true
value pairs
Possible
values are:
0:EmailIn
1:EmailOut
EntityTypeId Integer 2:Chat false true
3:PhoneCall
5:Callback
6:CoBrowse
(deprecated)
7:Interaction

Error
FaultCode FaultString Description
Interaction with Id=(InteractionId) is
510 {0} not found in database
not found in database
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS

Universal Contact Server API Guide 220


OMResponse UpdateInteraction

OMResponse
• CheckForUpdates

• GetAgentStdRespFavorites

• GetAllCategoryStatistics

• GetAllFAQObjectCategories

• GetAllGlobalStatistics

• GetAllGroups

• GetAllRegEx

• GetAllRules

• GetAllTestMessage

• GetCategory

• GetCategoryAttribute

• GetCategoryAttributes

• GetCategoryStatistics

• GetConfusionMatrices

• GetConfusionMatrix

• GetDocument

• GetEmailClassificationResult

• GetEmailClassificationResults

• GetFAQObjects

• GetFAQObjectCategories
• GetFieldCode

• GetFieldCodes

• GetFieldValue

• GetFieldValues

• GetGlobalStatistics

• GetGroup

• GetGroupContent

• GetModel

• GetModels

• GetRegEx

• GetRootCategories

Universal Contact Server API Guide 221


OMResponse UpdateInteraction

• GetRule

• GetScreeningRule

• GetScreeningRules

• GetStandardResponse

• GetStandardResponses

• GetTestMessage

• GetTestingResult

• GetTestingResults

• GetTrainingDataObject

• GetTrainingDataObjects

• GetTrainingEmail

• GetTrainingEmails

• GetTrainingJob

• GetTrainingJobs

• GetUpdates

• TrainingEmailListGet

• TrainingEmailListNext

Universal Contact Server API Guide 222


OMResponse CheckForUpdates

CheckForUpdates

Purpose
This method is intended for checking whether standard responses were updated or not since the time, provided as
a time-stamp.

URL
• GET /OMResponse/CheckForUpdates/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
The
configuration
Language String Language true true
Max.length:64characters

Time-stamp
from the last
update (in
LastUpdate String true true
format "yyyy-
MM-
ddTHH:mm:ss.SSSZ").

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


If true, UCS
NeedsUpdate String true or false true true
has newer

Universal Contact Server API Guide 223


OMResponse CheckForUpdates

Key ValueType Value Description Mandatory Unique Default


version of
SRL, client
copy has to
be updated, if
false, no
updates
required.

Universal Contact Server API Guide 224


OMResponse GetAgentStdRespFavorites

GetAgentStdRespFavorites

Purpose
Get the list of all Standard Response Favorites of an agent.

URL
• GET /OMResponse/GetAgentStdRespFavorites/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Agent Id
AgentId Integer (config server true true
DB id)

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


A Standard
Response Id
StdResp String in the false false
favorites of
this agent

Sample

Agent with 3 standard response favorites

Universal Contact Server API Guide 225


OMResponse GetAgentStdRespFavorites

StdResp 00001a39C4C9001H
StdResp 00001a39C4C9001J
StdResp 00001a39C4C9001K

Universal Contact Server API Guide 226


OMResponse GetAllGroups

GetAllGroups

Purpose
This method is intended for downloading of all PII Groups in specific tenant/SubscriberId.

URL
• GET /OMResponse/GetAllGroups/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The tenant ID
TenantId Integer of Groups to true true
retrieve
The
subscriber
(that is, line of
SubscriberId String false true
business)
within the
tenant

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Groups KVList List of groups false true

Universal Contact Server API Guide 227


OMResponse GetAllGroups

Group KVList

Key ValueType Value Description Mandatory Unique Default


ID of the
(GroupId) KVList false true
group

GroupId KVList

Key ValueType Value Description Mandatory Unique Default


255 chars Name of the
Name String true true
max group
255 chars Description of
Description String true true
max the group
Type of the
Type String 16 chars max true true
group
CategoryId String 16 chars false true

Error
FaultCode FaultString Description
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 228


OMResponse GetAllRegEx

GetAllRegEx

Purpose
This method is intended for downloading of all PII RegEx in specific tenant/SubscriberId.

URL
• GET /OMResponse/GetAllRegEx/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The tenant ID
TenantId Integer of RegEx to true true
retrieve
**Important**:
The
subscriber
SubscriberId String (i.e. line of false true
business)
within the
tenant

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of
RegEx KVList false true
expressions

Universal Contact Server API Guide 229


OMResponse GetAllRegEx

RegEx KVList

Key ValueType Value Description Mandatory Unique Default


ID of the
(RegExId) KVList false true
expression

RegExId KVList

Key ValueType Value Description Mandatory Unique Default


255 chars Name of the
Name String true true
max expression
Description of
255 chars
Description String the true true
max
expression
Properties of
Properties String the false true
expression
Expression
Expression String true true
content
TenantId Integer true true

Error
FaultCode FaultString Description
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 230


OMResponse GetAllRules

GetAllRules

Purpose
This method is intended for downloading of all PII rules in a specific tenant/SubscriberId.

URL
• GET /OMResponse/GetAllRules/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
RegExId String false true
expression
Return details
ReturnChildObjects
String true or false of associated false true false
object
The tenant ID
TenantId Integer of Rules to true true
retrieve
**Important**:
The
subscriber
SubscriberId String (i.e. line of false true
business)
within the
tenant

Universal Contact Server API Guide 231


OMResponse GetAllRules

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Rules KVList List of rules false true

Rules KVList

Key ValueType Value Description Mandatory Unique Default


(RuleId) KVList ID of the rule false true

RuleId KVList

Key ValueType Value Description Mandatory Unique Default


255 chars Name of the
Name String true true
max rule
255 chars Description of
Description String false true
max the rule
ID of the
expression.
RegExId String 16 chars false true
Only if
ReturnChildObjects=false

Reg Ex Detail
associated.Only
RegEx KVList true true
if
ReturnChildObjects=true
Pattern to use
ReplacementPattern
String for false true
replacement
Pattern to use
Actions String for false true
replacement
TenantId Integer true true

Universal Contact Server API Guide 232


OMResponse GetAllRules

RegEx KVList

Key ValueType Value Description Mandatory Unique Default


ID of the reg
Id String 16 chars false true
ex
255 chars Name of the
Name String true true
max expression
Description of
255 chars
Description String the true true
max
expression
Properties of
Properties String the false true
expression
Expression
Expression String true true
content
TenantId Integer true true

Error
FaultCode FaultString Description
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 233


OMResponse GetAllTestMessage

GetAllTestMessage

Purpose
This method is intended for downloading of all PII TestMessages in a specific tenant/SubscriberId.

URL
• GET /OMResponse/GetAllRules/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Comma (,)
separated list
of object IDs
Can also contain
RelatedObjectId String only one ID false true
without comma
Mandatory if
RelatedObjectType
is not provided

Type of
Object
associated
with the
RelatedObjectType
String message false true
"Mandatory if
RelatedObjectId
is not provided\n"

Universal Contact Server API Guide 234


OMResponse GetAllTestMessage

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of
TestMessages KVList false true
TestMessages

TestMessages KVList

Key ValueType Value Description Mandatory Unique Default


ID of the
(TestMessageId) KVList false true
message

TestMessageId KVList

Key ValueType Value Description Mandatory Unique Default


255 chars Name of the
Name String true true
max message
255 chars Description of
Description String false true
max the message
Text String false true
Type of the
RelatedObjectType
String 16 chars max associated true true
object
ID of the
RelatedObjectId String 16 chars associated true true
object

Error

Error

FaultCode FaultString Description


201 Missing parameter {0} Mandatory parameter missing
510 {0,1} not found in database Record is not found in database

Universal Contact Server API Guide 235


OMResponse GetCategory

GetCategory

Purpose
This method is intended for downloading of the Category, and category sub-tree, from server to client. Only Id,
StandardResponseId and TheName attributes are returned for each SRL. The GetStandardResponse method is
used to get each SR detailed information.

URL
• GET /OMResponse/GetCategory/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Root Category
to start from.
Only sub-
CategoryId String categories of true true
this category
will be
returned.
ReturnChildrenCategories
String true or false false true true
Will return
fields
TheName and
ReturnChildrenSRInfo
String true or false false true true
Id for children
standard
responses.

Universal Contact Server API Guide 236


OMResponse GetCategory

Success

CategoryId KVList

Key ValueType Value Description Mandatory Unique Default


Name String true true
(in format
ModifiedDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
Status String true true
Type Integer true true
Description String true true
Is not returned
if
ChildrenCategories
KVList false true
"ReturnChildrenCategories
= false"
Is not returned
if
ChildrenStdResponses
KVList false true
"ReturnChildrenSRInfo
= false"

ChildrenCategories KVList

Key ValueType Value Description Mandatory Unique Default


(CategoryId) KVList false true

ChildrenStdResponses KVList

Key ValueType Value Description Mandatory Unique Default


Id Field in
(StandardResponseId)
KVList StandardResponse
false true
table.

StandardResponseId

Key ValueType Value Description Mandatory Unique Default


StandardResponseId
StandardResponseId
String true true
field in

Universal Contact Server API Guide 237


OMResponse GetCategory

Key ValueType Value Description Mandatory Unique Default


StandardResponse
table.
TheName String true true

Error
FaultCode FaultString Description
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 238


OMResponse GetCategoryAttribute

GetCategoryAttribute

URL
• GET /OMResponse/GetCategoryAttribute/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of
Id String true true
attribute

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of
Id String true true
attribute
Name of the
CategoryId String true true
attribute
TheName String true true
TheType Integer From 0 to 127 true true
StrValue String false true
LongStrValue String false true
BinValue Binary false true
IntValue Integer false true
IdValue String false true

Universal Contact Server API Guide 239


OMResponse GetCategoryAttribute

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 240


OMResponse GetCategoryAttributes

GetCategoryAttributes

Purpose
GetCategoryAttributes used without parameter returns all the elements.

URL
• GET /OMResponse/GetCategoryAttributes/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The
CategoryId or
CategoryId of
CategoryId String TheName or false true
the
IdValue
CategoryAttributes
CategoryId or The name of
TheName String TheName or the false true
IdValue CategoryAttributes
CategoryId or
IdValue String TheName or The Id Value false true
IdValue

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The keys are
CategoryAttributes
KVList ID of attribute, false true
and each

Universal Contact Server API Guide 241


OMResponse GetCategoryAttributes

Key ValueType Value Description Mandatory Unique Default


value is a
KVList that
contains the
fields of
category
attributes (see
getAttribute).

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 242


OMResponse GetDocument

GetDocument

URL
• GET /OMResponse/GetDocument/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID
DocumentId String true true
document

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The document
DocumentId String false true
ID
The mime
MimeType String type of the true true
document
The name of
Name String true true
the document
The size of
Size Integer true true
the document
The
Description String description of false true
the document
The binary
Content Binary content of the false true
document

Universal Contact Server API Guide 243


OMResponse GetDocument

Error
FaultCode FaultString Description
{0} with name {1} already exists in
114 Object already exists in database
database
No language {0} defined in
201 Incorrect language parameter
configuration for Tenant {1}
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 244


OMResponse GetFieldCode

GetFieldCode

URL
• GET /OMResponse/GetFieldCode/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
field code

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
field code
The name of
Name String true true
the field code
The value of
Value String true true
the field code
The comment
Comment String of the field false true
code

Universal Contact Server API Guide 245


OMResponse GetFieldCode

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 246


OMResponse GetFieldCodes

GetFieldCodes

URL
• GET /OMResponse/GetFieldCodes/

Request
• Service name: OMResponse

• Method name: GetFieldCodes

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The keys are
field code ID,
and each
value is a
KVList that
FieldCodes KVList contains the false true
following
FieldCode
values: Name,
Value,
Comment.

Universal Contact Server API Guide 247


OMResponse GetFieldValue

GetFieldValue

URL
• GET /OMResponse/GetFieldValue/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
field value

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
field value
The name of
Name String true true
the field value
String=1;
Integer=2; The type of
Type Integer true true
Double=3; the field value
Date=4;
The comment
IsConstant String true or false of the field true true
value
The comment
Comment String of the field false true
value
String, The value of
Integer, the field value
Value String false true
Double, Date (according to
in format the type)

Universal Contact Server API Guide 248


OMResponse GetFieldValue

Key ValueType Value Description Mandatory Unique Default


"yyyy-MM-
ddTHH:mm:ss.SSSZ"

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 249


OMResponse GetFieldValues

GetFieldValues

URL
• GET /OMResponse/GetFieldValues/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The keys are
field value ID,
and each
value is a
KVList that
contains the
FieldValues KVList following false true
FieldValue
values: Name,
Type,
IsConstant,
Value,
Comment.

Universal Contact Server API Guide 250


OMResponse GetGroup

GetGroup

URL
• GET /OMResponse/GetGroup/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
group to
retrieve.
Id String 16 chars Mandatory if false true
Name and
TenantId are not
provided

Name of the
group to
retrieve.
255 chars
Name String false true
max Mandatory with
TenantID if Id is
not provided

Return details
ReturnChildObjects
String true or false of associated false true false
object
The tenant ID
of Group to
retrieve.
TenantId Integer false true
Mandatory with
Name if Id is not
provided

**Important**:
The
subscriber
SubscriberId String (i.e. line of false true
business)
within the
tenant

Universal Contact Server API Guide 251


OMResponse GetGroup

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
Id String 16 chars true true
group
255 chars Name of the
Name String true true
max group
255 chars Description of
Description String true true
max the group
Type of the
Type String 16 chars max true true
group
Rules KVList List of rules false true
CategoryId String 16 chars false true

Rules KVList

Key ValueType Value Description Mandatory Unique Default


(RuleId) KVList ID of the rule false true

RuleId KVList

Key ValueType Value Description Mandatory Unique Default


255 chars Name of the
Name String true true
max rule
255 chars Description of
Description String false true
max the rule
ID of the
expression.
RegExId String 16 chars false true
Only if
ReturnChildObjects=false

Reg Ex Detail
associated.Only
RegEx KVList true true
if
ReturnChildObjects=true
Pattern to use
ReplacementPattern
String for false true
replacement

Universal Contact Server API Guide 252


OMResponse GetGroup

Key ValueType Value Description Mandatory Unique Default


Pattern to use
Actions String for false true
replacement
TenantId Integer true true

RegEx KVList

Key ValueType Value Description Mandatory Unique Default


ID of the reg
Id String 16 chars false true
ex
255 chars Name of the
Name String true true
max expression
Description of
255 chars
Description String the true true
max
expression
Properties of
Properties String the false true
expression
Expression
Expression String true true
content
TenantId Integer true true

Error
FaultCode FaultString Description
201 Missing parameter {0} Mandatory parameter missing
510 {0} not found in database Record is not found in database
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 253


OMResponse GetGroupContent

GetGroupContent

URL
• GET /OMResponse/GetGroupContent/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
group content
to retrieve.
Id String 16 chars false true
Mandatory if
GroupId is not
provided

ID of the
group.
GroupId String 16 chars false true
Mandatory if Id is
not provided

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of
GroupContent KVList false true
GroupContent

Universal Contact Server API Guide 254


OMResponse GetGroupContent

GroupContent KVList

Key ValueType Value Description Mandatory Unique Default


ID of the
(GroupContentId)KVList false true
GroupContent

GroupContentId KVList

Key ValueType Value Description Mandatory Unique Default


ID of the
GroupId String 16 chars true true
group
RuleId String 16 chars ID of the Rule true true
255 chars Status of the
RuleStatus String true true
max rule
Priority of the
RulePriority Integer true true
rule

Error
FaultCode FaultString Description
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 255


OMResponse GetRegEx

GetRegEx

URL
• GET /OMResponse/GetRegEx/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the reg
ex

Id String 16 chars Mandatory if false true


Name and
TenantId are not
provided

Name of the
expression
255 chars
Name String Mandatory with false true
max
TenantId if Id is
not provided

The tenant ID
of RegEx to
retrieve
TenantId Integer false true
Mandatory with
Name if Id is not
provided

**Important**:
The
subscriber
SubscriberId String (i.e. line of false true
business)
within the
tenant

Universal Contact Server API Guide 256


OMResponse GetRegEx

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the reg
Id String 16 chars true true
ex
255 chars Name of the
Name String true true
max expression
Description of
255 chars
Description String the true true
max
expression
Properties of
Properties String the false true
expression
Expression
Expression String true true
content
TenantId Integer true true

Error
FaultCode FaultString Description
201 Missing parameter {0} Mandatory parameter missing
510 {0} not found in database Record is not found in database
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 257


OMResponse GetRootCategories

GetRootCategories

Purpose
This method is intended for downloading of the Root Categories information.

URL
• GET /OMResponse/GetRootCategories/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


TenantId Integer true true
The
subscriber
(that is, line of
business)
SubscriberId String within the false true
tenant to
which the
categories
belong to
The
configuration
Language String false true
configured
Language

Universal Contact Server API Guide 258


OMResponse GetRootCategories

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


List of Root
Categories KVList false true
Categories

Categories KVList

Key ValueType Value Description Mandatory Unique Default


(CategoryId) KVList false true

CategoryId KVList

Key ValueType Value Description Mandatory Unique Default


Name String true true
(in format
ModifiedDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
Status String true true
Type Integer true true
Description String true true
Lang String true true

Error
FaultCode FaultString Description
Provided tenant is not configured in
732 Invalid Tenant {0}
UCS

Universal Contact Server API Guide 259


OMResponse GetRule

GetRule

URL
• GET /OMResponse/GetRule/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the rule
Mandatory if
Id String 16 chars Name and false true
TenantId are not
provided

Name of the
expression
255 chars
Name String Mandatory with false true
max
TenantId if Id is
not provided

Return details
ReturnChildObjects
String true or false of associated false true false
object
The tenant ID
of Rule to
retrieve
TenantId Integer false true
Mandatory with
Name if Id is not
provided

**Important**:
The
subscriber
SubscriberId String (i.e. line of false true
business)
within the
tenant

Universal Contact Server API Guide 260


OMResponse GetRule

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id String 16 chars ID of the Rule false true
255 chars Name of the
Name String true true
max rule
255 chars Description of
Description String false true
max the rule
ID of the
expression.
RegExId String 16 chars false true
Only if
ReturnChildObjects=false

Reg Ex Detail
associated.Only
RegEx KVList true true
if
ReturnChildObjects=true
Pattern to use
ReplacementPattern
String for false true
replacement
Pattern to use
Actions String for false true
replacement
TenantId Integer true true

RegEx KVList

Key ValueType Value Description Mandatory Unique Default


ID of the reg
Id String 16 chars false true
ex
255 chars Name of the
Name String true true
max expression
Description of
255 chars
Description String the true true
max
expression
Properties of
Properties String the false true
expression
Expression
Expression String true true
content
TenantId Integer true true

Universal Contact Server API Guide 261


OMResponse GetRule

Error
FaultCode FaultString Description
201 Missing parameter {0} Mandatory parameter missing
510 {0} not found in database Record is not found in database
Provided tenant is not configured in
732 Invalid Tenant {1}
UCS

Universal Contact Server API Guide 262


OMResponse GetScreeningRule

GetScreeningRule

URL
• GET /OMResponse/GetRule/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
screening rule

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The ID of the
Id String true true
field value
The
description of
Description String true true
the screening
rule
Is screening
IsEnabled String true or false true true
rule enabled
Match text in
MatchTextInHeader
String true or false header for this true true
screening rule
Match text in
MatchTextInBodyString true or false body for this true true
screening rule
Match text in
MatchTextInSubject
String true or false subject for this true true
screening rule

Universal Contact Server API Guide 263


OMResponse GetScreeningRule

Key ValueType Value Description Mandatory Unique Default


The order of
Order Integer this screening true true
rule
The logical
LogicalRule String rule of this true true
screening rule
The tenant ID
TenantId Integer of this true true
screening rule
The language
Lang String of this true true
screening rule
The
addresses to
AddressesToMatch
String false true
match of this
screening rule
The match
MatchText String text of this false true
screening rule

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 264


OMResponse GetScreeningRules

GetScreeningRules

URL
• GET /OMResponse/GetScreeningRules/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


The tenant ID
of the
TenantId Integer screening false true
rules to
retrieve
The
subscriber
(that is, line of
business)
within the
SubscriberId String false true
tenant to
which the
screening
rules belong
to
The Language
of the
Lang String screening false true
rules to
retrieve
The
Description of
Description String the screening false true
rules to
retrieve

Universal Contact Server API Guide 265


OMResponse GetScreeningRules

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The keys are
screening
value ID, and
each value is
a KVList that
contains the
following
ScreeningRules
values:
Description,
ScreeningRules KVList false true
IsEnabled,
MatchTextInHeader,
MatchTextInBody,
MatchTextInSubject,
Order,
LogicalRule,
TenantId,
Lang,
AddressesToMatch,
MatchText.

Universal Contact Server API Guide 266


OMResponse GetStandardResponse

GetStandardResponse

Purpose
This method is intended for downloading of the Standard Response content from server to client. No attachment
content is returned, only Name, MimeType, Description, and Size.

URL
• GET /OMResponse/GetStandardResponse/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


StandardResponseId
field.
Note that only
StandardResponseId
String Active SRLs are true true
returned when
several historical
versions exist.

The
Versions are StandardResponse
version to get.
- 0: current - 1 or If no Version
Version Integer more: each false true
successive
get the
version Version=0.
(Introduced in
8.1.3)
When
specifying the
version, return
the
attachment
Attachments String true or false false true false
summaries
(without
content), if
any. (Added in
8.1.4)

Universal Contact Server API Guide 267


OMResponse GetStandardResponse

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Id field of a
Id String true true
SR
StandardResponseId
StandardResponseId
String true true
field of a SR
Body String false true
TheName String true true
Description String false true
IsActive String true true
Version Integer true true
OwnerId Integer true true
(in format
ModifiedDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
"Approved",
Status String true true
"NotApproved"
(in format
ExpirationDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
Lang String true true
Values are
- "Automatic", -
AckUsageType String true true
"Manual", - "Not
Used"

Values are
- "Automatic", -
AgentDesktopUsageType
String true true
"Manual", - "Not
Used"

Values are The auto


response
- "Automatic", -
AutoRespUsageType
String usage type of true true
"Manual", - "Not
Used" the Standard
Response
The email-out
Values are usage type of
the Standard
- "Automatic", -
EmailOutUsageType
String Response. true true
"Manual", - "Not
Used" Available only
if Version was
provided.**Important**:

Universal Contact Server API Guide 268


OMResponse GetStandardResponse

Key ValueType Value Description Mandatory Unique Default


Introduced in
8.1.3.
The voice
auto response
usage type of
Values are
the Standard
- "Automatic", - Response.
VoiceAutoRespUsageType
String true true
"Manual", - "Not Available only
Used" if Version was
provided.**Important**:
Introduced in
8.1.3.
The WSS
usage type of
Values are the Standard
Response.
- "Automatic", -
WSSUsageType String Available only true true
"Manual", - "Not
Used" if Version was
provided.**Important**:
Introduced in
8.1.3.
Subject String false true
(in format
StartDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
MimeType String false true
CustomFieldCodes
String false true
StructuredBody String false true
Attachments KVList false true

Attachments KVList

Key ValueType Value Description Mandatory Unique Default


DocumentId is
the unique
(DocumentId) KVList false true
identifier of a
Document

KVList

Key ValueType Value Description Mandatory Unique Default


Attachment
MimeType String true true
Mime Type

Universal Contact Server API Guide 269


OMResponse GetStandardResponse

Key ValueType Value Description Mandatory Unique Default


Attachment
TheName String true true
name
Attachment
Description String false true
description
Attachment
TheSize Integer true true
size

Error/Event3rdServerResponse
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
No such Standard Response defined:
StandardResponseId =
510 Record is not found in database
'(standardResponseId)' not found in
database

Universal Contact Server API Guide 270


OMResponse GetStandardResponses

GetStandardResponses

Purpose
This method is intended for downloading of all the versions of a Standard Response content for a standard
response ID from server to client. No attachment content is returned, only Name, MimeType, Description, and Size.

URL
• GET /OMResponse/GetStandardResponses/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


StandardResponseId
field. Returns
StandardResponseId
String all historical true true
versions that
exist.
Return the
attachment
summaries
(without
Attachments String true or false content), if false true
any, with the
revisions.
(Added in
8.1.4)

Universal Contact Server API Guide 271


OMResponse GetStandardResponses

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


A collection of
versions of
Standard
StdResp KVList true true
Response for
a Standard
Response ID.
A collection of
Documents
with Id as the
key and:
TheName,
Attachments KVList false true
TheSize,
MimeType
and
Description as
values.

Versions KVList

Key ValueType Value Description Mandatory Unique Default


A collection of
Standard
(version
KVList Response true false NO
number)
attributes for a
version.

Standard Response KVList

Key ValueType Value Description Mandatory Unique Default


Id field of a
Id String true true
SR
StandardResponseId
StandardResponseId
String true true
field of a SR
Body String false true
TheName String true true
Description String false true
IsActive String true true

Universal Contact Server API Guide 272


OMResponse GetStandardResponses

Key ValueType Value Description Mandatory Unique Default


Version Integer true true
OwnerId Integer true true
(in format
ModifiedDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
"Approved",
Status String true true
"NotApproved"
(in format
ExpirationDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
Lang String true true
Values are
- "Automatic", -
AckUsageType String true true
"Manual", - "Not
Used"

Values are
- "Automatic", -
AgentDesktopUsageType
String true true
"Manual", - "Not
Used"

Values are The auto


response
- "Automatic", -
AutoRespUsageType
String usage type of true true
"Manual", - "Not
Used" the Standard
Response
The email-out
Values are usage type of
the Standard
- "Automatic", -
EmailOutUsageType
String Response. true true
"Manual", - "Not
Used" Available only
if Version was
provided.
The voice
auto response
Values are
usage type of
- "Automatic", - the Standard
VoiceAutoRespUsageType
String true true
"Manual", - "Not Response.
Used" Available only
if Version was
provided.
The WSS
Values are usage type of
the Standard
- "Automatic", -
WSSUsageType String Response. true true
"Manual", - "Not
Used" Available only
if Version was
provided.
Subject String false true

Universal Contact Server API Guide 273


OMResponse GetStandardResponses

Key ValueType Value Description Mandatory Unique Default


(in format
StartDate String "yyyy-MM- true true
ddTHH:mm:ss.SSSZ")
MimeType String false true
CustomFieldCodes
String false true
StructuredBody String false true
Attachments KVList false true

Attachments KVList

Key ValueType Value Description Mandatory Unique Default


DocumentId is
the unique
(DocumentId) KVList false true
identifier of a
Document

KVList

Key ValueType Value Description Mandatory Unique Default


Attachment
MimeType String true true
Mime Type
Attachment
TheName String true true
name
Attachment
Description String false true
description
Attachment
TheSize Integer true true
size

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 274


OMResponse GetTestMessage

GetTestMessage

URL
• GET /OMResponse/GetTestMessage/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
Id String 16 chars true true
Message

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


ID of the
Id String 16 chars true true
Message
255 chars Name of the
Name String true true
max message
255 chars Description of
Description String false true
max the message
Text String false true
Type of the
RelatedObjectType
String 16 chars max associated true true
object
ID of the
RelatedObjectId String 16 chars associated true true
object

Universal Contact Server API Guide 275


OMResponse GetTestMessage

Error
FaultCode FaultString Description
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 276


OMResponse GetUpdates

GetUpdates

Purpose
This method cannot filter by tenantID because it is possible to receive events from other tenants. This is a technical
limitation of the UCS event system and there is no workaround. Because GetUpdates can be a blocking operation,
there is a limit of 10 concurrent blocking calls, to prevent usage of all UCS connections.

URL
• GET /OMResponse/GetUpdates/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


Comma (,)-
separated list
of Persistent
names within:

• Category

• CategoryAttribute
• CategoryStructure
Empty means
• EmRoute all monitored
EventType String • TrainingJob false true Persistent
names will be
• Model returned.
• StandardResponse

• PIIRule

• PIIRegEx

• PIIGroup

• PIIGroupContent

Universal Contact Server API Guide 277


OMResponse GetUpdates

Key ValueType Value Description Mandatory Unique Default

• PIITestMessage

Can also contain


only one value
without comma.

Will retrieve
all updates
since that
date. Time is
Date in
UCS time.
Since String ISO8601 Date false true
You can use
Format
GetServerTime
to retrieve it or
use a returned
date.
If present,
request will
block until an
event occurs
or timeout
Value is in expires. You
PoolTimeout Integer false true
minutes must set your
ESP client
timeout to a
value higher
than
PoolTimeout.

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


All returned
Date in
Persistent IDs
Since String ISO8601 Date true true
are updates
Format
from that date.
Date when
events were
gathered. You
can use this
Date in
value for the
EventDate String ISO8601 Date true true
'Since'
Format
parameter of
next
GetUpdates
request.

Universal Contact Server API Guide 278


OMResponse GetUpdates

Key ValueType Value Description Mandatory Unique Default


A KVList with
below content
with
Persistent IDs
and the date
when the
event
occurred.
Note that
several
identical
events can
• Category occur on the
• CategoryAttribute same ID but
only the last
• CategoryStructure one will be
shown. Notice
• EmRoute that the same
Depending on
• TrainingJob the number of ID (like
requested 00001a8VK7EC003T
• Model KVList EventType below) can be true true
you get at seen in
• PIIRule several lists to
least one of
• PIIRegEx these KVList be able to
reconstruct
• PIIGroup the event flow:
• PIIGroupContent Inserted={
00001a8VK7EC003S=
• PIITestMessage 2013 - 06 -
25T13:40:38.792Z
00001a8VK7EC003T=
2013 - 06 -
25T13:40:38.801Z
} Updated = {
00001a8VK7EC003T=
2013 - 06 -
25T13:40:59.523Z
} Deleted = {
00001a8VK7EC003T=
2013 - 06 -
25T13:41:40.221Z
}

• Category

• CategoryAttribute

• CategoryStructure
See above for
• EmRoute KVList false true
description
• TrainingJob

• Model

• PIIRule

Universal Contact Server API Guide 279


OMResponse GetUpdates

Key ValueType Value Description Mandatory Unique Default

• PIIRegEx

• PIIGroup

• PIIGroupContent

• PIITestMessage

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
Too many 'blocking getUpdates' in 10 blocking get updates request are
739
use, request rejected. currently in progress.

Universal Contact Server API Guide 280


ProfileService Methods GetUpdates

ProfileService Methods
• ProfileServiceCustomerProfileResource

• deleteProfile

• queryCustomerProfile

• updateCustomerProfile

• ProfileServiceProfilesResource

• createProfile

• identifyProfiles

• ProfileServiceProfileExtensionsResource

• insertExtensionRecord

• ProfileServiceUpdateRecordInProfileExtension

• updateRecordInProfileExtension

• ProfileServiceDeleteRecordInProfileExtension

• deleteRecordInProfileExtension

• ProfileServiceimportProfileRecords

• importProfileRecords

• ProfileMergeUnmerge

• mergeProfiles

• unmergeProfiles

• unmergeProfilesAsSource

Universal Contact Server API Guide 281


ProfileService Methods CustomerProfileResource

CustomerProfileResource
Handle methods for profile manipulation: Reading a profile (GET), Updating a profile (PUT).

• deleteProfile

• queryCustomerProfile

• updateCustomerProfile

Universal Contact Server API Guide 282


ProfileService Methods CustomerProfileResource

deleteCustomerProfile

URL
• DELETE /profiles/{customer_id}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String customerId of the given true true
customer.

HTTP Headers
Key ValueType Value Description Mandatory Unique Default
X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Universal Contact Server API Guide 283


ProfileService Methods CustomerProfileResource

Error

FaultCode FaultString Description


Credentials are missing or incorrect,
or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
404 Not Found This requested profile does not exist.

Universal Contact Server API Guide 284


ProfileService Methods CustomerProfileResource

queryCustomerProfile

URL
• GET /profiles/{customer_id}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String customerId of the given true true
customer.

HTTP Headers
Key ValueType Value Description Mandatory Unique Default
X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Parameters
Key ValueType Value Description Mandatory Unique Default
extensions String extensions false false

Sample
GET /profiles/0004Va58A92T0017

Universal Contact Server API Guide 285


ProfileService Methods CustomerProfileResource

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 286


ProfileService Methods CustomerProfileResource

Sample
200 OK
{ "customer_id": "0004Va58A92T0017 ",
"name": "Doe, John",
"birthdate": "1976-05-10",
"EmailAddress": [
"john.doe@genesyslab.com",
"jd34@hotmail.dom"],
"contacts": [
{"phone": "408-555-1234", "ext": "1234"},
{"phone": "408-832-7712"} ],
"preferences": { "newsletter": "y", "new_offers": "n", "email": "html" }

Universal Contact Server API Guide 287


ProfileService Methods CustomerProfileResource

updateCustomerProfile

Purpose
Overrides the attributes of the customer profile—prior attribute values are lost and replaced with the attribute list
specified in the body of the request. This operation uses the standard convention for HTTP PUT, which requires you
to update the profile with the complete profile to avoid losing information. Your application should use this operation
in conjunction with the Query Customer Profile operation:

• Query the Customer Profile

• Modify the Customer Profile data

• Update the Customer Profile.

Extensions can be part of the profile used for the update: If your application does not include any extensions in the
body, no modification occurs on extensions. If your application specifies extension values, extension information is
overridden. Your application must specify the complete extension set to avoid losing data.

URL
• PUT /profiles/{customer_id}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String customerId of the given true true
customer.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
X-Genesys- Segment
String false true
Segment value (not to

Universal Contact Server API Guide 288


ProfileService Methods CustomerProfileResource

Key ValueType Value Description Mandatory Unique Default


be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


The complete
set of
customer
attributes,
where
(attribute n) is
the attribute
name. See
the
configuration
options for
further details.
"single- The date/time
attribute n String valued" or formats are true true
"multi-valued" ISO 8601:
[YYYY]-[MM]-
[DD]T[HH]:[mm]:[ss].[SSS]Z.
Note: Attributes
will be overridden.
This
representation
must contain all
the profile
attributes' values,
including those
that were not
modified.

Extensions,
where
(extension n)
corresponds
to the unique
name of the
profile
extension
resource.
extension n String false true
Note: If you
specify
extensions,
extensions are
overridden. If you
wish to modify an
extension value,
this
representation
must contain all
the profile

Universal Contact Server API Guide 289


ProfileService Methods CustomerProfileResource

Key ValueType Value Description Mandatory Unique Default

extensions,
including those
that were not
modified.

Sample
PUT http://ucsserver.mycompany.com:8080/path/profiles/00027a52JCGY000M
Content-Location /profiles/00027a52JCGY000M
Content-Type: application/json
{
"FirstName": "Bruce",
"LastName": "Banner",
"DOB": "1962-05-10",
"EmailAddress": [
"bruce.banner@marvelous.com",
"b.banner@hulk.dom"
],
"Address": { "Type":1, "Address":"21 JumpStreet", "City":"Hollywood",
"County":"Santa Barbara", "PostCode":"555", "Country":"United States" }
}

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


401 Not Authorized
or the given user is not allowed to

Universal Contact Server API Guide 290


ProfileService Methods CustomerProfileResource

FaultCode FaultString Description


execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 291


ProfileService Methods ProfilesResource

ProfilesResource
Identifies a customer based on the Identification Key information submitted with the query. In addition to the
identified customer ID, your application can retrieve profile and extension information based on the query fields.
Query strings should be URL Encoded. If the "id_key" parameter is not specified, then UCS uses the following
algorithm:

1. Starting with the identification key with the lowest ID, UCS determines the number of attributes in the key which are
covered by the data specified in the "expr" parameter.

2. If all attributes are covered, then use this key. Otherwise, record the number of sequential attributes covered, starting
from the left. For example, if key 1 consists of attributes (a, b, c), and "expr" contains (a, b) then the score is 2.

3. If no key is selected after iterating through all the defined keys, choose the key with the highest score from Step 2. In
the event of a tie, UCS selects the key with the smallest ID.

• createProfile

• identifyProfiles

Universal Contact Server API Guide 292


ProfileService Methods ProfilesResource

createProfile

Purpose
Creates a Customer Profile and returns the ID created by UCS. Profiles are built on top of legacy UCS Contact
Attributes. They are multi-valued and support the primary attributes. If an attribute has several values, the first value
in the JSON array is the primary attribute and additional values are non-primary attributes. Standard multi-valued
extensions are available.

URL
• POST /profiles

Request

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


The unique ID
of the given
customer_id String customer. true true
Limited to 16
characters.
Customer
attributes,
where
attribute Token true true
(attribute n) is
the attribute
name. See

Universal Contact Server API Guide 293


ProfileService Methods ProfilesResource

Key ValueType Value Description Mandatory Unique Default


the
configuration
options for
further details.
Attributes are
not part of a
separated
array, see the
example
below. The
date/time
formats are
ISO 8601:
"yyyy-MM-
ddTHH:mm:ss.SSSZ".
Note: Do not
use
Unauthorized
Strings as
attribute
values
Extensions,
where
(extension n)
corresponds
to the unique
name of the
profile
extension
resource.

• For single-
valued
extensions,
the
extension's
value is a
extension StringList single false true
extension
object
(see
Extension).

• For multi-
valued
extensions,
the
extension's
value is
an array
of zero or
more
Extensions.

Universal Contact Server API Guide 294


ProfileService Methods ProfilesResource

Sample
POST /profiles/
{
"FirstName": "Bruce",
"LastName": "Banner",
"DOB": "1962-05-10",
"EmailAddress": [
"bruce.banner@marvelous.com",
"b.banner@hulk.dom"
],
"Phone": [
{
"PhoneType":0,
"prefix":"+33",
"PhoneNumber":"3145926535",
"description":"family phone",
"start_availability":"2009-12-18T18:30:00.000Z",
"end_availability":"2009-12-18T21:40:00.000Z"
},
{
"PhoneType":2,
"prefix":"+33",
"PhoneNumber":"6543210",
"description":"business calls only, no sales",
"start_availability":"2009-12-18T09:30:00.000Z",
"end_availability":"2009-12-18T17:45:00.000Z"
},
{
"PhoneType":5,
"prefix":"+33",
"PhoneNumber":"951357456",
"description":""
}
]
}

Responses

Success

ReturnCode ReturnString Description


The request has been fulfilled and
201 Created resulted in a new resource being
created

Error

FaultCode FaultString Description


General error which can be one of
400 Bad Request
the following reasons:

Universal Contact Server API Guide 295


ProfileService Methods ProfilesResource

FaultCode FaultString Description

• Missing required parameter.

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
201 Created
Content-Location http://ucsserver.mycompany.com:8080/path/profiles/00038b5SCVPU0007
{"customer_id":"0004Va58A92T0017"}

Universal Contact Server API Guide 296


ProfileService Methods ProfilesResource

identifyProfiles

URL
• GET /profiles

Request

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Parameters

Key ValueType Value Description Mandatory Unique Default

• "no"
(default)
to return
the list of
customers
IDs
without
their
profile
include_profile String "yes" or "no" false false no
attributes.

• "yes" to
return all
the profile
attributes
of the
identified
customers.

Universal Contact Server API Guide 297


ProfileService Methods ProfilesResource

Key ValueType Value Description Mandatory Unique Default


The key name
used for
identification.
Information.png
UCS can infer the
key based on the
attributes
included in the
id_key String "expr" parameter. false false
However,
explicitly
specifying the
identification key
with your
application
improves
performance.

• "always"
(default)
to return
the
extensions
specified
with the
field
"extension"
if one or
more
customers
"always" or are
include_extensions
String false false always
"unique" identified.

• "unique" to
return the
extensions
identified
in
parameter
"extensions"
if a unique
customer
is
identified.

The names of
the extension
to return with
A comma the customer
separated list profiles. Your
extensions String false false
of extension application
names can specify
multiple
values
separated

Universal Contact Server API Guide 298


ProfileService Methods ProfilesResource

Key ValueType Value Description Mandatory Unique Default


with comas,
such as:
extensions=contacts,
purchases
One or more
identification
keys used to
identify the
customer, for
instance:
last_name=Doe&first_name=Jane
Important.png
Attribute names
with no prefix are
attributes MapStringList supposed to be true false
profile attributes.
To refer to the
attributes of an
extension, your
application must
use the extension
name as a prefix
for the attribute:
(ext-
name).(attribute-
name)

Sample
GET /profiles/contacts.phone_number=408-888-3214&extensions=contacts,purchases∈clude_profile=yes
∈clude_extensions=unique

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.


400 Bad Request • Parameter value of unexpected
type.

• Invalid object syntax.

Universal Contact Server API Guide 299


ProfileService Methods ProfilesResource

FaultCode FaultString Description

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Sample
200 OK
[{"customer_id": "2DC255C02AF", "name": "Doe, John", "birthdate": "1976-05-10"},
{"customer_id": "DDF295802AF", "name": "Doe, Jane", "birthdate": "1978-02-25"}]

200 OK
[{ "customer_id": "0004Va58A92T0017 ",
"name": "Doe, John",
"birthdate": "1976-05-10",
"EmailAddress": [
"john.doe@genesyslab.com",
"jd34@hotmail.dom"],
"contacts": [
{"phone": "408-555-1234", "ext": "1234"},
{"phone": "408-832-7712"} ],
"preferences": { "newsletter": "y", "new_offers": "n", "email": "html" }
}]

Universal Contact Server API Guide 300


ProfileService Methods Profile ExtensionsResource

Profile ExtensionsResource
This operation inserts one or more extension records, which replace former records if they already exist.

• insertExtensionRecord

Universal Contact Server API Guide 301


ProfileService Methods Profile ExtensionsResource

insertExtensionRecord

Purpose
This operation inserts one or more extension records, which replace former records if they already exist.

URL
• POST /profiles/{customer_id}/extensions

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String of the given true true
customer.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


Extensions,
where
(extension n)
extension StringList false true
corresponds
to the unique
name of the

Universal Contact Server API Guide 302


ProfileService Methods Profile ExtensionsResource

Key ValueType Value Description Mandatory Unique Default


profile
extension
resource.

• For single-
valued
extensions,
the
extension's
value is a
single
extension
object
(see
Extension).
• For multi-
valued
extensions,
the
extension's
value is
an array
of zero or
more
Extensions.

Sample
POST /profiles/0004Va58A92T0017/extensions
{
"Phone": [
{"PhoneType":0,
"prefix":"+33",
"number":"3145926535",
"description":"family phone",
"start_availability":"2009-12-18T18:30:00.000Z",
"end_availability":"2009-12-18T21:40:00.000Z"},
{"PhoneType":2,
"prefix":"+33",
"number":"6543210",
"description":"business calls only, no sales",
"start_availability":"2009-12-18T09:30:00.000Z",
"end_availability":"2009-12-18T17:45:00.000Z"},
{"PhoneType":5,
"prefix":"+33",
"number":"951357456",
"description":"",
} ]
}

Universal Contact Server API Guide 303


ProfileService Methods Profile ExtensionsResource

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 304


ProfileService Methods UpdateRecordInProfileExtension

UpdateRecordInProfileExtension
Update Record In Profile Extension (PUT).

• updateRecordInProfileExtension

Universal Contact Server API Guide 305


ProfileService Methods UpdateRecordInProfileExtension

updateRecordInProfileExtension

Purpose
Updates the content of a single record in a multi-valued extension. The attributes which are part of the 'unique' list
specified at the Extension Schema creation are passed in the body and used to find the correct record to update.
This update cannot change the values of the attributes which are part of the 'unique' list of the Extension Schema;
'unique' attributes are used as identifiers for the given record.

Workaround: If you wish to update a value for an attribute stamped as unique, you must delete the concerned
record, then recreate this record with its correct values.

URL
• PUT /profiles/{customer_id}/extensions/{extension_name}/by/unique

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String of the given true true
customer.
The name of
the Profile
extension_name String true true
Extension to
update.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Universal Contact Server API Guide 306


ProfileService Methods UpdateRecordInProfileExtension

Body

Key ValueType Value Description Mandatory Unique Default


Individual
attributes
defined in the
Profile
Extension
Schema.
(attribute n)
corresponds to
"single- the attribute name
attribute n String valued" or defined in the true true
"multi-valued" schema. If the
attribute is
unique, its value
is used to select
the record to
update. It is not
updated. If the
attribute is not
unique, its value
is updated.

Sample
PUT /profiles/0000Sb5U97XE000Y/extensions/Phone/by/unique
"PhoneType":0,
"prefix":"+33",
"PhoneNumber":"3145926535",
"description":"family phone",
"start_availability":"2009-12-18T18:30:00.000Z",
"end_availability":"2009-12-18T21:40:00.000Z"
}

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
400 Bad Request
the following reasons:

Universal Contact Server API Guide 307


ProfileService Methods UpdateRecordInProfileExtension

FaultCode FaultString Description

• Missing required parameter.

• Parameter value of unexpected


type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 308


ProfileService Methods DeleteRecordInProfileExtension

DeleteRecordInProfileExtension
Deletes a single record in a multi-valued extension (PUT).

• deleteRecordInProfileExtension

Universal Contact Server API Guide 309


ProfileService Methods DeleteRecordInProfileExtension

deleteRecordInProfileExtension

Purpose
Deletes a single record in a multi-valued extension. You must specify the list of 'unique' attributes which identify the
record to delete.

URL
• PUT /profiles/{customer_id}/extensions/{extension_name}/delete/by/unique

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The unique ID
customer_id String of the given true true
customer.
The name of
the Profile
extension_name String true true
Extension to
modify.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Universal Contact Server API Guide 310


ProfileService Methods DeleteRecordInProfileExtension

Body

Key ValueType Value Description Mandatory Unique Default


Individual
attributes
defined in the
Profile
Extension
"single- Schema.
attribute n String valued" or true true
"multi-valued" (attribute n)
corresponds to
the attribute name
defined 'unique' in
the Extension
Schema.

Sample
PUT /profiles/0000Sb5U97XE000Y/extensions/Phone/delete/by/unique
{"PhoneType":0,
"prefix":"+33",
"PhoneNumber":"3145926535",
"description":"family phone",
"start_availability":"2009-12-18T18:30:00.000Z",
"end_availability":"2009-12-18T21:40:00.000Z"
}

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.


• Missing required attribute

Universal Contact Server API Guide 311


ProfileService Methods DeleteRecordInProfileExtension

FaultCode FaultString Description


Credentials are missing or incorrect,
or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 312


ProfileService Methods ProfileService importProfileRecords

ProfileService importProfileRecords
Import customer profiles in a single operation.

• importProfileRecords

Universal Contact Server API Guide 313


ProfileService Methods ProfileService importProfileRecords

importProfileRecords

Purpose
Imports several customer profiles in a single operation. Your application should use this operation if you need to
import a large number of profiles into the UCS database. Note that TenantId and Segment columns are not
compulsory. If omitted, default values are used.

URL
• POST /profiles/import

Request

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


Defines the
format of the
submitted
format String false true
data. Only
"CSV" value is
supported
File path, for
instance
profiles String false true
'C:/profiles.csv'.
File path, for

Universal Contact Server API Guide 314


ProfileService Methods ProfileService importProfileRecords

Key ValueType Value Description Mandatory Unique Default


instance
'C:/profiles.csv'.
Your application
is responsible for
uploading the file
on the server's
local filesystem.

A valid
identification
key." If
specified, the
server checks
to see
whether the
profile already
id-key String exists prior to false true
the insertion.
If the profile does
exist in the
database, the
record containing
the duplicate
profile is skipped.

Defines the
character
used to
separate the
delimiter String submitted false true
profiles:

char or "," by default.

The number
of errors to
allow before
ending the
bulk load.
An error can
indicate that a
max-errors String false true
given record was
not parsed
correctly, or that
an ambiguity
exists with an
existing customer
record (see
response below).

Encoding
character to
encoding String false true
use for file
import.

Universal Contact Server API Guide 315


ProfileService Methods ProfileService importProfileRecords

Key ValueType Value Description Mandatory Unique Default

Default is
UTF-8<ref>
UTF-8 without
BOM, see related
bug

The record
start-from- number from
String false true
index which to start
importing.
This flag turns
extended
import results
logging on or
off.
The log data is
written to an
create-log Boolean false true
output file that
has the same
name as the input
file, with an
extension of .log
appended. The
default value is
false.

Universal Contact Server API Guide 316


ProfileService Methods ProfileService importProfileRecords

Sample
POST /profiles/import
--zaHf8xb3LfVOXZ0o2KUyqWD4Zlfumh0R9uyMN
Content-Disposition: form-data; name="description"
Content-Type: application/json; charset=UTF-8
Content-Transfer-Encoding: 8bit

{"delimiter":",","profiles":"D:/successContentProfiles.csv","format":"csv","max-errors":20}
--zaHf8xb3LfVOXZ0o2KUyqWD4Zlfumh0R9uyMN--Example of CSV content:
TenantId,Segment,FirstName,LastName,PhoneNumber[2],PhoneNumber[1],EmailAddress,Address.AddressType,Address.PostCode,Address.Address,Address.County,Address.

Responses

Success

ReturnCode ReturnString Description


200 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of the following reasons:

• Missing required parameter.


400 Bad Request • Parameter value of unexpected type.

• Invalid object syntax.

Universal Contact Server API Guide 317


ProfileService Methods ProfileService importProfileRecords

FaultCode FaultString Description

• Missing required attribute

Credentials are missing or incorrect, or the given user is


not allowed to execute a given service (such as an
401 Not Authorized
administrative service method that changes the profile
schema).
The operation is forbidden and the reason is specified in
the error message. This error is returned in the following
cases:
403 Forbidden
• Attempt to add customer profiles prior to the
definition of a profile schema.

The specified URI is invalid, or the requested resource


404 Not Found (such as a customer, service, state, task, extension, or
identification key) does not exist.
Returned when an unsupported operation is requested.
For instance, if a resource supports only PUT and GET
405 Method Not Allowed
operations, a POST request on this resource returns this
error.
In the header of your request, Content-Type is not set to
415 Unsupported Media Type a valid value. Most operations of Context Services
support only "application/json".

Universal Contact Server API Guide 318


ProfileService Methods ProfileServiceMergeUnmerge

ProfileServiceMergeUnmerge


Universal Contact Server API Guide 319


ProfileService Methods ProfileServiceMergeUnmerge

mergeProfiles

Purpose
Merges two profiles together, transferring all data from one to the other (attributes and extensions).

URL
• PUT /profiles/{customer_id}/merge/{source_id}

Request

URL Parameters

Key ValueType Value Description Mandatory Unique Default


The customer
ID where the
customer_id String data is to be true true
merged
(destination).
The customer
ID of the
source
customer data
to be merged
source_id String true true
(source). This
ID will be
deleted once
the merge is
complete.

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
X-Genesys- Segment
String false true
Segment value (not to

Universal Contact Server API Guide 320


ProfileService Methods ProfileServiceMergeUnmerge

Key ValueType Value Description Mandatory Unique Default


be provided
by customer)

Body

Key ValueType Value Description Mandatory Unique Default


ID of the
agent
performing the
agent_id String merge false true 0
operation. 0
for no Agent
ID
Force the
merge in case
of extension
conflicts. Do
not fail and
force_merge Boolean false true false
use the
source value
for the
merged
contact.
Reason why
reason String this merge is false true
performed
description String false true

Sample
PUT /profiles/00001b8BBKDX000D/merge/00001b8BBKDX000H
{ }

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Universal Contact Server API Guide 321


ProfileService Methods ProfileServiceMergeUnmerge

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
following cases:
403 Forbidden
• Attempt to add customer profiles
prior to the definition of a profile
schema.

The specified URI is invalid, or the


requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 322


ProfileService Methods ProfileServiceMergeUnmerge

unmergeProfiles

Purpose
Split one profile into two profiles that were previously merged.

• Contact objects—All modifications made to the Contact (new/updated/deleted attributes) after the merge operation are
lost.

• Interaction objects—Interactions created and associated to a Contact before the merge operation are assigned back to
this Contact.

URL
• PUT /profiles/{customer_id}/unmerge/

URL Parameters

Key ValueType Value Description Mandatory Unique Default


Id of the
successfully
customer_id String merged true true
contact
destination

HTTP Headers

Key ValueType Value Description Mandatory Unique Default


X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
PUT /profiles/00001b8BBKDX000H/unmerge/
{ }

Universal Contact Server API Guide 323


ProfileService Methods ProfileServiceMergeUnmerge

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons:

• Missing required parameter.

• Parameter value of unexpected


400 Bad Request
type.

• Invalid object syntax.

• Missing required attribute

Credentials are missing or incorrect,


or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
403 Forbidden
following cases: Attempt to add
customer profiles prior to the
definition of a profile schema.
The specified URI is invalid, or the
requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 324


ProfileService Methods ProfileServiceMergeUnmerge

unmergeProfilesAsSource

Purpose
Split one profile in two profiles, that were previously merged.

• Contact objects—All modifications made to the Contact (new/updated/deleted attributes) after the merge operation are
lost.

• Interaction objects—Interactions created and associated to a Contact before the merge operation are assigned back to
this Contact.

URL
• PUT /profiles/{customer_id}/unmerge/as_source

URL Parameters
Key ValueType Value Description Mandatory Unique Default
Id of the
successfully
customer_id String merged true true
contact
destination.

HTTP Headers
Key ValueType Value Description Mandatory Unique Default
X-Genesys- Integer value
Integer false true
TenantId of tenant id
Segment
X-Genesys- value (not to
String false true
Segment be provided
by customer)

Sample
PUT /profiles/00001b8BBKDX000H/unmerge/as_source
{ }

Universal Contact Server API Guide 325


ProfileService Methods ProfileServiceMergeUnmerge

Responses

Success

ReturnCode ReturnString Description


204 OK Request successful

Error

FaultCode FaultString Description


General error which can be one of
the following reasons: Missing
400 Bad Request required parameter. Parameter value
of unexpected type. Invalid object
syntax. Missing required attribute.
Credentials are missing or incorrect,
or the given user is not allowed to
401 Not Authorized execute a given service (such as an
administrative service method that
changes the profile schema).
The operation is forbidden and the
reason is specified in the error
message. This error is returned in the
403 Forbidden
following cases: Attempt to add
customer profiles prior to the
definition of a profile schema.
The specified URI is invalid, or the
requested resource (such as a
404 Not Found customer, service, state, task,
extension, or identification key) does
not exist.
Returned when an unsupported
operation is requested. For instance,
405 Method Not Allowed if a resource supports only PUT and
GET operations, a POST request on
this resource returns this error.
In the header of your request,
Content-Type is not set to a valid
415 Unsupported Media Type value. Most operations of Context
Services support only "application/
json".

Universal Contact Server API Guide 326


System Information ProfileServiceMergeUnmerge

System Information
• GetIdentifier

• GetServerTime

• GetSystemSettings

• GetVersion

Universal Contact Server API Guide 327


System Information GetIdentifier

GetIdentifier

Purpose
Get a new UCS Id.

URL
• GET /SystemInformation/GetIdentifier/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Get a new
Id String true true
UCS Id.

Universal Contact Server API Guide 328


System Information GetServerTime

GetServerTime

Purpose
Retrieve the current time on UCS' server in ISO8601 Date Format.

URL
• GET /SystemInformation/GetServerTime/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Server time as
a String in
Time String true true
ISO8601 Date
Format.

Sample

Time 2013-04-11T10:06:56.646Z

Universal Contact Server API Guide 329


System Information GetSystemSettings

GetSystemSettings

Purpose
The purpose is to provide available options. This particular service aims at providing users with a picture of UCS
information, regardless of which client is connected behind a proxy.

The service could also serve as an audit on a UCS instance.

URL
• GET /SystemInformation/GetServerTime/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The host
information
summary (as
Host KVList true true
seen in
Configuration,
or audited).
The list of
ports defined
Ports KVList true true
and their
options.
Describe
Database KVList database true true
information.
The
application
options as
ApplicationOptions
KVList seen in true true
Options Tab
of
Configuration.
The cluster
ClusterOptions KVList true true
options as

Universal Contact Server API Guide 330


System Information GetSystemSettings

Key ValueType Value Description Mandatory Unique Default


seen in
Options Tab
of
Configuration.
Merged list of
application
Options KVList options and true true
cluster
options.

Host

Key ValueType Value Description Mandatory Unique Default


The host
name as
defined in
HostName String true true
Host
information in
Configuration.
IP Address as
defined in
IPAddress String Host true true
information in
Configuration.
LCA Port as
defined in
LCAPort String Host true true
information in
Configuration.

Ports

Key ValueType Value Description Mandatory Unique Default


The port ID
and
associated
options as
(PortId) KVList true true
defined in
Application
Server Info in
Configuration.

Universal Contact Server API Guide 331


System Information GetSystemSettings

(PortId)

Key ValueType Value Description Mandatory Unique Default


The port ID as
defined in
Id String Application true true
Server Info in
Configuration.
Listening port
as defined in
Port String Application true true
Server Info in
Configuration.
Protocol as
defined in
Protocol String Application true true
Server Info in
Configuration.
Specifies if
IsSecured Token yes or no the port is true true
secured.

DatabaseInfo attributes

Key ValueType Value Description Mandatory Unique Default


The database
(DAPName) KVList information for true true
this DAP.

DAPName

Key ValueType Value Description Mandatory Unique Default


The database
information
DBMSName String from true true
Configuration
Server DAP.
The database
information
DBMSType String from true true
Configuration
Server DAP.
Specifies the
main or
DBMSRole Token Role of the true true
archive
database.

Universal Contact Server API Guide 332


System Information GetSystemSettings

Key ValueType Value Description Mandatory Unique Default

Possible values
are: Main, Archive

Universal Contact Server API Guide 333


System Information GetVersion

GetVersion

Purpose
This method retrieves the UCS version from the server.

URL
• GET /SystemInformation/GetVersion/

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


Version of
Version String true true
UCS

Universal Contact Server API Guide 334


URS Service GetVersion

URS Service
• UpdateInteraction

Universal Contact Server API Guide 335


URS Service UpdateInteraction

UpdateInteraction

Purpose
For URS

URL
• PUT /URSService/UpdateInteraction/

Request

Parameters

Key ValueType Value Description Mandatory Unique Default


InteractionId String true true
Deleted String false true
IxnAttributesInUserData
String false true
DatePattern String false true
DateTimeZone String false true
TenantId Integer true true

Universal Contact Server API Guide 336


URS Service GetFAQObject

GetFAQObject

URL
• GET /OMResponse/GetFAQObject/

Parameters
Key ValueType Value Description Mandatory Unique Default
The
Id String true true
FAQObject Id

Success

Parameters

Key ValueType Value Description Mandatory Unique Default


The
Id String true true
FAQObject Id
The FAQ
FAQName String true true
name
The Root
RootCategoryId String true true
Category Id
Iso8601 Date The date of
CreationDate String true true
Format creation
DBId of the
OwnerId Integer true true
owner
DBId of the
TenantId Integer true true
tenant
Lang String The language true true
TOId String The to Id false true
Id of the
ModelId String false true
Model
A description
Info String 255 max of 255 chars false true
max

Universal Contact Server API Guide 337


URS Service GetFAQObject

Error
FaultCode FaultString Description
Incorrect value for parameter {0},
204 Incorrect value for parameter
expected {1} but was {2}
510 {0} not found in database Record is not found in database

Universal Contact Server API Guide 338


Data Segmentation GetFAQObject

Data Segmentation

Important
Other Genesys applications such as ESJ or ChatServer don't currently support segmentation. This
article is relevant to users developing their own applications.

The Segmentation concept


UCS 9.1 supports data segmentation on contacts and interactions. In the API the segment is referred to as
SubscriberId, and in Cassandra and Elasticsearch schema it is stored in the Segment column/field. A segment
exists only within a tenant—it can be considered as a "sub-tenant".

When segmentation is enabled, it allows the restriction of searches to a particular segment. Contact identification
also follows segmentation, identify on the same email address will create different contacts for different segments.
The segment is immutable—it is not possible to reassign the segment of a contact or an interaction. UCS also
prevents mixing segments—a contact created in segment "A" can't be associated with an interaction in segment
"B".

Accessing a contact or an interaction by its Id does not require a SubscriberId or Segment. UCS does not support
authentication so it's not possible to prevent a client with an Id from accessing data from a particular segment.
Filtering should be enforced on the application side. Note that SubscriberId/Segment is always a parameter and is
never returned to the client application, even when using wildcards.

When segmentation is disabled or if a segment is not provided, the value will default to "not-applicable".

UCS Options
• [subtenant]/enabled

• Default value—false

• Valid values—true, false

• Changes take effect—Immediately

• Description—Enables/disables support for segmentation.

• [subtenant]/subscriberid-required

• Default value—true

• Valid values—true, false

• Changes take effect—Immediately

Universal Contact Server API Guide 339


Data Segmentation GetFAQObject

• Description—Specifies whether SubscriberId is required for segmentation. If the parameter is missing, UCS rejects
the request.

Creating Segments
Segment are created dynamically on the General tab of the Transaction folder of a tenant. The segment's name
must follow this format:

ContactCenterSettings.<name>

and the segment's type should be Attribute. The example below shows the creation of a Support segment:

Universal Contact Server API Guide 340


Data Segmentation GetFAQObject

Using PSDK—Sample Java Code


This example assumes UCS is running with the option settings below:

• [subtenant/enabled] = true

• [subtenant/subscriberid-required] = false

final UniversalContactServerProtocol ucsClient = getPSDKClient();


final int tenantId = 101;

//Creating the first contact


RequestIdentifyContact identifyContact1 = new RequestIdentifyContact();
identifyContact1.setTenantId(tenantId);
identifyContact1.setSubscriberId("Support"); //This is the first segment
identifyContact1.setMediaType("email");

KeyValueCollection fields1 = new KeyValueCollection();


fields1.addString("EmailAddress", "buffy.summers@sunnydale.univ");
fields1.addString("FirstName", "Buffy");
fields1.addString("LastName", "Summers");

identifyContact1.setOtherFields(fields1);

EventIdentifyContact eventIdentifyContact1 = (EventIdentifyContact) ucsClient.request(identifyContact1);


String contactIdSupport = eventIdentifyContact1.getContactId();
contactIds.add(contactIdSupport);

RequestGetAttributes getAttributes1 = new RequestGetAttributes();


getAttributes1.setContactId(contactIdSupport);
EventGetAttributes attributes1 = (EventGetAttributes) ucsClient.request(getAttributes1);
System.out.println("First contact created:" + attributes1);
/*
11:03:45.663 Trc 21125 [SvcSrvW-1 ] RequestLogger <esp156Id1r1> Response:

Universal Contact Server API Guide 341


Data Segmentation GetFAQObject

Id = esp156Id1r1
Type = Response
AppName = UCS
AppType = UCS
Service = OMContacts
Method = IdentifyContact
Parameters =
FirstName [utf] = "Buffy"
LastName [utf] = "Summers"
EmailAddress [utf] = "buffy.summers@sunnydale.univ"
ContactIdList [utf] = "1000AE9YfdHYpsPK"
NumberOfContactsFound [int] = 0
ContactCreated [utf] = "true"
ContactId [utf] = "1000AE9YfdHYpsPK"
*/

//Creating the second contact with the same attributes


RequestIdentifyContact identifyContact2 = new RequestIdentifyContact();
identifyContact2.setTenantId(tenantId);
identifyContact2.setSubscriberId("VIP"); //This is the second segment
identifyContact2.setMediaType("email");

KeyValueCollection fields2 = new KeyValueCollection();


fields2.addString("EmailAddress", "buffy.summers@sunnydale.univ");
fields2.addString("FirstName", "Buffy");
fields2.addString("LastName", "Summers");

identifyContact2.setOtherFields(fields2);

EventIdentifyContact eventIdentifyContact2 = (EventIdentifyContact) ucsClient.request(identifyContact2);


String contactIdVIP = eventIdentifyContact2.getContactId();
contactIds.add(contactIdVIP);

RequestGetAttributes getAttributes2 = new RequestGetAttributes();


getAttributes2.setContactId(contactIdVIP);
EventGetAttributes attributes2 = (EventGetAttributes) ucsClient.request(getAttributes2);
System.out.println("Second contact created:" + attributes2);

/*
11:03:45.722 Trc 21125 [SvcSrvW-3 ] RequestLogger <esp158Id3r3> Response:

Universal Contact Server API Guide 342


Data Segmentation GetFAQObject

Id = esp158Id3r3
Type = Response
AppName = UCS
AppType = UCS
Service = OMContacts
Method = IdentifyContact
Parameters =
FirstName [utf] = "Buffy"
LastName [utf] = "Summers"
EmailAddress [utf] = "buffy.summers@sunnydale.univ"
ContactIdList [utf] = "1000AE9YfdHYAPPq"
NumberOfContactsFound [int] = 0
ContactCreated [utf] = "true"
ContactId [utf] = "1000AE9YfdHYAPPq"
*/

Thread.sleep(1000); //Wait for Elasticsearch refresh, not needed when accessing data by Id or using identify requests

RequestContactListGet contactListGet = new RequestContactListGet();


contactListGet.setSubscriberId("Support");
contactListGet.setTenantId(tenantId);

SearchCriteriaCollection search = new SearchCriteriaCollection();


SimpleSearchCriteria searchRequest = new SimpleSearchCriteria();
searchRequest.setAttrName("ESQuery");
searchRequest.setOperator(Operators.Equal);
searchRequest.setAttrValue("AttributeValues.FirstName:buffy AND AttributeValues.LastName:summers"); //New simple Lucene syntax

search.add(searchRequest);
contactListGet.setSearchCriteria(search);

EventContactListGet contactList = (EventContactListGet) ucsClient.request(contactListGet);


System.out.println("Finds first contact only:" + contactList);
/*
11:03:46.022 Trc 21125 [SvcSrvW-5 ] RequestLogger <esp161Id5r5> Response:
Id = esp161Id5r5
Type = Response
AppName = UCS
AppType = UCS
Service = OMContacts

Universal Contact Server API Guide 343


Data Segmentation GetFAQObject

Method = ContactListGet
Parameters =
TotalCount [int] = 1
PageSize [int] = 1
ContactData [lst] =
0 [lst] =
Id [utf] = "1000AE9YfdHYpsPK"
Attributes [lst] =
TenantId [int] = 101
FirstName [utf] = "Buffy"
CreatedDate [utf] = "2019-02-05T10:03:45.462Z"
LastName [utf] = "Summers"
ModifiedDate [utf] = "2019-02-05T10:03:45.462Z"
EmailAddress [utf] = "buffy.summers@sunnydale.univ"
HasNext [utf] = "FALSE"
*/

//SubscriberId is not mandatory to removing it will find both contacts, by default segment is set to "not-applicable"
contactListGet.setSubscriberId(null);
contactList = (EventContactListGet) ucsClient.request(contactListGet);
System.out.println("Finds both contacts:" + contactList);

//When segment is not required it is still possible to use it in regular queries including wildcard searches.
//Segment column is analysed in ES using Keyword analyser, it means it is possible to use path in segments.
//For example /emea/europe/france when inserting contacts and interactions making it possible to filter by /emea/europe/*
contactListGet.setSubscriberId(null);
searchRequest.setAttrValue("AttributeValues.FirstName:buffy AND Segment:Supp*");
contactList = (EventContactListGet) ucsClient.request(contactListGet);
System.out.println("Finds contact in Support segment:" + contactList);

//Interactions
RequestInsertInteraction insertInteraction = RequestInsertInteraction.create();
InteractionAttributes interactionAttributes = new InteractionAttributes();
interactionAttributes.setTenantId(tenantId);
interactionAttributes.setSubscriberId("Support");
interactionAttributes.setContactId(contactIdSupport);
interactionAttributes.setTypeId("Inbound");
interactionAttributes.setSubtypeId("InboundNew");
interactionAttributes.setCanBeParent(true);

Universal Contact Server API Guide 344


Data Segmentation GetFAQObject

interactionAttributes.setEntityTypeId(EntityTypes.EmailIn);
interactionAttributes.setMediaTypeId("email");
interactionAttributes.setStartDate(new Date());
interactionAttributes.setStatus(Statuses.New);
interactionAttributes.setSubject("Requesting assistance for customer billing");

insertInteraction.setInteractionAttributes(interactionAttributes);

EmailInEntityAttributes entityAttributes = new EmailInEntityAttributes();


entityAttributes.setFromAddress("buffy.summers@sunnydale.univ");
entityAttributes.setToAddresses("help@hunters.callcenter");
entityAttributes.setMailbox("help@hunters.callcenter");
insertInteraction.setEntityAttributes(entityAttributes);

InteractionContent content = new InteractionContent();


content.setText("Hi, I killed two vampires in one blow, should I bill them separately? Buffy.");
insertInteraction.setInteractionContent(content);

EventInsertInteraction eventInsertInteraction = (EventInsertInteraction) ucsClient.request(insertInteraction);


String interactionId = eventInsertInteraction.getInteractionId();
interactionIds.add(interactionId);

Thread.sleep(1000); //Wait for Elasticsearch refresh

RequestInteractionListGet interactionListGet = new RequestInteractionListGet();


interactionListGet.setSubscriberId("Support");
interactionListGet.setTenantId(tenantId);

SearchCriteriaCollection searchIxn = new SearchCriteriaCollection();


SimpleSearchCriteria searchIxnRequest = new SimpleSearchCriteria();
searchIxnRequest.setAttrName("ESQuery");
searchIxnRequest.setOperator(Operators.Equal);
searchIxnRequest.setAttrValue("Text:buffy");

searchIxn.add(searchIxnRequest);
interactionListGet.setSearchCriteria(searchIxn);

EventInteractionListGet ixnListGet = (EventInteractionListGet) ucsClient.request(interactionListGet);


System.out.println("Finds the interaction from the first contact:" + ixnListGet);

Universal Contact Server API Guide 345


Data Segmentation GetFAQObject

/*
14:38:27.686 Trc 21125 [SvcSrvW-7 ] RequestLogger <esp162Id7r7> Response:
Id = esp162Id7r7
Type = Response
AppName = UCS
AppType = UCS
Service = OMInteractions
Method = InteractionListGet
Parameters =
PageSize [int] = 1
InteractionData [lst] =
0 [lst] =
Id [utf] = "1000AE9YffYzRJYI"
*/

//Using ES JSON DSL, UCS takes care of wrapping segment constraint, query requests text highlighting that will in ES metadata
searchIxnRequest.setAttrValue("{\"query\":{\"wildcard\":{\"Text\":\"buff*\"}},\"highlight\":{\"fields\":{\"Text\":{}}}}");
ixnListGet = (EventInteractionListGet) ucsClient.request(interactionListGet);
System.out.println("Finds the interaction from the first contact:" + ixnListGet);

/* In below partial log, ES metadata found in ESQuery column contains the highlighted match of the wildcard query to substitute in a UI
15:00:36.979 Trc 21125 [SvcSrvW-8 ] RequestLogger <esp163Id7r8> Response:
Id = esp163Id7r8
Type = Response
AppName = UCS
AppType = UCS
Service = OMInteractions
Method = InteractionListGet
Parameters =
PageSize [int] = 1
InteractionData [lst] =
0 [lst] =
Id [utf] = "1000AE9Yfgd5qXCM"
Attributes [lst] =
AllAttributes [lst] =[]
ContactId [utf] = "1000AE9Yfgd4txXG"
...
ESQuery [lst] =
...
highlight [lst] =

Universal Contact Server API Guide 346


Data Segmentation GetFAQObject

Text [utf] = "<em>Buffy</em>."


...
Text [utf] = "Hi, I killed two vampires in one blow, should I bill them separately? Buffy."
Subject [utf] = "Requesting assistance for customer billing"
ToAddresses [utf] = "help@hunters.callcenter"
TenantId [int] = 101
Id [utf] = "1000AE9Yfgd5qXCM"
Mailbox [utf] = "help@hunters.callcenter"
ThreadHash [utf] = "136444583"
HasNext [utf] = "FALSE"
TotalCount [int] = 1
*/

//Search again in the other segment finds no interaction


interactionListGet.setSubscriberId("VIP");
ixnListGet = (EventInteractionListGet) ucsClient.request(interactionListGet);
System.out.println("No interaction found: " + ixnListGet);

//UCS ensures that it is not possible to associate a contact and an interaction in different segments
interactionAttributes.setSubscriberId("VIP");
Message error = ucsClient.request(insertInteraction);
System.out.println(error);
//FaultString = 10:03:46.162 Server: UCS Msg: Contact '1000AE9YfdHYpsPK on tenant 101/VIP' not found in database

Universal Contact Server API Guide 347

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy