# SMS Usage

## Get SMS/MMS Usage <a href="#get-sms-mms-usage" id="get-sms-mms-usage"></a>

```
curl "https://sms.accentvoice.com/api/v2/<DID Number>/usage/"
  -X POST
{
    "key": "<API Key>",
    "start": "2019-06-22",
    "stop": "2019-07-22"
}
```

> This request gets total SMS/MMS usage for a particular DID between two provided datestamps.

```
{
    "success": true,
    "error": false,
    "status_code": "DID-USAGE",
    "message": "SMS/MMS usage for <DID Number>.",
    "data": [
        {
            "did": "<DID Number>",
            "sms_inbound": "22",
            "sms_outbound": "3",
            "mms_inbound": "0",
            "mms_outbound": "0"
        }
    ]
}
```

This request gets total SMS/MMS usage for a particular DID between two provided datestamps.

#### HTTP Request <a href="#http-request-7" id="http-request-7"></a>

`POST https://sms.accentvoice.com/api/v2/<DID Number>/usage/`

#### Request Body Parameters <a href="#request-body-parameters-3" id="request-body-parameters-3"></a>

| Parameter | Description     | Required |
| --------- | --------------- | -------- |
| start     | Start datestamp | Yes      |
| stop      | Stop datestamp  | Yes      |

Remember: Both the `start` and `stop` parameters must be in the `Y-m-d` format. For example, December 4th, 2020 is represented as `2020-12-04`.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://guides.accentvoice.com/sms-api/sms-usage.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
