Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ If liquidity is available, 2 objects may be returned:
- `approval`: This is the “approval” object which contains the necessary information to process a gasless approval. See the [quote response](/api-reference/evm-ap-is/gasless/getquote#option-1) for an example.
- If a gasless approval is possible, this object includes all the required information to process it.
- If a gasless approval is **not** possible, this object will be `null`, and you must use the [standard approval flow](/evm/gasless-api/guides/understanding-gasless-api#technical-flow-charts) to [set a token allowance](/evm/0x-swap-api/additional-topics/how-to-set-your-token-allowances). NEVER SET AN ALLOWANCE ON THE SETTLER CONTRACT.
- You can also see all the token addresses that support gasless approvals with the [`/gasless-approval-tokens`](/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens) endpoint.
- Gasless approvals work only for tokens that support [EIP-2612](https://eips.ethereum.org/EIPS/eip-2612). Check the `approval` object in the [quote](https://docs.0x.org/api-reference/evm-ap-is/gasless/getquote) response — if it's not `null`, gasless approval is available for that token.

- `trade`: This is the "trade" object which contains the necessary information to process a gasless trade. See the quote response [here](/api-reference#tag/Gasless/operation/gasless::getQuote).

Expand Down Expand Up @@ -558,8 +558,8 @@ Once the trade is successful, you can display the transaction confirmation to yo

## Gasless Approval Tokens

Use [`/gasless/gasless-approval-tokens`](/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens) to get token addresses that support gasless approvals on each chain.
Gasless approvals work only for tokens that support [EIP-2612](https://eips.ethereum.org/EIPS/eip-2612). Check the `approval` object in the [quote](https://docs.0x.org/api-reference/evm-ap-is/gasless/getquote) response — if it's not `null`, gasless approval is available for that token.

## Gasless Chains

Use [`/gasless/chains`](/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens) to get a list of supported chains for gasless.
Use [`/gasless/chains`](/api-reference/evm-ap-is/gasless/getchains) to get a list of supported chains for gasless.
2 changes: 1 addition & 1 deletion fern/docs/pages/gasless-api/understanding-gasless-api.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Once these steps are complete, the Gasless API will execute the transaction with

Gasless API provides a gasless experience at two points of the trade experience where the user normally needs to pay gas:

- **Gasless approvals** work only for tokens listed in our [Gasless Approval Token endpoint](https://docs.0x.org/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens). These are tokens that support [EIP-2612](https://eips.ethereum.org/EIPS/eip-2612).
- **Gasless approvals** work only for tokens that support [EIP-2612](https://eips.ethereum.org/EIPS/eip-2612). Check the `approval` object in the [quote](https://docs.0x.org/api-reference/evm-ap-is/gasless/getquote) response — if it's not `null`, gasless approval is available for that token.

- **Gasless swaps** work for selling any non‑native token (anything that’s an ERC‑20 or similar).

Expand Down
10 changes: 6 additions & 4 deletions fern/docs/pages/introduction/faq.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ Read more about the contracts [here](/docs/core-concepts/contracts).

Gasless API provides a gasless experience at two points of the trade flow where users normally pay gas:
<ul>
<li><strong>Gasless approvals</strong> work only for tokens listed in our <a href="/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens">Gasless Approval Token endpoint</a> (tokens that support <a href="https://eips.ethereum.org/EIPS/eip-2612">EIP-2612</a>).</li>
<li><strong>Gasless approvals</strong> work only for tokens that support <a href="https://eips.ethereum.org/EIPS/eip-2612">EIP-2612</a>. Check the <code>approval</code> object in the <a href="/api-reference/evm-ap-is/gasless/getquote">quote</a> response — if it's not <code>null</code>, gasless approval is available for that token.</li>
<li><strong>Gasless swaps</strong> work for selling any non-native token (ERC-20 or similar).</li>
</ul>

Expand Down Expand Up @@ -537,9 +537,11 @@ https://api.0x.org/gasless/quote # Request a firm quote
<AccordionGroup>

<Accordion title="What tokens work with gasless approvals?">
Gasless approvals are supported only for tokens listed in the [gasless
approval token
endpoint](https://docs.0x.org/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens).
Gasless approvals work only for tokens that implement
[EIP-2612](https://eips.ethereum.org/EIPS/eip-2612) (`permit`). Check the
`approval` object in the
[quote](https://docs.0x.org/api-reference/evm-ap-is/gasless/getquote) — if
it's not `null`, the token supports gasless approval.
</Accordion>

<Accordion title="How do I know if an approval is required?">
Expand Down
2 changes: 1 addition & 1 deletion fern/docs/pages/upgrading/upgrading-to-gasless-v2.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ With the introduction of the `issues.allowance` field in Gasless API v2, some fi

### Standard Token Approval Flow

In v2, for [tokens that do not support gasless approvals](/api-reference/evm-ap-is/gasless/getgaslessapprovaltokens), use the [standard token approval flow](/evm/0x-swap-api/additional-topics/how-to-set-your-token-allowances).
In v2, for tokens that do not support gasless approvals (i.e. `approval` is `null` in the quote response), use the [standard token approval flow](/evm/0x-swap-api/additional-topics/how-to-set-your-token-allowances).

<Warning>
When using the [Standard Approval Flow](/evm/0x-swap-api/additional-topics/how-to-set-your-token-allowances) (aka Gasless Approvals are not supported)
Expand Down