Propose a customer conversion or closing rate sheet bound to a retained publication
/ledger/fx/rate-sheetsFresh treasury staff with ledger:treasury:write and an Idempotency-Key bound to the exact sheet. Every line's usd_per_foreign_major must equal the named snapshot's derived rate (no typed rates), lines are sorted and unique, and the snapshot must be the latest retained from its source on or before business_date and at most five days old. A customer_conversion sheet is for the current business date, valid for at most 24 hours, with spreads of 0 to 1000 basis points, a per-conversion limit per line and a daily per-customer limit, and only in currencies the ledger holds; a closing_revaluation sheet carries mid rates for a current or past business date. Proposals publish ledger.fx_rate_sheet.proposed.
Headers
Idempotency-KeystringRequiredSend on every write that creates or changes money or state; a replay with the same key returns the original result with 200.
Body parameters
business_datestring · dateRequiredA business date, YYYY-MM-DD
daily_customer_limit_usd_minorintegerOptionalevidencestringRequiredlinesarray of objectsRequired5 child attributes
currency_codestringRequiredcustomer_buy_spread_bpsintegerOptionalThe customer buys the currency: ask = mid × (1 + bps/10000)
customer_sell_spread_bpsintegerOptionalThe customer sells the currency: bid = mid × (1 − bps/10000)
max_conversion_usd_minorintegerOptionalusd_per_foreign_majorstringRequiredpolicy_referencestringRequiredpurposestringRequiredrate_snapshot_idstringRequiredvalid_fromstring · date-time or nullOptionalvalid_untilstring · date-time or nullOptionalReturns
200 OK
actorstringRequiredatstring · date-timeRequiredbusiness_datestring · dateRequiredA business date, YYYY-MM-DD
content_sha256stringRequireddaily_customer_limit_usd_minorintegerOptionaldecisionobject or nullOptional5 child attributes
actorstringRequiredapprovebooleanRequiredatstring · date-timeRequiredcontent_sha256stringRequiredevidencestringRequiredevidencestringRequiredidstringRequiredlinesarray of objectsRequired5 child attributes
currency_codestringRequiredcustomer_buy_spread_bpsintegerOptionalThe customer buys the currency: ask = mid × (1 + bps/10000)
customer_sell_spread_bpsintegerOptionalThe customer sells the currency: bid = mid × (1 − bps/10000)
max_conversion_usd_minorintegerOptionalusd_per_foreign_majorstringRequiredpolicy_referencestringRequiredpurposestringRequiredrate_snapshot_idstringRequiredrate_snapshot_sha256stringRequiredstatusstringRequiredProposed, approved or rejected
valid_fromstring · date-time or nullOptionalvalid_untilstring · date-time or nullOptionalErrors
Every error is a problem document with a stable code. See Errors.
400401403404409412413422424429500503