Skip to main content
POST
/
api
/
v1
/
orders
Create a new order.
curl --request POST \
  --url https://api.cow.fi/mainnet/api/v1/orders \
  --header 'Content-Type: application/json' \
  --data '
{
  "sellToken": "0x6810e776880c02933d47db1b9fc05908e5386b96",
  "buyToken": "0x6810e776880c02933d47db1b9fc05908e5386b96",
  "sellAmount": "1234567890",
  "buyAmount": "1234567890",
  "validTo": 123,
  "feeAmount": "1234567890",
  "kind": "buy",
  "partiallyFillable": true,
  "signingScheme": "eip712",
  "signature": "0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
  "appData": "{\"version\":\"0.9.0\",\"metadata\":{}}",
  "receiver": "0x6810e776880c02933d47db1b9fc05908e5386b96",
  "sellTokenBalance": "erc20",
  "buyTokenBalance": "erc20",
  "from": "0x6810e776880c02933d47db1b9fc05908e5386b96",
  "quoteId": 123,
  "appDataHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
  "fullBalanceCheck": false
}
'
"0xff2e2e54d178997f173266817c1e9ed6fee1a1aae4b43971c53b543cffcc2969845c6f5599fbb25dbdd1b9b013daf85c03f3c63763e4bc4a"

Body

application/json

The order to create.

Data a user provides when creating a new order.

sellToken
string
required

see OrderParameters::sellToken

Example:

"0x6810e776880c02933d47db1b9fc05908e5386b96"

buyToken
string
required

see OrderParameters::buyToken

Example:

"0x6810e776880c02933d47db1b9fc05908e5386b96"

sellAmount
string
required

see OrderParameters::sellAmount

Example:

"1234567890"

buyAmount
string
required

see OrderParameters::buyAmount

Example:

"1234567890"

validTo
integer
required

see OrderParameters::validTo

feeAmount
string
required

see OrderParameters::feeAmount

Example:

"1234567890"

kind
enum<string>
required

see OrderParameters::kind

Available options:
buy,
sell
partiallyFillable
boolean
required

see OrderParameters::partiallyFillable

signingScheme
enum<string>
required

How was the order signed?

Available options:
eip712,
ethsign,
presign,
eip1271
signature
required

A signature.

Example:

"0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"

appData
required

This field comes in two forms for backward compatibility. The hash form will eventually stop being accepted.

Example:

"{\"version\":\"0.9.0\",\"metadata\":{}}"

receiver
string

see OrderParameters::receiver

Example:

"0x6810e776880c02933d47db1b9fc05908e5386b96"

sellTokenBalance
enum<string>
default:erc20

see OrderParameters::sellTokenBalance

Available options:
erc20,
internal,
external
buyTokenBalance
enum<string>
default:erc20

see OrderParameters::buyTokenBalance

Available options:
erc20,
internal
from
string

If set, the backend enforces that this address matches what is decoded as the signer of the signature. This helps catch errors with invalid signature encodings as the backend might otherwise silently work with an unexpected address that for example does not have any balance.

Example:

"0x6810e776880c02933d47db1b9fc05908e5386b96"

quoteId
integer | null

Orders can optionally include a quote ID. This way the order can be linked to a quote and enable providing more metadata when analysing order slippage.

appDataHash
string

May be set for debugging purposes. If set, this field is compared to what the backend internally calculates as the app data hash based on the contents of appData. If the hash does not match, an error is returned. If this field is set, then appData MUST be a string encoding of a JSON object.

Example:

"0x0000000000000000000000000000000000000000000000000000000000000000"

fullBalanceCheck
boolean
default:false

If set to true, full sell amount will be checked during allowance and balance checking. This will ensure the account has correct allowance and available balance for the order to be created.

Response

Order has been accepted.

Unique identifier for the order: 56 bytes encoded as hex with 0x prefix.

Bytes 0..32 are the order digest, bytes 30..52 the owner address and bytes 52..56 the expiry (validTo) as a uint32 unix epoch timestamp.

Example:

"0xff2e2e54d178997f173266817c1e9ed6fee1a1aae4b43971c53b543cffcc2969845c6f5599fbb25dbdd1b9b013daf85c03f3c63763e4bc4a"

Last modified on March 17, 2026