> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kairosafrika.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get SMS Delivery Receipt

> Retrieve the delivery receipt and status details of a previously sent SMS message

# Get SMS Delivery Receipt

This endpoint allows you to retrieve the delivery receipt and status details of a previously sent SMS message using the sequence number.

**Endpoint:** `GET /v1/external/sms/logs/{sequenceNo}`

<RequestExample>
  ```bash cURL theme={null}
  curl --request GET \
    --url https://api.kairosafrika.com/v1/external/sms/logs/01K4195MWQY2V4V0A7JZFC183S \
    --header 'x-api-key: YOUR_API_KEY' \
    --header 'x-api-secret: YOUR_API_SECRET' \
    --header 'x-api-version: 2025-08-01'
  ```
</RequestExample>

## Path Parameter

* **sequenceNo** (string, required): The sequence number of the SMS message (returned when sending SMS).

## Responses

* **200 OK**: Returns SMS delivery receipt and status details.
* **404 Not Found**: Message not found.

## Response Example

```json theme={null}
{
  "statusCode": "200",
  "statusMessage": "Delivery receipt details successfully retrieved",
  "transactionId": "01K4195MWQY2V4V0A7JZFC183S",
  "sequenceNo": "01K4195MWQY2V4V0A7JZFC183S",
  "data": {
    "_id": "68b4e204caf5c1616d5efe1a",
    "clientCorrelatorId": "db4f4068-cc2b-46f6-9f8c-8a09983c5cc7",
    "consumerId": "1",
    "createdAt": "2025-09-01T00:00:04.014Z",
    "deliveryStatus": "EXPIRED",
    "gatewayId": "99696059172",
    "gatewayMessageId": 99696059172,
    "ipAddress": "41.189.160.10",
    "message": "Hello ASTCCU, your customer access report is ready for download.",
    "messageId": "99696059172",
    "receiverAddress": ["233003003000"],
    "requestDeliveryReceipt": true,
    "senderAddress": "KAIROS",
    "sequenceNo": "01K4195MWQY2V4V0A7JZFC183S",
    "transactionId": "db4f4068-cc2b-46f6-9f8c-8a09983c5cc7"
  },
  "timestamp": "2025-10-03T14:41:00.014Z"
}
```

## Response Fields

* **statusCode** (string): HTTP status code.
* **statusMessage** (string): Status message description.
* **transactionId** (string): Unique transaction identifier.
* **sequenceNo** (string): Sequence number for the request.
* **data** (object): Delivery receipt details.
  * **\_id** (string): MongoDB document ID.
  * **deliveryStatus** (string): Delivery status (DELIVERED, UNDELIVERED, REJECTED, EXPIRED, ACCEPTED).
  * **message** (string): The SMS message content.
  * **receiverAddress** (array): Array of receiver phone numbers.
  * **senderAddress** (string): Sender address/ID.
  * **createdAt** (string): Timestamp when the SMS was created.
  * **gatewayMessageId** (integer): Gateway message ID.
* **timestamp** (string): ISO 8601 timestamp of the response.


## OpenAPI

````yaml GET /v1/external/sms/logs/{sequenceNo}
openapi: 3.0.3
info:
  title: Kairos Afrika SMS API
  description: >-
    Send SMS messages through the Kairos Afrika platform. Switch between staging
    and production environments using the server dropdown.
  version: 1.0.0
  contact:
    name: Kairos Afrika Support
    email: support@kairosafrika.com
servers:
  - url: https://api.kairosafrika.com
    description: Sms API Base URL
security:
  - apiKeyAuth: []
    apiSecretAuth: []
paths:
  /v1/external/sms/logs/{sequenceNo}:
    get:
      tags:
        - SMS
      summary: Get SMS Delivery Receipt
      description: >-
        Retrieve the delivery receipt and status details of a previously sent
        SMS message using the sequence number
      operationId: getSMSLogs
      parameters:
        - name: sequenceNo
          in: path
          required: true
          description: The sequence number of the SMS message
          schema:
            type: string
          example: 01K4195MWQY2V4V0A7JZFC183S
        - name: x-api-version
          in: header
          required: true
          schema:
            type: string
            enum:
              - '2025-08-01'
          description: API version header (required for full JSON response)
          example: '2025-08-01'
      responses:
        '200':
          description: SMS delivery receipt retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SMSLogsResponse'
        '404':
          description: SMS message not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    SMSLogsResponse:
      type: object
      properties:
        statusCode:
          type: string
          description: HTTP status code
          example: '200'
        statusMessage:
          type: string
          description: Status message
          example: Delivery receipt details successfully retrieved
        transactionId:
          type: string
          description: Unique transaction identifier
          example: 01K4195MWQY2V4V0A7JZFC183S
        sequenceNo:
          type: string
          description: Sequence number
          example: 01K4195MWQY2V4V0A7JZFC183S
        data:
          type: object
          properties:
            _id:
              type: string
              description: MongoDB document ID
              example: 68b4e204caf5c1616d5efe1a
            clientCorrelatorId:
              type: string
              description: Client correlator ID
              example: db4f4068-cc2b-46f6-9f8c-8a09983c5cc7
            consumerId:
              type: string
              description: Consumer ID
              example: '1'
            createdAt:
              type: string
              format: date-time
              description: Timestamp when the SMS was created
              example: '2025-09-01T00:00:04.014Z'
            deliveryStatus:
              type: string
              description: Delivery status of the SMS
              example: EXPIRED
              enum:
                - DELIVERED
                - UNDELIVERED
                - REJECTED
                - EXPIRED
                - ACCEPTED
            gatewayId:
              type: string
              description: Gateway ID
              example: '99696059172'
            gatewayMessageId:
              type: integer
              description: Gateway message ID
              example: 99696059172
            ipAddress:
              type: string
              description: IP address of the requester
              example: 41.189.160.10
            message:
              type: string
              description: The SMS message content
              example: Hello ASTCCU, your customer access report is ready for download.
            messageId:
              type: string
              description: Message ID
              example: '99696059172'
            receiverAddress:
              type: array
              items:
                type: string
              description: Array of receiver phone numbers
              example:
                - '233003003000'
            requestDeliveryReceipt:
              type: boolean
              description: Whether delivery receipt was requested
              example: true
            senderAddress:
              type: string
              description: Sender address/ID
              example: KAIROS
            sequenceNo:
              type: string
              description: Sequence number
              example: 01K4195MWQY2V4V0A7JZFC183S
            transactionId:
              type: string
              description: Transaction identifier
              example: db4f4068-cc2b-46f6-9f8c-8a09983c5cc7
        timestamp:
          type: string
          format: date-time
          description: ISO 8601 timestamp
          example: '2025-10-03T14:41:00.014Z'
    Error:
      type: object
      required:
        - error
        - message
      properties:
        error:
          type: string
          description: Error code
          example: INVALID_PHONE_NUMBER
        message:
          type: string
          description: Human-readable error message
          example: The provided phone number is not valid
        details:
          type: object
          description: Additional error details
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: API Key for authentication
    apiSecretAuth:
      type: apiKey
      in: header
      name: x-api-secret
      description: API Secret for authentication

````