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

# Get invoice payment page by public token

> Данные платёжной страницы: адрес, актив, сумма, срок (отсчёт), статус оплаты, бренд. 410 Gone если ссылка отключена (прошёл срок + 1 день).



## OpenAPI

````yaml /openapi-public.json get /v1/public/invoices/{token}
openapi: 3.0.0
info:
  title: Wallet Platform — Public API
  description: >-
    API для интеграции CMS обменника: создание депозитов и выплат, отслеживание
    статусов, справочники активов и сетей.


    ## Аутентификация

    Каждый запрос подписывается HMAC-SHA256. Обязательные заголовки:

    - `X-Api-Id` — публичный идентификатор ключа (выдаётся в админке).

    - `X-Api-Key` — публичный ключ.

    - `X-Timestamp` — Unix-секунды; сервер принимает ±300 сек от своего времени.

    - `X-Signature` — `HMAC_SHA256_Hex( X-Timestamp + "." + raw_body, api_secret
    )`. Для GET тело пустое.

    - `X-Idempotency-Key` — опционально (UUID). Гарантирует, что повторный POST
    не создаст дубликат.


    Дополнительно: IP-вызывающего должен быть в whitelist сайта (настраивается в
    админке). Секрет (`api_secret`) показывается один раз при создании ключа и
    хранится только у вас.


    ## Формат ответа

    Все ответы — единый envelope: `{ "ok": true, "data": ... }` при успехе либо
    `{ "ok": false, "error": { "code": "...", "message": "..." } }` при ошибке.


    ## Идемпотентность

    Создание депозита/выплаты идемпотентно по вашему `order_id` (уникален в
    рамках сайта и актива) и/или по `X-Idempotency-Key`. Повторный вызов с тем
    же ключом вернёт исходный объект, а не создаст новый.


    ## Webhooks (исходящие)

    При смене статуса платформа шлёт POST на ваш `callback_url`. Заголовки:
    `X-Event-Type`, `X-Event-Id` (uuid, идемпотентность на вашей стороне),
    `X-Timestamp`, `X-Signature` = `HMAC_SHA256_Hex(raw_body, callback_secret)`.
    Проверяйте подпись перед обработкой.

    События: `deposit.tx_detected`, `deposit.finalized`, `deposit.failed`,
    `deposit.refunded`, `payout.broadcasted`, `payout.confirmed`,
    `payout.failed`.

    Доставка считается успешной при HTTP 2xx за 10 секунд. Ретраи: 30s, 2m, 10m,
    1h, 6h, 24h (до 8 попыток).
  version: '1'
  contact: {}
servers: []
security:
  - X-Api-Id: []
    X-Api-Key: []
    hmac: []
    X-Timestamp: []
tags: []
paths:
  /v1/public/invoices/{token}:
    get:
      tags:
        - public · invoices
      summary: Get invoice payment page by public token
      description: >-
        Данные платёжной страницы: адрес, актив, сумма, срок (отсчёт), статус
        оплаты, бренд. 410 Gone если ссылка отключена (прошёл срок + 1 день).
      operationId: InvoicePublicController_getByToken
      parameters:
        - name: token
          required: true
          in: path
          description: Публичный токен из ссылки счёта.
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvoicePublicResponseDto'
components:
  schemas:
    InvoicePublicResponseDto:
      type: object
      properties:
        token:
          type: string
        title:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        assetCode:
          type: string
          example: USDT_TRC20
        assetSymbol:
          type: string
          example: USDT
        assetName:
          type: string
          example: Tether USD (TRC-20)
        network:
          type: string
          example: TRON
        address:
          type: string
          description: Адрес для оплаты (показывается + QR).
        memo:
          type: string
          nullable: true
          description: Memo (ОБЯЗАТЕЛЕН для memo-based сетей, иначе null).
        expectedAmount:
          type: string
          example: '100.50'
        amountUsd:
          type: string
          nullable: true
          example: '100.42'
          description: USD-эквивалент (best-effort).
        decimals:
          type: number
          example: 6
        expiresAt:
          type: string
          format: date-time
          description: Срок оплаты (для обратного отсчёта).
        createdAt:
          type: string
          format: date-time
        state:
          type: string
          enum:
            - pending
            - detected
            - paid
            - overpaid
            - underpaid
            - expired
          description: Состояние оплаты для UI.
        paymentStatus:
          type: string
          description: Сырой статус депозита.
        receivedAmount:
          type: string
          nullable: true
        confirmations:
          type: number
          nullable: true
        requiredConfirmations:
          type: number
          example: 19
        txhash:
          type: string
          nullable: true
        explorerTxUrl:
          type: string
          nullable: true
        explorerAddressUrl:
          type: string
          nullable: true
        paidAt:
          type: string
          format: date-time
          nullable: true
        branding:
          $ref: '#/components/schemas/InvoiceBrandingDto'
      required:
        - token
        - title
        - description
        - assetCode
        - assetSymbol
        - assetName
        - network
        - address
        - memo
        - expectedAmount
        - amountUsd
        - decimals
        - expiresAt
        - createdAt
        - state
        - paymentStatus
        - receivedAmount
        - confirmations
        - requiredConfirmations
        - txhash
        - explorerTxUrl
        - explorerAddressUrl
        - paidAt
        - branding
    InvoiceBrandingDto:
      type: object
      properties:
        displayName:
          type: string
          example: WalletCore
        primaryColor:
          type: string
          example: '#3b82f6'
      required:
        - displayName
        - primaryColor
  securitySchemes:
    X-Api-Id:
      type: apiKey
      in: header
      name: X-Api-Id
      description: Публичный идентификатор API-ключа
    X-Api-Key:
      type: apiKey
      in: header
      name: X-Api-Key
      description: Публичный API-ключ
    hmac:
      type: apiKey
      in: header
      name: X-Signature
      description: HMAC-SHA256-Hex(timestamp + "." + raw_body, api_secret)
    X-Timestamp:
      type: apiKey
      in: header
      name: X-Timestamp
      description: Unix-секунды, ±300с

````