Questions tagged [0x]
The 0x tag has no usage guidance.
164
questions with no upvoted or accepted answers
2
votes
0
answers
86
views
How to really encode dynamicall length array of structs in Solidity ? Or how to use the Muliplex Feature of 0x?
I need to use the Multiplex Feature of 0x in order to perform a specific trade that perform a UniswapV3 call followed by a _FillOTCorder using the SelfBalance feature of the the Multiplex Feature.
As ...
2
votes
0
answers
92
views
ZIPPO_CONTEXT_INVALID error when querying 0x mumbai api quote endpoint
When querying the following endpoint and parameters: https://mumbai.api.0x.org/swap/v1/quote?sellToken=0xA6FA4fB5f76172d178d61B04b0ecd319C5d1C0aa&buyToken=...
2
votes
1
answer
176
views
Reducing CallData Size
I have an implementation where I'm needing to send 0x parameters (from the API) to a swap function that's being used in another function's logic.
To pass the data over a struct is being used, which is ...
2
votes
1
answer
199
views
Tracking orders on 0x network
How are the various 0x network order trackers sourcing on-chain settlement data?
My first assumption was that they were utilising the Etherscan API, however Etherscan have their own tracker, found at ...
1
vote
0
answers
40
views
Any example of a transaction where `feeRecipient` is used in 0x
I need to see what these transactions look like on Etherscan, but can't find any examples. Seems to be very rare. Some transaction hash of such transaction where feeRecipient is receiving some small ...
1
vote
1
answer
149
views
Why did 0x swap API get deprecated and what is its substitute?
0x swap API was a great project that was under active development for several years. But recently it got deprecated and no longer kept up to date. I could not find any other substitute for it on the ...
1
vote
0
answers
30
views
What are those trx periodically being sent to the zero address
An example of such trx is the following (0x1c22498f94934e18b32f2fdb00d8bf091af7cd77e8aeea0191f21efc211aeebc) in particular they have a calldata which UTF-8 decoding looks like 'data:application/json,{&...
1
vote
0
answers
138
views
0x protocol swap api not fetching liquidity from pancakeswap
I created a liquidity pool on pancakeswap for an asset pair for goerli network. I get this error when i try and fetch the price.
here is the api request
https://goerli.api.0x.org/swap/v1/price?...
1
vote
0
answers
66
views
Decode FillQuoteTransformer data in 0x Protocol
I'm trying to decode FillQuoteTransformer input data for 0x protocol. I'm able to decode other transformer very well but am stuck with this one. It does technically decode the data but I'm not sure ...
1
vote
0
answers
33
views
0x ExchangeProxy addresses point to different implementations on Ethereum and Polygon
Why is it that on ethereum the 0xDef1C0ded9bec7F1a1670819833240f027b25EfF contract is a ERC1155OrdersFeature and on Polygon it is a ERC721OrdersFeature? Does is mean that there is no ERC1155 support ...
1
vote
1
answer
36
views
Does 0x still have the condensed RFQ order type, and if so where is its structure defined?
I am looking into the 0x docs at the moment, and get a 404 error when attempting to view the RFQ order type structure in the cheat sheet section. Where can I find this order type's struct?
Thanks!
1
vote
0
answers
53
views
CORS Issue with the /quote 0x API endpoint
I'm a new web2 fullstack web dev trying to get his feet in web3 and i've tried to create my first web3 dApp.
For the profile section and displaying a users' NFT and tokens balances I easily managed my ...
1
vote
1
answer
32
views
0x swap Expected quote.orders to conform to schema /signedOrdersSchema
Hi i should like to know if the fonction "swapQuoteConsumer.executeSwapQuoteOrThrowAsync(quote,{opt})" is depreciated in 0x protocol V4 or not ? i have a perdsistent "error Expected ...
1
vote
1
answer
311
views
Call Requests Limit
I made a bot swap on bsc network using 1inch 0x and para swap.. everything is great except one thing which is Call requests I can’t make call every 1 sec for more than 1 token when make 2 tokens my ip ...
1
vote
1
answer
111
views
0x swap api gas is doubled when adding feeRecipient and buyTokenPercentageFee
I would like to collect fees on trade using 0x API. But the gas in the quote response is doubled or more when adding feeRecipient and buyTokenPercentageFee which doubles the gas price users are paying....
1
vote
2
answers
73
views
Wallet Integration with 0x
We are building a decentralized wallet. There are some questions about the integration with 0x.
Is there any direct way to add fee
If there is any API parameters to add fee.
Please share your ...
1
vote
0
answers
139
views
0x API buy USDC with ETH works, buy ETH with USDC fails
have been building a little front end app to execute trades back and forth between ETH and USDC, partly to learn and partly to build a tool I want to exist.
I have all the quotes and stuff working OK, ...
1
vote
1
answer
45
views
Customize 0x API to get more details
we are testing the 0x API our goal is to get more details, like the top 5 rates along with the best rate also routing information
can anyone point me in the right direction, please
by default, it only ...
1
vote
0
answers
102
views
Is there an API to create/remove Liquidity Pools on different DEXes?
I'm looking for a way to automate liquidity allocation into the most profitable pools,
for this, I need the ability to create/remove liquidity pools on the most popular DEXes.
At a low level to do ...
1
vote
1
answer
58
views
Problem using 0x polygon API - 500 - reason: 'relation "valid_signed_orders_v4" does not exist'
I am attempting to use the 0x Orderbook API for Polygon. I think there might be an issue with the API though, as whilst I remember it previously working, it doesn't seem to be anymore.
I'm getting the ...
1
vote
1
answer
648
views
Selling tokens with fees on Uniswap
I'm attempting to sell a token (0xC5a9BC46A7dbe1c6dE493E84A18f02E70E2c5A32) with fees (5% buy and sell) using the 0x: Exchange Proxy but the transaction fails with Uniswap K. This is the url I'm using ...
1
vote
0
answers
43
views
Receiving affiliateFee in sellToken instead of buyToken
I'm currently implementing 0xRouter into my app and encountered a hurdle.
How can I deduct the fee of a trade from sellToken and not receive it in the form of buyToken? The main use for this is, if a ...
1
vote
0
answers
75
views
setup the local 0x-api. internal server error in Order Watcher
I'm tring to deploy 0x-api locally, when I use the api /orderbook/v1/order to create an order, I got the 500 Internal Server Error, the error log is :
req: {
"id": "bbce499b-61f8-...
1
vote
0
answers
78
views
Build and Sign a 0x Erc1155 order with python
I would like to use the 0x protocol to post orders through the backend of a protocol that uses 0x.
The biggest challenge here for me is to correctly sign an order with python web3 library.
order = { &...
1
vote
1
answer
295
views
Looking for a Python way to query ETH chain LAST prices
I have no need for a smart contract or dApp. Using a local Python script, I just want to query different asset prices on ETH/EVM chains. No trading.
Querying the ETH chain seems very complicated, ...
1
vote
0
answers
94
views
How to use a DEX aggregator in a fund without risking concurrency calls?
I will begin with some context.
I currently building a kind of vault (like enzyme.finance or nested.fi) where an administrator can create a vault and then an investor can deposit fund in the form of a ...
1
vote
1
answer
56
views
Invalid orders returned from 0x orderbook endpoint?
can someone help to explain the small remainingFillableTakerAmount for the following order hash: 0x886618b8da6aa22193ddffc6cfc7d89782a16a7dea9cd698dacb82b8b7e430f9:
maker: ...
1
vote
1
answer
66
views
How can i foward funds swaped from 0x api quotes in the same transaction
ideally i will like to add more logic (like fowarding funds or fees) to the quote.data before letting a user send the transaction to the blockchain.
1
vote
1
answer
211
views
0x Bad request error
since a few days, I am receiving a Bad Request error (status code 400) when trying to sign and submit an order:
ERROR(status code 400): {
"code": 100,
"reason": "...
1
vote
1
answer
125
views
0x-api backend running without swap service
I have to use the '/swap/v1/quote' on Rinkeby testnet but currently, the 0x-API are not supported by default for Rinkeby as mentioned in the documentation. so I was trying to run the backend locally ...
1
vote
2
answers
758
views
How to bubble up meaningful 0x contract revert data?
I'm fairly new to solidity so thanks in advance for your patience with this question.
I'm trying to implement a contract that uses the following line from the 0x sample provided here: https://github....
1
vote
1
answer
48
views
Help regarding website based javascript using 0x for order trades
Hey I apologize in advance, I am very new to a lot of the development regarding this subject. I have written my own erc20 token and was trying to find a way to easily trade it. I am aware of the many ...
1
vote
1
answer
431
views
0x bsc api returning the wrong path for Pancakeswap router v2
I query the api for bsc
https://bsc.api.0x.org/swap/v1/quote?buyToken=0x368ce786ea190f32439074e8d22e12ecb718b44c&sellToken=0xe9e7cea3dedca5984780bafc599bd69add087d56&sellAmount=...
1
vote
1
answer
127
views
Enterprise 0x.org API access
We are currently using 0x API for data analysis, but we are getting blocked by the rate limiter many times.
I tried to search for 0x Enterprise API Access but couldn't find anything...
Does anyone ...
1
vote
3
answers
944
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 '@...
1
vote
2
answers
431
views
Swap problem with big amounts (PancakeSwap liquidity)
I try to swap some tokens and receive BUSD. When I enter the amount 100_000 for my token, API returns the normal price. But it doesnt work when I increase this amount more then 1_000_000. All ...
1
vote
1
answer
120
views
Are there multiple 0x order formats?
I am currently writing an arbitrage bot which fills 0x orders but something that is confusing me is that the 0x order format is not consistent within their documentation.
The order message format ...
1
vote
1
answer
118
views
What is the method to send a transaction with data from solidity?
Sorry for the noob question, but Im trying to understand some definitions and clarify the limits between solidity, web3, etc. I have obtained a tx looking like the following from the 0x API:
b'{"...
1
vote
0
answers
108
views
How to customize my own 0x exchange
I would like to know how my custom ERC721 0x marketplace can be customized.
I know the FAQ has a walkthrough and I already found out how to inject my custom ERC20 token address, symbols etc. but I ...
1
vote
0
answers
183
views
call zeroEx.exchange.fillOrderAsync throw Error: Contract call failed (returned null)
I have created order ,but when I call fillOrderAsync encounter a error.
Contract call failed (returned null),Help me please!
fillOrder.callAsync { from: '0xe9c6f611639f1cb7b23af24a3519385f6b8d4c91',
...
0
votes
0
answers
2k
views
0x API: Am I able to Swap absolutely NEW coins?
I have a trading bot that operates on newly created tokens in BSC and ETH networks. It works only for new tokens, that were created with WBNB (BSC chain with PancakeSwap) or with WETH (ETH chain with ...
0
votes
0
answers
17
views
How Does 0x Protocol Manage Market Impact for Large Limit Orders?
I'm exploring the 0x protocol for decentralized trading and I have a question regarding its handling of large limit orders. I understand that limit orders do not experience slippage by design, as they ...
0
votes
1
answer
769
views
0X Swap failing when swapping Token X for Native Currency Smart Contract Integration
i have a contract that i would like to utilize the zeroEx protocol with
i am calling the qoute endpoint like this
https://bsc.api.0x.org/swap/v1/quote?sellToken=...
0
votes
0
answers
375
views
Execution Reverted: GS013 Error in Safe Wallet During 0x OTC Transaction
I am encountering a 'execution reverted: GS013' error when trying to execute a script that aims to fill an Over-the-Counter (OTC) transaction through Safe Wallet using the 0x protocol. This issue ...
0
votes
0
answers
31
views
getting reverted with reason string 'SWAP_CALL_FAILED' while trying back sell unitymeta Token
const unityMeta = '0xca861e289f04cB9C67fd6b87ca7EAFa59192f164';
const WBNB = '0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c';
const params = {
sellToken: unityMeta,
buyToken: WBNB,
...
0
votes
1
answer
49
views
Verify signature result return 0x
The return signature result from signMessage method obtained is 0x. How do we handle 0x signer result from frontend?
const signer = new ethers.providers.Web3Provider(provider).getSigner();
try {
...
0
votes
0
answers
26
views
Why registerAllowedOrderSigner function doesnt work
i created a limit order. Then what I wanted is to give access to another address who can sign the order on behalf of me.
I called the registerAllowedOrderSigner method from the proxy contract and ...
0
votes
2
answers
205
views
Batch Token Swap using 0x
I'm trying to make a telegram bot that sells all the tokens available on a wallet using Ox API. In order to automate the process with only command, I'm okay with adding the private key to the script.
...
0
votes
1
answer
43
views
How to subscribe to swap events for 0x protocol?
I'm building an nft marketplace and I'm getting the data from reservoir. I have built swap/trade functionality using 0x on my marketplace. I want to now subscribe to swap events on my marketplace. Is ...
0
votes
1
answer
36
views
Too few ERC721 Orders on 0x v4 Exchange
I'm trying to grab information about NFT-to-ERC20 swaps conducted over 0x V4 (on Ethereum). My initial intention was to read ERC321OrderFilled events from https://etherscan.io/address/...