docs(openapi): correct exchangeRate example to match documented basis (PROD-54)#630
docs(openapi): correct exchangeRate example to match documented basis (PROD-54)#630ls-bolt[bot] wants to merge 1 commit into
Conversation
… (PROD-54) The exchangeRate field on the /exchange-rates ExchangeRate schema is documented as 'Number of sending currency units per receiving currency unit', but the examples showed destination-per-source values (USD->INR 82.50, USD->EUR 0.925), the inverse of both the field description and the live API. Correct the examples to the documented basis (sending units per receiving unit) and keep each response example internally consistent with its sendingAmount and receivingAmount: USD->INR 0.012121 (= 1/82.50, $100 -> 8250 INR), USD->EUR 1.081081 (= 1/0.925, $100 -> 92.50 EUR, receivingAmount 18500 -> 9250).
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
This stack of pull requests is managed by Graphite. Learn more about stacking. |
✱ Stainless preview builds for gridThis PR will update the cli go kotlin php ruby Edit this comment to update them. They will appear in their respective SDK's changelogs. ⏳ grid-typescript studio⏳ grid-openapi studio⏳ grid-ruby studio⏳ grid-go studio · code · diff
⏳ grid-kotlin studio⏳ grid-python studio⏳ grid-csharp studio⏳ grid-php studio⏳ grid-cli studio⏳ These are partial results; builds are still running. This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push. |
… (PROD-54) (#631) ## Summary The `exchangeRate` field on the `/exchange-rates` `ExchangeRate` schema is documented as **"Number of sending currency units per receiving currency unit"**, but the examples were showing the inverse (destination-per-source) direction — contradicting both the field description and the live API: - `ExchangeRate.yaml` schema example: USD→INR `82.50` - `allRatesFromUSD` response example: USD→INR `82.50`, USD→EUR `0.925` The live API returns `~0.01` for USD→INR, confirming the field is sending-units-per-receiving-unit. This is a docs-only example fix — the API itself is correct (confirmed by the ticket owner on PROD-54). ## Changes Corrected the examples to the documented basis, keeping each response example internally consistent with its `sendingAmount`/`receivingAmount`: | Corridor | Before | After | Basis check | |----------|--------|-------|-------------| | USD→INR `exchangeRate` | `82.50` | `0.012121` | `1/82.50`; $100 → ₹8,250 (receivingAmount 825000) ✓ | | USD→EUR `exchangeRate` | `0.925` | `1.081081` | `1/0.925`; $100 → €92.50 | | USD→EUR `receivingAmount` | `18500` | `9250` | €92.50 at the corrected rate ✓ | Files: - `openapi/components/schemas/exchange_rates/ExchangeRate.yaml` - `openapi/paths/exchange-rates/exchange_rates.yaml` - `openapi.yaml` + `mintlify/openapi.yaml` (regenerated via `make build`) ## Scope note PROD-54 was split out of PROD-50 (the broader exchange-rate basis cleanup). The many `exchangeRate` examples in the narrative Mintlify docs (`0.92`, `17.25`, etc.) share the same directional inconsistency but are tracked under PROD-50 and intentionally **out of scope** here. The `Quote.yaml` `exchangeRate` field shares the same description but has no example, so nothing to fix there. ## Test plan - `make build` — rebundles cleanly - `make lint-openapi` — 0 errors (pre-existing warnings/infos on unrelated schemas only) - Verified each corrected example is internally consistent with its `sendingAmount`/`receivingAmount` Fixes PROD-54 Slack thread: https://lightsparkgroup.slack.com/archives/D0AHP8H9E13/p1782750571018079 --- 🤖 [volatile-relay](https://zeus.dev.dev.sparkinfra.net/#/arc?id=volatile-relay)[(#1)](https://zeus.dev.dev.sparkinfra.net/#/instance?id=volatile-relay) | [Feedback](https://zeus.dev.dev.sparkinfra.net/feedback) Original PR: #630

Summary
The
exchangeRatefield on the/exchange-ratesExchangeRateschema is documented as "Number of sending currency units per receiving currency unit", but the examples were showing the inverse (destination-per-source) direction — contradicting both the field description and the live API:ExchangeRate.yamlschema example: USD→INR82.50allRatesFromUSDresponse example: USD→INR82.50, USD→EUR0.925The live API returns
~0.01for USD→INR, confirming the field is sending-units-per-receiving-unit. This is a docs-only example fix — the API itself is correct (confirmed by the ticket owner on PROD-54).Changes
Corrected the examples to the documented basis, keeping each response example internally consistent with its
sendingAmount/receivingAmount:exchangeRate82.500.0121211/82.50; $100 → ₹8,250 (receivingAmount 825000) ✓exchangeRate0.9251.0810811/0.925; $100 → €92.50receivingAmount185009250Files:
openapi/components/schemas/exchange_rates/ExchangeRate.yamlopenapi/paths/exchange-rates/exchange_rates.yamlopenapi.yaml+mintlify/openapi.yaml(regenerated viamake build)Scope note
PROD-54 was split out of PROD-50 (the broader exchange-rate basis cleanup). The many
exchangeRateexamples in the narrative Mintlify docs (0.92,17.25, etc.) share the same directional inconsistency but are tracked under PROD-50 and intentionally out of scope here. TheQuote.yamlexchangeRatefield shares the same description but has no example, so nothing to fix there.Test plan
make build— rebundles cleanlymake lint-openapi— 0 errors (pre-existing warnings/infos on unrelated schemas only)sendingAmount/receivingAmountFixes PROD-54
Slack thread: https://lightsparkgroup.slack.com/archives/D0AHP8H9E13/p1782750571018079
🤖 volatile-relay(#1) | Feedback