Repository navigation
docs(routes): show FX values in the swap guide's request samples - #1140
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Nothing blocking. The comments below are optional suggestions. There is no need to push a fix for them before merging.
Beyond the inline finding, I checked two more things and found no problems. The source and destination token addresses match OUSD and EURC.e as listed in src/pages/docs/routes/examples/fx.mdx:17. The curl headers (tempo-api-key, idempotency-key) match the ones used in src/pages/docs/routes/api-setup.mdx and src/lib/routes-execution.ts.
Extended reasoning...
This is a docs-only change to src/pages/docs/routes/fx.mdx, and it touches no security-sensitive code. The token addresses and header names in the new samples agree with other sources in the repo.
There was a problem hiding this comment.
LGTM. This is a docs-only update to the FX guide's request samples, and the latest commit resolves my earlier point about the dummy quote account by telling readers to send their listed account instead.
What was reviewed:
- The token addresses: OUSD is
0x20c0…6a37da5c996874beand EURC.e is0x20c0…1621e21f71cf12fb, which matchesroutes/examples/fx.mdx. That page also says1000000base units is 1 OUSD, so the "1 OUSD" sentence is right. - The endpoint paths (
POST /v1/routes/transfers,POST /v1/prop-amms/<POOL_ADDRESS>/access/prepare) and thetempo-api-keyandidempotency-keyheaders match the existing examples and e2e tests. The request bodies matchexamples/fx.mdx. - Other pages already pass
querytoOpenApi.Playground(for exampleaccounts/fund.mdx). The new code fences usebash [Terminal], and placeholders use<UPPER_SNAKE>. - Not done: I didn't run the build or the Markdown export check. Everything above was checked by reading only.
Extended reasoning...
This change touches one docs page, src/pages/docs/routes/fx.mdx. It prefills the quote playground, replaces two playgrounds with curl examples, and adds one sentence of prose. It doesn't touch any code, auth or other security-sensitive surface. Token addresses, amounts, endpoint paths and headers all match existing repo sources such as routes/examples/fx.mdx and e2e/routes-demo.test.ts. No CODEOWNERS file covers the path, and my only prior comment was addressed in commit f9de8be.
The Swap currencies guide embedded the generic API reference samples, so its request samples showed a cross-chain USDC transfer and a
closePairaccess change instead of an FX swap and a list change.Changes
src/pages/docs/routes/fx.mdx:senderandrecipient, through thequeryprop.setMembersrequest replaces the playground, whose default sample closed a pair.Checks
pnpm check,pnpm check:types,pnpm test,pnpm buildandpnpm check:markdownpass. The built Markdown export shows the FX quote sample.