🔒Request crypto payment
This is an authenticated endpoint
Initiate a payment request
POST
https://payments.b2bpay.co/api/v1/payments
An endpoint for initiating a crypto payment request. Upon success, a unique paymentUrl
is provided in the response which can be served within an iframe
Alternatively, you can redirect to the payment URL and if you have supplied a redirectUrl
in the request, we will navigate the end-user back to your website upon payment completion (when we have received a deposit against this payment request). There is also a button which the end-user can use if they wish to get redirected back sooner.
Request Body
Name | Type | Description |
---|---|---|
depositAmount | string | Request amount in cryptocurrency that should be deposited (i.e. 0.55 BTC). |
depositCurrency | string | Cryptocurrency that should be used for the deposit. Required if |
type | string | Can be one of [ONE_TIME, REUSABLE] |
rateType | string | Can be one of [FIXED, FLOATING]. Defaults to FIXED when certain conditions are met. |
redirectUrl | string | Redirect a customer back to a specific URL upon payment completion. |
businessId* | string | UUID Unique business identifier. Optional for businessToken implementation |
expirationMinutes | integer |
Indicates the timeframe in which the deposit should happen. A value of
You can omit this parameter. Reusable payments are set to non-expiry. |
displayCurrency | string | Fiat currency abbreviation (i.e. EUR, USD, GBP). Required if |
displayAmount | string | Amount in
|
locale* | string | Language localisation abbreviation. The following languages are available through their ISO 639-1 codes: en-US, de-DE, tr-TR es-ES, fr-FR, ru-RU, pt-PT and ja-JP. |
clientPaymentId* | string | Unique payment identifier for reconciliation purposes. |
network | string | Add a specific network that will be used for the deposit. The list of available currencies and network pairs can be found here. For example if you wish to create a deposit for USDT, the value for the |
Response schema
Parameter | Type | Description |
---|---|---|
paymentInfo | object [required] | Object with payment details |
actualDepositAmount | string [required] | The actual deposit amount in cryptocurrency |
actualDisplayAmount | string [required] | The actual display amount upon receiving the cryptocurrency |
expectedDepositAmount | string [optional] | The expected amount in Cryptocurrency |
expectedDisplayAmount | string [optional] | The expected amount in Fiat currency |
expectedNetwork | string [optional] | The expected network on which this deposit should occur |
businessId | string [required] | B2BPay business ID |
clientPaymentId | string [required] | Unique payment identifier provided in the request |
deposits | array [required] | Array with all the transactions that happened for this payment |
expirationMinutes | number [required] | The timeframe in which the deposit should happen |
locale | string [required] | Language localisation abbreviation. |
paymentId | string [required] | Unique payment identifier within B2BPay system |
paymentInitiatedAt | number [required] | Timestamp when the payment got created |
status | string [required] | Status of the payment |
processorType | string [required] | Type of the payment. Can be one of [BLOCKCHAIN, CARD]. For crypto payments it's BLOCKCHAIN |
redirectUrl | string [optional] | A specific URL the customer will be redirected to upon payment completion |
overpaymentPolicy | string [optional] | Payment configuration for overpayments. Can be one of: |
refundFollowUpDepositsForOneTimePayments | boolean [optional] | Payment configuration if follow-up deposits should be refunded. |
rateType | string [required] | Can be one of [FIXED, FLOATING] |
type | string [required] | Can be one of [ONE_TIME, REUSABLE] |
paymentUrl | string [required] | A unique payment URL which could be used to serve the B2BPay checkout page |
Last updated