Skip to content

Fetch Payment Options Method

Returns available payment options (payment methods with per-bank availability and limits).

RPC: invoice.v1.PubInvoiceService/FetchPaymentOptions


TIP

amount is optional. If provided, options will be filtered by min/max limits.

Request Example

shell
curl 'https://api.ibuy.exchange/invoice.v1.PubInvoiceService/FetchPaymentOptions'   --header 'Authorization: Bearer <token>'   --header 'Content-Type: application/json'   --data '{
    "amount": "1499.00"
  }'
typescript
import { createClient } from "@connectrpc/connect";
import { ibuy } from "@ibuy.exchange/api";

const invoiceService = createClient(ibuy.invoicev1.PubInvoiceService, transport);

const response = await invoiceService.fetchPaymentOptions({
  amount: "1499.00",
});

for (const opt of response.options) {
  console.log(opt.id, opt.code, opt.type, opt.available);
  for (const bank of opt.banks) {
    console.log("  -", bank.code, bank.name, bank.available);
  }
}

Response Example

json
{
  "options": [
    {
      "id": "pm_123",
      "code": "card",
      "type": "CARD",
      "name": "Bank Cards",
      "available": true,
      "limits": {
        "min_amount": "1.00",
        "max_amount": "500000.00"
      },
      "banks": [
        {
          "code": "tinkoff",
          "name": "Tinkoff",
          "available": true,
          "limits": {
            "min_amount": "1.00",
            "max_amount": "300000.00"
          }
        },
        {
          "code": "sber",
          "name": "Sberbank",
          "available": true,
          "limits": {
            "min_amount": "10.00",
            "max_amount": "500000.00"
          }
        }
      ]
    },
    {
      "id": "pm_456",
      "code": "sbp",
      "type": "SBP",
      "name": "SBP (Phone)",
      "available": true,
      "limits": {
        "min_amount": "1.00",
        "max_amount": "500000.00"
      },
      "banks": [
        {
          "code": "sber",
          "name": "Sberbank",
          "available": true,
          "limits": {
            "min_amount": "1.00",
            "max_amount": "500000.00"
          }
        }
      ]
    }
  ]
}