Submit a signed Fusion order

Submits a single signed limit order to the Fusion orderbook. The order will be validated and made available to resolvers for execution. Requires a valid EIP-712 signature from the order maker.

POSThttps://api.1inch.com/fusion/relayer/v2.0/{chain}/order/submit
Supported on:
EthereumBaseSolanaBNB ChainUnichainArbitrumAvalancheZKsyncGnosisOptimismPolygonLineaSonic

Parameters

chain
* number path

Request Body

SignedOrderInput object
order
* any
allOf[0]
OrderInput object
salt
* string
makerAsset
* string
takerAsset
* string
maker
* string
receiver
string
makingAmount
* string
takingAmount
* string
makerTraits
string
signature
* string
extension
* string
quoteId
* string
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
const axios = require('axios');

async function httpCall() {
  const url = 'https://api.1inch.com/fusion/relayer/v2.0/{chain}/order/submit';

  const config = {
    headers: {
      Authorization: `Bearer ${API_KEY}`,
    },
    params: {},
    paramsSerializer: {
      indexes: null,
    },
  };
  const body = {
    order: {
      salt: 'string',
      makerAsset: 'string',
      takerAsset: 'string',
      maker: 'string',
      receiver: '0x0000000000000000000000000000000000000000',
      makingAmount: 'string',
      takingAmount: 'string',
      makerTraits: '0',
    },
    signature: 'string',
    extension: '0x',
    quoteId: 'string',
  };

  try {
    const response = await axios.post(url, body, config);
    console.log(response.data);
  } catch (error) {
    console.error(error);
  }
}

Returns

201
400
403
409
500

201 response doesn’t have payload.

Did you find what you need?