---
title: "Create Checkout"
method: POST
path: "/ecommerce/{virtualBPTId}/checkout"
---

# Create Checkout

`POST /ecommerce/{virtualBPTId}/checkout`

## Request

- Base URL: `https://ibexpay-api.ibexmercado.com`
- URL: `https://ibexpay-api.ibexmercado.com/ecommerce/{virtualBPTId}/checkout`
- Auth: API key in header `Authorization`

## Path parameters

- `virtualBPTId` string, required

## Request body

- object
  - `amount` number, float, required: amount of fiat
  - `orderId` string, required: ID of the order on the shop side
  - `webhookUrl` string: Optional URL to notify when the transaction is paid. A /POST with is made to webhookUrl. Check the request body below.
  - `webhookSecret` string: Optional secret for the webhook
  - `description` string: Optional text explaining whats on the transaction
  - `successUrl` string: URL to redirect when the invoice is paid, only works if using IBEXPay checkout page.
  - `gobackUrl` string: URL to go back when cancelling the checkout, only works if using IBEXPay checkout page.
  - `notifyAll` boolean: Optional param to specify the webhooks you want to received, true if you want to received webhooks for all the states of the transaction, or false if you just want to received the webhook when the transaction is paid. By default is false. You can always get the state of the transaction by calling the get checkout endpoint
  - `previousAmountMsat` integer: Msat amount before updating the exchange rate
  - `addressType` string: Optional address type to generate. Supported types: `P2WKH`, `NP2WKH`, `P2TR`

## Response `200`

200

- object
  - `id` string
  - `amount` integer
  - `orderId` string
  - `webhookUrl` string
  - `transactionId` integer

## Other responses

- `400`: 400

## Changes

- **2026-11-03** `0b7d0265e831`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/ibexmercado/apis/ibexpay-api/changes/ecommerce/:virtualBPTId/checkout/post.md)

---

[API](https://skmtc.dev/ibexmercado/apis/ibexpay-api.md) - [All operations](https://skmtc.dev/ibexmercado/apis/ibexpay-api/llms.txt) - [OpenAPI document](https://skmtc.dev/ibexmercado/apis/ibexpay-api/revisions/0b7d0265e831?raw)
