A2PGetSmsHistory

View as Markdown

Gets the history of sent/or received A2P SMS.

Allowed roles: Owner, Admin, CallsSMS.

Example request: Get messages that had been sent to number 12345678222 starting from March 1, 2019. Number of resulting rows is limited to 2.

Authentication

AuthorizationBearer
Voximplant Management API uses signed JWT tokens generated from your service-account private key. Pass the token in the `Authorization` header as a Bearer value: ``` Authorization: Bearer $VOXIMPLANT_TOKEN ``` See [Authorization](/api-reference/management-api/authorization) for ready-to-copy snippets in bash, Python, Node.js and Go that turn your `credentials.json` into a token.

Query parameters

source_numberstringOptional
The source phone number
destination_numberstringOptional
The destination phone number
countintegerOptional
Maximum number of resulting rows fetched. Must be not bigger than 1000. If left blank, then the default value of 1000 is used
offsetintegerOptional

The first N records are skipped in the output

from_datestringOptional

Date from which the search is to start. Format is ‘yyyy-MM-dd HH:mm:ss’, time zone is UTC

to_datestringOptional

Date from which the search is to end. Format is ‘yyyy-MM-dd HH:mm:ss’, time zone is UTC

outputstringOptionalDefaults to json

The output format. The following values available: json, csv, xls. The default value is json

delivery_statusintegerOptional

The delivery status ID: QUEUED - 1, DISPATCHED - 2, ABORTED - 3, REJECTED - 4, DELIVERED - 5, FAILED - 6, EXPIRED - 7, UNKNOWN - 8

Response

Successful response
resultlist of objects
total_countinteger
Total number of messages matching the query parameters