diff --git a/applications/crossbar/doc/sms.md b/applications/crossbar/doc/sms.md index ca580b862df..9e1aa24b44f 100644 --- a/applications/crossbar/doc/sms.md +++ b/applications/crossbar/doc/sms.md @@ -2,6 +2,8 @@ #### About Sms +SMS api endpoint allows sending a text message. + #### Schema sms document @@ -16,12 +18,38 @@ Key | Description | Type | Default | Required | Support Level -#### Fetch +## Sending a text message -> GET /v2/accounts/{ACCOUNT_ID}/sms +> PUT /v2/accounts/{ACCOUNT_ID}/sms ```shell -curl -v -X GET \ +curl -v -X PUT \ -H "X-Auth-Token: {AUTH_TOKEN}" \ + -d '{"data": {"from": "+15551112222", "to": "+15552221111", "body": "wave if you received this"}}' \ http://{SERVER}:8000/v2/accounts/{ACCOUNT_ID}/sms ``` + +```json +{ + "request_id": "{REQUEST_ID}", + "tokens": { + "consumed": 1, + "remaining": 100 + }, + "auth_token": "{AUTH_TOKEN}", + "data": { + "message_id": "{REQUEST_ID}", + "from": "+15551112222", + "to": "+15552221111", + "body": "waive if you received this", + "custom_vars": { + "account_id": "{ACCOUNT_ID}", + "reseller_id": "{RESELLER_ID}", + "authorizing_type": "account", + "authorizing_id": "{ACCOUNT_ID}" + }, + "route_type": "offnet" + }, + "status": "success" +} +```