As of May 31, 2023, we have updated our Code of Conduct.

Questions tagged [0x]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
1 answer
266 views

How to check and Increase API rate limit on 0x?

I am using 0x API for my dex and I am expecting at least 4k users on my app. But I don't see any subscription plan or anything on 0x documentation to increase or at least know my API rate limits. Is ...
ninja's user avatar
  • 74
0 votes
1 answer
62 views

How is a direct swap transaction fullfilled by 0x

Looking at the direct swap example https://github.com/0xProject/0x-api-starter-guide-code/blob/master/src/direct-swap.js#L105-L113 Seems like the transaction is send to the chain's RPC URL which is ...
NRJ's user avatar
  • 73
0 votes
1 answer
60 views

Cannot approve transaction on Matcha [closed]

After I hit approve, this immediately showed up. I tried several times, reset, etc. still didn't work
Vince's user avatar
  • 1
1 vote
1 answer
310 views

Approving tokens after flash loan

I'm creating a smart contract that can both make flash loans and swap tokens via 0x. I can call the flash loan and token swap functions just fine, but when I try to call the token swap within the ...
kingfish's user avatar
0 votes
1 answer
21 views

0x unstaking not possible on the site

I want to unstake my 0x from the site. But is does not work. Please help. My account 0x26336EA0829cd88307032DB2C8ABaaa05e97e082. Kind regards, Arie
Arie Gold's user avatar
0 votes
0 answers
45 views

Withdrawing 0x from 0x.org

I was successfully able to un-stake my 0x from the staking pool I had on https://0x.org/zrx/staking/pool But I try to Withdraw my funds, nothing happens. I click on "Withdraw" which is next ...
D-Qba's user avatar
  • 1
0 votes
1 answer
79 views

Transactions revert for ropsten only

We use 0x for swaps on ethereum-mainnet, avalanche-mainnet, and polygon-mainnet and all is generally working. Previously we would also use kovan for testing, but recently moved to ropsten as 0x is ...
Mike's user avatar
  • 15
0 votes
1 answer
56 views

how to track swaps through affiliateAddress or feeRecipient that are done through 0x api?

I found in the documentation that affiliateAddress can be used to track swaps that are sent to the 0x api, but how to filter this data based on affiliateAddress, I haven't found any way to track the ...
Ikram Ansari's user avatar
1 vote
2 answers
163 views

Trade resulting in incorrect ratio for value traded out-of and into

I am helping a friend try to recover approximately $36K of value traded through an 0X router. We have been given the run-around on multiple customer supports each one pointing to a different entity ...
Rome Montle's user avatar
0 votes
1 answer
76 views

Parse tranformations data

I want to make a multi-swap smart contract in which each swap will swap the amount obtained with the last swap. For that I'll need to modify the amount hardcored in the transformations array data. Are ...
Max's user avatar
  • 36
0 votes
1 answer
197 views

How to extract and read swap call data from 0x quote API

I'm currently working on a new decentralised derivatives exchange and I'm considering using 0x protocol to perform swaps. In order to create market orders on chain I'm following this example here. The ...
Matteo Ugolotti's user avatar
0 votes
2 answers
208 views

Is it possible to sell multiple tokens in one order on 0x?

Let's imagne I have DAI and USDT, and I want to sell both for ETH. But it seems like API might only support one token at a time: sellToken The ERC20 token address or symbol of the token you want to ...
devzero's user avatar
  • 11
0 votes
3 answers
323 views

How to sign order for 0x protocol

I am looking at https://0x.org/docs/api#post-orderbookv1order It talks about sending signed order to the API, but I was unable find the documentation on how to sign the order this api. Can anyone ...
NRJ's user avatar
  • 73
0 votes
1 answer
53 views

Security issue in 0x in-chain example

I was going through 0x on-chain docs and I saw the official example here which calls an arbitrary contract swapTarget whose address is given as a parameter. It seems a huge security pitfall, as it can ...
Anelito's user avatar
  • 113
1 vote
1 answer
127 views

TRANSFORM ERC 20 vs Sell to pancake swap

I am able to do the Sell to pancake swap tranx But failed with the API when i do TRANSFORM E R C20 Tranx example of failed: https://bscscan.com/tx/...
DAOdAppDev's user avatar
0 votes
1 answer
82 views

0xAPI `swap/quote`: Is the `value` ever > 0 for ERC20 swaps

I'm working on a smart contract that uses 0xAPI data passed in by the user to execute a number of ERC20 swaps. I noticed that so far during my usage of the 0xAPI, when sellToken and buyToken are both ...
Chris's user avatar
  • 439
0 votes
1 answer
39 views

Does the `to` field of the 0xAPI swap/quote response always return the same Proxy Address

I'm working on a smart contract that uses 0xAPI data passed in by the user to execute a number of ERC20 swaps. I noticed that the 'to' field of the /swap/v1/quote response seems to always contain the ...
Chris's user avatar
  • 439
0 votes
1 answer
413 views

Swap BEP-20 based tokens with 0x and ethers.js

I am trying to swap BEP-20 based tokens with 0x and Ethers.js. https://bsc.api.0x.org/swap/v1/quote I used this endpoint to get quote of the exchange. https://bsc.api.0x.org/swap/v1/quote?sellToken=...
Ryan Charley's user avatar
0 votes
1 answer
92 views

why I can't add slippage percentage greater than 1 in 0x API? what if I want to use 5% of slippage?

I am making a DEX app and I need a mode where users will get 5% of slippage But I can't do this with 0x API, every time I try to swap with 5% of slippagePercentage I got this error. { "code&...
ninja's user avatar
  • 74
0 votes
1 answer
46 views

My transaction finally received 0 token

This is not the first time this happened to me. I also added the buyAmount parameter to judge, and still received 0 tokens. Is there any way to prevent it from happening again? Thank you my txid: ...
ufo cv cvufo's user avatar
0 votes
1 answer
218 views

Getting `Gas estimation failed` for Avalanche quotes

I'm currently implementing the Avalanche 0x API for swapping in our UI. The quote arguments are the same as what we use for the ETH mainnet, but it returns Gas estimation failed; not sure how to debug ...
alexo382's user avatar
0 votes
1 answer
49 views

Expiry of RFQ order with 0x protocol

I set the expiration time of the RFQ order, but the actual expiration time of the order is inconsistent with what I set. For example: I set up an order that is 10 seconds overdue and send it over the ...
tml's user avatar
  • 1
0 votes
1 answer
188 views

0x quote endpoint

we are trying to integrate 0x protocol in our derivatives protocol and I have a couple of questions regarding the quote endpoint (GET /swap/v1/quote API, https://0x.org/docs/api#get-swapv1quote) ...
Walodja1987's user avatar
0 votes
1 answer
468 views

BSC token swap API error with 0x.org

I am using 0x for swapping my Binance token to other respected tokens. I got the required data from the 0X API but every time it's showing that the transaction reverted without reason error by the EVM....
Ajoy Karmakar's user avatar
1 vote
1 answer
219 views

How to submit a swap using EIP-1559 style?

I'd like to submit a swap to 0x using an eip1559 style transaction, but am unable to figure out how this should be done. Can someone provide some guidance on how to achive this using web3, in a ...
Degen Duck's user avatar
0 votes
1 answer
128 views

GET quote on polygon chain using 0x API

I can get quote from ethereum mainnet using this GET api call, the token are WETH and DAI https://api.0x.org/swap/v1/quote?sellToken=0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2&buyToken=...
NRJ's user avatar
  • 73
0 votes
1 answer
287 views

Quote received from 0x swap API returns no valid, unsigned transaction?

I'm trying out the new 0x Fantom integration API, in order to automate some trading tasks. According to this, using the Swap-API from 0x returns a transaction for a quote, which just needs to be ...
JohnnyF's user avatar
  • 103
0 votes
1 answer
232 views

charge commission/fee on every DEX transaction using 0x API

I would Like to charge commission/fee on every DEX transaction using 0x API; i am calling GET /swap/v1/quote with adding feeRecipient & buyTokenPercentageFee but when a user does a tranx via the ...
DAOdAppDev's user avatar
0 votes
1 answer
112 views

Issues removing stake from 0x

When on the 0x website in the staking portion, I can see all my data. When I click the remove button, I get the modal popup asking if I'm sure. I click the "I understand, remove my stake" ...
Jimmy's user avatar
  • 1
0 votes
1 answer
109 views

Integration of 0X (payments and router)

Two questions for the team of 0x.org Can we connect our own router to your system? (same as apeswap and cafeswap did) Can we somehow take payment for the transactions in our coin, not in yours? (...
LewisRobert's user avatar
0 votes
1 answer
85 views

Can not install @0x/asset-swapper with NPM / Yarn. Ends up in error "Error: spawn cargo ENOENT"

When trying to install asset-swapper repo, either via NPM or Yarn, I end up on: "response status 404 Not Found on https://github.com/0xProject/fast-abi/releases/download/0.0.2/node-v83-win32-x64....
LubWn's user avatar
  • 23
1 vote
1 answer
90 views

0x API swap destination address

Looks like there is no way to specify destination address for the swap function, is it so? Is there a way such that the swapped to tokens will be sent to another address, but not the original sender's?...
michaelr524's user avatar
0 votes
1 answer
71 views

0x Kovan API returning 503 responses?

We have been using the Kovan 0x endpoint (https://kovan.api.0x.org/swap/v1) for a few months without trouble, but just started receiving HTTP 503 responses back today. Is the endpoint still supported ...
Mike's user avatar
  • 15
0 votes
1 answer
217 views

Start API Network timeout

I am trying to start local 0x-api(https://github.com/0xProject/0x-api). I first tried starting the api setting Infura Rpc Url in .env . Everything worked great. But I want to use my Local Ethereum ...
xKarma's user avatar
  • 11
1 vote
2 answers
217 views

Failed to swap BEP20 > BNB, WalletExecuteDelegateError

I try to use 0x Swap rest API to swap a token. buyToken=0x0e09fabb73bd3ade0a17ecc321fd13a19e81ce82 sellToken=0x07515f6d56879040b02c4d355df62ec5aede4c7e But i got WalletExecuteDelegateCallFailedError, ...
Wawan Brutalx's user avatar
0 votes
1 answer
1k views

BEP20: transfer amount exceeds allowance

I want to swap bep20 tokens like BUSD - BNB and BNB - BUSD, i already approved tokens for the swapping but while i try to swap BNB - BUSD it's throw error like BEP20: transfer amount exceeds allowance ...
Dharmesh's user avatar
0 votes
1 answer
129 views

I am trying to setup the local 0x-api. (https://github.com/0xProject/0x-api). However I am encountering an error which doesn’t look handled?

When tried to run a local version 0x-api, an internal server error is encountered. How do we overcome this to complete the local setup? Error Message {"level":"info","time&...
Akshay's user avatar
  • 1
0 votes
0 answers
50 views

The remainingFillableTakerAmount of new sell order is zero on Polygon and it lasts a long time

When I sell a order successfully on Polygon, the remainingFillableTakerAmount is zero and it lasts a long time before remainingFillableTakerAmount return to normal value. Now, I can not find the ...
younks zhao's user avatar
0 votes
1 answer
132 views

Using 0x Swap can I build a system that will swap and transfer tokens between two addresses?

I'm hoping to build a system that would let me, in one transaction, transfer ETH from WalletA and receive DAI in Wallet B. Is that possible with 0x Swap or any other 0x product?
ben church's user avatar
0 votes
1 answer
237 views

What are the 0x testnet endpoints?

I’m trying to test the 0x REST api, and can see the endpoints for the main nets, but what about the test nets? Specifically interested in endpoints for Polygon Mumbai and Goerli
Gingertrash's user avatar
1 vote
1 answer
456 views

List of tokens available to trade via Ox API (Avalanche)

I'm trying to trade TEDDY on Avalanche via 0x, when I call the tokens API curl -X 'GET' 'https://avalanche.api.0x.org/swap/v1/tokens' -H 'accept: application/json' I only get AVAX, WAVAX, and WETH, ...
Carlos Reyes's user avatar
0 votes
1 answer
239 views

0x swap quote api - confused about all fees/costs in the different response params

I'm wanting to use the 0x swap quote API but I'm struggling to understand some of the response params. Let's say for example I'm doing an arbitration and I'm starting with 10 WETH, then I sell the ...
havesomejoe's user avatar
0 votes
1 answer
40 views

How to integrate my Pullagable Liquidity Provider to 0x network?

I am thinking of building a Pullagable Liquidity Provider. How can I supply that liquidity to the 0x network? Do I need permission to integrate it so that the official 0x API can sample my PLP's data? ...
Query's user avatar
  • 1
0 votes
1 answer
307 views

How can I fill order from my contract by using V4 API and contract?

I'm trying to fill order from my contract by using 0x V4 API and contract on Mainnet. So far I'm guessing that I should call batchFill function in this contract. https://etherscan.io/address//...
Taka Suzuki's user avatar
0 votes
1 answer
51 views

How to fix it? It’s about 0x API

I’m waiting online. It’s urgent
ethcrazy's user avatar
0 votes
1 answer
80 views

The websokcet api on Polygon about 0x

I find only the mainnet has the websockt api, now I want to use the websocket of Polygon, but I can not find it So, only the mainnet has the websockt api?
younks zhao's user avatar
0 votes
1 answer
291 views

0x API returns invalid result

We've noticed that in one edge case the 0x API returns a weird result. We're trying to get a swap transaction for the exact same token, it works with sellAmount 0.1 BNB but fails with sellAmount of 0....
Nico's user avatar
  • 1
0 votes
1 answer
110 views

Validation failed, creating limit order on BSC. 0x

We've tried multiple times to create a limit order (SRA) on BSC and every time receives this: {code: 100, reason: "Validation Failed", validationErrors: []} Our order: { "chainId&...
Ilia's user avatar
  • 1
1 vote
3 answers
714 views

How to get a quote and swap on 0x with ethers.js

I'm trying to make a simple swap from 10 USDC to 10 USDT using 0x API quote. I'm doing this: import type { UnsignedTransaction } from '@ethersproject/transactions' import { Web3Provider } from '@...
v1rtl's user avatar
  • 11
0 votes
1 answer
205 views

0x Websocket on ropsten

I try to use it on ropsten testnet with below code but i never get any message from the server. Does 0x websocket not support ropsten, or is anything wrong in my code? const socket = W3CWebSocket('wss:...
Sascha's user avatar
  • 1