Questions tagged [0x]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
56 views

0x Protocol | Getting error when validating Order: execution reverted: Wrong trade direction

I'm trying to make an Sellorder to sell NFT's against ERC20 tokens. I can generate the r,s and v signatures, and the orderstatus is checking to true (logs "1" in the console). But when ...
Sdev's user avatar
  • 11
0 votes
1 answer
172 views

How to swap tokens using 0x using smart contracts only.?

I am building an dApp and want to integrate 0x in the smart contract directly instead of me depending on the http request and passing that. Is there a way to implement 0x directly from the smart ...
Tushar Tapadia's user avatar
0 votes
0 answers
41 views

All transactions sent are duplicated

As the title says, every transaction I send through the window.ethereum object injected by metamask is duplicated. Currently I am trying to send one transaction to set the token allowance for a swap ...
user107167's user avatar
0 votes
1 answer
63 views

How is the gas information transmitted into Metamask signing transaction on Polygon?

we are building a swap tokens feature using your API to get the quotes data. The reason is the inability to provide adequate gas value to Metamask on Polygon (other chains work fine) We wonder how ...
user109328's user avatar
0 votes
0 answers
87 views

How can I deploy 0x contract?

How can I deploy 0x contract with remix IDE? I cloned GitHub repository and compiled ZeroEx.sol but I don't know what is bootstrapper address. Please tell me how to fully deploy 0x contract.
Allen He's user avatar
0 votes
0 answers
27 views

execution reverted when direction (enum) (uint8) = 1 | 0x Protocol | getERC1155OrderInfo

def get_order_info(order): function_signature = web3.Web3.keccak(text=f'getERC1155OrderInfo(({",".join(erc1155_order_field_types)}))').hex()[:10] encoded_args = eth_abi.encode_abi(...
Davidedaji's user avatar
1 vote
0 answers
55 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-...
2501 helvetica's user avatar
0 votes
1 answer
44 views

Find breakdown of quotes & fees

good day! I'm exploring the 0x API documentation but wasn't able to find the clear reference, but I'm wondering how can we know the fees breakdown especially related different/multiple liquidity ...
Elli Anto's user avatar
1 vote
0 answers
51 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 = { &...
Davidedaji's user avatar
0 votes
0 answers
54 views

0x protocol - use /swap/v1/quote in executeMetaTransaction

I'd like to use the 0x swap api and execute the returned orders in a meta transaction. Is it possible to use the data returned by GET /swap/v1/quote for executing a meta transaction? I also discovered ...
anonym111's user avatar
1 vote
1 answer
303 views

How to swap using 0x from a smart contract without using the API?

Is it possible for a smart contract to swap using 0x without receiving the calldata from outside? I know how to make my deployed contract to swap with 0x by creating a fillQuote function and passing ...
lewa's user avatar
  • 11
0 votes
2 answers
268 views

How to resolve insufficient asset liquidity in 0x on polygon mumbai testnet

I am testing the 0x api to get quote on Mumbai testnet. I want to swap BAL -> wETH. https://mumbai.api.0x.org/swap/v1/quote?buyToken=0x2e3A2fb8473316A02b8A297B982498E661E1f6f5&sellToken=...
Rishabh Raghwendra's user avatar
0 votes
0 answers
51 views

0x Api is giving an internal server error, is the issue on my end?

Trying to do a swap from ETH -> AAVE Swapping any amount over 1 ETH, doesn't work. For example: https://api.0x.org/swap/v1/quote?slippagePercentage=0.5&sellToken=ETH&buyToken=...
Esaul's user avatar
  • 1
0 votes
1 answer
51 views

Why 0x is showing different buyAmount for selling at same price

I am working on a project in which I am converting ETH -> DAI and then DAI -> ETH. Since the market is bearish right now, so when I am selling 1 Eth for DAI it's giving me 1573.0360852806744 DAI ...
Rishabh Raghwendra's user avatar
0 votes
1 answer
156 views

0x quote request failing code 105

any time I submit a quote request to the 0x API with the taker address specified I get the following message: {"code":105,"reason":"SenderNotAuthorizedError","values&...
user107167's user avatar
1 vote
1 answer
118 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, ...
Rhubear's user avatar
  • 11
1 vote
0 answers
63 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 ...
0xParty.rocks's user avatar
0 votes
2 answers
75 views

0x swap quote API not giving quote with SHIBA INU token

Tried 0x swap quote API GET /swap/v1/quote to sell the SHIBA INU tokens but it is not working. Although working for other tokens like USDT, DAI, etc. Query params I used: With symbol https://api.0x....
chakshu jain's user avatar
1 vote
1 answer
59 views

How buyTokenPercentageFee is calculated in 0x

I am using a 0x Quote API to convert BUSD to USDC by exploring the feeRecipient and buyTokenPercentageFee but have confusion in the calculation. Initial Quote without buyTokenPercentageFee Request ...
Gourav's user avatar
  • 33
0 votes
1 answer
116 views

0x swap quote gives "gas estimation failed error" on ropsten testnet even though I have enough funds

I'm using 0x swap quote api to convert my WETH -> UNI token. 0x swap quote gives "gas estimation failed error" on ropsten testnet even though I have enough funds. The 0x swap price gives ...
Aneesha Kota's user avatar
0 votes
0 answers
49 views

Is it possible to deploy these contracts ourselves or can we get solidly merged on fantom for the protocol?

In short we use the opensourced API to support more uniswapv2 Dexs than the dev team was able to pick up for multiple chains as many smaller level dexs are missed. One of those bigger ones was solidly ...
Krunal Amin's user avatar
0 votes
1 answer
25 views

Is it possible to ask for a minimal depth for quotation and swap?

I'm using 0x. The documentation is great, but a field depth looks missing. It's probably not implemented, but I still ask the question. Suppose I want a very quick quotation for WETH -> USDT I ...
Nicolas Zozol's user avatar
0 votes
2 answers
135 views

0x Protocol API - Polygon (Mumbai)

The 0x Protocol API Endpoint for Polygon (Mumbai) doesn't seem to work. curl --location --request GET 'https://mumbai.api.0x.org/swap/v1/quote?buyToken=0xcB1e72786A6eb3b44C2a2429e317c8a2462CFeb1&...
Shreyas Agarwal's user avatar
0 votes
0 answers
59 views

How do I parse errors returned by 0x?

I'm new to solidity and trying to understand how to parse errors return by 0x protocol: https://github.com/0xProject/protocol/blob/main/contracts/zero-ex/contracts/src/features/native_orders/...
theluckyemil's user avatar
1 vote
1 answer
46 views

Invalid orders returned from 0x orderbook endpoint?

can someone help to explain the small remainingFillableTakerAmount for the following order hash: 0x886618b8da6aa22193ddffc6cfc7d89782a16a7dea9cd698dacb82b8b7e430f9: maker: ...
Walodja1987's user avatar
0 votes
1 answer
52 views

Can we take the fees from seller and not buyer in 0x v4?

In v4 it was introduced that fees are paid by the buyer, denominated in the asset paid by the buyer, and are paid in addition to the erc20TokenAmount specified in the order. https://docs.0x.org/nft-...
Ashish Mittal's user avatar
0 votes
2 answers
54 views

Swap bundles in 0x Protocol

Do you know if future updates of the protocol will allow to swap NFT bundles as in version V3 of the protocol? I would be very interested in that functionality but I can't use the v3 version because ...
Juli's user avatar
  • 1
0 votes
1 answer
40 views

0x orders endpoint pagination

I was reading the documentation page about the /orders endpoint and couldn't find how they are sorted. It's not clear how to avoid requesting all pages to get new orders.
theluckyemil's user avatar
0 votes
1 answer
72 views

What are the possible ways of integrating(on chain) a custom smart contract with 0x?

Dont want to depend upon web api based fetching quotes for swapping, rather swap completely on chain. But the 0x doc mentions:-
waverune's user avatar
0 votes
1 answer
74 views

When using buyAmount, is the sellAmount returned by the API the max that can be sold?

I'm running into some issues trying to swap when specifying buyAmount. Specifically, I'd like to set my allowance to exactly sellAmount returned by the API before doing a swap, but I'm getting "...
Kevin Ji's user avatar
  • 135
0 votes
1 answer
34 views

Does 0x limit order has a "Max Orders" limitation?

1inch has a max 100 order limitation, does 0x has the same setting
Panda's user avatar
  • 1
0 votes
1 answer
51 views

0x - Orders are not mutually fillable on insufficient approval

I've encountered the following issue that I'm not able to solve myself. I'd appreciate any help from the 0x dev community. Let's say a user is creating two buy limit orders: makerAmount: 1 USDC, ...
Walodja1987's user avatar
0 votes
1 answer
65 views

0x API Quote estimatedPriceImpact unit

What is a unit of estimatedPriceImpact, as the field isn't added to the documentation? I'm asking because we want to display the percentage For example, I receive from API 0,0072, so what should I ...
w1n1ar's user avatar
  • 3
0 votes
1 answer
31 views

Using node.js to get LimitOrders from 0x v4 API: once I've selected an order to fill, how do I proceed to call fillLimitOrder?

After getting all the orders from the v4 REST API and going through them, supposing that I have found an order I would like to fill, what do I need to do from this point to successfully call ...
Paul Wardrip's user avatar
0 votes
2 answers
249 views

0x API: Invalid Signature

I found out how to sign an approval into Metamask,in conformity with EIP712: const domain = [ { name: "name", type: "string" }, { name: "version", type: "...
Spart's user avatar
  • 1
0 votes
3 answers
79 views

0x batchFillLimitOrders not working with small remainingFillableTakerAmount

I am experiencing issues filling orders using the batchFillLimitOrders function when the remainingFillableTakerAmount is small. I am calling the following piece of code using the input parameters ...
Walodja1987's user avatar
0 votes
0 answers
292 views

every time i ran command line Yarn as instructed i get all those Error? why it does thise i have no idea. @0x

I Have all those error i dont know the reason of? PS C:\Users\FCRF1\Desktop\0xQQ\0x-api> yarn >> yarn install v1.22.19 warning ..\..\..\package.json: No license field [1/4] Resolving packages....
QQQ's user avatar
  • 1
0 votes
2 answers
81 views

Funds stucked in smart contract

I have a question. So there is a project named StarsLab that had it's mint live in the beginning of this year. They started first the WL sale. I wasn't WL but was able to mint so reported it to the ...
Nils's user avatar
  • 1
0 votes
1 answer
454 views

Is there an API to fetch collection-level NFT stats from 0x orders like floor price, total volume, etc?

Opensea and Looksrare offer collection-level NFT stats API endpoints (i.e. https://docs.opensea.io/reference/retrieving-collection-stats and https://looksrare.github.io/api-docs/#/Collections/...
coffee-converter's user avatar
0 votes
0 answers
128 views

Trying to swap into MATIC -- when fee % > 0 revert, when fee % = 0 success -- WalletExecuteDelegateError

Hi having some issues with a swapper I am working on, I can freely swap from WETH/MATIC to a bunch of various tokens, however when trying to do swap INTO MATIC I get a revert with data starting in ...
Ongaz's user avatar
  • 1
0 votes
1 answer
126 views

Unable to validate signature using validateERC721OrderSignature(order, signature) function on the ERC721OrdersFeature.sol contract (0xv4)

We are building a NFT marketplace using the 0xv4 NFT contracts. We successfully completed integrations for onchain order processing, but are having a difficulty with offchain order processing. We ...
Omar Farooq's user avatar
0 votes
2 answers
227 views

Is there any open source of NFT Marketplace using 0x Protocol?

I have worked on several NFT Marketplaces using Solidity before. Now I am going to build MVP NFT Marketplace using 0x protocal. Can you help me how to find the open source (with document hopefully) ...
Akachi1325's user avatar
0 votes
1 answer
96 views

Response time, Rate limit and decodedUniqueID

I just found out about 0x and therefore have a few questions: Using the https://bsc.api.0x.org/swap/v1/quote API endpoint, I'm experiencing a big variation in response time, usually between 400ms and ...
user101817's user avatar
0 votes
0 answers
133 views

hardhat: <functionName> is not a function while using proxy

I'm trying to deploy and register functions to the proxy, using hardhat (in this case, zeroEx). And when I registered the "migrate" function to zeroEx, await initialMigration....
ryan's user avatar
  • 1
1 vote
1 answer
56 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.
NFA's user avatar
  • 11
0 votes
1 answer
202 views

0x Orderbook Explained

I'm trying to query the USDC/WETH orderbook for the best bid and ask. However, I don't think the response data makes much sense. There is a makerAmount and takerAmount. Does this mean that to interact ...
Alex Agrawal's user avatar
0 votes
1 answer
116 views

importing qs to a html/javascript page

I'm experimenting with 0x samples. I'm not a back-end dev so I'm NOT running NodeJS. I don't want to go full blown ReactJS on it so I built this html wrapper for the example 0x code for retrieving a ...
Orbit Mechanic's user avatar
0 votes
2 answers
63 views

Can i build an NFT marketplace on 0x api

I just saw 0x.org today it looks interesting, i am working on an NFT marketplace on Polygon, your docs looks familiar as to what i am working on. so i want to know, if i can build an NFT marketplace ...
gelgit's user avatar
  • 1
0 votes
1 answer
144 views

How to implement features(e.g. ERC721OrdersFeature) into 0x proxy

I want to integrate with 0x-protocol v4 for trading ERC20 Token <-> ERC721 Token & ERC1155 Token, and I want to deploy it myself. I have deployed 0xProxy, 0x Proxy Governor, and other ...
ryan's user avatar
  • 1
0 votes
1 answer
87 views

0x api: how to set specific receiver address on quote interface?

in our project,i wanna specific a address to receive all tx tokens,but i cant find any params about this. 0xapi quote
hongxue fu's user avatar