Skip to content
GetSMS
Sign inCreate an account

Get started

Sandbox

With your sk_test_ key, the API validates your requests exactly as in production, then simulates the send. No SMS goes out and no credits are used. Your webhooks receive the same events as in production, signed the same way.

  • Sandbox messages are always sent from the virtual number +212600000099. The from field is ignored.
  • A normal message goes from pending to sending, sent (after 2 s), then delivered (after 4 s).
  • The test key only gives access to sending, bulk sending and retrieving messages, and only sees sandbox messages.
to number Simulated behavior Webhooks received
+212600000000 and any other number Sent after 2 s, delivered after 4 s message.phone.sent, message.phone.delivered
+212600000001 Fails after 3 s, failure_reason = SANDBOX_SIMULATED_FAILURE message.send.failed
+212600000002 Delivered, then the recipient replies “OUI” after 9 s message.phone.sent, message.phone.delivered, message.phone.received
+212600000003 Never sent, status expired after 60 s message.send.expired
Fenêtre de terminal
curl -X POST https://api.getsms.tech/v1/messages/send \
-H "x-api-key: sk_test_VOTRE_CLE" \
-H "Content-Type: application/json" \
-d '{"to": "+212600000002", "content": "Order #8841: 349 DH, delivery tomorrow. Reply OUI to confirm."}'

Nine seconds later, your server receives message.phone.received with "content": "OUI".