Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.msgflash.com/llms.txt

Use this file to discover all available pages before exploring further.

Base URL

https://srv.msgflash.com
All public endpoints are prefixed with /api/v1/. Examples:
https://srv.msgflash.com/api/v1/messages/send
https://srv.msgflash.com/api/v1/templates
https://srv.msgflash.com/api/v1/contacts
https://srv.msgflash.com/api/v1/billing/usage

Authentication

All requests to /api/v1/* require a MsgFlash API key in the x-api-key header.
curl https://srv.msgflash.com/api/v1/usage \
  -H "x-api-key: msgf_live_your_api_key_here"
See Authentication for exact header format and security requirements.

Team workspace (msgf_team_…)

Team API keys require X-Team-Id matching the key’s team; workspace /api/v1/* routes then use the team’s shared data and the team owner’s plan. Personal keys must not send X-Team-Id (TEAM_KEY_REQUIRED). Account, compact usage, and most billing reads require a personal key (TEAM_KEY_NOT_ALLOWED with a team key). Full rules: Team context.

Rate limiting

LimitValue
Requests per second10 req/s
ScopePer API key
Error codeAPI_RATE_LIMIT_EXCEEDED
If the limit is exceeded:
{
  "error": {
    "code": "API_RATE_LIMIT_EXCEEDED",
    "message": "Too many API requests"
  }
}
The real-time rate limit is separate from the monthly monthlyApiRequestQuota. You can stay under your monthly quota and still receive 429 if you exceed 10 req/s.

Response format

Success

All successful responses are wrapped in data.
{
  "data": {
    "id": "uuid",
    "status": "queued"
  }
}
For simple lists:
{
  "data": [
    { "id": "..." },
    { "id": "..." }
  ]
}
For paginated lists:
{
  "data": {
    "messages": [],
    "nextCursor": null,
    "hasMore": false
  }
}

Error

{
  "error": {
    "code": "NOT_FOUND",
    "message": "Message not found"
  }
}
See Error codes for the main codes.

Available endpoints

Messages

MethodEndpointDescription
POST/api/v1/messages/sendSend an instant message
POST/api/v1/messages/scheduleSchedule a message
GET/api/v1/messagesList messages
GET/api/v1/messages/{id}Message details

Campaigns

MethodEndpointDescription
POST/api/v1/campaignsCreate a campaign
GET/api/v1/campaigns/{id}Campaign details
GET/api/v1/campaigns/{id}/statsDelivery statistics
POST/api/v1/campaigns/{id}/pausePause a campaign
POST/api/v1/campaigns/{id}/resumeResume a campaign

Templates

MethodEndpointDescription
GET/api/v1/templatesList templates
POST/api/v1/templatesCreate a template
GET/api/v1/templates/{id}Template details
PUT/api/v1/templates/{id}Update a template
DELETE/api/v1/templates/{id}Delete a template
POST/api/v1/templates/{id}/previewPreview a template render

Contacts

MethodEndpointDescription
GET/api/v1/contactsList contacts
POST/api/v1/contactsCreate a contact
GET/api/v1/contacts/{id}Contact details
PUT/api/v1/contacts/{id}Update a contact
DELETE/api/v1/contacts/{id}Delete a contact
POST/api/v1/contacts/bulk-deleteBulk delete contacts
GET/api/v1/contacts/bulk-jobsList bulk contact jobs
GET/api/v1/contacts/bulk-jobs/{jobId}Bulk job details
GET/api/v1/contacts/bulk-jobs/{jobId}/progressBulk job progress
POST/api/v1/contacts/bulk-jobs/{jobId}/cancelCancel a bulk job

Contact groups

MethodEndpointDescription
GET/api/v1/contacts/groupsList groups
POST/api/v1/contacts/groupsCreate a group
GET/api/v1/contacts/groups/{groupId}Group details
PUT/api/v1/contacts/groups/{groupId}Update a group
DELETE/api/v1/contacts/groups/{groupId}Delete a group
POST/api/v1/contacts/groups/{groupId}/membersAdd members
DELETE/api/v1/contacts/groups/{groupId}/membersRemove members
GET/api/v1/contacts/groups/{groupId}/membersList members
GET/api/v1/contacts/{id}/groupsList groups for a contact

Webhooks

MethodEndpointDescription
GET/api/v1/webhooksList your webhook endpoints
POST/api/v1/webhooksCreate a webhook endpoint
DELETE/api/v1/webhooks/{id}Delete a webhook endpoint

WhatsApp statuses

MethodEndpointDescription
POST/api/v1/statusesPublish a WhatsApp status

Instances

MethodEndpointDescription
GET/api/v1/instancesList instances
GET/api/v1/instances/{id}Instance details
GET/api/v1/instances/{id}/stateLive instance state

Billing public read-only

MethodEndpointDescription
GET/api/v1/usageCompact usage summary
GET/api/v1/billing/plansPlan catalog
GET/api/v1/billing/subscriptionCurrent subscription and billing period
GET/api/v1/billing/usageUsage, limits, and features
GET/api/v1/billing/paymentsPayment history