Skip to Content
Notification APIDocs

Scheduling and cancellation

Send messages later and cancel them before delivery starts.

Scheduling

Set scheduledAt to deliver a message later:

{
  "channel": "sms",
  "recipients": [{ "type": "Phone", "value": "+905321234567" }],
  "content": "Your appointment is tomorrow at 10:00.",
  "scheduledAt": "2026-12-01T09:00:00+03:00"
}
  • Use ISO 8601 with an offset (Z or +03:00). The value is stored in UTC.
  • It must be in the future and at most 90 days ahead (otherwise 400 validation.failed).
  • The message is accepted right away (202) with status Pending; its dispatches are picked up when the time comes.

Cancelling

Cancel a message to stop dispatches that have not been picked up yet. This works for scheduled messages and for messages still waiting in line.

curl -X POST 'https://api.gbnotification.dokploy.geobilgi.net/api/v1/companies/COMPANY_ID/projects/PROJECT_ID/messages/MESSAGE_ID/cancel' \  -H 'X-Api-Key: YOUR_API_KEY'
200 OK
{ "messageId": "0197a6b2-5c1e-7d33-9a8e-3f4b2c1d0e9f", "status": "Cancelled", "cancelledDispatches": 3 }

Rules:

  • Only a message whose status is Pending can be cancelled. Any other status answers 422 message.not_cancellable (for example once delivery has started, or after it was already cancelled).
  • Only Pending dispatches are cancelled. Dispatches already handed to the delivery queue (Inqueue and later) are delivered normally.
  • When every dispatch ends up cancelled the message becomes Cancelled. If some dispatches were already queued, the response shows how many were cancelled (cancelledDispatches) and the message keeps its status until the remaining dispatches finish.
  • Calling cancel again while the message is still Pending is safe: it answers 200 with cancelledDispatches: 0 when there is nothing left to cancel.

The key needs the messages.send permission to cancel.

On this page