Create a Payment

Create a payment and get a hosted pay URL.

Create a Payment

POST https://api.open-finance.ai/v2/payments

This creates a payment and returns its id plus a hosted payUrl. At minimum
you send paymentInformation (amount, currency, description) and identify the
payee
— either a merchantId (see Merchants (Payees)) or the creditor's
account details. Requires a Bearer token (see Authentication); rejected
requests (validation, disallowed redirect URL, sandbox gate, …) return the
standard error shape — see Errors.

⚠️

Payments require a connection. To make or receive a payment, the user

must have a linked bank (a Connection), and the payment must involve one of
their connected accounts — either as the debtor (paying from a connected
account) or the creditor (receiving into a connected account). If neither
side is a connected account, the payment can't proceed. Connections are created
only in the Financy UI — see Connections.

paymentInformation

Describes what to charge and (unless you pass a merchantId) who to pay:

FieldRequiredDescription
amountAmount to charge, greater than 0. E.g. 100.
currencyISO-4217 code, e.g. ILS.
descriptionDescription shown to the payer.
creditorName✳️Payee name. Required unless a merchantId is set.
creditorAccountType✳️Payee account type: iban or bban. Required unless a merchantId is set.
creditorAccountNumber✳️Payee account number (e.g. IL730200040000000552717). Required unless a merchantId is set.
debtorAccountTypePayer account type (iban / bban), when known up front.
debtorAccountNumberPayer account number, when known up front.
✳️

Provide the payee either by setting merchantId at the top level or

by giving creditorName + creditorAccountType + creditorAccountNumber
here. Omitting both returns Merchant Id or creditor info is required.

Top-level fields

FieldDescription
merchantIdPay a saved payee instead of inline creditor details (see Merchants (Payees)).
redirectUrlWhere the user returns after the hosted journey completes.
providerIdsRestrict bank selection to specific providers (see Providers & Branches).
languageJourney language: he or en.
paymentServiceForce a rail: masav, fp, or zahav (see below).
psuIdThe payer's national ID / passport, when the provider requires it.
psuCorporateIdThe payer's business ID, for corporate payments.
allowBusinessAllow the payer to pay from a business account.
isBusinessRequire the payer to pay from a business account.
iframeRender the hosted journey inside an iframe.
externalIdYour own reference id, echoed back on the payment.
includeFakeProvidersAllow sandbox providers (testing) — see Errors (sandbox gate).
directPayOnlyComplete the payment without the open-banking consent journey.
callbackInformationWebhook configuration — see Payment Webhooks.
📘

This covers the common fields. POST /v2/payments also accepts

bulkPaymentInformation and periodicPaymentInformation (for bulk and
recurring payments) and request-to-pay options — see the API Reference for
the full, field-by-field list.

Payment rails (paymentService)

If you don't set paymentService, Financy picks the appropriate rail. The three
rails are:

RailWhen it's used
masavDefault. Transfers under 1,000,000 ILS.
zahavFast/high-value transfers over 1,000,000 ILS (fees may apply).
fpTransfers within the same bank (creditor and debtor share a provider).

Request

curl -X POST https://api.open-finance.ai/v2/payments \
  -H "Authorization: Bearer <accessToken>" \
  -H "Content-Type: application/json" \
  -d '{
    "redirectUrl": "https://your-app.com/payment/done",
    "language": "he",
    "paymentInformation": {
      "amount": 149.90,
      "currency": "ILS",
      "description": "Order #4471"
    }
  }'

Response

{
  "id": "01J8X...",
  "payUrl": "https://api.open-finance.ai/journey/01J8X..."
}
  • id — the paymentId you use for status polling and for the direct-init step.
  • payUrl — the hosted journey. Hosted flow: redirect the user here and skip
    to Payment Status. Direct flow: ignore payUrl and continue to
    Initiate a Payment (Direct).
💡

Set callbackInformation to be pushed the outcome instead of polling — see

Payment Webhooks. For what each status means, see Payment Statuses & FAQ.


Did this page help you?