Skip to content

Deflects a conversation to a channel (same request body as API v2).

Request

Security
bearerAuth and apiKeyAuth
Bodyapplication/jsonrequired
serialVersionUIDobject

Unresolved type (staticfinallong)

assetIdstring
snIdstring
accountIdinteger, (int64)
deflectionTypestring
viaDeflectionTypestring

Channel to sent deflection message on. Ex. If you want to share live chat link on SMS using twilio. viaDeflectionType would be TWILO

viaAccountIdinteger, (int64)

Account to use for sending deflection message.

caseNumberstring

Case number to which the conversation needs to be linked.

createCaseboolean

Boolean flag for whether or not a new case needs to be created. Default value is true

customPropertiesobject

Map of case custom property field name vs list of values to be inserted into case

messageCustomPropertiesobject

Map of message custom property field name vs list of values to be inserted into case

commentstring

Any comments to be included from any previous cases/interactions in the case

urlShortnerIdstring

Id of the url shortner to be used

caseConfigIdstring

Case Create/Associate Config to be used

selfTextstring

Text which the fan will have to send to associate case

caseIdstring
conversationIdstring
createNewCaseForGivenIdboolean
linkSentboolean
newCaseIdstring
contentReplacementDetailsobject
attachmentobject(Attachment_outbound)
languagestring
deflectionParamsany(DeflectionParams)
processAsyncboolean
additionalobject
inReplyToUMKeystring
preGeneratePostIdboolean
curl -i -X POST \
  https://developer.sprinklr.com/_mock/apis/sprinklr-v3/deflect \
  -H 'Authorization: Bearer <YOUR_Token_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'Key: YOUR_API_KEY_HERE' \
  -d '{
    "serialVersionUID": {},
    "assetId": "string",
    "snId": "string",
    "accountId": 0,
    "deflectionType": "string",
    "viaDeflectionType": "string",
    "viaAccountId": 0,
    "caseNumber": "string",
    "createCase": true,
    "customProperties": {
      "property1": [
        "string"
      ],
      "property2": [
        "string"
      ]
    },
    "messageCustomProperties": {
      "property1": [
        "string"
      ],
      "property2": [
        "string"
      ]
    },
    "comment": "string",
    "urlShortnerId": "string",
    "caseConfigId": "string",
    "selfText": "string",
    "caseId": "string",
    "conversationId": "string",
    "createNewCaseForGivenId": true,
    "linkSent": true,
    "newCaseId": "string",
    "contentReplacementDetails": {
      "property1": {},
      "property2": {}
    },
    "attachment": {
      "displayName": "string",
      "type": {},
      "mediaList": [
        {
          "langVsTranslatedFieldValues": {
            "property1": {
              "property1": "string",
              "property2": "string"
            },
            "property2": {
              "property1": "string",
              "property2": "string"
            }
          },
          "mediaUploadLocation": {},
          "type": "POST",
          "imageUrl": "string",
          "previewImageUrl": "string",
          "title": "string",
          "description": "string",
          "alternateText": "string",
          "content": "string",
          "source": "string",
          "caption": "string",
          "preTranscodingUrl": "string",
          "transcodedMediaUrl": "string",
          "clickThroughUrl": "string",
          "assosciatedMediaAssetId": "string",
          "mediaAssetId": "string",
          "ugcId": "string",
          "ugcSenderId": "string",
          "defaultMedia": {},
          "mediaList": [
            {}
          ],
          "additional": {
            "property1": [
              "string"
            ],
            "property2": [
              "string"
            ]
          },
          "rawMediaContent": "string",
          "mediaProperties": {
            "serialVersionUID": {},
            "channelType": "SLIDESHARE",
            "templateProperties": {
              "serialVersionUID": {},
              "elementId": "string",
              "quantity": 0,
              "price": 0,
              "currency": "string",
              "payload": "string",
              "subtitle": "string",
              "type": "string",
              "url": "string",
              "payloadMd5": "string"
            },
            "downloadable": true,
            "makePrivate": true,
            "shareable": true,
            "embedable": true,
            "secret": true,
            "tags": [
              "string"
            ]
          },
          "sourceType": "string",
          "originalSource": "string",
          "embedHtml": "string",
          "callToAction": {
            "serialVersionUID": {},
            "type": "string",
            "value": {
              "serialVersionUID": {},
              "link": "string",
              "appLink": "string",
              "page": 0,
              "productLink": "string",
              "linkCaption": "string",
              "leadGenFormId": "string",
              "applicationId": "string",
              "appDestination": "string",
              "linkFormat": "string",
              "eventId": "string",
              "whatsappNumber": "string",
              "objectStoreURLs": [
                "string"
              ],
              "messengerAppDestinationPageId": "string"
            }
          },
          "mediaDetails": {
            "imageDetails": {
              "width": 0,
              "height": 0,
              "aspectRatio": 0.1
            },
            "videoDetails": {
              "width": 0,
              "height": 0,
              "duration": 0,
              "size": 0,
              "aspectRatio": 0.1,
              "frameRate": 0.1,
              "bitRate": 0,
              "videoCodec": "string",
              "audioCodec": "string",
              "audioSampleRate": 0,
              "audioChannel": 0,
              "audioProfile": "string",
              "videoPixelFmt": "string",
              "audioBitrate": 0,
              "totalBitrate": 0,
              "audioStreamCount": 0,
              "rotation": 0,
              "moments": [
                {
                  "additional": {}
                }
              ]
            },
            "pollsDetails": {
              "anonymous": true,
              "pollId": "string",
              "ownerId": "string",
              "pollQuestion": "string",
              "duration": "string",
              "pollOptions": [
                {}
              ],
              "totalVotes": 0,
              "expiryTime": "string"
            },
            "eventDetails": {
              "startTime": 0,
              "endTime": 0,
              "privacyPolicyUrl": "string",
              "eventUrl": "string",
              "type": "string",
              "venue": "string",
              "address": "string",
              "format": "string",
              "authorId": 0,
              "timezone": "string"
            }
          },
          "closedCaptions": [
            {
              "serialVersionUID": {},
              "title": "string",
              "captionResourceUrl": "string",
              "languageCode": "string",
              "extension": "string",
              "autoGenerated": true,
              "additional": {
                "property1": [
                  null
                ],
                "property2": [
                  null
                ]
              }
            }
          ],
          "ignorePreProcessing": true,
          "setAsThumbnail": true,
          "messageLocation": {
            "serialVersionUID": {},
            "text": "string",
            "lat": 0.1,
            "lon": 0.1,
            "placeId": "string",
            "link": "string",
            "additional": {
              "property1": "string",
              "property2": "string"
            }
          },
          "featuredImage": true,
          "sizeInBytes": 0,
          "duration": 0.1,
          "previewSizeInBytes": 0,
          "actionDetails": {
            "serialVersionUID": {},
            "action": "CreateCalendarEventActionDetails",
            "makeExternalCall": true,
            "externalCallParams": "string",
            "langVsTranslatedFieldValues": {
              "property1": {
                "property1": "string",
                "property2": "string"
              },
              "property2": {
                "property1": "string",
                "property2": "string"
              }
            },
            "startTime": 0,
            "endTime": 0,
            "dateType": {},
            "dynamicStartTime": "string",
            "dynamicEndTime": "string"
          },
          "thumbnailList": [
            "string"
          ],
          "previews": [
            {
              "serialVersionUID": {},
              "url": "string",
              "offset": 0
            }
          ],
          "videoLocalizationDetails": [
            {
              "title": "string",
              "description": "string",
              "locale": "string"
            }
          ],
          "defaultLocale": "string",
          "mediaMimeType": "string",
          "previewSourceUrl": "string",
          "copyrightDetails": {
            "id": "string",
            "status": {},
            "matchesFound": true,
            "lastUpdatedTime": 0
          },
          "order": 0
        }
      ],
      "secondaryMediaList": [
        {
          "langVsTranslatedFieldValues": {
            "property1": {
              "property1": "string",
              "property2": "string"
            },
            "property2": {
              "property1": "string",
              "property2": "string"
            }
          },
          "mediaUploadLocation": {},
          "type": "POST",
          "imageUrl": "string",
          "previewImageUrl": "string",
          "title": "string",
          "description": "string",
          "alternateText": "string",
          "content": "string",
          "source": "string",
          "caption": "string",
          "preTranscodingUrl": "string",
          "transcodedMediaUrl": "string",
          "clickThroughUrl": "string",
          "assosciatedMediaAssetId": "string",
          "mediaAssetId": "string",
          "ugcId": "string",
          "ugcSenderId": "string",
          "defaultMedia": {},
          "mediaList": [
            {}
          ],
          "additional": {
            "property1": [
              "string"
            ],
            "property2": [
              "string"
            ]
          },
          "rawMediaContent": "string",
          "mediaProperties": {
            "serialVersionUID": {},
            "channelType": "SLIDESHARE",
            "templateProperties": {
              "serialVersionUID": {},
              "elementId": "string",
              "quantity": 0,
              "price": 0,
              "currency": "string",
              "payload": "string",
              "subtitle": "string",
              "type": "string",
              "url": "string",
              "payloadMd5": "string"
            },
            "downloadable": true,
            "makePrivate": true,
            "shareable": true,
            "embedable": true,
            "secret": true,
            "tags": [
              "string"
            ]
          },
          "sourceType": "string",
          "originalSource": "string",
          "embedHtml": "string",
          "callToAction": {
            "serialVersionUID": {},
            "type": "string",
            "value": {
              "serialVersionUID": {},
              "link": "string",
              "appLink": "string",
              "page": 0,
              "productLink": "string",
              "linkCaption": "string",
              "leadGenFormId": "string",
              "applicationId": "string",
              "appDestination": "string",
              "linkFormat": "string",
              "eventId": "string",
              "whatsappNumber": "string",
              "objectStoreURLs": [
                "string"
              ],
              "messengerAppDestinationPageId": "string"
            }
          },
          "mediaDetails": {
            "imageDetails": {
              "width": 0,
              "height": 0,
              "aspectRatio": 0.1
            },
            "videoDetails": {
              "width": 0,
              "height": 0,
              "duration": 0,
              "size": 0,
              "aspectRatio": 0.1,
              "frameRate": 0.1,
              "bitRate": 0,
              "videoCodec": "string",
              "audioCodec": "string",
              "audioSampleRate": 0,
              "audioChannel": 0,
              "audioProfile": "string",
              "videoPixelFmt": "string",
              "audioBitrate": 0,
              "totalBitrate": 0,
              "audioStreamCount": 0,
              "rotation": 0,
              "moments": [
                {
                  "additional": {}
                }
              ]
            },
            "pollsDetails": {
              "anonymous": true,
              "pollId": "string",
              "ownerId": "string",
              "pollQuestion": "string",
              "duration": "string",
              "pollOptions": [
                {}
              ],
              "totalVotes": 0,
              "expiryTime": "string"
            },
            "eventDetails": {
              "startTime": 0,
              "endTime": 0,
              "privacyPolicyUrl": "string",
              "eventUrl": "string",
              "type": "string",
              "venue": "string",
              "address": "string",
              "format": "string",
              "authorId": 0,
              "timezone": "string"
            }
          },
          "closedCaptions": [
            {
              "serialVersionUID": {},
              "title": "string",
              "captionResourceUrl": "string",
              "languageCode": "string",
              "extension": "string",
              "autoGenerated": true,
              "additional": {
                "property1": [
                  null
                ],
                "property2": [
                  null
                ]
              }
            }
          ],
          "ignorePreProcessing": true,
          "setAsThumbnail": true,
          "messageLocation": {
            "serialVersionUID": {},
            "text": "string",
            "lat": 0.1,
            "lon": 0.1,
            "placeId": "string",
            "link": "string",
            "additional": {
              "property1": "string",
              "property2": "string"
            }
          },
          "featuredImage": true,
          "sizeInBytes": 0,
          "duration": 0.1,
          "previewSizeInBytes": 0,
          "actionDetails": {
            "serialVersionUID": {},
            "action": "CreateCalendarEventActionDetails",
            "makeExternalCall": true,
            "externalCallParams": "string",
            "langVsTranslatedFieldValues": {
              "property1": {
                "property1": "string",
                "property2": "string"
              },
              "property2": {
                "property1": "string",
                "property2": "string"
              }
            },
            "startTime": 0,
            "endTime": 0,
            "dateType": {},
            "dynamicStartTime": "string",
            "dynamicEndTime": "string"
          },
          "thumbnailList": [
            "string"
          ],
          "previews": [
            {
              "serialVersionUID": {},
              "url": "string",
              "offset": 0
            }
          ],
          "videoLocalizationDetails": [
            {
              "title": "string",
              "description": "string",
              "locale": "string"
            }
          ],
          "defaultLocale": "string",
          "mediaMimeType": "string",
          "previewSourceUrl": "string",
          "copyrightDetails": {
            "id": "string",
            "status": {},
            "matchesFound": true,
            "lastUpdatedTime": 0
          },
          "order": 0
        }
      ],
      "title": "string",
      "description": "string",
      "existingAlbumId": "string",
      "content": {
        "langVsTranslatedFieldValues": {
          "property1": {
            "property1": "string",
            "property2": "string"
          },
          "property2": {
            "property1": "string",
            "property2": "string"
          }
        },
        "translatedLanguage": "string",
        "samId": "string",
        "type": "string",
        "otherConfigs": {
          "property1": {},
          "property2": {}
        },
        "themeVsStyledFieldValues": {
          "property1": {},
          "property2": {}
        },
        "hideAttachment": true,
        "voiceCommands": "string",
        "screenReaderLabel": "string"
      },
      "additional": {
        "property1": [
          "string"
        ],
        "property2": [
          "string"
        ]
      },
      "preUploadedMediaDetails": {
        "serialVersionUID": {},
        "id": "string",
        "outboundId": "string",
        "createdDate": 0,
        "locked": true,
        "status": "string",
        "preUploadedMediaInfos": [
          {
            "serialVersionUID": {},
            "mediaKey": "string",
            "mediaSource": "string",
            "channelMediaId": "string",
            "uploadedTime": 0,
            "expiryTime": 0,
            "accountId": 0,
            "accountGroupId": "string",
            "additional": {
              "property1": {},
              "property2": {}
            }
          }
        ]
      }
    },
    "language": "string",
    "deflectionParams": {
      "type": "VIDEO_CHAT",
      "initiateCall": true,
      "isUsed": true,
      "slotId": "string"
    },
    "processAsync": true,
    "additional": {
      "property1": [
        "string"
      ],
      "property2": [
        "string"
      ]
    },
    "inReplyToUMKey": "string",
    "preGeneratePostId": true
  }'

Responses

Success

Bodyapplication/json
dataobject
errorsArray of objects(Error)
metadataobject(ResponseMetadata)
Response
{ "data": {}, "errors": [ { … } ], "metadata": {} }