Base path: /nexus/v3
POST
|
/channels/{channelId}/media
Upload a media resource
|
Upload a binary media file to Genesys to use in a RichMedia message. The response to this request includes a URL you can use as the image in the outgoing message payload.
Parameters
Name |
Default |
Description |
Parameter Type |
Data Type |
Required
|
X-Hub-Signature
|
|
The request signature, for example sha1=hash. The hash is built using the body of the message and secret for the channel.
|
header
|
string
|
true
|
x-ccid
|
|
The ID of the contact center the message is sent within.
|
header
|
string
|
true
|
X-B3-TraceId
|
|
The unique trace ID for the request.
|
header
|
string
|
|
channelId
|
|
The ID of the channel.
|
path
|
string
|
true
|
file
|
|
The file to upload.
|
formData
|
file
|
|
Responses
Code |
Reason
|
200
|
Operation was successful
|
{
"status": {
"code": 0,
"message": "string"
},
"data": {
"mediaId": "string",
"url": "string",
"filename": "string",
"mimetype": "string",
"length": 0
}
}
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
data
|
mediaId
|
(string):
The ID of the media resource.
bb4a9f86-dbbb-4464-a669-650da94fbad6
|
url
|
(string):
A synthetic URL to be used as reference in the outgoing message payload.
genesys://nexus/bb4a9f86-dbbb-4464-a669-650da94fbad6
|
filename
|
(string):
The name of the media resource.
MyImage
|
mimetype
|
(string):
The type of file.
image/jpeg
|
length
|
(integer):
The length of the media file.
|
UploadResponse
|
status
|
(object):
|
data
|
(object):
|
|
|
400
|
Bad Request
|
|
BadRequest
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
401
|
Unauthorized
|
|
Unauthorized
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
403
|
Forbidden
|
|
Forbidden
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
404
|
Channel not found
|
|
NotFound
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
415
|
Unsupported Media Type
|
|
UnsupportedMedia
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
500
|
Internal Server Error
|
|
ServerError
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
Usage
curl -X POST
-H "x-api-key: your_API_key"
-H "Content-Type: application/json"
"https://api-demo.com/nexus/v3/channels/{channelId}/media?"
GET
|
/channels/{channelId}/media/{mediaId}
Download a media resource
|
Download a media resource you previously uploaded to Genesys with POST /channels/{channelId}/media.
Parameters
Name |
Default |
Description |
Parameter Type |
Data Type |
Required
|
X-Hub-Signature
|
|
The request signature, for example sha1=hash. The hash is built using the body of the message and secret for the channel.
|
header
|
string
|
true
|
x-ccid
|
|
The ID of the contact center the message is sent within.
|
header
|
string
|
true
|
X-B3-TraceId
|
|
The unique trace ID for the request.
|
header
|
string
|
|
channelId
|
|
The ID of the channel.
|
path
|
string
|
true
|
mediaId
|
|
The media resource ID.
|
path
|
string
|
true
|
Responses
Code |
Reason
|
200
|
Operation was successful
|
400
|
Bad Request
|
|
BadRequest
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
401
|
Unauthorized
|
|
Unauthorized
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
403
|
Forbidden
|
|
Forbidden
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
404
|
Channel 1234567890 not found
|
|
NotFound
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
500
|
Internal Server Error
|
|
ServerError
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
Usage
curl -X GET
-H "x-api-key: your_API_key"
-H "Content-Type: application/json"
"https://api-demo.com/nexus/v3/channels/{channelId}/media/{mediaId}?"
DELETE
|
/channels/{channelId}/media/{mediaId}
Delete a media resource
|
Delete a media resource you previously uploaded to Genesys with POST /channels/{channelId}/media.
Parameters
Name |
Default |
Description |
Parameter Type |
Data Type |
Required
|
X-Hub-Signature
|
|
The request signature, for example sha1=hash. The hash is built using the body of the message and secret for the channel.
|
header
|
string
|
true
|
x-ccid
|
|
The ID of the contact center the message is sent within.
|
header
|
string
|
true
|
X-B3-TraceId
|
|
The unique trace ID for the request.
|
header
|
string
|
|
channelId
|
|
The ID of the channel.
|
header
|
path
|
true
|
mediaId
|
|
The media resource ID.
|
header
|
path
|
true
|
Responses
Code |
Reason
|
200
|
Operation was successful
|
{
"status": {
"code": 0,
"message": "string"
},
"data": {
"mediaId": "string",
"url": "string",
"filename": "string",
"mimetype": "string",
"length": 0
}
}
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
data
|
mediaId
|
(string):
The ID of the media resource.
bb4a9f86-dbbb-4464-a669-650da94fbad6
|
url
|
(string):
A synthetic URL to be used as reference in the outgoing message payload.
genesys://nexus/bb4a9f86-dbbb-4464-a669-650da94fbad6
|
filename
|
(string):
The name of the media resource.
MyImage
|
mimetype
|
(string):
The type of file.
image/jpeg
|
length
|
(integer):
The length of the media file.
|
UploadResponse
|
status
|
(object):
|
data
|
(object):
|
|
|
400
|
Bad Request
|
|
BadRequest
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
401
|
Unauthorized
|
|
Unauthorized
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
403
|
Forbidden
|
|
Forbidden
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
404
|
Channel not found
|
|
NotFound
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
500
|
Internal Server Error
|
|
ServerError
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
Usage
curl -X DELETE
-H "x-api-key: your_API_key"
-H "Content-Type: application/json"
"https://api-demo.com/nexus/v3/channels/{channelId}/media/{mediaId}?"
POST
|
/channels/{channelId}/messages
Send a message
|
Send a message to an agent in Genesys from an external messaging system, such as SMS.
Parameters
Name |
Default |
Description |
Parameter Type |
Data Type |
Required
|
X-Hub-Signature
|
|
The request signature, for example sha1=hash. The hash is built using the body of the message and secret for the channel.
|
header
|
string
|
true
|
x-ccid
|
|
The ID of the contact center the message is sent within.
|
header
|
string
|
true
|
X-B3-TraceId
|
|
The unique trace ID for the request.
|
header
|
string
|
|
channelId
|
|
The ID of the channel.
|
path
|
string
|
true
|
messages
|
|
Message
|
body
|
|
true
|
|
Responses
Code |
Reason
|
200
|
Operation was successful
|
{
"status": {
"code": 0,
"message": "string"
},
"data": {
"ids": [
{
"id": "string"
}
]
}
}
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ids
|
id
|
(string):
|
data
|
ids
|
(array:object):
The ID of the accepted message, if provided.
|
InboundMessageResponse
|
status
|
(object):
|
data
|
(object):
|
|
|
400
|
Bad Request
|
|
BadRequest
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
401
|
Unauthorized
|
|
Unauthorized
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
403
|
Forbidden
|
|
Forbidden
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
404
|
Channel not found
|
|
NotFound
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
500
|
Internal Server Error
|
|
ServerError
|
status
|
(object):
|
status
|
code
|
(integer):
A code that can provide more information when an error occurs.
|
message
|
(string):
Provides additional information when a request returns an error response.
|
ResponseError
|
status
|
(object):
|
|
|
Usage
curl -X POST
-H "x-api-key: your_API_key"
-H "Content-Type: application/json"
-d '{}'
"https://api-demo.com/nexus/v3/channels/{channelId}/messages?"