Developer hub

SMS, WhatsApp and iMessage API documentation

VoidFix Gateway has three REST APIs, one for each channel: the SMS and MMS API, the WhatsApp API and the iMessage API. Each one sends from the numbers connected to your own account. Pick your channel, get its API key, and send your first message with one curl request.

10 min read3 REST APIs: SMS, WhatsApp, iMessage

Choose your API

Each channel runs in its own portal with its own API key, base URL and full reference. You only need the API for the channels on your plan.

APIBase URLAuthenticationFull reference
SMS and MMShttps://sms.voidfix.comkey parameterSMS API reference
WhatsApphttps://wa.voidfix.comX-API-Key headerWhatsApp API reference
iMessagehttps://imessage.voidfix.com/apiBearer token from your key and secretiMessage API reference

API keys give full sending access to your account. Keep them on your server and out of front-end code, mobile apps and public repositories.

SMS and MMS API

The SMS API sends texts and MMS through the Android phones connected to your account. You need at least one phone connected. If you haven’t done that yet, follow the Android device connection guide first.

  1. Copy your SMS API key

    Sign in at sms.voidfix.com, open API & Settings in the left menu and click Copy key in the API key section. Direct link: sms.voidfix.com/configuration.php#api. Send the key as the key parameter on every request: in the query string for GET, or as a form field for POST.

  2. Check your key and list your phones

    curl
    curl "https://sms.voidfix.com/services/get-devices.php?key=YOUR_API_KEY"
  3. Send an SMS

    POST form fields (not JSON) to /services/send.php. Include the country code in the number. Leave out devices to send from your default phone.

    curl
    curl -X POST "https://sms.voidfix.com/services/send.php" \
      --data-urlencode "key=YOUR_API_KEY" \
      --data-urlencode "number=+15551234567" \
      --data-urlencode "message=Hi Sam, your appointment is tomorrow at 10am." \
      --data-urlencode "devices=YOUR_DEVICE_ID"
  4. Follow the message status

    Use the ID from the response. Messages start as Pending (or Scheduled) while your phone sends them.

    curl
    curl "https://sms.voidfix.com/services/read-messages.php?key=YOUR_API_KEY&id=MESSAGE_ID"

Send parameters

For POST /services/send.php, provide one of number + message, messages, or listID + message.

ParameterDescription
numberRecipient with country code. Separate several numbers with commas
messageMessage text. With listID, %name% becomes each contact’s name. Spintax such as {Hi|Hello} works too
messagesJSON array of {"number", "message"} objects, to send a different text to each number
listIDSend message to every subscribed contact in a contact list
devicesDevice ID, or a JSON array of "deviceID|simSlot" entries such as ["12|0","15|1"]
simSlot0 = SIM 1, 1 = SIM 2
option0 = use devices, 1 = spread across every connected device, 2 = every SIM of every device
type + attachmentstype=mms with comma-separated public file URLs in attachments to send an MMS
scheduleUnix timestamp (seconds) to send later
prioritize1 to send ahead of the queue, even during quiet hours

To send an MMS, add type=mms and the file URL:

curl
curl -X POST "https://sms.voidfix.com/services/send.php" \
  --data-urlencode "key=YOUR_API_KEY" \
  --data-urlencode "number=+15551234567" \
  --data-urlencode "message=Here is your ticket" \
  --data-urlencode "type=mms" \
  --data-urlencode "attachments=https://example.com/ticket.png"

Every response is JSON in the same shape and comes back with HTTP 200 even when the request fails, so always check success and error.

SMS API endpoints

EndpointMethodWhat it does
/services/send.phpPOSTSend single, bulk, contact-list, scheduled or MMS messages
/services/read-messages.phpGETGet messages by ID, group ID or status
/services/v2/list-messages.phpGETList sent and incoming messages, page by page
/services/resend.phpPOSTResend messages by ID or group ID
/services/v2/cancel-messages.phpPOSTCancel pending or scheduled messages
/services/v2/get-message-stats.phpGETMessage statistics
/services/v2/get-conversations.phpGETList conversations
/services/v2/mark-read.phpPOSTMark a conversation as read
/services/get-devices.phpGETList your connected phones
/services/v2/get-contacts-lists.phpGETList contact lists
/services/v2/add-contacts-list.phpPOSTCreate a contact list
/services/v2/get-contacts.phpGETList contacts
/services/manage-contacts.phpPOSTAdd a contact or unsubscribe one
/services/v2/get-blacklist.phpGETList opt-outs
/services/v2/add-to-blacklist.phpPOSTAdd numbers to opt-outs
/services/v2/remove-from-blacklist.phpPOSTRemove numbers from opt-outs
/services/v2/get-templates.phpGETList message templates
/services/v2/get-webhook.phpGETGet your webhook URL
/services/v2/set-webhook.phpPOSTSet or remove your webhook URL
/services/send-ussd-request.phpPOSTRun a USSD code on a phone
/services/read-ussd-requests.phpGETGet USSD results
/services/v2/get-account.phpGETAccount details

Request and response fields for every endpoint, with a try-it console, are in the full SMS API reference.

WhatsApp API

The WhatsApp API sends and receives WhatsApp messages through the numbers linked to your VoidFix WhatsApp account. It’s a plain REST API with JSON in and out, and it doesn’t use the WhatsApp Business API, so there are no Meta templates or per-conversation fees. Link a number first with the WhatsApp connection guide, or connect one through the API by QR code.

  1. Get your WhatsApp API key

    Sign in at wa.voidfix.com and open Settings → API. Keys start with vf_. Send yours in the X-API-Key header (recommended) or as the api_key query parameter.

  2. Find your session ID

    Each linked WhatsApp number is a session. List them to get the sessionId you’ll send from.

    curl
    curl "https://wa.voidfix.com/api/external/sessions" \
      -H "X-API-Key: vf_your_api_key"
  3. Send a WhatsApp message

    Write the recipient number with the country code but without + or spaces. Add mediaUrl, mediaType and caption to send an image, video or document.

    curl
    curl -X POST "https://wa.voidfix.com/api/external/send-message" \
      -H "X-API-Key: vf_your_api_key" \
      -H "Content-Type: application/json" \
      -d '{"sessionId": "YOUR_SESSION_ID", "to": "14155551234", "message": "Hello from VoidFix!"}'
  4. Receive replies by webhook

    Register a webhook with POST /api/external/webhooks and subscribe to message.incoming for replies and message.ack for delivery and read receipts.

WhatsApp API endpoints

All paths start with https://wa.voidfix.com/api/external.

EndpointMethodWhat it does
/send-messagePOSTSend text, image, video or document
/send-locationPOSTSend a location pin
/message-status/{messageId}GETGet a message’s delivery status
/messagesGETList message history
/mark-readPOSTMark a chat as read
/check-numberGETCheck if a number is on WhatsApp
/sessionsGETList linked numbers (sessions)
/qr-codePOSTCreate a session and get a QR code to link a number
/session-status/{sessionId}GETCheck whether a number is connected
/sessions/{sessionId}/pairing-codePOSTGet a pairing code to link without scanning
/sessions/{sessionId}/qrGETGet a fresh QR code
/sessions/{sessionId}/restartPOSTRestart a session
/sessions/{sessionId}/logoutPOSTDisconnect a number
/sessions/{sessionId}/profileGETGet the linked WhatsApp profile
/sessions/{sessionId}/chatsGETList chats
/webhooksGET, POSTList or create webhooks
/webhooks/{webhookId}PUT, DELETEUpdate or delete a webhook
/webhooks/{webhookId}/testPOSTSend a test event
/webhooks/{webhookId}/logsGETWebhook delivery logs
/webhooks/eventsGETList webhook event types
/accountGETAccount and plan usage

Payloads for every endpoint and webhook event are in the full WhatsApp API reference.

iMessage API

The iMessage API sends blue-bubble iMessages from your VoidFix iMessage lines. If a recipient doesn’t have iMessage, the message falls back to SMS automatically. You need an active iMessage line, and each line can message up to 50 unique contacts per day. See iMessage pricing for plans.

  1. Create an API key and secret

    Sign in at imessage.voidfix.com and create a key under Settings → API Keys. You get an API key (starts with vf_pk_) and an API secret (starts with vf_sk_). Store the secret safely.

  2. Exchange them for an access token

    Tokens last 24 hours. Send the token as Authorization: Bearer <token> on every other request.

    curl
    curl -X POST "https://imessage.voidfix.com/api/v1/auth/token" \
      -H "Content-Type: application/json" \
      -d '{"apiKey": "vf_pk_...", "apiSecret": "vf_sk_..."}'
  3. Send an iMessage

    recipient is a number in E.164 format or an Apple ID email. Add iMessageLineId to choose the line, or leave it out to use your most recently active line. Pass attachmentUrl to send an image or video.

    curl
    curl -X POST "https://imessage.voidfix.com/api/v1/messages/send" \
      -H "Authorization: Bearer YOUR_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{"recipient": "+14155551234", "message": "Hello! Thanks for your inquiry."}'
  4. Check delivery and get replies

    Poll GET /v1/messages/{messageId}/status, or create a webhook with POST /v1/webhooks for message.inbound, message.outbound, message.read and message.failed events.

iMessage API endpoints

All paths start with https://imessage.voidfix.com/api. The default rate limit is 1,000 requests per 15 minutes per API key.

EndpointMethodWhat it does
/v1/auth/tokenPOSTGet an access token from your key and secret
/v1/messages/sendPOSTSend an iMessage, with SMS fallback
/v1/messages/{messageId}/statusGETGet a message’s delivery status
/v1/messages/validate-imessagePOSTCheck whether a number has iMessage
/v1/messages/conversationsGETList conversations
/v1/messages/history/{lineId}/{recipient}GETChat history with a contact
/v1/messages/mark-read/{lineId}/{recipient}PUTMark a conversation as read
/v1/linesGET, POSTList or create iMessage lines
/v1/lines/{id}GET, PUT, DELETEGet, update or delete a line
/v1/lines/stats/summaryGETLine statistics
/v1/analytics/overviewGETOverview statistics
/v1/analytics/message-activityGETDaily activity
/v1/analytics/line-performanceGETPerformance per line
/v1/analytics/inbound-outboundGETDaily inbound vs outbound trend
/v1/ghl/sub-accountsGETGoHighLevel sub-accounts connected to iMessage
/v1/ghl/assignmentsGET, POSTList or create GHL sub-account to line assignments
/v1/ghl/assignments/{id}DELETERemove a GHL assignment
/v1/ghl/statsGETGHL integration statistics
/v1/webhooksGET, POSTList or create webhooks
/v1/webhooks/{id}PUT, DELETEUpdate or delete a webhook
/v1/webhooks/{id}/testPOSTSend a test event
/v1/api-keysGET, POSTList or create API keys (dashboard login token)
/v1/api-keys/{id}DELETERevoke an API key

API keys can be limited by scope: messages:send, messages:read, lines:read, lines:write, analytics:read, ghl:read and ghl:write. Full request bodies and a try-it console are in the full iMessage API reference.

Webhooks: replies and delivery status

All three APIs can push events to your server, so you don’t have to poll for replies.

APIHow to set it upEvents
SMSPOST /services/v2/set-webhook.php or API & Settings → WebhooksIncoming and outgoing message updates, USSD results
WhatsAppPOST /api/external/webhooksmessage.incoming, message.outbound, message.ack, session.status, call events
iMessagePOST /v1/webhooksmessage.inbound, message.outbound, message.read, message.failed

A phone or linked device has to be online to send. If it goes offline, SMS messages wait as pending and can be resent by ID or group ID once it’s back.

No-code and low-code guides

Prefer not to write code? These guides connect VoidFix to the tools you already use.

Developer FAQ

Do I need a separate API key for each channel?

Yes. SMS, WhatsApp and iMessage each have their own portal and their own keys: the SMS key from API & Settings at sms.voidfix.com, the WhatsApp key from Settings → API at wa.voidfix.com, and the iMessage key and secret from Settings → API Keys at imessage.voidfix.com.

Do I need A2P 10DLC registration to use the SMS API?

No. The SMS API sends from the SIMs in your own Android phones as person-to-person messages, so there’s no A2P 10DLC registration step. Carrier rules, consent and opt-outs still apply. Read more in SMS without A2P registration.

Is the WhatsApp API the official WhatsApp Business API?

No. It sends through the WhatsApp numbers you link to VoidFix, like WhatsApp Web, so you don’t need Meta approval or message templates. Send only to people who expect to hear from you, because WhatsApp can restrict numbers that get reported.

What happens if an iMessage recipient doesn’t have an iPhone?

The iMessage API checks whether the recipient has iMessage. If not, it sends the message as SMS instead, and stores both in the same conversation history.

Get help with your integration

Email support@voidfix.com (24/7) or open a ticket. Need an integration we don’t have? Our development team can build custom integrations, so book a call to talk it through.

Get an API key and start sending

Create your account, connect an Android phone and copy your API key from the portal. Stuck at any step? Our team will help on a call.