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

# Get a plan

> One plan, with the full list of countries it covers.

## Error codes

| Status | `code` | Cause |
| - | - | - |
| `404` | `esim_package_unavailable` | The plan has been withdrawn from the catalog. |
| `401` | `INVALID_API_KEY` | The key is missing, invalid, inactive, expired, from the other environment, or blocked by its IP allowlist. |
| `429` | `api_key_rate_limit_exceeded` | The per-minute limit for this key was exceeded. |
| `503` | `esim_feature_disabled` | eSIM is not enabled on this deployment. |
| `503` | `esim_catalog_unavailable` | The catalog is empty and could not be refreshed from the provider. |
| `503` | `esim_provider_unavailable` | The eSIM provider could not be reached. Nothing was charged. |


## OpenAPI

````yaml /openapi.json get /v1/esims/catalog/packages/{slug}
openapi: 3.1.0
info:
  title: Sakawave Business API
  version: 1.0.0-draft
  summary: >-
    Accounts, transfers, FX quotes, and transaction reconciliation for Sakawave
    businesses.
  description: >-
    Generated from the public NestJS controllers and their Zod request schemas.
    Public URLs and policy statements remain draft until the Phase 1 contract
    checklist is approved.
  contact:
    name: Sakawave API Support
    email: api-support@sakawave.example
servers:
  - url: https://sandbox-api.sakawave.example
    description: Sandbox (default)
  - url: https://api.sakawave.example
    description: Live
security:
  - bearerAuth: []
tags:
  - name: Bill payments
    description: Browse the biller catalog, validate a customer, and pay a bill.
  - name: Cards
    description: Issue, fund, and control USD virtual and disposable cards.
  - name: eSIM
    description: >-
      Sell mobile data abroad: browse the catalog, buy an eSIM, and manage it
      once installed.
  - name: Currencies and countries
    description: >-
      Reference data: what may be held, what may be sent where, and which
      jurisdictions are served.
  - name: Customers
    description: Create and manage customers of your business.
  - name: Accounts
    description: >-
      Open business and customer accounts, and issue the destinations that fund
      them.
  - name: Transfer destinations
    description: Resolve temporary destinations and saved recipients.
  - name: FX quotes
    description: Create and retrieve time-limited cross-currency quotes.
  - name: Transfers
    description: Preview, create, and monitor transfers.
  - name: Transactions
    description: Read ledger entries for reconciliation.
paths:
  /v1/esims/catalog/packages/{slug}:
    get:
      tags:
        - eSIM
      summary: Get a plan
      description: One plan, with the full list of countries it covers.
      operationId: getEsimPackage
      parameters:
        - name: slug
          in: path
          required: true
          description: Plan slug.
          schema:
            type: string
          example: united-states-5gb-30d-pkgus5gb
      responses:
        '200':
          description: Successful response.
          headers:
            X-Request-ID:
              description: >-
                The request identifier assigned by Sakawave. Include it in
                support requests.
              schema:
                type: string
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EsimPackageResponse'
              example:
                slug: united-states-5gb-30d-pkgus5gb
                name: United States 5GB
                description: null
                region:
                  code: US
                  name: United States
                  kind: country
                  flagEmoji: 🇺🇸
                dataType: fixed
                data:
                  totalBytes: '5368709120'
                  dailyCapBytes: null
                  display: 5 GB
                validityDays: 30
                price:
                  amount: '999'
                  currency: USD
                  display: '9.99'
                supportsTopUp: true
                supportsPlatformSms: false
                coverage:
                  - US
        '400':
          $ref: '#/components/responses/ValidationError'
        '401':
          $ref: '#/components/responses/AuthenticationError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitError'
        '500':
          $ref: '#/components/responses/ServerError'
        '503':
          $ref: '#/components/responses/ProviderUnavailableError'
      security:
        - bearerAuth: []
components:
  schemas:
    EsimPackageResponse:
      type: object
      additionalProperties: false
      properties:
        slug:
          type: string
          description: Stable identifier for the plan. Send it when quoting or buying.
        name:
          type: string
        description:
          anyOf:
            - type: string
            - type: 'null'
        region:
          anyOf:
            - $ref: '#/components/schemas/EsimRegionResponse'
            - type: 'null'
        dataType:
          type: string
          enum:
            - fixed
            - unlimited
            - daily
        data:
          type: object
          additionalProperties: false
          properties:
            totalBytes:
              anyOf:
                - type: string
                  description: Null on an unlimited plan.
                - type: 'null'
            dailyCapBytes:
              anyOf:
                - type: string
                  description: Set on a daily-allowance plan.
                - type: 'null'
            display:
              type: string
          required:
            - totalBytes
            - dailyCapBytes
            - display
        validityDays:
          type: integer
          minimum: 1
        price:
          $ref: '#/components/schemas/EsimMoney'
        supportsTopUp:
          type: boolean
          description: Whether this plan can extend an eSIM already installed.
        supportsPlatformSms:
          type: boolean
          description: >-
            Whether the provider flags this plan as SMS-capable. Not a phone
            number and not inbound SMS: an eSIM has no MSISDN and cannot receive
            a message. It concerns only messages the platform pushes to the
            handset.
        coverage:
          type: array
          items:
            type: string
          description: ISO 3166-1 alpha-2 codes the plan covers.
      required:
        - slug
        - name
        - description
        - region
        - dataType
        - data
        - validityDays
        - price
        - supportsTopUp
        - supportsPlatformSms
        - coverage
    EsimRegionResponse:
      type: object
      additionalProperties: false
      properties:
        code:
          type: string
          description: >-
            The destination code. A two-letter country, or a bundle code such as
            `!EU`.
        name:
          type: string
        kind:
          type: string
          enum:
            - country
            - regional
            - global
        flagEmoji:
          anyOf:
            - type: string
            - type: 'null'
      required:
        - code
        - name
        - kind
        - flagEmoji
    EsimMoney:
      type: object
      additionalProperties: false
      properties:
        amount:
          type: string
          description: Minor units, as a string. Use this for arithmetic.
        currency:
          type: string
          description: ISO 4217 code.
        display:
          type: string
          description: The same figure rendered. Never use it in a calculation.
      required:
        - amount
        - currency
        - display
    RequestError:
      anyOf:
        - $ref: '#/components/schemas/ValidationError'
        - $ref: '#/components/schemas/Error'
      description: >-
        Either a field-level validation failure carrying an errors array, or a
        rule the request broke, identified by code.
    Error:
      type: object
      additionalProperties: true
      properties:
        statusCode:
          type: integer
        message:
          type: string
          description: >-
            A sentence suitable for a log or a support conversation, not for a
            user interface.
        code:
          type: string
          description: >-
            The stable machine-readable reason. Branch on this, never on the
            message.
      required:
        - message
        - code
      description: >-
        An error body. Individual errors may add context fields alongside these
        three.
    RateLimitError:
      type: object
      additionalProperties: false
      properties:
        statusCode:
          const: 429
        message:
          type: string
        code:
          const: api_key_rate_limit_exceeded
        retryAfterSeconds:
          type: integer
          minimum: 1
      required:
        - statusCode
        - message
        - code
        - retryAfterSeconds
    ValidationError:
      type: object
      additionalProperties: false
      properties:
        statusCode:
          const: 400
        message:
          type: string
          description: The single failure, or a count when more than one field failed.
        code:
          const: validation_failed
        errors:
          type: array
          items:
            $ref: '#/components/schemas/ValidationFailure'
      required:
        - statusCode
        - message
        - code
        - errors
    ValidationFailure:
      type: object
      additionalProperties: false
      properties:
        message:
          type: string
        field:
          type: string
        code:
          type: string
        path:
          type: array
          items:
            anyOf:
              - type: string
              - type: integer
      required:
        - message
        - field
        - code
        - path
  responses:
    ValidationError:
      description: >-
        The request was rejected before it was acted on. Field failures list
        every failing field.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/RequestError'
          example:
            statusCode: 400
            message: Must be a valid identifier.
            code: validation_failed
            errors:
              - message: Must be a valid identifier.
                field: accountId
                code: custom
                path:
                  - accountId
    AuthenticationError:
      description: >-
        The API key is missing, invalid, inactive, expired, for another
        environment, or blocked by its IP allowlist.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            statusCode: 401
            code: INVALID_API_KEY
            message: Invalid or inactive API credentials.
    NotFoundError:
      description: The requested resource was not found for this business.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            statusCode: 404
            code: resource_not_found
            message: Resource not found.
    RateLimitError:
      description: The API key rate limit was exceeded.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/RateLimitError'
          example:
            statusCode: 429
            message: Too many API requests. Try again later.
            code: api_key_rate_limit_exceeded
            retryAfterSeconds: 17
    ServerError:
      description: An unexpected server error occurred.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            statusCode: 500
            code: internal_server_error
            message: An unexpected error occurred.
    ProviderUnavailableError:
      description: >-
        A payment provider could not be reached. The request had no effect;
        retry shortly.
      headers:
        X-Request-ID:
          description: >-
            The request identifier assigned by Sakawave. Include it in support
            requests.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            statusCode: 503
            code: provider_unavailable
            message: We could not issue an account number just now. Try again shortly.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Sakawave API key
      description: >-
        A secret API key, sent as `Authorization: Bearer sk_test_…` in sandbox
        or `Bearer sk_live_…` in live.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.