Developer reference
Exchange rates and summaries
Use contextual reference quotes without replacing actual account exchange facts.
Reference rates support a multi-currency reading. They do not guarantee what a bank paid, charged or exchanged for the user.
Quote evidence
A quote needs a base currency, quote currency, rate and observation time. Refresh uses the configured provider and supported pairs. Retained stored rates should not be presented as current merely because they are available.
A failed provider request remains unavailable; a missing pair does not become a one-to-one conversion.
Actual conversion
The conversion command uses actual outgoing and received amounts from their accounts, balanced separately in both currencies. It requires an idempotency key.
For a fictional exchange, moving EGP 1,000 out and receiving USD 20 records those actual amounts. A later reference quote cannot retroactively change that history.
Summary behavior
A combined base-currency answer should retain the conversion basis and completeness notes. Individual account currencies remain meaningful even if the combined answer cannot be computed.
Changing a base-currency preference changes how a summary is read; it does not change the underlying account currency or invent a quote.
Original charges
Foreign purchase evidence also has an original/settled distinction. Use the settled account amount for the money entry and preserve original pricing independently.
Read quote API and money semantics before implementing a conversion UI.