Jump to: navigation, search

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
InteractionAttributes KVList The list of attributes and their values. true true
EntityAttributes KVList The list of Entity specific attributes and their values. The list of attributes depends on the EntityTypeId

mandatory if EntityTypeId=0, 1, 2, 3, 5, or 6

false true
InteractionContent KVList Content. false true
InteractionContentSentReceived KVList Important—Supports specifically ESJ MIME Customization false true
DeleteAllAttachmentsBefore String Important—(For ESJ only) Introduced to support ESJ insert interaction with attachments, delete all previous attachments before adding new ones. false true false
Attachments KVList Important—(For ESJ only) Introduced to support ESJ insert interaction with attachments. The list of attachments for this interaction. false true


InteractionAttributes

Key ValueType Value Description Mandatory Unique Default
TenantId Integer Tenant value true true
SubscriberId String Important—The subscriber (line of business) within the tenant to which the interaction belongs false true
MediaTypeId String Media Type value (must be declared in Configuration Server).

Max length: 32 characters

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

Max length: 32 characters

true true
StartDate String Formatted String using Date pattern (in format "yyyy-MM-ddTHH:mm:ss.SSSZ")

This attribute is mandatory in MCR DB but UCS provides a default value if no value is provided

false true Current UCS date
Status Integer Must be one of 0 (NEW), 1 (PENDING), 2 (IN_PROCESS), 3 (STOPPED) true true
Id String Max. length: 16 characters false true UCS generated Id
Timeshift Integer false true null
CategoryId String Max. length: 16 characters false true
SubtypeId String Max. length: 32 characters false true
ExternalId String Max. length: 256 characters false true
ThreadId String Max. length: 16 characters false true
Subject String Max. length: 512 characters false true
IsCategoryApproved String Value can be true or false false true
StoppedReason String Max. length: 64 characters false true
ContactId String Max. length: 16 characters false true
ParentId String Max. length: 16 characters false true
Lang String Max. length: 64 characters false true
QueueName String Max. length: 64 characters false true
IsSpam String Value can be true or false false true
WebSafeEmailStatus String Max. length: 32 characters false true
OwnerId Integer false true
TheComment String false true
EndDate String Formatted String using Date pattern (in format "yyyy-MM-ddTHH:mm:ss.SSSZ") false true
AllAttributes KVList User data key/value pairs false true
EntityTypeId Integer Possible values are:

0:EmailIn 1:EmailOut 2:Chat 3:PhoneCall 5:Callback 6:CoBrowse (deprecated) 7:Interaction If EntityTypeId is not equal to 7, then specific parameters might be required(see XxxAttributes KVList details).

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


EntityAttributes KVList (EntityTypeId = 0)

Key ValueType Value Description Mandatory Unique Default
FromAddress String Must conform to RFC

Max length: 256 characters

false true
FromPersonal String Must conform to RFC

Max length: 256 characters

false true
ReplyToAddress String Must conform to RFC

Max length: 256 characters

false true
ToAddresses String Must conform to RFC false true
CcAddresses String Must conform to RFC false true
BccAddresses String Must conform to RFC false true
SentDate String Formatted with pattern "yyyy-MM-ddTHH:mm:ss.SSSZ" false true
Mailbox String Max. length: 256 characters true true
WhichRuleMatched String Max. length: 16 characters false true
EmailOutId String Max. length: 16 characters false true
Header Binary Important—Applies also to GetInteractionContent if EntityTypeId=0 EmailIn false true
NullAttributes String Important—Comma-separated attributes names as described above; for example, "Text, StructuredText" false true


EntityAttributes KVList (EntityTypeId = 1)

Key ValueType Value Description Mandatory Unique Default
FromAddress String Must conform to RFC false true
FromPersonal String Must conform to RFC false true
ReplyToAddress String Must conform to RFC false true
ToAddresses String Must conform to RFC false true
CcAddresses String Must conform to RFC false true
BccAddresses String Must conform to RFC false true
SentDate String Formatted with pattern "yyyy-MM-ddTHH:mm:ss.SSSZ" false true
Forward Integer true true
ReferenceId String Max. length: 255 characters false true
ReviewerId Integer false true
StandardResponseId String Max. length: 16 characters false true
NullAttributes String Important—Comma-separated attributes names as described above; for example, "Text, StructuredText" false true


EntityAttributes KVList (EntityTypeId = 2)

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


EntityAttributes KVList (EntityTypeId = 3)

Key ValueType Value Description Mandatory Unique Default
Duration Integer false true
Outcome String Max. length: 100 characters false true
PhoneNumber String Max. length: 30 characters false true
TConnectionId String Max. length: 16 characters false true
NullAttributes String Important—Comma-separated attributes names as described above; for example, "Text, StructuredText" false true


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
StartTime String Formatted with pattern "yyyy-MM-ddTHH:mm:ss.SSSZ" true true
EndTime String Formatted with pattern "yyyy-MM-ddTHH:mm:ss.SSSZ" false true
CustomerNumber String Max. length: 32 characters true true
Attempts Integer true true
DN String Max. length: 32 characters false true
Location String Max. length: 32 characters false true
CallbackServerID String Max. length: 256 characters false true
CallResult Integer false true
TheType Integer false true
NullAttributes String Comma-separated attributes names as described above, such as "Text, StructuredText" false true

EntityAttributes KVList (EntityTypeId = 6)

Key ValueType Value Description Mandatory Unique Default
(Visited URL) String The String value formatted with pattern "yyyy-MM-ddTHH:mm:ss.SSSZ" is the Visited Date

(Visited URL) Max length: 255 characters

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


InteractionContent

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

Max length: 256 characters

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

InteractionContentSentReceived KVList

Key ValueType Value Description Mandatory Unique Default
Content Binary If not null, a record is created in IxnContentSentReceived table true true
MimeType String Max. length: 256 characters true true

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
DocumentId String Mandatory in link creation mode

If not null, attach this document ID to this interaction

false true
MimeType String Mandatory in document creation mode

Max. length: 256 characters

false true
TheName String Mandatory in document creation mode

Max. length: 256 characters

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

Success

Parameters

Key ValueType Value Description Mandatory Unique Default
InteractionId String Unique id for newly created interaction true true


Error

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

Feedback

Comment on this article:

blog comments powered by Disqus
This page was last modified on May 18, 2018, at 07:05.