{"openapi":"3.1.0","info":{"title":"Deaglo R&D API","summary":"FX market data and analytics over HTTP and MCP.","version":"1.5.1"},"paths":{"/api/v1/analytics/carry":{"post":{"tags":["analytics"],"summary":"Annualised carry between a spot and a forward rate.","description":"Annualised carry between a spot and a forward rate.\n\nReturns the carry in basis points and percent for the given tenor.\n\nPorted from rd-api/src/rd_api/providers/forwards.py:59-63.","operationId":"analytics_carry","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CarryRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CarryResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/excel/spot":{"get":{"tags":["excel","market"],"summary":"Indicative spot rate for Excel / spreadsheet clients.","description":"Indicative spot rate for Excel / spreadsheet clients.\n\nQuoted as foreign per base. Not an executable quote. Intended as the cell-facing\ncounterpart of ``market_spot`` (e.g. a future ``=DEAGLO.SPOT`` binding).","operationId":"excel_spot","parameters":[{"name":"base","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"}},{"name":"foreign","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"}},{"name":"side","in":"query","required":false,"schema":{"$ref":"#/components/schemas/Side","default":"MID"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpotRate"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/me":{"get":{"tags":["identity"],"summary":"Who you are, as this service sees you.","description":"Who you are, as this service sees you.\n\nUseful for confirming which credential a client is actually presenting, and what\nauthorization level it carries.","operationId":"whoami","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WhoAmI"}}}}}}},"/api/v1/market/spot":{"get":{"tags":["market"],"summary":"Current spot rate for a currency pair.","description":"Current spot rate for a currency pair.\n\nQuoted as foreign per base. Indicative, not an executable quote.","operationId":"market_spot","parameters":[{"name":"base","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"}},{"name":"foreign","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"}},{"name":"side","in":"query","required":false,"schema":{"$ref":"#/components/schemas/Side","default":"MID"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpotRate"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/market/spot/history":{"get":{"tags":["market"],"summary":"Daily spot rates for a currency pair over a date range.","description":"Daily spot rates for a currency pair over a date range.\n\nBoth dates are inclusive and the series is ordered ascending.","operationId":"market_spot_history","parameters":[{"name":"base","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"}},{"name":"foreign","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"}},{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Start"}},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date","title":"End"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SpotHistory"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/market/forward":{"get":{"tags":["market"],"summary":"Forward rate for a currency pair at a weekly horizon.","description":"Forward rate for a currency pair at a weekly horizon.\n\n`on` defaults to today. Returns bid, ask and mid.","operationId":"market_forward","parameters":[{"name":"base","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"}},{"name":"foreign","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"}},{"name":"horizon_weeks","in":"query","required":true,"schema":{"type":"integer","maximum":520,"minimum":1,"title":"Horizon Weeks"}},{"name":"on","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"On"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForwardQuote"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/market/volatility":{"get":{"tags":["market"],"summary":"Annualised volatility for a currency pair.","description":"Annualised volatility for a currency pair.\n\nComputed from the trailing year of daily spot rates, annualised over 251 sessions.","operationId":"market_volatility","parameters":[{"name":"base","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"}},{"name":"foreign","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"}},{"name":"on","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"On"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VolatilityQuote"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/market/currencies":{"get":{"tags":["market"],"summary":"Supported currencies and their latest USD rate.","description":"Supported currencies and their latest USD rate.","operationId":"market_currencies","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrencyList"}}}}}}},"/api/v1/quickrisk/confirm-conventions":{"post":{"tags":["quickrisk"],"summary":"Validate required pricing conventions before any QuickRisk valuation.","description":"Validate required pricing conventions before any QuickRisk valuation.\n\nFails loud on empty daycount or BUS/252 without a calendar. Does not price.\nProof of concept — constructed data until live curves replace placeholders.","operationId":"quickrisk_confirm_conventions","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmConventionsRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmConventionsResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/legs/floating":{"post":{"tags":["quickrisk"],"summary":"Fair value of a compounded floating (nominal) leg. Not a swap value.","description":"Fair value of a compounded floating (nominal) leg. Not a swap value.","operationId":"quickrisk_price_floating_leg","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FloatingLegRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FloatingLegResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/legs/inflation":{"post":{"tags":["quickrisk"],"summary":"Fair value of an inflation-linked (accreting) leg. Not a swap value.","description":"Fair value of an inflation-linked (accreting) leg. Not a swap value.","operationId":"quickrisk_price_inflation_leg","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InflationLegRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InflationLegResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/legs/hybrid":{"post":{"tags":["quickrisk"],"summary":"Fair value of a hybrid leg that migrates indices mid-life. Not a swap net.","description":"Fair value of a hybrid leg that migrates indices mid-life. Not a swap net.","operationId":"quickrisk_price_hybrid_leg","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HybridLegRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HybridLegResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/swap/net":{"post":{"tags":["quickrisk"],"summary":"Net two pre-valued legs (receive - pay). Only path with is_swap_value=true.","description":"Net two pre-valued legs (receive - pay). Only path with is_swap_value=true.","operationId":"quickrisk_swap_net","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SwapNetRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SwapNetResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/reconcile/currency-gap":{"post":{"tags":["quickrisk"],"summary":"Total embedded margin: fair_pv_net - bank_quote_ours. Always determinable.","description":"Total embedded margin: fair_pv_net - bank_quote_ours. Always determinable.","operationId":"quickrisk_currency_gap","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrencyGapRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrencyGapResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quickrisk/reconcile/term-sheet":{"post":{"tags":["quickrisk"],"summary":"Per-leg decomposition — gated on authoritative_term_sheet (engine gate).","description":"Per-leg decomposition — gated on authoritative_term_sheet (engine gate).","operationId":"quickrisk_term_sheet_decompose","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TermSheetDecomposeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TermSheetDecomposeResultModel"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/diagnostics":{"get":{"tags":["admin"],"summary":"Per-dependency health, breaker states and pool depth.","description":"Per-dependency health, breaker states and pool depth.","operationId":"admin_diagnostics","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Diagnostics"}}}}}}},"/api/v1/admin/auth-cache/purge":{"post":{"tags":["admin"],"summary":"Drop every cached credential for one subject.","description":"Drop every cached credential for one subject.\n\nUse after an out-of-band revocation, or when a level change needs to take effect\nbefore the 60s cache TTL expires. Note there is no equivalent for OAuth tokens\nrevoked platform-side: those are keyed on the token hash, with no subject index, so\nthey expire on their own.","operationId":"admin_purge_auth_cache","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurgeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurgeResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/oauth/start":{"get":{"tags":["auth"],"summary":"Begin the authorization-code flow.","description":"Begin the authorization-code flow.\n\n404s when OAuth is not configured, rather than redirecting somewhere useless.","operationId":"oauth_start","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v1/auth/oauth/callback":{"get":{"tags":["auth"],"summary":"Complete the flow and tell the user they can close the tab.","description":"Complete the flow and tell the user they can close the tab.\n\nRenders a terminal page rather than redirecting. This service owns no frontend, so it\nhas nowhere of its own to send a browser, and the destination it used to use -- a\nsettings page on the platform -- is not this service's to guarantee. When that path\ndoes not exist, a SUCCESSFUL sign-in ends on a 404 and reads as a broken flow.\n\nRendering also disposes of the open-redirect question rather than defending against\nit. No path here emits a Location header, so there is no destination for a\nnext=/return_to to override and nothing for a later change to quietly reintroduce.\n\nEvery outcome is a key into _CALLBACK_OUTCOMES and nothing else -- never a reflected\nupstream message, never a request parameter -- so no attacker-controlled text can\nreach the page.","operationId":"oauth_callback","parameters":[{"name":"code","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"}},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},{"name":"Cookie","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cookie"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/me":{"get":{"tags":["auth"],"summary":"Who the current credential belongs to.","description":"Who the current credential belongs to.","operationId":"auth_me","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WhoAmI"}}}}}}},"/api/v1/auth/tokens":{"post":{"tags":["auth"],"summary":"Mint a long-lived personal access token.","description":"Mint a long-lived personal access token.\n\nThe plaintext is returned exactly once and is never retrievable afterwards. Only an\nOAuth access token may call this, so a PAT cannot mint another PAT.\n\n`ctx` is declared and its principal is NOT used, on purpose. The platform must derive\nthe owner from the forwarded bearer, never from a user id this service supplies — that\nis the impersonation guard (see docs/AUTH.md). Taking ctx forces authentication to\nresolve and names the actor in the audit line; reading ctx.principal.subject and\nsending it to the platform would be the bug.","operationId":"create_token","parameters":[{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenCreateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["auth"],"summary":"List the caller's personal access tokens. No secrets are returned.","description":"List the caller's personal access tokens. No secrets are returned.","operationId":"list_tokens","parameters":[{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/tokens/{token_id}":{"delete":{"tags":["auth"],"summary":"Revoke a token, and purge it from this service's verification cache.","description":"Revoke a token, and purge it from this service's verification cache.\n\nA FAILED cache purge is reported, not swallowed: the revocation is durable on the\nplatform either way, but rd-api may keep honouring the token for up to the cache TTL\nand the operator needs to know that.","operationId":"revoke_token","parameters":[{"name":"token_id","in":"path","required":true,"schema":{"type":"string","title":"Token Id"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenRevokeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/health":{"get":{"tags":["health"],"summary":"Liveness. Touches nothing.","description":"Liveness. Touches nothing.\n\nReturns 200 for as long as the process is alive, regardless of Redis, the platform\nor euthyphro. The target group's matcher is hardcoded to \"200\".","operationId":"health","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Health"}}}}}}},"/live":{"get":{"tags":["health"],"summary":"Liveness probe (alias of /health).","description":"Alias of /health, for tooling that expects this name.","operationId":"live","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Health"}}}}}}},"/ready":{"get":{"tags":["health"],"summary":"Readiness.","description":"Readiness.\n\n200 with {\"ok\": true} when every dependency answers, 503 otherwise. No per-check\ndetail on purpose — see the module docstring.","operationId":"ready","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Ready"}}}}}}},"/version":{"get":{"tags":["meta"],"summary":"Build and runtime metadata.","description":"Build and runtime metadata.\n\nThe deploy smoke test asserts on this: it is the only check that proves the NEW\nimage is serving rather than the previous task-definition revision.","operationId":"version","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Version"}}}}}}},"/meta":{"get":{"tags":["meta"],"summary":"What this service is and how to talk to it.","description":"What this service is and how to talk to it.","operationId":"meta","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceMeta"}}}}}}},"/index":{"get":{"tags":["meta"],"summary":"Public route index.","description":"Public route index.\n\nLists ONLY routes that are themselves unauthenticated. The full inventory, with\nauth modes and limits, is /meta/routes, behind ADMIN.","operationId":"route_index","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RouteIndex"}}}}}}},"/api/v1/meta/routes":{"get":{"tags":["meta"],"summary":"The full route manifest, including auth modes, levels and rate limits.","description":"The full route manifest, including auth modes, levels and rate limits.\n\nThis gate is only meaningful because OpenAPI is disabled in production — otherwise\n/openapi.json is the same reconnaissance with more detail.","operationId":"route_manifest","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RouteManifest"}}}}}}},"/metrics":{"get":{"tags":["meta"],"summary":"Prometheus exposition format.","description":"Prometheus exposition format.\n\nRequires `Authorization: Bearer <metrics_auth_token>`.","operationId":"metrics","parameters":[{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/.well-known/oauth-protected-resource":{"get":{"tags":["well-known"],"summary":"Tell a client which authorization server protects this resource.","description":"Tell a client which authorization server protects this resource.","operationId":"oauth_protected_resource","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProtectedResourceMetadata"}}}}}}}},"components":{"schemas":{"AccretionConventionPayload":{"properties":{"data":{"additionalProperties":true,"type":"object","title":"Data"}},"type":"object","required":["data"],"title":"AccretionConventionPayload","description":"Opaque convention blob matching ir_risk AccretionConvention fields."},"CarryRequest":{"properties":{"spot":{"type":"number","exclusiveMinimum":0.0,"title":"Spot","description":"Spot rate, quoted foreign per base."},"forward":{"type":"number","exclusiveMinimum":0.0,"title":"Forward","description":"Forward rate for the same pair and tenor."},"tenor_weeks":{"type":"integer","maximum":520.0,"minimum":1.0,"title":"Tenor Weeks","description":"Tenor of the forward, in weeks."}},"additionalProperties":false,"type":"object","required":["spot","forward","tenor_weeks"],"title":"CarryRequest"},"CarryResult":{"properties":{"spot":{"type":"number","title":"Spot"},"forward":{"type":"number","title":"Forward"},"tenor_weeks":{"type":"integer","title":"Tenor Weeks"},"carry_bps":{"type":"number","title":"Carry Bps"},"carry_pct":{"type":"number","title":"Carry Pct"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"computed"}},"type":"object","required":["spot","forward","tenor_weeks","carry_bps","carry_pct"],"title":"CarryResult"},"ConfirmConventionsRequest":{"properties":{"daycount":{"type":"string","title":"Daycount"},"compounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Compounding Mode"},"spread_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Spread Mode"},"quote_convention_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quote Convention Id"},"calendar_required":{"type":"boolean","title":"Calendar Required","default":false},"calendar_holidays_count":{"type":"integer","title":"Calendar Holidays Count","default":0},"migration_assumptions_present":{"type":"boolean","title":"Migration Assumptions Present","default":false},"notes":{"additionalProperties":true,"type":"object","title":"Notes"}},"type":"object","required":["daycount"],"title":"ConfirmConventionsRequest"},"ConfirmConventionsResult":{"properties":{"ok":{"type":"boolean","title":"Ok"},"confirmed":{"additionalProperties":true,"type":"object","title":"Confirmed"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["ok","confirmed"],"title":"ConfirmConventionsResult"},"CurrencyGapRequest":{"properties":{"fair_swap":{"$ref":"#/components/schemas/SwapNetResultModel"},"bank_quote_raw":{"type":"number","title":"Bank Quote Raw"},"quote_convention_id":{"type":"string","enum":["already_receive_minus_pay","negate_to_receive_minus_pay"],"title":"Quote Convention Id"},"parameter_source":{"type":"string","title":"Parameter Source","default":"constructed"}},"type":"object","required":["fair_swap","bank_quote_raw","quote_convention_id"],"title":"CurrencyGapRequest"},"CurrencyGapResultModel":{"properties":{"currency_gap":{"type":"number","title":"Currency Gap"},"fair_pv_net":{"type":"number","title":"Fair Pv Net"},"bank_quote_raw":{"type":"number","title":"Bank Quote Raw"},"bank_quote_ours":{"type":"number","title":"Bank Quote Ours"},"quote_convention_id":{"type":"string","enum":["already_receive_minus_pay","negate_to_receive_minus_pay"],"title":"Quote Convention Id"},"provenance":{"additionalProperties":true,"type":"object","title":"Provenance"}},"type":"object","required":["currency_gap","fair_pv_net","bank_quote_raw","bank_quote_ours","quote_convention_id","provenance"],"title":"CurrencyGapResultModel"},"CurrencyList":{"properties":{"count":{"type":"integer","title":"Count"},"currencies":{"items":{"$ref":"#/components/schemas/CurrencyRate"},"type":"array","title":"Currencies"},"as_of":{"type":"string","format":"date-time","title":"As Of"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"euthyphro"}},"type":"object","required":["count","currencies","as_of"],"title":"CurrencyList"},"CurrencyRate":{"properties":{"code":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Code"},"rate":{"type":"number","title":"Rate"}},"type":"object","required":["code","rate"],"title":"CurrencyRate","description":"euthyphro types.CurrencyRate{code, rate}."},"CurveKnot":{"properties":{"tenor_or_date":{"type":"string","title":"Tenor Or Date"},"rate_or_df":{"type":"number","title":"Rate Or Df"}},"type":"object","required":["tenor_or_date","rate_or_df"],"title":"CurveKnot"},"CurveRegistryPayload":{"properties":{"curves":{"items":{"$ref":"#/components/schemas/NamedCurve"},"type":"array","title":"Curves"}},"type":"object","required":["curves"],"title":"CurveRegistryPayload","description":"Caller-supplied curves — never read from a fixed path at call time."},"DailySpot":{"properties":{"date":{"type":"string","format":"date","title":"Date"},"base":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"},"foreign":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"},"rate":{"type":"number","title":"Rate"}},"type":"object","required":["date","base","foreign","rate"],"title":"DailySpot","description":"euthyphro models.DailySpotRate{date, base_currency, foreign_currency, rate}."},"DependencyStatus":{"properties":{"name":{"type":"string","title":"Name"},"ok":{"type":"boolean","title":"Ok"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail"}},"type":"object","required":["name","ok"],"title":"DependencyStatus"},"Diagnostics":{"properties":{"service":{"type":"string","title":"Service"},"tenant":{"type":"string","title":"Tenant"},"environment":{"type":"string","title":"Environment"},"version":{"type":"string","title":"Version"},"dependencies":{"items":{"$ref":"#/components/schemas/DependencyStatus"},"type":"array","title":"Dependencies"},"redis_breaker_open":{"type":"boolean","title":"Redis Breaker Open"},"platform_breaker_open":{"type":"boolean","title":"Platform Breaker Open"},"euthyphro_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Euthyphro Host"},"euthyphro_key_configured":{"type":"boolean","title":"Euthyphro Key Configured"},"identity_provider":{"type":"string","title":"Identity Provider"},"thread_pool_queue_depth":{"type":"integer","title":"Thread Pool Queue Depth"},"fallback_limiter_buckets":{"type":"integer","title":"Fallback Limiter Buckets"}},"type":"object","required":["service","tenant","environment","version","redis_breaker_open","platform_breaker_open","euthyphro_key_configured","identity_provider","thread_pool_queue_depth","fallback_limiter_buckets"],"title":"Diagnostics","description":"Operational detail. Contains NO secret material — asserted by a test."},"FloatingLegRequest":{"properties":{"schedule":{"items":{"$ref":"#/components/schemas/SchedulePeriod"},"type":"array","title":"Schedule"},"curves":{"$ref":"#/components/schemas/CurveRegistryPayload"},"projection_curve_name":{"type":"string","title":"Projection Curve Name"},"discount_curve_name":{"type":"string","title":"Discount Curve Name"},"valuation_date":{"type":"string","title":"Valuation Date"},"compounding_mode":{"type":"string","enum":["daily_compounded","simple"],"title":"Compounding Mode"},"spread_mode":{"type":"string","enum":["multiplicative_annual","additive_to_year_fraction","additive_in_compound","percent_of_index"],"title":"Spread Mode"},"daycount":{"type":"string","title":"Daycount"},"calendar":{"anyOf":[{"$ref":"#/components/schemas/HolidayCalendarPayload"},{"type":"null"}]},"spread":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Spread"},"notional_scale":{"type":"number","title":"Notional Scale","default":1.0},"side":{"type":"string","enum":["receive","pay"],"title":"Side","default":"receive"},"provenance":{"$ref":"#/components/schemas/LegProvenance"}},"type":"object","required":["schedule","curves","projection_curve_name","discount_curve_name","valuation_date","compounding_mode","spread_mode","daycount","provenance"],"title":"FloatingLegRequest"},"FloatingLegResultModel":{"properties":{"pv":{"type":"number","title":"Pv"},"total_coupon":{"type":"number","title":"Total Coupon"},"valuation_side":{"type":"string","enum":["receive","pay"],"title":"Valuation Side"},"provenance":{"$ref":"#/components/schemas/LegProvenance"},"periods":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Periods"}},"type":"object","required":["pv","total_coupon","valuation_side","provenance"],"title":"FloatingLegResultModel"},"ForwardQuote":{"properties":{"base":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"},"foreign":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"},"date":{"type":"string","format":"date","title":"Date"},"horizon_weeks":{"type":"integer","title":"Horizon Weeks"},"bid":{"type":"number","title":"Bid"},"ask":{"type":"number","title":"Ask"},"mid":{"type":"number","title":"Mid"},"as_of":{"type":"string","format":"date-time","title":"As Of"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"euthyphro"}},"type":"object","required":["base","foreign","date","horizon_weeks","bid","ask","mid","as_of"],"title":"ForwardQuote","description":"euthyphro types.ForwardOnDayResponse{base, foreign, bid, ask, mid, date}."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"Health":{"properties":{"ok":{"type":"boolean","title":"Ok"},"service":{"type":"string","title":"Service"},"version":{"type":"string","title":"Version"},"git_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Sha"}},"type":"object","required":["ok","service","version"],"title":"Health"},"HolidayCalendarPayload":{"properties":{"holidays":{"items":{"type":"string"},"type":"array","title":"Holidays"}},"type":"object","title":"HolidayCalendarPayload","description":"Explicit holiday list; required when daycount needs a calendar (e.g. BUS/252)."},"HybridLegRequest":{"properties":{"spec":{"additionalProperties":true,"type":"object","title":"Spec"},"schedule":{"items":{"$ref":"#/components/schemas/SchedulePeriod"},"type":"array","title":"Schedule"},"curves":{"$ref":"#/components/schemas/CurveRegistryPayload"},"calendar":{"anyOf":[{"$ref":"#/components/schemas/HolidayCalendarPayload"},{"type":"null"}]},"index_series":{"$ref":"#/components/schemas/IndexSeriesPayload"},"accretion_convention":{"$ref":"#/components/schemas/AccretionConventionPayload"}},"type":"object","required":["spec","schedule","curves","index_series","accretion_convention"],"title":"HybridLegRequest","description":"HybridInstrumentSpec + schedule/curves/index as data."},"HybridLegResultModel":{"properties":{"pv":{"type":"number","title":"Pv"},"nominal_phase_pv":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nominal Phase Pv"},"inflation_phase_pv":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Inflation Phase Pv"},"provenance":{"additionalProperties":true,"type":"object","title":"Provenance"},"detail":{"additionalProperties":true,"type":"object","title":"Detail"},"periods":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Periods"}},"type":"object","required":["pv","provenance"],"title":"HybridLegResultModel"},"IndexPoint":{"properties":{"period":{"type":"string","title":"Period"},"level":{"type":"number","title":"Level"},"release_status":{"type":"string","enum":["published","projected","unknown"],"title":"Release Status","default":"published"}},"type":"object","required":["period","level"],"title":"IndexPoint","description":"One month: period is YYYY-MM (engine contract)."},"IndexSeriesPayload":{"properties":{"series_id":{"type":"string","title":"Series Id"},"unit":{"type":"string","title":"Unit","default":""},"asof":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asof"},"is_placeholder":{"type":"boolean","title":"Is Placeholder","default":false},"placeholder_warning":{"type":"string","title":"Placeholder Warning","default":""},"source":{"type":"string","title":"Source","default":"request"},"points":{"items":{"$ref":"#/components/schemas/IndexPoint"},"type":"array","title":"Points"},"uses_fabricated_index_series":{"type":"boolean","title":"Uses Fabricated Index Series","default":false}},"type":"object","required":["series_id","points"],"title":"IndexSeriesPayload"},"InflationLegRequest":{"properties":{"schedule":{"items":{"$ref":"#/components/schemas/SchedulePeriod"},"type":"array","title":"Schedule"},"base_index_ref":{"type":"number","title":"Base Index Ref"},"index_series":{"$ref":"#/components/schemas/IndexSeriesPayload"},"convention":{"$ref":"#/components/schemas/AccretionConventionPayload"},"curves":{"$ref":"#/components/schemas/CurveRegistryPayload"},"discount_curve_name":{"type":"string","title":"Discount Curve Name"},"valuation_date":{"type":"string","title":"Valuation Date"},"calendar":{"anyOf":[{"$ref":"#/components/schemas/HolidayCalendarPayload"},{"type":"null"}]},"coupon_rate":{"type":"number","title":"Coupon Rate"},"coupon_daycount":{"type":"string","title":"Coupon Daycount"},"side":{"type":"string","enum":["receive","pay"],"title":"Side","default":"receive"},"provenance":{"$ref":"#/components/schemas/LegProvenance"},"accretion_provenance":{"additionalProperties":true,"type":"object","title":"Accretion Provenance"}},"type":"object","required":["schedule","base_index_ref","index_series","convention","curves","discount_curve_name","valuation_date","coupon_rate","coupon_daycount","provenance"],"title":"InflationLegRequest"},"InflationLegResultModel":{"properties":{"pv":{"type":"number","title":"Pv"},"valuation_side":{"type":"string","enum":["receive","pay"],"title":"Valuation Side"},"provenance":{"$ref":"#/components/schemas/LegProvenance"},"accretion_provenance":{"additionalProperties":true,"type":"object","title":"Accretion Provenance"},"periods":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Periods"},"detail":{"additionalProperties":true,"type":"object","title":"Detail"}},"type":"object","required":["pv","valuation_side","provenance"],"title":"InflationLegResultModel"},"LegProvenance":{"properties":{"valuation_date":{"type":"string","title":"Valuation Date"},"curve_asof":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Curve Asof"},"is_placeholder_curve":{"type":"boolean","title":"Is Placeholder Curve","default":false},"placeholder_warning":{"type":"string","title":"Placeholder Warning","default":""},"projection_curve_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Projection Curve Name"},"discount_curve_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discount Curve Name"},"compounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Compounding Mode"},"spread_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Spread Mode"},"daycount":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Daycount"},"leg_label":{"type":"string","title":"Leg Label"},"is_swap_value":{"type":"boolean","title":"Is Swap Value","default":false},"scope_boundary":{"type":"string","title":"Scope Boundary"},"parameter_source":{"type":"string","title":"Parameter Source"},"parameter_source_detail":{"additionalProperties":{"type":"string"},"type":"object","title":"Parameter Source Detail"},"uses_fabricated_index_series":{"type":"boolean","title":"Uses Fabricated Index Series","default":false},"migration_assumptions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Migration Assumptions"}},"type":"object","required":["valuation_date","leg_label","scope_boundary","parameter_source"],"title":"LegProvenance"},"NamedCurve":{"properties":{"name":{"type":"string","title":"Name"},"asof":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asof"},"is_placeholder":{"type":"boolean","title":"Is Placeholder","default":false},"placeholder_warning":{"type":"string","title":"Placeholder Warning","default":""},"knots":{"items":{"$ref":"#/components/schemas/CurveKnot"},"type":"array","title":"Knots"},"conventions":{"additionalProperties":true,"type":"object","title":"Conventions"}},"type":"object","required":["name"],"title":"NamedCurve"},"PreValuedLeg":{"properties":{"pv":{"type":"number","title":"Pv"},"valuation_side":{"type":"string","enum":["receive","pay"],"title":"Valuation Side"},"kind":{"type":"string","title":"Kind"},"provenance":{"additionalProperties":true,"type":"object","title":"Provenance"},"body":{"additionalProperties":true,"type":"object","title":"Body"}},"type":"object","required":["pv","valuation_side","kind","provenance"],"title":"PreValuedLeg","description":"Pre-valued leg envelope (API-ready: no re-load of global files)."},"ProtectedResourceMetadata":{"properties":{"resource":{"type":"string","title":"Resource"},"authorization_servers":{"items":{"type":"string"},"type":"array","title":"Authorization Servers"},"scopes_supported":{"items":{"type":"string"},"type":"array","title":"Scopes Supported"},"bearer_methods_supported":{"items":{"type":"string"},"type":"array","title":"Bearer Methods Supported"},"resource_name":{"type":"string","title":"Resource Name","default":"Deaglo R&D API"}},"type":"object","required":["resource"],"title":"ProtectedResourceMetadata"},"PurgeRequest":{"properties":{"subject":{"type":"string","maxLength":128,"minLength":1,"title":"Subject"}},"type":"object","required":["subject"],"title":"PurgeRequest"},"PurgeResult":{"properties":{"subject":{"type":"string","title":"Subject"},"purged":{"type":"boolean","title":"Purged"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","required":["subject","purged"],"title":"PurgeResult"},"Ready":{"properties":{"ok":{"type":"boolean","title":"Ok"}},"type":"object","required":["ok"],"title":"Ready"},"RouteEntry":{"properties":{"name":{"type":"string","title":"Name"},"methods":{"items":{"type":"string"},"type":"array","title":"Methods"},"path":{"type":"string","title":"Path"},"summary":{"type":"string","title":"Summary"},"min_level":{"type":"string","title":"Min Level"},"surfaces":{"items":{"type":"string"},"type":"array","title":"Surfaces"}},"type":"object","required":["name","methods","path","summary","min_level","surfaces"],"title":"RouteEntry"},"RouteIndex":{"properties":{"count":{"type":"integer","title":"Count"},"routes":{"items":{"$ref":"#/components/schemas/RouteEntry"},"type":"array","title":"Routes"}},"type":"object","required":["count"],"title":"RouteIndex"},"RouteManifest":{"properties":{"version":{"type":"integer","title":"Version"},"api_prefix":{"type":"string","title":"Api Prefix"},"routes":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Routes"}},"type":"object","required":["version","api_prefix"],"title":"RouteManifest"},"SchedulePeriod":{"properties":{"accrual_start":{"type":"string","title":"Accrual Start"},"accrual_end":{"type":"string","title":"Accrual End"},"pay_date":{"type":"string","title":"Pay Date"},"notional":{"type":"number","title":"Notional"},"compounding_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Compounding Mode"},"spread_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Spread Mode"},"spread":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Spread"},"daycount":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Daycount"},"projection_curve_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Projection Curve Name"},"discount_curve_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discount Curve Name"}},"type":"object","required":["accrual_start","accrual_end","pay_date","notional"],"title":"SchedulePeriod"},"ServiceMeta":{"properties":{"service":{"type":"string","title":"Service"},"tenant":{"type":"string","title":"Tenant"},"environment":{"type":"string","title":"Environment"},"version":{"type":"string","title":"Version"},"public_base_url":{"type":"string","title":"Public Base Url"},"api_prefix":{"type":"string","title":"Api Prefix"},"surfaces":{"items":{"type":"string"},"type":"array","title":"Surfaces"},"auth_modes":{"items":{"type":"string"},"type":"array","title":"Auth Modes"},"mcp_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mcp Endpoint"},"mcp_endpoints":{"additionalProperties":{"type":"string"},"type":"object","title":"Mcp Endpoints"},"docs_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Docs Url"}},"type":"object","required":["service","tenant","environment","version","public_base_url","api_prefix","surfaces","auth_modes"],"title":"ServiceMeta"},"Side":{"type":"string","enum":["BID","ASK","MID"],"title":"Side"},"SpotHistory":{"properties":{"base":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"},"foreign":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"},"start":{"type":"string","format":"date","title":"Start"},"end":{"type":"string","format":"date","title":"End"},"count":{"type":"integer","title":"Count"},"points":{"items":{"$ref":"#/components/schemas/DailySpot"},"type":"array","title":"Points"},"as_of":{"type":"string","format":"date-time","title":"As Of"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"euthyphro"}},"type":"object","required":["base","foreign","start","end","count","points","as_of"],"title":"SpotHistory"},"SpotRate":{"properties":{"base":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"},"foreign":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"},"side":{"$ref":"#/components/schemas/Side"},"rate":{"type":"number","title":"Rate"},"as_of":{"type":"string","format":"date-time","title":"As Of"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"euthyphro"}},"type":"object","required":["base","foreign","side","rate","as_of"],"title":"SpotRate"},"SwapNetProvenanceModel":{"properties":{"swap_label":{"type":"string","title":"Swap Label"},"scope_boundary":{"type":"string","title":"Scope Boundary"},"parameter_source":{"type":"string","title":"Parameter Source"},"is_swap_value":{"type":"boolean","title":"Is Swap Value","default":true},"perspective":{"type":"string","const":"receive_minus_pay","title":"Perspective","default":"receive_minus_pay"},"leg_valuation_side_required":{"type":"string","const":"receive","title":"Leg Valuation Side Required","default":"receive"},"uses_placeholder_curve":{"type":"boolean","title":"Uses Placeholder Curve","default":false},"uses_fabricated_index_series":{"type":"boolean","title":"Uses Fabricated Index Series","default":false},"placeholder_warning":{"type":"string","title":"Placeholder Warning"},"valuation_date_receive":{"type":"string","title":"Valuation Date Receive"},"valuation_date_pay":{"type":"string","title":"Valuation Date Pay"},"receive_leg_kind":{"type":"string","title":"Receive Leg Kind"},"pay_leg_kind":{"type":"string","title":"Pay Leg Kind"},"receive_leg_provenance":{"additionalProperties":true,"type":"object","title":"Receive Leg Provenance"},"pay_leg_provenance":{"additionalProperties":true,"type":"object","title":"Pay Leg Provenance"},"migration_assumptions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Migration Assumptions"},"detail":{"additionalProperties":{"type":"string"},"type":"object","title":"Detail"}},"type":"object","required":["swap_label","scope_boundary","parameter_source","placeholder_warning","valuation_date_receive","valuation_date_pay","receive_leg_kind","pay_leg_kind","receive_leg_provenance","pay_leg_provenance"],"title":"SwapNetProvenanceModel"},"SwapNetRequest":{"properties":{"receive_leg":{"$ref":"#/components/schemas/PreValuedLeg"},"pay_leg":{"$ref":"#/components/schemas/PreValuedLeg"},"swap_label":{"type":"string","title":"Swap Label"},"scope_boundary":{"type":"string","title":"Scope Boundary"},"parameter_source":{"type":"string","title":"Parameter Source"},"placeholder_warning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placeholder Warning"}},"type":"object","required":["receive_leg","pay_leg","swap_label","scope_boundary","parameter_source"],"title":"SwapNetRequest"},"SwapNetResultModel":{"properties":{"pv_net":{"type":"number","title":"Pv Net"},"receive_leg_pv":{"type":"number","title":"Receive Leg Pv"},"pay_leg_pv":{"type":"number","title":"Pay Leg Pv"},"receive_leg":{"additionalProperties":true,"type":"object","title":"Receive Leg"},"pay_leg":{"additionalProperties":true,"type":"object","title":"Pay Leg"},"provenance":{"$ref":"#/components/schemas/SwapNetProvenanceModel"}},"type":"object","required":["pv_net","receive_leg_pv","pay_leg_pv","receive_leg","pay_leg","provenance"],"title":"SwapNetResultModel"},"TermSheetDecomposeRequest":{"properties":{"stated_receive_param":{"type":"number","title":"Stated Receive Param"},"stated_pay_param":{"type":"number","title":"Stated Pay Param"},"parameter_source":{"type":"string","const":"authoritative_term_sheet","title":"Parameter Source"},"detail":{"additionalProperties":true,"type":"object","title":"Detail"}},"type":"object","required":["stated_receive_param","stated_pay_param","parameter_source"],"title":"TermSheetDecomposeRequest"},"TermSheetDecomposeResultModel":{"properties":{"result_kind":{"type":"string","const":"term_sheet_per_leg_decomposition","title":"Result Kind"},"stated_receive_param":{"type":"number","title":"Stated Receive Param"},"stated_pay_param":{"type":"number","title":"Stated Pay Param"},"fair_receive_param":{"type":"number","title":"Fair Receive Param"},"fair_pay_param":{"type":"number","title":"Fair Pay Param"},"provenance":{"additionalProperties":true,"type":"object","title":"Provenance"},"detail":{"additionalProperties":true,"type":"object","title":"Detail"}},"type":"object","required":["result_kind","stated_receive_param","stated_pay_param","fair_receive_param","fair_pay_param","provenance"],"title":"TermSheetDecomposeResultModel"},"TokenCreateRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"scopes":{"items":{"type":"string"},"type":"array","maxItems":32,"title":"Scopes"},"expires_in_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Expires In Days","description":"Days until the token expires. Omit for a token that never expires."}},"additionalProperties":false,"type":"object","required":["name"],"title":"TokenCreateRequest","description":"A request to mint a personal access token.\n\nTHE EXPIRY IS THE CALLER'S CHOICE, AND OMITTING IT MEANS THE TOKEN DOES NOT EXPIRE.\n\nThis field used to be `int = 90` with a comment reading \"non-expiring tokens are not\noffered\". That comment described an intention the code never had: the platform's request\nschema named the field `expiresInDays` while this model has always sent\n`expires_in_days`, and zod strips unknown keys rather than rejecting them. So the value\nwas discarded on every call, the platform saw no expiry at all, and EVERY token minted\nthrough this service has in fact never expired. The default was decorative.\n\nBoth halves are fixed together -- the platform now reads the field this sends -- so the\nnumber here is finally load-bearing, and it is worth knowing which way. A non-expiring\ndefault is a real choice: these credentials are long-lived by design, they are capped at\n20 live per user per audience, and they are revocable, but nothing will age one out on\nits own. Callers that want a bounded credential must now say so."},"TokenCreateResponse":{"properties":{"token_id":{"type":"string","title":"Token Id"},"token":{"type":"string","title":"Token"},"display_id":{"type":"string","title":"Display Id"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["token_id","token","display_id"],"title":"TokenCreateResponse"},"TokenListResponse":{"properties":{"tokens":{"items":{"$ref":"#/components/schemas/TokenSummary"},"type":"array","title":"Tokens"}},"type":"object","title":"TokenListResponse"},"TokenRevokeResponse":{"properties":{"revoked":{"type":"boolean","title":"Revoked"},"token_id":{"type":"string","title":"Token Id"},"cache_purge":{"type":"string","title":"Cache Purge","default":"ok"},"effective_within_s":{"type":"integer","title":"Effective Within S","default":0}},"type":"object","required":["revoked","token_id"],"title":"TokenRevokeResponse"},"TokenSummary":{"properties":{"token_id":{"type":"string","title":"Token Id"},"name":{"type":"string","title":"Name"},"display_id":{"type":"string","title":"Display Id"},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"}},"type":"object","required":["token_id","name","display_id"],"title":"TokenSummary"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"Version":{"properties":{"version":{"type":"string","title":"Version"},"git_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Sha"},"python":{"type":"string","title":"Python"},"started_at":{"type":"number","title":"Started At"},"uptime_s":{"type":"number","title":"Uptime S"}},"type":"object","required":["version","python","started_at","uptime_s"],"title":"Version"},"VolatilityQuote":{"properties":{"base":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Base"},"foreign":{"type":"string","pattern":"^[A-Za-z]{3}$","title":"Foreign"},"on":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"On"},"annualised_vol":{"type":"number","title":"Annualised Vol"},"as_of":{"type":"string","format":"date-time","title":"As Of"},"source":{"type":"string","enum":["euthyphro","computed"],"title":"Source","default":"euthyphro"}},"type":"object","required":["base","foreign","annualised_vol","as_of"],"title":"VolatilityQuote"},"WhoAmI":{"properties":{"authenticated":{"type":"boolean","title":"Authenticated"},"kind":{"type":"string","title":"Kind"},"subject":{"type":"string","title":"Subject"},"level":{"type":"integer","title":"Level"},"level_name":{"type":"string","title":"Level Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes"},"token_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Token Id"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["authenticated","kind","subject","level","level_name"],"title":"WhoAmI"}}}}