Fetch SMS delivery reports with scroll-based pagination.
Overview
The DLR Fetch API allows users to fetch detailed SMS delivery reports (DLR) in a paginated manner using a scroll-based mechanism. This API supports multiple filters such as feed ID, date range, mobile number, delivery status, and request ID.
HTTP Method
This API uses the below HTTP method to fetch detailed SMS delivery reports.
- GET
API Endpoint
https://smstemplateapigdc.mytoday.com/v1/template/dlr-consolidated-report
Request Headers
You need to pass the API username and password in the header.
Example Header
-H "username: 98705xxx33"
-H "password: Aksxxxsx"
Request Parameters
Query Parameters
The following query parameters are used to filter the DLR report and retrieve paginated results.
| Parameter | Description | Type | Example | Mandatory(Y/N) |
|---|---|---|---|---|
| feed_id | Identifies which report feeds to include in the response. | Comma-separated integers | 345623,345621 | Yes (Required if scroll_id is not provided) |
| from_date | Date from which the report data should start. | string (YYYY-MM-DD) | 2025-06-04 | Yes (Required if scroll_id is not provided) |
| to_date | End date of the report data range | string (YYYY-MM-DD) | 2025-06-05 | Yes (Required if scroll_id is not provided) |
| ent_id | Enterprise ID to restrict results to a specific enterprise account. | integer | 26408889 | Optional |
| delivery_status | Filters results by message delivery status | string | delivered, failed | Optional |
| sender_id | Filters records generated by a specific sender ID. | integer | 640828 | Optional |
| mobile_number | Returns records associated with a specific recipient mobile number. | integer | 9800xx2343 | Optional |
| request_id | Fetches details for a specific API request ID. | integer | 3848xx61361 | Optional |
| scroll_id | Token used to retrieve the next set of results when paginating large responses. | string | <token> | Mandatory for subsequent requests |
Good to know
Scroll ID is a unique token returned by the API in the first response, used to fetch the next consecutive set of records. It helps retrieve large datasets page by page without returning duplicate records.
Pagination Logic (Scroll API)
| Request Type | Parameters to Pass | Description |
|---|---|---|
| First Request | feed_id, from_date, to_date (and other optional filters) | Fetches the initial set of DLR records and returns a scroll_id along with the data. |
| Next Requests | scroll_id only | Retrieves the next consecutive batch of records using the scroll token. No other parameters should be passed. |
| End of Data | scroll_id | When no more records are available, the API returns an empty data array, indicating completion. |
Example Request
curl -s "https://smstemplateapigdc.mytoday.com/v1/template/dlr-consolidated-report?from_date=2026-01-12&to_date=2026-01-12&feed_id=392095" \
-H "username: 98xxx24533" \
-H "password: Axs@xxsx"
curl -s "https://smstemplateapigdc.mytoday.com/v1/template/dlr-consolidated-report?scroll_id=FGluY2x1ZGVfY29udGV4dF91dWlkDnF1ZXJ5VGhlbkZldGNoDBZ..." \
-H "username: 9870XX4X33" \
-H "password: Aks@2xxx"
Success Response
{
"status": "success",
"code": 200,
"message": "Data fetched successfully",
"scroll_id": "FGluY2x1ZGVfY29udGV4dF91dWlkDnF1ZXJ5VGhlbkZldGNoDBZ...",
"data": [
{
"mobile_no": "91xx57xx6508",
"request_id": 68xxx66x120,
"sender_id": "NETCRE",
"dlt_template_id": 1107xxx66704xx08673,
"feed_name": "QA_TESTING_OTP",
"message": "Hi, How are you?",
"operator": "Reliance GSM",
"circle": "Maharashtra-Goa",
"requested_on": "2026-01-12 09:34:32",
"last_activity": "2026-01-12 09:34:33",
"status": "27",
"sms_count": 1,
"tag": "",
"transaction_id": 363147xxx39,
"message_type": "Text"
}
]
}
