Discard a message draft
Deletes exactly the saved draft revision identified by id and draftRevision. A newer edit is never discarded; sent messages are unaffected. An id that holds no draft visible to the key (already discarded or sent, or not a draft) is a safe no-op that returns threadId: null. A draftRevision that no longer matches the saved draft answers 409 with customCode draftChanged, and a draft that is being sent answers 409 with customCode draftSendInProgress; both delete nothing.
Authorization
apiKeyAuth API key authentication. Create an API key in your user profile and include it in the x-api-key header.
In: header
Path Parameters
The draft message id to discard
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$uuidQuery Parameters
Opaque revision returned with the saved draft; required whenever draftMessageId is provided
^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d\.\d{3}(?:Z|([+-](?:[01]\d|2[0-3]):[0-5]\d)))$date-timeResponse Body
application/json
application/json
application/json
application/json
application/json
curl -X DELETE "https://customermates.com/api/v1/messaging/drafts/497f6eca-6276-4993-bfeb-53cbbbba6f08?draftRevision=2019-08-24T14%3A15%3A22Z"{
"threadId": "string"
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}