1. Installment
Freedom Pay
  • Overview
  • Gateway API
    • Overview
    • Sync API
      • Overview
      • Card data encryption
      • Payments
        • Overview
        • Pay by card
        • Pay by card: complete 3DS
        • Pay with Apple Pay
        • Pay with Google Pay
        • Pay by recurring profile
        • Create payment page
        • Create payment page with any amount
        • Capture payment (clearing)
        • Cancel payment
        • Refund payment
        • Get payment status
      • Payouts
        • Overview
        • Pay out to card
        • Pay out to IBAN
        • Get payout balance
        • Get payout status
      • Transfers
        • Overview
        • Transfer from card to card
        • Transfer from card to card: complete 3DS
        • Get exchange rates
        • Get transfer status
      • Saved cards
        • Overview
        • Save card
        • Save card: complete 3DS
        • List saved cards
        • Remove saved card
        • Pay by card token
        • Pay out to card token
        • Get payment status
    • Async API
      • Overview
      • Create
        • Create payment
        • Save card without a charge
      • Read
        • Get payment status
        • Get request result
      • Edit
        • Capture payment (clearing)
        • Cancel payment (reverse)
        • Refund payment
  • Merchant API
    • Overview
    • Payments
      • Overview
      • Checkout
      • Pay by saved card
        • Overview
        • Create payment
        • Confirm payment with CVC
        • Confirm payment without the client
      • Create payment
      • Create payment with a payment page template
      • Create payment in a payment frame
      • Create payment with any amount
      • Create recurring payment
      • Capture payment (clearing)
      • Cancel payment
      • Refund payment
      • Get payment status
    • Payouts
      • Overview
      • Create payout page
      • Pay out to saved card
      • Pay out to IBAN
      • Get payout status
      • Get payout balance
    • Saved cards
      • Get saved cards
      • Save card
      • Save card for payouts
      • Delete saved card
      • Save card without a charge
    • Mobile balance
      • Overview
      • Create mobile balance payment
      • Charge mobile balance
      • Get mobile balance payment status
      • Confirm payment with SMS code
      • Resend SMS code
    • Invoices
      • Overview
      • Recurring payments
        • Overview
        • Create recurring profile
        • Get recurring profile
        • Charge by recurring profile
        • Cancel recurring profile
        • Recurring profile notification
      • Tips
        • Overview
        • Create
      • Create invoice
      • Get invoice status
      • Get invoice details
      • Cancel invoice
      • Refund invoice
    • SDK
      • JS SDK
      • Merchant SDK
        • Android
        • iOS
        • Migration guide
    • CMS
      • Overview
      • Get Merchant ID and key
      • WordPress
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
        • Update
      • Tilda
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • InSales
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • Ecwid
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • Bitrix
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • PrestaShop
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • OpenCart
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
      • CS-Cart
        • Overview
        • Installation
        • Configuration
        • Test
        • Live payments
    • Installment
      • Overview
      • Status
        • Get application status
        • Application status notification
        • Change application status
      • Get partners
        GET
      • Create application
        POST
    • Callbacks
      • Overview
      • Result notify
      • Check request
      • Payout notify
      • Redirect back
  • Partner API
    • Overview
    • Rates
      • Overview
      • Rates
    • Products
      • Overview
      • Dictionaries
      • Add client with product
      • Client request status
      • Create terminal
      • Update terminal limits
      • Product request status
    • E-Money
      • Overview
      • Add
      • Owner identification
      • Info
      • Close
      • Block
      • Balance
      • Statement
      • Request Status
    • Device ID
      • Android SDK
      • iOS SDK
    • Implement SuperApp
      • Overview
      • Pay
      • Refund
      • Status
    • Account
      • Overview
      • Create payment
      • Payment status
      • Batch statuses
      • Statement
      • Statement status
      • Balance
      • Balance status
    • Invoices
      • Info
  1. Installment

Overview

Installment: the client buys now and pays in installments or with a loan from a partner bank.
You create an application, the client completes it on the Freedom Pay page by the link, the bank decides.
Signature and request headers are the same as in Invoice API: see Invoice Overview. The phone number of the client is passed encrypted: see «Phone encryption».
Installment is in development: the methods may change.

How it works#

1.
Get the banks and their programs with Get partners and show the terms to the client.
2.
Create an application with Create application: the order, the encrypted phone number, callback_url. Get redirect_url.
3.
Open redirect_url for the client: the client gives consent, chooses a bank offer and signs the agreement with the bank.
4.
Follow the status with Get application status: when it is signed, hand over the goods and set delivered with Change application status.
5.
To cancel an application or to request a refund, use Change application status.

Methods#

MethodWhat it does
Get partnersReturns the banks, their amount limits and programs.
Create applicationCreates an application and returns the link for the client.
Get application statusReturns the status of an application.
Change application statusCancels an application, confirms the delivery or requests a refund.
Application status notificationNotification about the status of an application (in development).

Application statuses#

StatusMeaningFinal
newThe application is created: the client has not opened the link yet or has not given consent.No
consent_signedThe client gave consent to the data check.No
pre_scoring_approvedThe preliminary check is passed: the client chooses a bank offer.No
pre_scoring_rejectedThe preliminary check is failed.Yes
bank_selectedThe client chose a bank and a program: approved_amount and bank_code are returned.No
scoring_rejectedThe bank declined the application.No
signedThe client signed the agreement with the bank: hand over the goods, then set delivered.No
deliveredThe merchant confirmed the delivery with Change application status.No
canceledThe merchant cancelled the application with Change application status.Yes
canceled_customerThe client cancelled the application.Yes
expiredThe application expired: the client did not complete it in time.Yes
refundThe merchant requested a refund with Change application status.No
refundedThe refund is completed.Yes
The transitions between statuses: see Get application status.

Response headers#

HeaderValue
X-Request-Statussuccess or error.
X-DatetimeResponse date and time, ISO 8601.

Errors#

The body of an error: error_code and error_description. The texts of validation errors are in Russian.
HTTPerror_codeWhen
400, 4221001The request is invalid: X-Request-Id, a field, or the encrypted phone number.
4013001The signature is invalid.
4013002X-JWS-Signature is missing.
4044001The application is not found.
4092001The status transition is not allowed.
4092002The application is in a final status.
500, 5035000Internal error: repeat the request later.

Phone encryption#

Pass customer.phone in Create application as a compact JWE:
ParameterValue
PayloadPhone number, 998XXXXXXXXX.
algPBES2-HS512+A256KW
encA256GCM
p2cNumber of iterations: from 1000 to 600 000.
KeyYour secret key: the key you sign requests with.
Only alg, enc, p2s, p2c, kid, typ and cty are allowed in the JWE header.

Python#

Library: jwcrypto.

PHP#

Libraries: web-token/jwt-library, spomky-labs/aes-key-wrap.
Previous
Live payments
Next
Get application status