Skip to Content
Notification APIDocs
Messages

Get a message

GET
/api/v1/companies/{companyId}/projects/{projectId}/messages/{messageId}

Gets a message with dispatch status counts.

Required permission: messages.read. See the guide for details.

Error codes:

  • 404 message.not_found

Every endpoint can also answer 401 (missing or invalid key), 403 (route outside the key's project or permission) and 429 rate_limit.exceeded.

Authorization

ApiKey
headerX-Api-Key<token>

Project API key: nb_<prefix>_<secret>.

Path Parameters

companyId*string

Id of the company that owns the project (shown with the API key in the dashboard).

Formatuuid
projectId*string

Id of the project the API key belongs to.

Formatuuid
messageId*string
Formatuuid

Response Body

OK

application/json
  1. response
message*
content*string

Message-level content (template body or the request content).

subject*null|string
variables*
idempotencyKey*null|string
apiKeyId*|

The API key that sent the message, if any.

Formatuuid
dispatches*

Number of dispatches per status; statuses with no dispatch are left out.

attachments*array<>
data*|

Provider-specific JSON object, or null.

Example Request
curl -X GET 'https://api.gbnotification.dokploy.geobilgi.net/api/v1/companies/497f6eca-6276-4993-bfeb-53cbbbba6f08/projects/497f6eca-6276-4993-bfeb-53cbbbba6f08/messages/497f6eca-6276-4993-bfeb-53cbbbba6f08'
Example Response
{  "message": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "channel": "string",    "priority": "Critical",    "status": "Pending",    "messageTemplateId": null,    "recipientCount": 0,    "scheduledAt": null,    "isOtp": true,    "createdAt": "2019-08-24T14:15:22Z",    "templateName": null,    "subject": null,    "firstRecipient": null  },  "content": "string",  "subject": null,  "variables": {    "property1": "string",    "property2": "string"  },  "idempotencyKey": null,  "apiKeyId": null,  "dispatches": {    "property1": 0,    "property2": 0  },  "attachments": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "fileName": "string",      "contentType": "string",      "sizeBytes": 0,      "source": "Template"    }  ],  "data": null}