{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/raiffeisen-ru/main/json-schema/raiffeisen-ru-payment-order-schema.json",
  "title": "PaymentOrder",
  "x-generated": "2026-10-09",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/raiffeisen-ru-brokerage-payment-orders-openapi.yml#/components/schemas/PaymentOrder",
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/PaymentOrderId"
    },
    "agreementNumber": {
      "type": "string",
      "description": "Номер брокерского договора"
    },
    "accountFrom": {
      "type": "string",
      "description": "Счёт списания"
    },
    "accountTo": {
      "type": "string",
      "description": "Счёт зачисления"
    },
    "description": {
      "type": "string",
      "description": "Назначение платежа"
    },
    "amount": {
      "type": "number",
      "description": "Сумма платежа"
    },
    "status": {
      "$ref": "#/$defs/PaymentOrderStatus"
    },
    "errorDescription": {
      "type": [
        "string",
        "null"
      ],
      "description": "Описание ошибки обработки поручения"
    }
  },
  "$defs": {
    "PaymentOrderId": {
      "type": "integer",
      "format": "int64",
      "description": "Идентификатор платёжного поручения"
    },
    "PaymentOrderStatus": {
      "type": "string",
      "description": "Статус обработки платёжного поручения",
      "enum": [
        "IN_PROGRESS",
        "SUCCESS",
        "ERROR"
      ]
    }
  }
}