Get Email Log
Retrieve all email messaging-related information in bulk.
Request | |
---|---|
Method | GET |
Resource | https://[customer].asp.virtual-call-center.eu/v2/projects/[projectid]/emails/[year]/[month] |
Options | start, num, direction |
Body | /N/A |
Response | |
Body | Array of email objects, encoded in JSON. |
Request
Resource parameters
Name | Type | Mandatory | Comment |
---|---|---|---|
projectid | integer | yes | Project unique identifier |
year | integer | yes | year |
month | integer | yes | Month within the requested year. Possible values: 01-12 |
day | integer | yes | Day within the requested month. Possible values: 01-31 |
Optional
Name | Type | Mandatory | Comment |
---|---|---|---|
start | integer | no | Specifies the offset of the first email. Possible values: [0-9]+ |
num | integer | no | Specifies the maximum number of CDRs to be returned. Possible values: [0-9]+ |
direction | string | no | Specifies the order of how the response is displayed. Possible values: “ASC”, “DESC” |
Response
Response object
Name | Type | Comment |
---|---|---|
rows | array of object | Array of email elements. |
total count | integer | Number of email logs returned. |
Email object
Name | Type | Comment |
---|---|---|
emailId | integer | Email unique identifier. |
queueId | integer | Queue unique identifier. |
subject | string | Subject of email |
to | string | Addressee email address. |
firstLine | string | First line of the email (excerpt). |
from | string | Sender. |
receivedTime | string | Exact time when the email arrived. |
receivedTime_utc | string | Exact time when the email arrived in UTC. |
lockTime | string | When the email got locked |
lockTime_utc | string | When the email got locked in UTC |
emailSize | integer | Email size |
isSpam | integer | Spam detected. 0=false |
isVirus | integer | Virus detected. 0 =false |
direction | string | inbound or outbound |
dispositionId | integer | Disposition assigned to email. |
templateId | integer | The unique identifier of email template used. |
status | string | Status of the email, e.g. “sent” |
diagnosticCode | string | Error code |
language | string | The language of the email, if the functionality to detect is enabled. |
responseTime | string | The time spent responding to the email after receiving it. |
slaStatus | string | The status of the Email SLA. |
attachedFiles | array of object | Attached files to the email, if any |
lockUser | string | The unique identifier of the agent user editing the email. |
title | string | Email subject. |
ticketNo | string | Ticket number. |
ticketId | integer | Ticket unique identifier. |
entityId | integer | Default value: 0 |
contactId | integer | Contact unique identifier. |
name | string | Contact name. |
templateName | string | Name of the email template. |
dispositionName | string | Disposition name. |
queueName | string | The name of the queue to which the email was routed. |
fromAddress | string | Sender email address. |
Attached files object
Name | Type | Comment |
---|---|---|
fileName | string | The name of the file attachment |
size | integer | The size of the file attachment, in Bytes |
link | string | The link to download the file attachment |
The file attachment can be downloaded using the link in the following format (where the actual link is provided in the response). The emailId (941) in the link must match the same attribute of the email:
Example
What it does and what information we get using this example.
Request
Response body
{
"response": {
"rows": [
{
"emailId": 1111,
"queueId": 1,
"subject": "Increase the number of agents",
"to": "[email protected]",
"firstLine": "This is the first line of the email.",
"from": "[email protected]",
"receivedTime": "2018-05-15 13:12:52",
"receivedTime_utc": "2018-05-15 13:12:52",
"lockTime": "2018-05-20 15:26:11",
"lockTime_utc": "2018-05-20 15:26:11",
"emailSize": 413,
"isSpam": 0,
"isVirus": 0,
"direction": "out",
"dispositionId": 0,
"templateId": 18,
"status": "sent",
"diagnosticCode": "OK",
"language": null,
"responseTime": null,
"slaStatus": "",
"attachedFiles": [
{
"fileName": "test.json",
"size": 3,
"link": "https://customer.asp.virtual-call-center.eu/v2/projects/130/emails/941/attachment/130_0_5f36b2ea290645ee34d943220a14b54ee5ea5be5/download"
},
{
"fileName": "red.json",
"size": 2332,
"link": "https://customer.asp.virtual-call-center.eu/v2/projects/130/emails/941/attachment/130_0_6fc8bf6e8d1af6b9e9daa4e238d5b4547cc8e854/download"
}
],
"lockUser": "-",
"title": "increase the number of agents",
"ticketNo": null,
"ticketId": null,
"entityId": 0,
"contactId": null,
"name": null,
"templateName": "test",
"dispositionName": "",
"queueName": "Customer support",
"fromAddress": "[email protected]",
}
],
"totalCount": 1
},
"errors": []
}
Comments
Can’t find what you need? Use the comment section below to connect with others, get answers from our experts, or share your ideas with us.
There are no comments yet.