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

# Send an SMS batch



## OpenAPI

````yaml POST /sms/batch
openapi: 3.1.0
info:
  title: Robase API
  version: '2026-04-17'
  description: Transactional email and programmable SMS for Africa.
  contact:
    email: support@robase.dev
    url: https://robase.dev
  license:
    name: Proprietary
servers:
  - url: https://api.robase.dev/v1
    description: Production
security:
  - bearerAuth: []
paths:
  /sms/batch:
    post:
      tags:
        - SMS
      summary: Send an SMS batch
      operationId: batchSms
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchSMSRequest'
      responses:
        '200':
          description: Partial success — check per-row `error`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchSMSResponse'
components:
  schemas:
    BatchSMSRequest:
      type: object
      required:
        - from
        - messages
      properties:
        from:
          type: string
        template:
          type: string
        country:
          type: string
        send_at:
          type: string
          format: date-time
        messages:
          type: array
          maxItems: 1000
          items:
            type: object
            required:
              - to
            properties:
              to:
                type: string
              body:
                type: string
              template:
                type: string
              variables:
                type: object
                additionalProperties: true
              idempotency_key:
                type: string
    BatchSMSResponse:
      type: object
      properties:
        accepted:
          type: integer
        failed:
          type: integer
        success:
          type: boolean
        data:
          type: array
          items:
            type: object
            properties:
              index:
                type: integer
              replayed:
                type: boolean
              sms:
                $ref: '#/components/schemas/SMSMessage'
              error:
                $ref: '#/components/schemas/Error'
    SMSMessage:
      type: object
      properties:
        id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - queued
            - scheduled
            - sent
            - delivered
            - failed
            - rejected
            - cancelled
        to:
          type: string
          example: '+2348012345678'
        from:
          type: string
          example: SHUTTLERS
        body:
          type: string
        segments:
          type: integer
        encoding:
          type: string
          enum:
            - GSM7
            - UCS2
        country:
          type: string
          example: NG
        carrier:
          type: string
          example: mtn_ng
        provider:
          type: string
          example: beem
        provider_message_id:
          type: string
        provider_attempts:
          type: array
          items:
            type: object
            properties:
              provider:
                type: string
              attempted_at:
                type: string
                format: date-time
              ok:
                type: boolean
              provider_message_id:
                type: string
              error_code:
                type: string
              error_message:
                type: string
        cost:
          $ref: '#/components/schemas/Cost'
        test_mode:
          type: boolean
        created_at:
          type: string
          format: date-time
        sent_at:
          type: string
          format: date-time
        delivered_at:
          type: string
          format: date-time
    Error:
      type: object
      properties:
        error:
          type: object
          required:
            - type
            - message
          properties:
            type:
              type: string
              enum:
                - validation_error
                - authentication_error
                - permission_error
                - not_found
                - conflict
                - rate_limit_exceeded
                - quota_exceeded
                - sms_quota_exceeded
                - idempotency_conflict
                - internal_error
                - upstream_error
                - domain_unverified
                - address_suppressed
                - phone_invalid
                - sender_id_invalid
                - dnd_blocked
                - plan_forbidden
            message:
              type: string
            field:
              type: string
    Cost:
      type: object
      properties:
        amount_kobo:
          type: integer
          format: int64
          description: Smallest currency unit (kobo for NGN, pesewas for GHS).
        currency:
          type: string
          example: NGN
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: rb_<env>_<token>
      description: 'Pass your API key as `Authorization: Bearer rb_live_...`'

````