Skip to content

Document 0x Swidge module - #217

Open
ihsraham wants to merge 1 commit into
tetherto:developfrom
ihsraham:feat/0x-swidge-docs-review
Open

Document 0x Swidge module#217
ihsraham wants to merge 1 commit into
tetherto:developfrom
ihsraham:feat/0x-swidge-docs-review

Conversation

@ihsraham

@ihsraham ihsraham commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Document @0x/wdk-protocol-swidge-0x@0.1.0 against the published npm artifact and tagged source.
  • Add install, usage, configuration, API, runtime, and safety guidance for same-chain EVM swaps through the 0x Swap API v2.
  • Integrate 0x into the Swidge navigation and chooser, module feed, changelog, search, and tracked LLM artifacts.

Release references

Contributor review notes

  • quoteSwidge() returns an indicative /price result; swidge() obtains the firm /quote used for execution.
  • Automatic ERC-20 approval can submit an approval before the swap, so the host application must disclose that transaction and verify account receipt support.
  • Fee checks are conditional on returned fields, do not cap fees.integratorFee or a separate approval transaction, and use JavaScript number conversions for fallback calculations.
  • ZeroExUnknownTransactionError can be thrown by status lookup but is not a runtime export.
  • The package declares no Bare engine minimum; a fresh 0.1.0 dependency tree currently requires Bare 1.29.4 or later.

Validation

  • npm run build on Node 22.22.2: 338 static routes, TypeScript passed, LLM artifacts validated, and 0 broken built links.
  • LLM Markdown tests: 20/20 passed; raw-link routing tests: 2/2 passed.
  • Metadata, redirects, navigation order, feed synchronization, and exact four-page LLM mirroring passed.
  • Link scan: 333 source files and 2,761 links, with 0 broken internal, anchor, asset, or external links. npm and authentication-gated URLs produced warning-only 403 responses.
  • Published tarball runtime import and TypeScript consumer checks passed.
  • Served output: four HTML and four Markdown routes returned 200; llms.txt and llms-full.txt remained text/plain; search contains all four 0x routes.
  • Desktop and mobile render checks completed with no console errors, page errors, or failed requests.
  • WDK policy attestation and git diff --check passed for the exact 10-file commit.

Rendered pages

swidge-modules-overview 0x-overview-sidebar 0x-usage-install

Comment thread content/docs/sdk/swidge-modules/swidge-0x/index.mdx Outdated
Comment thread content/docs/sdk/swidge-modules/swidge-0x/api-reference.mdx Outdated
Comment thread content/docs/sdk/swidge-modules/swidge-0x/configuration.mdx Outdated
Comment thread content/docs/sdk/swidge-modules/swidge-0x/configuration.mdx Outdated
Comment thread content/docs/sdk/swidge-modules/swidge-0x/api-reference.mdx Outdated
Comment thread content/docs/sdk/swidge-modules/swidge-0x/api-reference.mdx
Comment thread content/docs/sdk/swidge-modules/swidge-0x/api-reference.mdx Outdated
@ihsraham
ihsraham force-pushed the feat/0x-swidge-docs-review branch from 3c27a19 to 886cf64 Compare August 7, 2026 11:04
@ihsraham

ihsraham commented Aug 7, 2026

Copy link
Copy Markdown
Contributor Author

@jlin27 Thanks for the review. I addressed the comments and rebased onto the latest develop in 886cf64. Could you take another look when you have a chance?

@jlin27 jlin27 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving, docs changes look good to me. Thanks @ihsraham

@ihsraham
ihsraham force-pushed the feat/0x-swidge-docs-review branch from 886cf64 to d80dbd1 Compare August 13, 2026 05:58
@ihsraham
ihsraham marked this pull request as ready for review August 13, 2026 06:07
@ihsraham
ihsraham requested a review from jlin27 August 13, 2026 06:07
@ihsraham

Copy link
Copy Markdown
Contributor Author

@jlin27 @0x/wdk-protocol-swidge-0x@0.1.0 is now published, so I updated the docs against the release artifact and tag, added the publication integrations, and reran the source, link, build, and render checks. The PR is ready for another look: d80dbd1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants