Quickstart
Five steps from a new account to a delivered message. No SIM of your own yet? Skip to step 2 — sends without a connected SIM route through Connecfy's shared pool automatically.
-
Connect a SIM
In the dashboard, go to Devices → Add device and follow the on-screen steps — takes a couple of minutes, and the SIM is live immediately afterward. Skip this step if you're sending through the platform pool for now.
-
Create an API key
Dashboard → API Keys → New key. Name it after what's going to use it. The full key is shown exactly once — copy it now. See API Keys for why it can't be shown again later.
Save it as an environment variable, not in your sourceexport CONNECFY_API_KEY="paste-the-key-here" -
Authenticate
Every API request carries the key as a bearer token:
Header on every requestAuthorization: Bearer $CONNECFY_API_KEY -
Send an SMS
bashcurl -X POST https://www.connecfy.com/api/v1/sms/send/ \ -H "Authorization: Bearer $CONNECFY_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "to": "+212612345678", "from": "+212600000000", "message": "Hello from Connecfy" }'frommust be a number attached to a SIM your account can use. If you skipped step 1, use the platform pool number shown on your dashboard's Send page instead. -
Read the response
A
202 Acceptedmeans it's queued, not delivered yet:JSON{ "status": "queued", "message_id": "f3a1b2c4-d5e6-7890-abcd-ef1234567890", "request_id": "", "device_id": "a8b9c0d1-...", "from_number": "+212600000000", "to": "+212612345678", "created_at": "2026-08-26T14:30:00.123Z" }Keep
message_id— it's how you'll check delivery. -
Track its status
Poll for the result (a paired SIM picks up work within ~20 seconds, so don't check faster than that):
bashcurl https://www.connecfy.com/api/v1/sms/f3a1b2c4-d5e6-7890-abcd-ef1234567890/ \ -H "Authorization: Bearer $CONNECFY_API_KEY"statuswill move through queued → sending → sent → delivered, or land on failed. Full meaning of each in Message Lifecycle.