POST
/
orders
{
  "orderId": "3ae57c43-6fae-4b0c-b0d5-2c35759e76d9",
  "quoteId": "63e154dbc47d9176668a9af6",
  "amountIn": 1313696,
  "amountOut": 1,
  "symbolIn": "CLP",
  "symbolOut": "ETH",
  "paymentMethodId": "63473a5f743da0f55fa04c8f",
  "providedAction": "url.example.com",
  "email": "kenneth@koywe.com",
  "documentNumber": "158289164"
}

IMPORTANT: As of November 6, 2023, This endpoint requires the quote ID, you can get an ID from:
- POST /quote

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
quoteId
string
required
destinationAddress
string
required

This is a required attribute when creating an order. Its content varies depending on the type of order: for an 'off-ramp' order, destinationAddress should contain the identifier of the bank account (BankAccount); for an 'on-ramp' order, it should be the destination address for the cryptocurrencies. This attribute is crucial in ensuring that funds are sent to the correct place.

email
string
documentNumber
string
metadata
string

This is an optional attribute that you can use to store any additional information you need to associate with the order. This information will be stored with the order details and can come in handy for keeping track of customer-specific data, order features, or other relevant information not covered in other attributes of the order.

externalId
string

This attribute is employed to provide idempotency in the order creation requests. It is a unique identifier per order, supplied from the client side, that allows for a unique identification of an order and prevents the duplicate processing of the same order. By incorporating an externalId, clients have the ability to safely retry requests without the fear of inadvertently carrying out repeated transactions.

callbackUrl
string

This is an optional attribute that can be provided when creating an order. If supplied, this value will be returned in the 'providedAction' attribute of the response upon the creation of the order. The primary purpose is to allow the client to redirect users to a specific URL following the order creation. If no callbackUrl is provided, the system will generate and return a default URL, reflected in the 'providedAction' attribute, that points to a specific interface of Koywe.

Response

200 - application/json
orderId
string
quoteId
string
amountIn
number
amountOut
number
symbolIn
string
symbolOut
string
paymentMethodId
string
providedAction
string
email
string
documentNumber
string
externalId
string