{"openapi":"3.1.0","info":{"title":"IDEALX Firm API","version":"1.0.0","description":"\nConnect your firm's systems (a CRM, a portfolio tool, your reporting) to IDEALX: your clients and the accounts\nthey gave you a mandate on, proposals, messages, strategies, your fees and fee statements, client reports and\ndocuments, invitations from clients, and webhooks. A firm key acts for your firm.\n\nUsing IDEALX for your own accounts? Use the [IDEALX API](https://docs.idealx.com/public/overview/). Want Claude, ChatGPT or another\nAI assistant to work with your clients' data? [Connect it over MCP](https://docs.idealx.com/mcp/). Guides and journeys:\nhttps://docs.idealx.com/console/overview/\n\n## Quickstart\n\n1. In Console, open **Team → API and webhooks** (firm admins) and make a key with the `read` scope. It is\n   shown once: keep it somewhere safe.\n2. List your clients in the sandbox (your firm's id is shown next to API and webhooks in Console):\n\n```bash\ncurl https://api.staging.idealx.com/v1/firms/frm_…/clients -H \"Authorization: Bearer idx_test_…\"\n```\n\n3. Read a client's account the same way Console does: `GET /v1/accounts/{id}/detail`,\n   `GET /v1/accounts/{id}/positions`.\n4. To send proposals and messages, make a key with `read` and `advise`.\n\n## Environments\n\n| Environment | Address | Keys start with |\n|---|---|---|\n| Sandbox | `https://api.staging.idealx.com` | `idx_test_` |\n| Live | `https://api.idealx.com` | `idx_live_` |\n\nThe sandbox has made-up prices, banks and blockchains: build and test there freely. A key works only in the\nenvironment it was made in. \n\n## Authentication\n\nSend the key on every request:\n\n```\nAuthorization: Bearer idx_test_…\n```\n\nA firm key acts as the admin who made it, for that firm only. Endpoints under `/v1/firms/{firmId}` take your\nown firm's id; another firm's answers `403`. On a client's account (`/v1/accounts/{id}/…`) the key works within\nthe mandate the client gave your firm on each portfolio (view, advisory or discretionary, and any limits), never\nbeyond it, and only while the engagement lasts.\n\n## Scopes\n\n| Scope | What it allows |\n|---|---|\n| `read` | Every read in this reference: clients, their accounts, holdings, orders, activity, reports, proposals, messages, strategies, fees |\n| `trade` | Place, cancel and approve orders on clients' accounts where the mandate allows it; start yield |\n| `move` | Move money and holdings between a client's portfolios and convert currencies, where the mandate allows it |\n| `advise` | Send and withdraw proposals; start conversations and send messages to clients |\n\nSome things are never possible with a key, by design: money leaving a client's account, adding recipients,\nchanging anyone's identity details, opening accounts, team and firm settings, and managing keys or webhooks.\nThose need a person in Console with their code. A request outside a key's scopes, or for anything not in this\nreference, answers `403`.\n\n## Requests\n\n- Send JSON with `Content-Type: application/json`.\n- Amounts are decimal strings with a currency: `{ \"amount\": \"1250.00\", \"currency\": \"GBP\" }`. Never numbers.\n- Ids are prefixed by kind (`acc_`, `ptf_`, `ord_`…). Treat them as opaque.\n- Lists of states and kinds can grow: handle a value you do not know.\n\n## Idempotency\n\nEvery write that places an order or moves money takes an `Idempotency-Key` header (16–128 characters, for\nexample a UUID). Sending the same key again returns the first answer instead of acting twice, so a timed-out\nrequest can be retried safely. Use a new key for each new action.\n\n## Errors\n\nErrors look the same everywhere. Switch on `code`, never on `message`; quote `requestId` when you ask us\nabout a request.\n\n```json\n{ \"error\": { \"code\": \"conflict\", \"message\": \"Not enough balance\", \"requestId\": \"req_…\", \"details\": { } } }\n```\n\n| Status | Code | Meaning |\n|---|---|---|\n| 400 | `invalid_id`, `invalid_idempotency_key` | The request is malformed |\n| 401 | `unauthenticated` | No key, or the key is not valid (revoked, expired, other environment) |\n| 403 | `forbidden` | Outside the key's scopes, or not possible with a key |\n| 404 | `not_found` | No such thing, or not one the key may see |\n| 409 | `conflict`, `invalid_transition` | Not possible in its current state (for example not enough balance) |\n| 422 | `validation_failed` | A field is missing or wrong; `details.issues` says which |\n| 429 | `rate_limited` | Too many requests; wait for `Retry-After` seconds |\n| 5xx | | Our side: retry later with the same `Idempotency-Key` |\n\n## Rate limits\n\nEach key may make **120 requests a minute**. Every answer carries `RateLimit-Limit`, `RateLimit-Remaining`\nand `RateLimit-Reset` (seconds). Past the limit the API answers `429` with `Retry-After`.\n\n## Webhooks\n\nAdd an endpoint (an `https://` address) and choose events in Console (Team → API and webhooks). Each event is a POST with a JSON body:\n\n```json\n{ \"id\": \"whd_…\", \"type\": \"deposit.credited\", \"createdAt\": \"2026-11-20T09:30:00Z\",\n  \"data\": { \"accountId\": \"acc_…\", \"units\": \"25000\", \"currency\": \"AUD\" } }\n```\n\nEvents: `account.opened`, `deposit.credited`, `withdrawal.settled`, `withdrawal.failed`,\n`approval.waiting`, `order.updated`, `order.expired`, `crypto.received`, `crypto.sent`, `crypto.failed`.\nAn event reaches your firm when it happens on an account your firm works on.\n\n**Check the signature** on every delivery before trusting it. The `IDEALX-Signature` header is\n`t=<unix time>,v1=<hex>`, where `v1` is the HMAC-SHA256 of `<t>.<raw body>` with your endpoint's secret:\n\n```js\nimport { createHmac, timingSafeEqual } from \"node:crypto\";\n\nfunction verify(secret, rawBody, header) {\n  const { t, v1 } = Object.fromEntries(header.split(\",\").map((p) => p.split(\"=\")));\n  if (Math.abs(Date.now() / 1000 - Number(t)) > 300) return false; // older than five minutes\n  const want = createHmac(\"sha256\", secret).update(`${t}.${rawBody}`).digest();\n  const got = Buffer.from(v1, \"hex\");\n  return got.length === want.length && timingSafeEqual(got, want);\n}\n```\n\nAnswer `2xx` within ten seconds. Anything else is retried after 1, 2, 4, 8… minutes, up to ten times. The\nsame event may arrive more than once: use its `id` to ignore repeats. Each endpoint keeps a delivery log, and\nyou can send yourself a test event from Console (Team → API and webhooks).\n\n## Versions and changes\n\nThe version is in the address (`/v1`). Within v1 we only add: new endpoints, new optional fields, new values\nin lists of states and kinds, new events. Build so that an unknown field or value does not break you. A change\nthat would break integrations comes as a new version, announced here ahead of time.\n\n**Changes**\n\n- 2026-11-25: Connect an AI assistant (Claude, ChatGPT or another MCP client) over MCP: see\n  [Connect an AI assistant](https://docs.idealx.com/mcp/).\n- 2026-11-24: The IDEALX API and the IDEALX Firm API have separate references. A key reaches only the\n  endpoints in its reference; anything else answers `403`.\n"},"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","bearerFormat":"idx_live_… / idx_test_…","description":"Your firm's API key, made in Console under Team → API and webhooks."}},"schemas":{"WebhookEvent":{"type":"object","properties":{"id":{"type":"string","description":"The delivery's id: the same event may arrive more than once"},"type":{"type":"string","enum":["account.opened","approval.waiting","crypto.failed","crypto.received","crypto.sent","deposit.credited","order.expired","order.updated","withdrawal.failed","withdrawal.settled"]},"createdAt":{"type":"string","example":"2026-11-20T09:30:00Z"},"data":{"type":"object","additionalProperties":{},"description":"What happened; always names the account (accountId)"}},"required":["id","type","createdAt","data"]},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string","example":"validation_failed"},"message":{"type":"string"},"requestId":{"type":"string"},"details":{"type":"object","additionalProperties":{}}},"required":["code","message","requestId"]}},"required":["error"]},"Health":{"type":"object","properties":{"status":{"type":"string","enum":["ok","degraded"]},"environment":{"type":"string"},"version":{"type":"string"},"time":{"type":"string","format":"date-time"},"database":{"type":"string","enum":["ok","unavailable","not_configured"]},"minAppVersion":{"type":"object","properties":{"ios":{"type":["string","null"]},"android":{"type":["string","null"]}},"required":["ios","android"],"description":"Lowest native app versions (D162); null: no minimum"}},"required":["status","environment","version","time","database","minAppVersion"]},"Catalog":{"type":"object","properties":{"version":{"type":"integer"},"jurisdictions":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"name":{"type":"string"},"currency":{"type":"string"},"enabled":{"type":"boolean"}},"required":["code","name","currency","enabled"]}},"accountTypes":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","example":"AU.smsf"},"jurisdiction":{"type":"string"},"type":{"type":"string"},"label":{"type":"string"},"description":{"type":"string"},"holder":{"type":"object","additionalProperties":{}},"roleLabels":{"type":"object","additionalProperties":{"type":"string"}},"products":{"type":"array","items":{"type":"string"}},"retirement":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"],"description":"Set for retirement funds (D127): the rule set and its menu name"},"steps":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"fields":{"type":"array","items":{"$ref":"#/components/schemas/CatalogField"}}},"required":["id","title","fields"]}}},"required":["id","jurisdiction","type","label","description","holder","roleLabels","products","steps"]}}},"required":["version","jurisdictions","accountTypes"]},"CatalogField":{"type":"object","additionalProperties":{},"description":"A wizard field. Shape: packages/catalog/src/fields.ts (kind, id, label, required, …)."},"FollowedStrategy":{"type":"object","properties":{"assignmentId":{"type":"string"},"accountId":{"type":"string"},"portfolioId":{"type":"string"},"strategy":{"type":"object","additionalProperties":{}},"currency":{"type":"string"},"approximate":{"type":"boolean"},"total":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"driftBp":{"type":"number","description":"How much of the portfolio is away from target"},"outside":{"type":"boolean","description":"Some line is outside its band"},"lines":{"type":"array","items":{"type":"object","additionalProperties":{}}},"trades":{"type":"array","items":{"type":"object","additionalProperties":{}}}},"required":["assignmentId","accountId","portfolioId","strategy","currency","approximate","total","driftBp","outside","lines","trades"],"additionalProperties":{}},"StrategyAnalysis":{"type":"object","properties":{"backtest":{"type":["object","null"],"additionalProperties":{},"description":"Growth of 100 on past month-end prices with the strategy's rebalancing; null without history"},"simulated":{"type":"boolean","description":"The history is simulated (staging), not market data"},"notes":{"type":"array","items":{"type":"string"}},"byKind":{"type":"array","items":{"type":"object","additionalProperties":{}}},"byRegion":{"type":"array","items":{"type":"object","additionalProperties":{}}},"byCurrency":{"type":"array","items":{"type":"object","additionalProperties":{}}},"liquidity":{"type":"object","additionalProperties":{}},"fees":{"type":"object","additionalProperties":{}},"currency":{"type":"string"},"factsSimulated":{"type":"boolean","description":"Some fund facts are simulated (staging), not market data"},"factsEstimated":{"type":["object","null"],"properties":{"kpis":{"type":"array","items":{"type":"string","enum":["feeBp","yieldBp","techBp","cashInDayBp"]}},"asOf":{"type":"string"}},"required":["kpis","asOf"],"description":"Headline figures resting partly on facts estimated from public information (D188), with the oldest estimate's date; each line's `estimated` names its estimated facts"},"lines":{"type":"array","items":{"type":"object","additionalProperties":{}},"description":"Each line with its kind, region, fee and yield"},"kpis":{"type":"object","additionalProperties":{},"description":"Yearly return, volatility, worst fall, income yield, fee, tech exposure, cash in a day, rates +2%"},"byClass":{"type":"array","items":{"type":"object","additionalProperties":{}}},"bySector":{"type":"array","items":{"type":"object","additionalProperties":{}}},"constraints":{"type":"array","items":{"type":"object","additionalProperties":{}},"description":"Each check with its value now: pass, warn or fail"},"stress":{"type":"array","items":{"type":"object","additionalProperties":{}},"description":"Simulations: past stretches (March 2020, inflation 2022) and sensitivities"},"lookThrough":{"type":"object","additionalProperties":{},"description":"The largest companies held through funds, and how much of the mix this sees"},"ms":{"type":"number","description":"Time taken on the server, milliseconds"}},"required":["backtest","simulated","notes","byKind","byRegion","byCurrency","liquidity","fees","currency","factsSimulated","factsEstimated","lines","kpis","byClass","bySector","constraints","stress","lookThrough","ms"]},"RetirementSummary":{"type":"object","properties":{"ruleSet":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"beneficiaryLabel":{"type":"string"},"pensionLabel":{"type":"string"}},"required":["id","label","beneficiaryLabel","pensionLabel"]},"currency":{"type":"string"},"year":{"type":"object","properties":{"year":{"type":"number"},"label":{"type":"string"},"from":{"type":"string"},"to":{"type":"string"},"current":{"type":"boolean"}},"required":["year","label","from","to","current"]},"years":{"type":"array","items":{"type":"object","properties":{"year":{"type":"number"},"label":{"type":"string"},"from":{"type":"string"},"to":{"type":"string"},"current":{"type":"boolean"},"confirmed":{"type":"boolean"},"contributed":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"caps":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"used":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["id","label","used"]}},"outsideCaps":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"unclassified":{"type":"object","properties":{"count":{"type":"number"},"amount":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["count","amount"]},"beneficiaries":{"type":"array","items":{"type":"object","properties":{"personId":{"type":"string"},"caps":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"explain":{"type":"string"},"used":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"limit":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"annual":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"left":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"usedBp":{"type":"number"},"over":{"type":"boolean"},"near":{"type":"boolean"},"note":{"type":["string","null"]}},"required":["id","label","explain","used","limit","annual","left","usedBp","over","near","note"]}}},"required":["personId","caps"]}},"pensions":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"lumpSums":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["year","label","from","to","current","confirmed","contributed","caps","outsideCaps","unclassified","beneficiaries","pensions","lumpSums"]}},"beneficiaries":{"type":"array","items":{"type":"object","properties":{"personId":{"type":"string"},"name":{"type":"string"},"age":{"type":["number","null"]},"phase":{"type":"string","enum":["accumulation","pension","both"]},"preservation":{"type":["object","null"],"properties":{"id":{"type":"string"},"label":{"type":"string"},"explain":{"type":"string"}},"required":["id","label","explain"]},"contributed":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"paidOut":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"shareBp":{"type":"number"},"pension":{"type":["object","null"],"properties":{"balanceAtStart":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"startedOn":{"type":["string","null"]},"age":{"type":["number","null"]},"rateBp":{"type":["number","null"]},"minimum":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"paid":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"left":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"met":{"type":["boolean","null"]},"missing":{"type":["string","null"]}},"required":["balanceAtStart","startedOn","age","rateBp","minimum","paid","left","met","missing"]}},"required":["personId","name","age","phase","preservation","contributed","paidOut","shareBp","pension"]}},"payments":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"personId":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["pension","lump_sum"]},"amount":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"paidOn":{"type":"string"}},"required":["id","personId","name","kind","amount","paidOn"]}}},"required":["ruleSet","currency","year","years","beneficiaries","payments"],"description":"A retirement fund at a glance (D141), read only: contributions by financial year against the caps, each beneficiary's phase, preservation stage and share, pension minimums and payments. A guide; the fund's accountant confirms the figures."},"RetirementYear":{"type":"object","properties":{"ruleSet":{"type":"object","additionalProperties":{}},"year":{"type":"object","additionalProperties":{}},"years":{"type":"array","items":{"type":"object","additionalProperties":{}}},"confirmed":{"type":"boolean"},"currency":{"type":"string"},"kinds":{"type":"array","items":{"type":"object","additionalProperties":{}}},"limits":{"type":"object","additionalProperties":{}},"members":{"type":"array","items":{"type":"object","additionalProperties":{}}},"contributions":{"type":"array","items":{"type":"object","additionalProperties":{}}},"payments":{"type":"array","items":{"type":"object","additionalProperties":{}}},"toClassify":{"type":"array","items":{"type":"object","additionalProperties":{}}},"toTag":{"type":"array","items":{"type":"object","additionalProperties":{}}},"settings":{"type":"object","additionalProperties":{}},"strategy":{"type":["object","null"],"additionalProperties":{}},"checklist":{"type":"array","items":{"type":"object","additionalProperties":{}}},"canEdit":{"type":"boolean"}},"required":["ruleSet","year","years","confirmed","currency","kinds","limits","members","contributions","payments","toClassify","toTag","settings","strategy","checklist","canEdit"],"description":"A retirement fund's year (D127): its members, contributions against the caps, pension minimums and the trustees' checklist. Figures are a guide; the fund's accountant and auditor confirm them."},"AccountProfile":{"type":"object","properties":{"holder":{"type":"object","properties":{"kind":{"type":"string","enum":["person","organisation"]},"name":{"type":"string"},"verified":{"type":"boolean"}},"required":["kind","name","verified"]},"groups":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string"},"facts":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"]}}},"required":["title","facts"]}},"tax":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"]}}},"required":["holder","groups","tax"],"description":"Who holds the account and what was given when it opened, in the account type's words (catalog). Tax numbers are masked."},"Account":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"nickname":{"type":["string","null"]},"accountTypeId":{"type":"string"},"accountTypeLabel":{"type":"string"},"jurisdiction":{"type":"string"},"currency":{"type":"string","description":"The account's main currency, from its country","example":"AUD"},"status":{"type":"string","enum":["open","frozen","closed"]},"myRoles":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string"},"label":{"type":"string"}},"required":["role","label"]}},"portfolios":{"type":"array","items":{"$ref":"#/components/schemas/Portfolio"}},"openedAt":{"type":"string"}},"required":["id","name","nickname","accountTypeId","accountTypeLabel","jurisdiction","currency","status","myRoles","portfolios","openedAt"]},"Portfolio":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"isPrimary":{"type":"boolean"},"status":{"type":"string","enum":["open","closed"]}},"required":["id","name","isPrimary","status"]},"AccountDetail":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"nickname":{"type":["string","null"]},"accountTypeId":{"type":"string"},"accountTypeLabel":{"type":"string"},"jurisdiction":{"type":"string"},"currency":{"type":"string","description":"The account's main currency, from its country","example":"AUD"},"status":{"type":"string","enum":["open","frozen","closed"]},"myRoles":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string"},"label":{"type":"string"}},"required":["role","label"]}},"portfolios":{"type":"array","items":{"$ref":"#/components/schemas/PortfolioDetail"}},"totals":{"type":"array","items":{"$ref":"#/components/schemas/Balance"}},"value":{"$ref":"#/components/schemas/Value"},"breakdown":{"$ref":"#/components/schemas/ValueBreakdown"},"actions":{"type":"array","items":{"$ref":"#/components/schemas/AccountAction"},"description":"What you may do here, from your account role or your firm's role, kind and mandate. add_money, trade, transfer, withdraw, send_crypto, manage_payees, schedule, propose and decide_proposals move money or ask a client to; an approval policy may still apply when they run."},"openedAt":{"type":"string"}},"required":["id","name","nickname","accountTypeId","accountTypeLabel","jurisdiction","currency","status","myRoles","portfolios","totals","value","breakdown","actions","openedAt"]},"PortfolioDetail":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"isPrimary":{"type":"boolean"},"status":{"type":"string","enum":["open","closed"]},"balances":{"type":"array","items":{"$ref":"#/components/schemas/Balance"}},"value":{"$ref":"#/components/schemas/Value"},"breakdown":{"$ref":"#/components/schemas/ValueBreakdown"},"actions":{"type":"array","items":{"$ref":"#/components/schemas/AccountAction"},"description":"What you may do here, from your account role or your firm's role, kind and mandate. add_money, trade, transfer, withdraw, send_crypto, manage_payees, schedule, propose and decide_proposals move money or ask a client to; an approval policy may still apply when they run."}},"required":["id","name","isPrimary","status","balances","value","breakdown","actions"]},"Balance":{"type":"object","properties":{"instrumentId":{"type":"string"},"amount":{"type":"string"},"currency":{"type":"string"}},"required":["instrumentId","amount","currency"]},"Value":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"},"approximate":{"type":"boolean"},"complete":{"type":"boolean"}},"required":["amount","currency","approximate","complete"]},"ValueBreakdown":{"type":"array","items":{"type":"object","properties":{"bucket":{"type":"string","enum":["cash","yield","markets","digital_assets","strategies"]},"amount":{"type":"string"},"count":{"type":"integer","description":"Currencies (cash) or positions counted"}},"required":["bucket","amount","count"]},"description":"The value in disjoint parts, in the main currency; they add up to value exactly (D138). Cash is uninvested cash in every currency; strategies holds the positions of portfolios that follow a strategy and is listed only when one does."},"AccountAction":{"type":"string","enum":["add_money","trade","transfer","withdraw","send_crypto","manage_payees","schedule","propose","decide_proposals","message","keep_records","manage_people","open_portfolio","close_account","documents","reports"]},"Money":{"type":"object","properties":{"amount":{"type":"string","example":"1250.00"},"currency":{"type":"string","example":"AUD"}},"required":["amount","currency"]},"Instruction":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["internal_transfer","withdrawal","crypto_withdrawal"]},"state":{"type":"string"},"fromPortfolioId":{"type":"string"},"toPortfolioId":{"type":["string","null"]},"payeeId":{"type":["string","null"]},"amount":{"$ref":"#/components/schemas/Money"},"reference":{"type":["string","null"]},"note":{"type":["string","null"],"description":"The customer's own words on why; kept with the record"},"attachments":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"contentType":{"type":"string"},"size":{"type":"number"},"createdAt":{"type":"string"}},"required":["id","name","contentType","size","createdAt"]},"description":"Files kept with it; download at /v1/instructions/{id}/files/{fileId}"},"approvalsRequired":{"type":"number"},"approvals":{"type":"number"},"approvedByMe":{"type":"boolean"},"position":{"type":["object","null"],"properties":{"instrumentId":{"type":"string"},"quantity":{"type":"string"}},"required":["instrumentId","quantity"],"description":"Set when units of an investment were moved instead of cash"},"createdAt":{"type":"string"}},"required":["id","kind","state","fromPortfolioId","toPortfolioId","payeeId","amount","reference","note","attachments","approvalsRequired","approvals","approvedByMe","position","createdAt"]},"FileUpload":{"type":"object","properties":{"name":{"type":"string","maxLength":200},"contentType":{"type":"string"},"dataBase64":{"type":"string"}},"required":["name","contentType","dataBase64"],"description":"PDF, image, Word, Excel, CSV or text; up to 4 MB"},"Transaction":{"type":"object","properties":{"id":{"type":"string","description":"Open its details at /v1/accounts/{id}/transactions/{txId}"},"kind":{"type":"string","enum":["buy","sell","conversion","deposit","withdrawal","receive","send","transfer","income","yield","fee","other"]},"title":{"type":"string","example":"Bought 11 VAS"},"flow":{"type":"string","enum":["in","out","within"],"description":"Money or assets came in, went out, or moved between two portfolios both shown"},"amount":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"The cash it moved, signed (negative is out); for a conversion, what arrived"}]},"paid":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"For a conversion, what was paid (negative)"}]},"asset":{"type":["object","null"],"properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"quantity":{"type":"string"}},"required":["instrumentId","symbol","quantity"],"description":"Units of an investment it moved, signed"},"status":{"type":"string","enum":["waiting_approval","waiting_market","processing","sent","done","failed","cancelled","expired"]},"statusLabel":{"type":"string"},"portfolioIds":{"type":"array","items":{"type":"string"}},"createdAt":{"type":"string"}},"required":["id","kind","title","flow","amount","paid","asset","status","statusLabel","portfolioIds","createdAt"]},"TransactionDetail":{"type":"object","properties":{"transaction":{"$ref":"#/components/schemas/Transaction"},"facts":{"type":"array","items":{"$ref":"#/components/schemas/TransactionFact"}},"documents":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"path":{"type":"string","description":"API path of the PDF"},"fileName":{"type":"string"}},"required":["label","path","fileName"]}}},"required":["transaction","facts","documents"]},"TransactionFact":{"type":"object","properties":{"label":{"type":"string"},"text":{"type":"string"},"money":{"$ref":"#/components/schemas/Money"},"at":{"type":"string","description":"A moment (ISO)"},"date":{"type":"string","description":"A day (YYYY-MM-DD)"}},"required":["label"],"description":"One line of details: a label and one value"},"CashStatement":{"type":"object","properties":{"currency":{"type":"string"},"mainCurrency":{"type":"string"},"currencies":{"type":"array","items":{"type":"string"},"description":"Every currency the scope has held, the main one first"},"accountName":{"type":"string"},"portfolio":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"from":{"type":"string"},"to":{"type":"string"},"opening":{"type":"string"},"closing":{"type":"string"},"moneyIn":{"type":"string"},"moneyOut":{"type":"string"},"reconciled":{"type":"boolean"},"transactions":{"type":"array","items":{"type":"object","properties":{"at":{"type":"string"},"kind":{"type":"string"},"description":{"type":"string"},"reference":{"type":["string","null"],"description":"The short reference of the order, payment or deposit"},"counterparty":{"type":["string","null"],"description":"Who the money went to or came from (payee, investment, firm)"},"moneyIn":{"type":["string","null"]},"moneyOut":{"type":["string","null"]},"balance":{"type":"string"}},"required":["at","kind","description","reference","counterparty","moneyIn","moneyOut","balance"]}}},"required":["currency","mainCurrency","currencies","accountName","portfolio","from","to","opening","closing","moneyIn","moneyOut","reconciled","transactions"]},"Performance":{"type":"object","properties":{"currency":{"type":"string"},"since":{"type":"string"},"series":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"value":{"type":"string"}},"required":["day","value"]}},"returns":{"type":"object","properties":{"oneMonth":{"type":["number","null"]},"threeMonths":{"type":["number","null"]},"yearToDate":{"type":["number","null"]},"oneYear":{"type":["number","null"]},"sinceStart":{"type":["number","null"]}},"required":["oneMonth","threeMonths","yearToDate","oneYear","sinceStart"],"description":"Time-weighted returns in percent: money in and out left out; null until there are two days"},"sinceOpening":{"type":"object","properties":{"value":{"type":"string"},"netMoneyIn":{"type":"string"},"gain":{"type":"string"}},"required":["value","netMoneyIn","gain"]},"approximate":{"type":"boolean"}},"required":["currency","since","series","returns","sinceOpening","approximate"]},"Allocation":{"type":"object","properties":{"currency":{"type":"string"},"total":{"type":"string"},"byClass":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"percent":{"type":"number"}},"required":["key","value","percent"]}},"byCurrency":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"},"percent":{"type":"number"}},"required":["key","value","percent"]}}},"required":["currency","total","byClass","byCurrency"]},"Statement":{"type":"object","properties":{"currency":{"type":"string"},"accountName":{"type":"string"},"from":{"type":"string"},"to":{"type":"string"},"portfolios":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"lines":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"isCash":{"type":"boolean"},"opening":{"type":"string"},"closing":{"type":"string"},"reconciled":{"type":"boolean"},"movements":{"type":"array","items":{"type":"object","properties":{"at":{"type":"string"},"kind":{"type":"string"},"description":{"type":"string"},"units":{"type":"string"},"balance":{"type":"string"}},"required":["at","kind","description","units","balance"]}}},"required":["instrumentId","symbol","name","isCash","opening","closing","reconciled","movements"]}}},"required":["id","name","lines"]}}},"required":["currency","accountName","from","to","portfolios"]},"TaxYear":{"type":"object","properties":{"jurisdiction":{"type":"string"},"currency":{"type":"string"},"estimated":{"type":"boolean","enum":[true]},"notice":{"type":"string"},"year":{"type":"number"},"label":{"type":"string"},"from":{"type":"string"},"to":{"type":"string","description":"The day after the tax year ends"},"capitalGains":{"type":"object","properties":{"method":{"type":"string","enum":["fifo","share_pooling","none"]},"holdingPeriodMonths":{"type":["number","null"]},"longTermLabel":{"type":["string","null"]}},"required":["method","holdingPeriodMonths","longTermLabel"],"description":"How the country works gains out (D175)"},"sales":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"quantity":{"type":"string"},"acquiredAt":{"type":"string"},"soldAt":{"type":"string"},"heldDays":{"type":"number"},"heldOver12Months":{"type":"boolean","description":"Sold after the country's holding period (12 months in Australia). Shown only; no discount is applied. False where the country has none"},"longTerm":{"type":["boolean","null"],"description":"Long term under the country's holding period; null where it has none (D175)"},"matching":{"type":"string","enum":["lot","same_day","bed_and_breakfast","pool"],"description":"What the sale was matched with: a lot (oldest first), or under the UK rules a buy the same day, a buy in the next 30 days, or the pool at average cost"},"cost":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"],"description":"What was paid, including the transaction fee"},"proceeds":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"],"description":"What the sale brought in, less the transaction fee"},"gain":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"inAccountCurrency":{"type":["object","null"],"properties":{"cost":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"proceeds":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"gain":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["cost","proceeds","gain"],"description":"In the account's currency: cost at the rate when bought, proceeds at the rate when sold. Null when not recorded"}},"required":["instrumentId","quantity","acquiredAt","soldAt","heldDays","heldOver12Months","longTerm","matching","cost","proceeds","gain","inAccountCurrency"]}},"income":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"kind":{"type":"string"},"payDate":{"type":"string"},"amount":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["instrumentId","kind","payDate","amount"]}},"interest":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"maturityDate":{"type":"string"},"amount":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["name","maturityDate","amount"]}},"fees":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string"},"description":{"type":"string"},"amount":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["date","description","amount"]},"description":"Fees paid in the year, with any tax on them (D109)"}},"required":["jurisdiction","currency","estimated","notice","year","label","from","to","capitalGains","sales","income","interest","fees"]},"AnnualPack":{"type":"object","properties":{"label":{"type":"string"},"from":{"type":"string"},"to":{"type":"string"},"statement":{"$ref":"#/components/schemas/Statement"},"closingValue":{"type":["string","null"],"description":"Value on the last day of the year; null when no value was recorded then"},"currency":{"type":"string"}},"required":["label","from","to","statement","closingValue","currency"]},"AccountingFormat":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"jurisdictions":{"type":"array","items":{"type":"string"},"description":"\"*\" serves every country"},"accountTypes":{"type":["array","null"],"items":{"type":"string"}},"usesMapping":{"type":"boolean"},"bestEffort":{"type":"boolean"},"assumptions":{"type":"array","items":{"type":"string"}},"files":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"fileType":{"type":"string","enum":["csv","xlsx","zip"]},"columns":{"type":"array","items":{"type":"string"}}},"required":["id","label","fileType","columns"]}}},"required":["id","name","jurisdictions","accountTypes","usesMapping","bestEffort","assumptions","files"]},"AccountingRow":{"type":"object","properties":{"key":{"type":"string"},"date":{"type":"string"},"accountId":{"type":"string"},"accountName":{"type":"string"},"portfolioId":{"type":"string"},"portfolioName":{"type":"string"},"type":{"type":"string"},"typeLabel":{"type":"string"},"subtype":{"type":["string","null"]},"subtypeLabel":{"type":["string","null"]},"instrument":{"type":["object","null"],"properties":{"id":{"type":"string"},"code":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"}},"required":["id","code","name","assetClass"]},"quantity":{"type":["string","null"]},"price":{"type":["string","null"]},"priceCurrency":{"type":["string","null"]},"currency":{"type":"string"},"gross":{"type":"string"},"fees":{"type":"string"},"taxWithheld":{"type":"string"},"net":{"type":"string"},"fxFrom":{"type":["object","null"],"properties":{"currency":{"type":"string"},"amount":{"type":"string"}},"required":["currency","amount"]},"extras":{"type":"object","additionalProperties":{"type":"string"},"description":"Country facts keyed by the catalog's ids, e.g. AU.franking_credit"},"costBase":{"type":["string","null"]},"gain":{"type":["string","null"]},"lots":{"type":"array","items":{"type":"object","properties":{"lotId":{"type":"string"},"acquiredOn":{"type":"string"},"quantity":{"type":"string"},"cost":{"type":"string"},"proceeds":{"type":"string"},"gain":{"type":"string"},"heldDays":{"type":"number"},"longTerm":{"type":["boolean","null"]},"costEstimated":{"type":"boolean"}},"required":["lotId","acquiredOn","quantity","cost","proceeds","gain","heldDays","longTerm","costEstimated"]}},"counterparty":{"type":["string","null"]},"description":{"type":"string"},"reference":{"type":"string"},"source":{"type":"object","properties":{"type":{"type":"string"},"id":{"type":"string"}},"required":["type","id"]},"offLedger":{"type":"boolean"}},"required":["key","date","accountId","accountName","portfolioId","portfolioName","type","typeLabel","subtype","subtypeLabel","instrument","quantity","price","priceCurrency","currency","gross","fees","taxWithheld","net","fxFrom","extras","costBase","gain","lots","counterparty","description","reference","source","offLedger"]},"AccountingPreview":{"type":"object","properties":{"account":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"jurisdiction":{"type":"string"},"currency":{"type":"string"},"type":{"type":"string"},"variantId":{"type":"string"},"retirement":{"type":["object","null"],"properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"]}},"required":["id","name","jurisdiction","currency","type","variantId","retirement"]},"from":{"type":"string"},"to":{"type":"string"},"format":{"$ref":"#/components/schemas/AccountingFormat"},"profileId":{"type":["string","null"]},"rowCount":{"type":"number"},"byType":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"label":{"type":"string"},"count":{"type":"number"}},"required":["type","label","count"]}},"totals":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string"},"moneyIn":{"type":"string"},"moneyOut":{"type":"string"},"fees":{"type":"string"},"taxWithheld":{"type":"string"},"rows":{"type":"number"}},"required":["currency","moneyIn","moneyOut","fees","taxWithheld","rows"]}},"holdings":{"type":"number"},"reconciled":{"type":"boolean"},"warnings":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"count":{"type":"number"}},"required":["code","message","count"]}},"sample":{"type":"array","items":{"$ref":"#/components/schemas/AccountingRow"}}},"required":["account","from","to","format","profileId","rowCount","byType","totals","holdings","reconciled","warnings","sample"]},"AccountingExport":{"type":"object","properties":{"id":{"type":"string"},"batchId":{"type":["string","null"]},"accountId":{"type":"string"},"accountName":{"type":"string"},"format":{"type":"string"},"profileId":{"type":["string","null"]},"from":{"type":"string"},"to":{"type":"string"},"status":{"type":"string","enum":["done","failed"]},"trigger":{"type":"string","enum":["manual","bulk","schedule"]},"scheduleId":{"type":["string","null"]},"rowCount":{"type":"number"},"reconciled":{"type":"boolean"},"warnings":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"count":{"type":"number"}},"required":["code","message","count"]}},"totals":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string"},"moneyIn":{"type":"string"},"moneyOut":{"type":"string"},"fees":{"type":"string"},"taxWithheld":{"type":"string"},"rows":{"type":"number"}},"required":["currency","moneyIn","moneyOut","fees","taxWithheld","rows"]}},"files":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"fileName":{"type":"string"},"contentType":{"type":"string"},"bytes":{"type":"number"},"label":{"type":"string"}},"required":["id","fileName","contentType","bytes","label"]}},"error":{"type":["string","null"]},"createdAt":{"type":"string"}},"required":["id","batchId","accountId","accountName","format","profileId","from","to","status","trigger","scheduleId","rowCount","reconciled","warnings","totals","files","error","createdAt"]},"AccountingProfile":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"format":{"type":"string"},"jurisdiction":{"type":"string"},"mapping":{"type":"object","additionalProperties":{"type":"string"}},"settings":{"type":"object","additionalProperties":{"type":"string"}},"updatedAt":{"type":"string"}},"required":["id","name","format","jurisdiction","mapping","settings","updatedAt"]},"AccountingSchedule":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"accountIds":{"type":"array","items":{"type":"string"}},"format":{"type":"string"},"profileId":{"type":["string","null"]},"frequency":{"type":"string","enum":["daily","weekly","monthly","quarterly","yearly"]},"recipients":{"type":"array","items":{"type":"string"}},"status":{"type":"string","enum":["active","paused"]},"nextRunAt":{"type":"string"},"lastRunAt":{"type":["string","null"]},"lastBatchId":{"type":["string","null"]}},"required":["id","name","accountIds","format","profileId","frequency","recipients","status","nextRunAt","lastRunAt","lastBatchId"]},"LibraryItem":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"origin":{"type":"string","enum":["upload","agentx_chat","agentx_output","research_memo","client_report"]},"contentType":{"type":"string"},"type":{"type":"string","enum":["pdf","image","sheet","doc","text","email","media","archive","other"]},"size":{"type":"number"},"sha256":{"type":"string"},"version":{"type":"number"},"folderId":{"type":["string","null"]},"tags":{"type":"array","items":{"type":"string"}},"client":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"account":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"proposalId":{"type":["string","null"]},"strategyId":{"type":["string","null"]},"threadId":{"type":["string","null"]},"region":{"type":"string","description":"The data region its files are kept in"},"createdBy":{"type":"object","properties":{"teamMemberId":{"type":"string"},"name":{"type":"string"}},"required":["teamMemberId","name"]},"mine":{"type":"boolean"},"shared":{"type":"boolean"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"deletedAt":{"type":["string","null"]},"restorableUntil":{"type":["string","null"]}},"required":["id","name","origin","contentType","type","size","sha256","version","folderId","tags","client","account","proposalId","strategyId","threadId","region","createdBy","mine","shared","createdAt","updatedAt","deletedAt","restorableUntil"]},"LibraryFolder":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"parentId":{"type":["string","null"]}},"required":["id","name","parentId"]},"LibraryVersion":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"number"},"name":{"type":"string"},"contentType":{"type":"string"},"size":{"type":"number"},"sha256":{"type":"string"},"region":{"type":"string"},"stored":{"type":"string","enum":["regional","database"]},"scan":{"type":"string","enum":["clean","not_scanned","infected"]},"note":{"type":["string","null"]},"createdBy":{"type":"string"},"createdAt":{"type":"string"}},"required":["id","version","name","contentType","size","sha256","region","stored","scan","note","createdBy","createdAt"]},"LibraryShare":{"type":"object","properties":{"id":{"type":"string"},"accountId":{"type":"string"},"accountName":{"type":"string"},"versionId":{"type":"string"},"title":{"type":"string"},"sharedBy":{"type":"string"},"createdAt":{"type":"string"},"revokedAt":{"type":["string","null"]}},"required":["id","accountId","accountName","versionId","title","sharedBy","createdAt","revokedAt"]},"FirmFeeSettings":{"type":"object","properties":{"taxRegistered":{"type":"boolean"},"taxNumber":{"type":["string","null"]},"taxLabel":{"type":["string","null"]},"taxPercent":{"type":["number","null"]},"currency":{"type":["string","null"]},"limits":{"type":["object","null"],"properties":{"maxManagementPercent":{"type":"string"},"maxPerformancePercent":{"type":"string"},"arrearsGraceDays":{"type":"number"}},"required":["maxManagementPercent","maxPerformancePercent","arrearsGraceDays"]}},"required":["taxRegistered","taxNumber","taxLabel","taxPercent","currency","limits"]},"FeeSchedule":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"archived":{"type":"boolean"},"current":{"$ref":"#/components/schemas/FeeScheduleVersion"},"agreementsInForce":{"type":"number"}},"required":["id","name","archived","current","agreementsInForce"]},"FeeScheduleVersion":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"number"},"period":{"type":"string","enum":["monthly","quarterly","yearly"]},"lines":{"type":"array","items":{"$ref":"#/components/schemas/FeeLine"}},"summary":{"type":"string","description":"The words the client agrees to"},"createdAt":{"type":"string"}},"required":["id","version","period","lines","summary","createdAt"]},"FeeLine":{"type":"object","properties":{"kind":{"type":"string","enum":["management","fixed","performance","entry"]},"currency":{"type":["string","null"],"description":"Of the amounts and tier limits"},"tiers":{"type":["array","null"],"items":{"type":"object","properties":{"upTo":{"type":["string","null"]},"percent":{"type":"string"}},"required":["upTo","percent"]},"description":"Management: the percent a year up to each value (null: the rest)"},"amount":{"type":["string","null"]},"percent":{"type":["string","null"]},"hurdlePercent":{"type":["string","null"]}},"required":["kind","currency","tiers","amount","percent","hurdlePercent"]},"FeeAgreement":{"type":"object","properties":{"id":{"type":"string"},"accountId":{"type":"string"},"accountName":{"type":"string"},"engagementId":{"type":"string"},"firmName":{"type":"string"},"scheduleName":{"type":"string"},"status":{"type":"string","enum":["pending","agreed","declined","withdrawn","superseded","ended"]},"terms":{"$ref":"#/components/schemas/FeeScheduleVersion"},"tax":{"type":"object","properties":{"label":{"type":["string","null"]},"percent":{"type":"string"}},"required":["label","percent"]},"proposedAt":{"type":"string"},"agreedAt":{"type":["string","null"]},"agreedVia":{"type":["string","null"],"enum":["client","reduction",null]},"startsOn":{"type":["string","null"]},"endedOn":{"type":["string","null"]}},"required":["id","accountId","accountName","engagementId","firmName","scheduleName","status","terms","tax","proposedAt","agreedAt","agreedVia","startsOn","endedOn"]},"FeeStatement":{"type":"object","properties":{"id":{"type":"string"},"firmId":{"type":"string"},"from":{"type":"string"},"to":{"type":"string"},"fees":{"$ref":"#/components/schemas/Money"},"tax":{"$ref":"#/components/schemas/Money"},"idealxShare":{"$ref":"#/components/schemas/Money"},"net":{"$ref":"#/components/schemas/Money"},"stillOwed":{"$ref":"#/components/schemas/Money"},"status":{"type":"string","enum":["ready","paid"]},"paidReference":{"type":["string","null"]},"paidAt":{"type":["string","null"]}},"required":["id","firmId","from","to","fees","tax","idealxShare","net","stillOwed","status","paidReference","paidAt"]},"FeeStatementDetail":{"type":"object","properties":{"statement":{"$ref":"#/components/schemas/FeeStatement"},"lines":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/FeeCharge"},{"type":"object","properties":{"accountName":{"type":"string"},"idealxShare":{"$ref":"#/components/schemas/Money"}},"required":["accountName","idealxShare"]}]}}},"required":["statement","lines"]},"FeeCharge":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["management","fixed","performance","entry"]},"accountId":{"type":"string"},"portfolioId":{"type":"string"},"from":{"type":"string"},"to":{"type":"string","description":"Last day covered"},"fee":{"$ref":"#/components/schemas/Money"},"tax":{"$ref":"#/components/schemas/Money"},"collected":{"$ref":"#/components/schemas/Money"},"owed":{"$ref":"#/components/schemas/Money"},"status":{"type":"string","enum":["due","collected","waived"]},"createdAt":{"type":"string"}},"required":["id","kind","accountId","portfolioId","from","to","fee","tax","collected","owed","status","createdAt"]},"AccountFees":{"type":"object","properties":{"agreements":{"type":"array","items":{"$ref":"#/components/schemas/FeeAgreement"}},"charges":{"type":"array","items":{"$ref":"#/components/schemas/FeeCharge"}}},"required":["agreements","charges"]},"OrderFee":{"type":"object","properties":{"estimate":{"$ref":"#/components/schemas/Money"},"fee":{"$ref":"#/components/schemas/Money"}},"required":["estimate","fee"]},"CurrencyAccounts":{"type":"object","properties":{"accounts":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string"},"status":{"type":"string","enum":["active","requested"]},"since":{"type":"string"}},"required":["currency","status","since"]}},"available":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string"},"instant":{"type":"boolean","description":"Issued at once; otherwise Ops issues it"}},"required":["currency","instant"]}}},"required":["accounts","available"]},"DepositDetails":{"type":"object","properties":{"currency":{"type":"string"},"accountName":{"type":"string"},"scheme":{"type":"string","description":"Bank details scheme (D96): au, nz, gb, iban, us, swift"},"details":{"type":"array","items":{"$ref":"#/components/schemas/BankDetailLine"},"description":"The usual way's details (the first of methods), labelled, in order"},"methods":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","description":"Payment method (bank scheme) id, D133"},"name":{"type":"string"},"details":{"type":"array","items":{"$ref":"#/components/schemas/BankDetailLine"}}},"required":["id","name","details"]},"description":"Every way this account can receive the currency (e.g. BSB and PayID)"},"bsb":{"type":["string","null"],"deprecated":true,"description":"Australian accounts only; use details"},"accountNumber":{"type":["string","null"],"deprecated":true,"description":"Use details"},"payId":{"type":["string","null"],"deprecated":true,"description":"Use details"}},"required":["currency","accountName","scheme","details","methods","bsb","accountNumber","payId"],"description":"Where to send money. It always arrives in the Primary portfolio."},"BankDetailLine":{"type":"object","properties":{"key":{"type":"string"},"label":{"type":"string"},"value":{"type":"string"}},"required":["key","label","value"]},"BankScheme":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"fields":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"label":{"type":"string"},"example":{"type":"string"},"optional":{"type":"boolean"},"hint":{"type":"string"},"options":{"type":"array","items":{"type":"object","properties":{"value":{"type":"string"},"label":{"type":"string"}},"required":["value","label"]},"description":"A choice instead of free text; the first is the usual one"}},"required":["key","label","example","optional","hint"]}},"short":{"type":"string","description":"The method in a word (BSB, PayID, BPAY, ACH, Wire)"},"nameLabel":{"type":"string","description":"What the recipient's name is called"}},"required":["id","name","fields","short","nameLabel"]},"RecurringPayment":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string","enum":["active","paused","ended"]},"recipient":{"type":"object","properties":{"kind":{"type":"string","enum":["bank","wallet"]},"id":{"type":"string"},"name":{"type":"string"},"line":{"type":"string"},"removed":{"type":"boolean"}},"required":["kind","id","name","line","removed"]},"instrumentId":{"type":"string","description":"A currency code, or a coin (CRYPTO:USDC)"},"amount":{"type":"object","properties":{"kind":{"type":"string","enum":["fixed","percent","above"]},"amount":{"type":["string","null"],"description":"Fixed: sent each time"},"percent":{"type":["string","null"],"description":"Percent: share of the balance"},"keep":{"type":["string","null"],"description":"Above: the balance that stays"},"cap":{"type":["string","null"],"description":"The most one payment sends"}},"required":["kind","amount","percent","keep","cap"]},"schedule":{"type":"object","properties":{"startDate":{"type":"string"},"frequency":{"type":"string","enum":["weekly","fortnightly","monthly","quarterly","yearly"]},"dayOfMonth":{"type":["integer","null"]},"lastDay":{"type":"boolean"},"endDate":{"type":["string","null"]},"maxRuns":{"type":["integer","null"]}},"required":["startDate","frequency","dayOfMonth","lastDay","endDate","maxRuns"]},"timezone":{"type":"string"},"nextRunOn":{"type":["string","null"]},"paymentsMade":{"type":"integer"},"reference":{"type":["string","null"]},"lastRun":{"$ref":"#/components/schemas/RecurringRun"},"createdAt":{"type":"string"}},"required":["id","status","recipient","instrumentId","amount","schedule","timezone","nextRunOn","paymentsMade","reference","lastRun","createdAt"],"description":"A payment repeated on a schedule from the Primary portfolio (D134)"},"RecurringRun":{"type":["object","null"],"properties":{"id":{"type":"string"},"dueOn":{"type":"string","description":"The date it was for, local to the account"},"status":{"type":"string","enum":["running","created","skipped","failed"]},"amount":{"type":["string","null"],"description":"In the units of what is sent"},"reason":{"type":["string","null"],"description":"Why it was skipped or failed"},"instructionId":{"type":["string","null"]},"instructionState":{"type":["string","null"],"description":"The payment it made: pending_approval, settled…"}},"required":["id","dueOn","status","amount","reason","instructionId","instructionState"]},"ListedInvestment":{"allOf":[{"$ref":"#/components/schemas/Investment"},{"type":"object","properties":{"shown":{"type":["object","null"],"properties":{"currency":{"type":"string"},"last":{"type":"string"},"previousClose":{"type":["string","null"]}},"required":["currency","last","previousClose"],"description":"Prices in the asked currency at today's middle rate; an estimate"},"marketCap":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"Units in circulation × price, in the asked currency (or the trading one)"}]},"category":{"type":"string","enum":["cryptocurrency","tokenized_stock","tokenized_commodity","stablecoin","meme"],"description":"Digital assets: cryptocurrency, stablecoin, tokenized_stock…"},"rank":{"type":["number","null"],"description":"Digital assets: rank by market capitalisation; null when unranked"},"marketCapUsd":{"type":["string","null"],"description":"Digital assets: market capitalisation in US dollars (reference)"},"volume24hUsd":{"type":["string","null"],"description":"Digital assets: traded in the last 24 hours, in US dollars (reference)"},"change7d":{"type":["string","null"],"description":"Digital assets: change over seven days in percent (reference)"}},"required":["shown","marketCap"]}]},"Quote":{"type":["object","null"],"properties":{"bid":{"type":"string"},"ask":{"type":"string"},"last":{"type":"string"},"previousClose":{"type":["string","null"]},"asOf":{"type":"string","description":"When the price is from"},"freshness":{"type":"string","enum":["live","delayed","close"],"description":"live: minutes old; delayed: the usual 15–20 minute delay while the exchange trades; close: the exchange is shut or the price is from before today's open"}},"required":["bid","ask","last","previousClose","asOf","freshness"],"description":"Prices in the investment's currency; bonds per 100 of face value"},"Investment":{"type":"object","properties":{"id":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"},"market":{"type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"quantityDecimals":{"type":"number"},"priceDecimals":{"type":"number","description":"Most decimals its prices carry (four, more for coins below a cent)"},"securityType":{"type":["string","null"],"description":"common, preferred, etf, fund, adr, warrant, bond, index, crypto…"},"logo":{"type":"string","description":"Its logo, a path on this API (an image)"},"tradable":{"type":"boolean","description":"On offer now: an active, tradable listing with a price (always true in lists)"},"accent":{"type":["string","null"],"description":"Its logo's colour (#rrggbb) for washes, lines and borders, never text; null without one","example":"#f7931a"},"priceUsd":{"type":["string","null"],"description":"Digital assets: the last price in US dollars, shown beside the price in the account's currency; null for others"},"quote":{"$ref":"#/components/schemas/Quote"},"bond":{"type":["object","null"],"properties":{"couponRate":{"type":"string","example":"4.50"},"couponsPerYear":{"type":"number"},"maturityDate":{"type":"string"},"accruedPer100":{"type":"string","description":"Accrued interest today per 100 of face value"}},"required":["couponRate","couponsPerYear","maturityDate","accruedPer100"]},"term":{"type":["object","null"],"properties":{"rate":{"type":"string","example":"4.60"},"termDays":{"type":"number"},"minAmount":{"type":"string"}},"required":["rate","termDays","minAmount"],"description":"Yield: rate a year, length and smallest amount"}},"required":["id","symbol","name","assetClass","market","currency","description","quantityDecimals","priceDecimals","securityType","logo","tradable","accent","priceUsd","quote","bond","term"]},"InvestmentHistory":{"type":"object","properties":{"simulated":{"type":"boolean"},"series":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"points":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"close":{"type":"string","description":"In the investment's currency; bonds per 100"}},"required":["day","close"]}}},"required":["id","points"]}}},"required":["simulated","series"]},"InvestmentDetail":{"allOf":[{"$ref":"#/components/schemas/ListedInvestment"},{"type":"object","properties":{"profile":{"$ref":"#/components/schemas/DigitalAssetProfile"}},"required":["profile"]}]},"DigitalAssetProfile":{"type":["object","null"],"properties":{"description":{"type":["string","null"]},"category":{"type":"string"},"tags":{"type":"array","items":{"type":"string"}},"dateAdded":{"type":["string","null"]},"links":{"type":"object","properties":{"website":{"type":"array","items":{"type":"string"}},"whitepaper":{"type":"array","items":{"type":"string"}},"sourceCode":{"type":"array","items":{"type":"string"}},"explorers":{"type":"array","items":{"type":"string"}},"social":{"type":"object","properties":{"twitter":{"type":["string","null"]},"reddit":{"type":["string","null"]},"telegram":{"type":["string","null"]},"discord":{"type":["string","null"]},"facebook":{"type":["string","null"]},"forum":{"type":["string","null"]}},"required":["twitter","reddit","telegram","discord","facebook","forum"]}},"required":["website","whitepaper","sourceCode","explorers","social"]},"platform":{"type":["object","null"],"properties":{"name":{"type":"string"},"contract":{"type":"string"}},"required":["name","contract"],"description":"Tokens: the chain it is issued on and its contract address"},"metrics":{"type":"object","properties":{"rank":{"type":["number","null"]},"marketCapUsd":{"type":["string","null"]},"fdvUsd":{"type":["string","null"],"description":"Fully diluted market cap, US dollars"},"volume24hUsd":{"type":["string","null"]},"dominance":{"type":["string","null"],"description":"Share of all digital assets' market cap, percent"},"circulating":{"type":["string","null"]},"total":{"type":["string","null"]},"max":{"type":["string","null"]},"change":{"type":"object","properties":{"h1":{"type":["string","null"]},"d1":{"type":["string","null"]},"d7":{"type":["string","null"]},"d30":{"type":["string","null"]},"d60":{"type":["string","null"]},"d90":{"type":["string","null"]}},"required":["h1","d1","d7","d30","d60","d90"],"description":"Percent over 1 hour, 1, 7, 30, 60 and 90 days"},"ath":{"type":["object","null"],"properties":{"priceUsd":{"type":"string"},"at":{"type":["string","null"]}},"required":["priceUsd","at"],"description":"All-time high in US dollars, when known"},"atl":{"type":["object","null"],"properties":{"priceUsd":{"type":"string"},"at":{"type":["string","null"]}},"required":["priceUsd","at"],"description":"All-time low in US dollars, when known"},"updatedAt":{"type":["string","null"]}},"required":["rank","marketCapUsd","fdvUsd","volume24hUsd","dominance","circulating","total","max","change","ath","atl","updatedAt"]}},"required":["description","category","tags","dateAdded","links","platform","metrics"],"description":"Digital assets only; null for others"},"Order":{"type":"object","properties":{"id":{"type":"string"},"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string"},"limitPrice":{"type":["string","null"]},"state":{"type":"string"},"filledQuantity":{"type":"string"},"filledValue":{"allOf":[{"$ref":"#/components/schemas/Money"},{"description":"Paid (buy) or received (sell), with any accrued interest"}]},"setAside":{"type":"string","description":"Still set aside: cash for buys, units for sells"},"approvalsRequired":{"type":"number"},"approvals":{"type":"number"},"approvedByMe":{"type":"boolean"},"rejectReason":{"type":["string","null"]},"reason":{"type":["string","null"],"description":"Why the firm placed it under its discretionary mandate"},"createdAt":{"type":"string"}},"required":["id","portfolioId","instrumentId","side","type","quantity","limitPrice","state","filledQuantity","filledValue","setAside","approvalsRequired","approvals","approvedByMe","rejectReason","reason","createdAt"]},"Position":{"type":"object","properties":{"portfolioId":{"type":"string"},"investment":{"$ref":"#/components/schemas/Investment"},"quantity":{"type":"string"},"quantityInOrders":{"type":"string"},"costBase":{"$ref":"#/components/schemas/Money"},"value":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"]}]},"gain":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"]}]},"valueInAccountCurrency":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"The value in the account's main currency at today's middle rate; null without a rate"}]},"gainInAccountCurrency":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"]}]}},"required":["portfolioId","investment","quantity","quantityInOrders","costBase","value","gain","valueInAccountCurrency","gainInAccountCurrency"]},"Exchange":{"type":"object","properties":{"mic":{"type":"string"},"name":{"type":"string"},"shortName":{"type":"string"},"country":{"type":"string"},"currency":{"type":"string"},"timezone":{"type":"string"},"region":{"type":"string"},"days":{"type":"array","items":{"type":"number"},"description":"ISO weekdays it trades (1 = Monday)"},"sessions":{"type":"array","items":{"type":"object","properties":{"opens":{"type":"string"},"closes":{"type":"string"}},"required":["opens","closes"]}},"open":{"type":"boolean"},"changesAt":{"type":["string","null"],"description":"When it closes (open) or next opens (closed)"},"listings":{"type":"number","description":"What can be bought on it here"},"rate":{"type":["string","null"],"description":"1 of the asked currency in the exchange's, at today's middle rate"}},"required":["mic","name","shortName","country","currency","timezone","region","days","sessions","open","changesAt","listings","rate"]},"DigitalAssetCategory":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"count":{"type":"number"}},"required":["id","name","count"]},"MarketIndex":{"type":"object","properties":{"id":{"type":"string","example":"INDEX:SPX"},"name":{"type":"string"},"country":{"type":"string","description":"ISO 3166-1 alpha-2 (EU for a euro-area index)"},"value":{"type":"string","description":"The latest level, decimal","example":"6650.25"},"change":{"type":["string","null"],"description":"Change since the previous close, decimal"},"changePct":{"type":["string","null"],"description":"Percentage change, two decimals"},"currency":{"type":"string"},"at":{"type":["string","null"],"description":"When the level is from (delayed)"},"open":{"type":"boolean","description":"Whether its exchange is trading now"}},"required":["id","name","country","value","change","changePct","currency","at","open"]},"IndexPoint":{"type":"object","properties":{"at":{"type":"string"},"value":{"type":"string"}},"required":["at","value"]},"YieldHolding":{"type":"object","properties":{"id":{"type":"string"},"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"name":{"type":"string"},"amount":{"$ref":"#/components/schemas/Money"},"rate":{"type":"string"},"startDate":{"type":"string"},"maturityDate":{"type":"string"},"state":{"type":"string","enum":["active","matured","refused"]},"interestSoFar":{"$ref":"#/components/schemas/Money"},"interestAtMaturity":{"$ref":"#/components/schemas/Money"}},"required":["id","portfolioId","instrumentId","name","amount","rate","startDate","maturityDate","state","interestSoFar","interestAtMaturity"]},"CryptoDepositAddress":{"type":"object","properties":{"coin":{"type":"string"},"network":{"type":"string","enum":["bitcoin","ethereum","base","polygon","solana"]},"networkName":{"type":"string"},"address":{"type":"string"},"confirmationsNeeded":{"type":"number"}},"required":["coin","network","networkName","address","confirmationsNeeded"],"description":"Send only this coin on this network. It always arrives in the Primary portfolio."},"CryptoCoin":{"type":"object","properties":{"coin":{"type":"string"},"name":{"type":"string"},"instrumentId":{"type":["string","null"],"description":"The instrument held, when there is exactly one; else match by coin"},"logo":{"type":["string","null"],"description":"The coin's logo, a path on this API (an image); null when IDEALX lists no such coin"},"networks":{"type":"array","items":{"$ref":"#/components/schemas/CryptoNetwork"},"description":"Popular networks first, then the rest by name"}},"required":["coin","name","instrumentId","logo","networks"]},"CryptoNetwork":{"type":"object","properties":{"id":{"type":"string","description":"The network to name in other calls"},"name":{"type":"string"},"confirmations":{"type":"number"},"canReceive":{"type":"boolean"},"canSend":{"type":"boolean"},"minimumDeposit":{"type":["string","null"]},"minimumSend":{"type":["string","null"]},"maximumSend":{"type":["string","null"]},"networkFee":{"type":["string","null"],"description":"Fixed network fee, in the coin"},"networkFeePercent":{"type":["string","null"]},"decimals":{"type":"number"},"logo":{"type":["string","null"],"description":"The network's logo, a path on this API (an image); null when there is none"}},"required":["id","name","confirmations","canReceive","canSend","minimumDeposit","minimumSend","maximumSend","networkFee","networkFeePercent","decimals","logo"]},"CryptoReceive":{"type":"object","properties":{"coin":{"type":"string"},"network":{"type":"string"},"networkName":{"type":"string"},"address":{"type":"string"},"memo":{"type":["string","null"],"description":"Send it with the transfer when present"},"confirmationsNeeded":{"type":"number"},"minimum":{"type":["string","null"]}},"required":["coin","network","networkName","address","memo","confirmationsNeeded","minimum"]},"CryptoIncoming":{"type":"object","properties":{"id":{"type":"string"},"coin":{"type":"string"},"network":{"type":"string"},"quantity":{"type":"string"},"status":{"type":"string","enum":["confirming","checking","ready","failed"]},"confirmations":{"type":"number"},"confirmationsNeeded":{"type":"number"},"txHash":{"type":"string"},"seenAt":{"type":"string"},"readyAt":{"type":["string","null"]}},"required":["id","coin","network","quantity","status","confirmations","confirmationsNeeded","txHash","seenAt","readyAt"]},"CryptoAddress":{"type":"object","properties":{"id":{"type":"string"},"network":{"type":"string"},"address":{"type":"string"},"memo":{"type":["string","null"]},"label":{"type":"string"},"ownership":{"type":"string","enum":["mine","someone_else"]},"hosting":{"type":"string","enum":["self_hosted","exchange"]},"exchangeName":{"type":["string","null"]},"beneficiaryName":{"type":["string","null"]},"usableFrom":{"type":"string"},"createdAt":{"type":"string"}},"required":["id","network","address","memo","label","ownership","hosting","exchangeName","beneficiaryName","usableFrom","createdAt"]},"ActivityPage":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/ActivityItem"}},"nextCursor":{"type":["string","null"]},"summary":{"type":["object","null"],"properties":{"count":{"type":"integer"},"inflow":{"$ref":"#/components/schemas/Money"},"outflow":{"allOf":[{"$ref":"#/components/schemas/Money"},{"description":"Positive"}]},"complete":{"type":"boolean","description":"False when the account has more history than one request reads (tens of thousands of records): the figures then cover the newest part only"}},"required":["count","inflow","outflow","complete"],"description":"Null only when asked for with summary=false"},"facets":{"$ref":"#/components/schemas/ActivityFacets"}},"required":["items","nextCursor","summary","facets"]},"ActivityItem":{"type":"object","properties":{"id":{"type":"string","description":"Unique in the feed: order:…, send:…, receive:…, ins:… or tx:…"},"at":{"type":"string"},"kind":{"type":"string","enum":["deposit","withdrawal","buy","sell","order","transfer","receive","send","convert","dividend","interest","fee","adjustment","professional"],"description":"order: an order that has not filled (open, waiting for approval, cancelled, expired, refused); convert: a currency conversion or a filled order on a stablecoin"},"title":{"type":"string","example":"Bought 11 VAS"},"titleParts":{"type":"object","properties":{"verb":{"type":"string","example":"Bought"},"quantity":{"type":["string","null"],"example":"11"},"symbol":{"type":["string","null"],"example":"VAS"},"rest":{"type":["string","null"],"description":"What follows, e.g. → AUD"}},"required":["verb","quantity","symbol","rest"]},"status":{"type":"string","enum":["pending","done","cancelled","failed","approval"]},"statusDetail":{"type":"string","description":"The owning module's own state: an order's (open, filled…), a receipt's (pending, credited), an instruction's (pending_approval, settled…) or the register's"},"statusLabel":{"type":"string"},"flow":{"type":"string","enum":["in","out","within","none"],"description":"Money or assets came in, went out, moved between two portfolios both shown, or nothing moved yet (an order)"},"amount":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"Signed, in the currency it moved in (negative is out); for a conversion, what arrived"}]},"amountInAccountCurrency":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"The amount in the account's currency, signed. Null without a rate"}]},"estimate":{"type":"boolean","description":"The amount is at today's price (coins moved, an order not filled)"},"asset":{"type":["object","null"],"properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"},"quantity":{"type":"string","description":"Units moved or ordered, signed"}},"required":["instrumentId","symbol","name","assetClass","quantity"]},"assetClass":{"type":"string","description":"cash when no investment moved"},"portfolioIds":{"type":"array","items":{"type":"string"}},"portfolioId":{"type":["string","null"],"description":"The first of portfolioIds"},"actor":{"type":["object","null"],"properties":{"personId":{"type":"string"},"name":{"type":"string"}},"required":["personId","name"]},"orderId":{"type":["string","null"]},"transferId":{"type":["string","null"]},"txId":{"type":["string","null"],"description":"Open its details at /v1/accounts/{id}/transactions/{txId}"},"network":{"type":["string","null"]},"networkName":{"type":["string","null"]},"txHash":{"type":["string","null"]},"explorerUrl":{"type":["string","null"]},"detail":{"anyOf":[{"$ref":"#/components/schemas/DigitalAssetActivity"},{"type":"null"}],"description":"For a digital asset order or transfer: the item as Digital Assets shows it"}},"required":["id","at","kind","title","titleParts","status","statusDetail","statusLabel","flow","amount","amountInAccountCurrency","estimate","asset","assetClass","portfolioIds","portfolioId","actor","orderId","transferId","txId","network","networkName","txHash","explorerUrl","detail"]},"DigitalAssetActivity":{"type":"object","properties":{"id":{"type":"string","description":"Unique in the timeline: order:…, receive:… or send:…"},"kind":{"type":"string","enum":["order","receive","send","convert"],"description":"convert: a filled order on a stablecoin (coin to cash or cash to coin)"},"at":{"type":"string"},"instrumentId":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"quantity":{"type":"string","description":"Coin units: ordered, received or sent"},"status":{"type":"string","description":"An order's state; a receipt's pending, credited or unmatched; a send's instruction state"},"amount":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"In the account's currency, signed: received +, sent −; orders unsigned. Null without a price or rate"}]},"estimate":{"type":"boolean","description":"The amount is at today's price or rate, not what was paid"},"side":{"type":["string","null"],"enum":["buy","sell",null]},"orderId":{"type":["string","null"]},"orderType":{"type":["string","null"],"enum":["market","limit",null]},"limitPrice":{"type":["string","null"],"description":"In the coin's trading currency"},"priceCurrency":{"type":["string","null"]},"filledQuantity":{"type":["string","null"]},"filledValue":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"],"description":"In the coin's trading currency"}]},"transferId":{"type":["string","null"]},"network":{"type":["string","null"]},"networkName":{"type":["string","null"]},"address":{"type":["string","null"],"description":"Received: our deposit address. Sent: the saved address"},"addressLabel":{"type":["string","null"]},"txHash":{"type":["string","null"]},"explorerUrl":{"type":["string","null"]},"confirmations":{"type":["number","null"]},"confirmationsNeeded":{"type":["number","null"]}},"required":["id","kind","at","instrumentId","symbol","name","quantity","status","amount","estimate","side","orderId","orderType","limitPrice","priceCurrency","filledQuantity","filledValue","transferId","network","networkName","address","addressLabel","txHash","explorerUrl","confirmations","confirmationsNeeded"]},"ActivityFacets":{"type":["object","null"],"properties":{"kind":{"type":"array","items":{"type":"object","properties":{"value":{"type":"string"},"count":{"type":"integer"}},"required":["value","count"]}},"assetClass":{"type":"array","items":{"type":"object","properties":{"value":{"type":"string"},"count":{"type":"integer"}},"required":["value","count"]}},"status":{"type":"array","items":{"type":"object","properties":{"value":{"type":"string"},"count":{"type":"integer"}},"required":["value","count"]}},"currency":{"type":"array","items":{"type":"object","properties":{"value":{"type":"string"},"count":{"type":"integer"}},"required":["value","count"]}},"instruments":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"},"count":{"type":"integer"}},"required":["instrumentId","symbol","name","assetClass","count"]}},"people":{"type":"array","items":{"type":"object","properties":{"personId":{"type":"string"},"name":{"type":"string"},"count":{"type":"integer"}},"required":["personId","name","count"]}}},"required":["kind","assetClass","status","currency","instruments","people"],"description":"Counts for each filter's choices, with every other filter applied"},"Client":{"type":"object","properties":{"id":{"type":"string","description":"Client relationship id"},"personId":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"path":{"type":"string","enum":["firm_verified","confirm_link","invited","existing_user"]},"status":{"type":"string","enum":["pending","active","declined","ended"]},"verified":{"type":"boolean"},"signedIn":{"type":"boolean"},"createdAt":{"type":"string"}},"required":["id","personId","name","email","path","status","verified","signedIn","createdAt"]},"Mandate":{"type":"object","properties":{"portfolioId":{"type":"string"},"level":{"type":"string","enum":["view","advisory","discretionary"]},"limits":{"type":["object","null"],"properties":{"allowedAssetClasses":{"type":"array","items":{"type":"string","enum":["cash","equity","etf","fund","bond","yield_product","crypto","alternative"]}},"maxAmountPerInstruction":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"maxAmountPerDay":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"noWithdrawals":{"type":"boolean"},"noPayeeChanges":{"type":"boolean"}},"additionalProperties":false}},"required":["portfolioId","level","limits"]},"Engagement":{"type":"object","properties":{"id":{"type":"string"},"accountId":{"type":"string"},"firm":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"licence":{"type":["string","null"]}},"required":["id","name","licence"]},"status":{"type":"string","enum":["pending","active","declined","ended"]},"acceptedVia":{"type":["string","null"],"enum":["portal","firm_attestation","demo",null]},"startedAt":{"type":["string","null"]},"mandates":{"type":"array","items":{"$ref":"#/components/schemas/Mandate"}}},"required":["id","accountId","firm","status","acceptedVia","startedAt","mandates"]},"Proposal":{"type":"object","properties":{"id":{"type":"string"},"firmId":{"type":"string"},"accountId":{"type":"string"},"portfolioId":{"type":"string"},"title":{"type":"string"},"note":{"type":["string","null"],"description":"The message to the client"},"items":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["order"]},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string"},"limitPrice":{"type":"string"},"amount":{"type":"string"}},"required":["kind","instrumentId","side","type","quantity"]}},"status":{"type":"string","enum":["draft","pending_approval","approved","sent","viewed","accepted","declined","expired","superseded","withdrawn","executing","executed","failed"]},"approvalsRequired":{"type":"number"},"approvals":{"type":"number"},"approvedByMe":{"type":"boolean"},"needsCode":{"type":"boolean"},"results":{"type":["array","null"],"items":{"type":"object","properties":{"orderId":{"type":"string"},"error":{"type":"string"}}}},"expiresAt":{"type":"string"},"expiresInDays":{"type":"number"},"views":{"type":"number","description":"How often the client opened it (D166)"},"lastViewedAt":{"type":["string","null"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"sentAt":{"type":["string","null"]},"draftedBy":{"type":["string","null"],"enum":["agentx",null],"description":"AgentX wrote this draft and no person has changed it yet"},"rationale":{"type":["object","null"],"properties":{"objective":{"type":"string"},"recommendation":{"type":"string"},"alternatives":{"type":"string"},"draftedBy":{"type":"string","enum":["agentx","person"]}},"required":["recommendation"]},"costs":{"$ref":"#/components/schemas/ProposalCosts"},"checks":{"$ref":"#/components/schemas/ProposalChecks"},"needsSecondApproval":{"type":"boolean"},"author":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"approver":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"approvedAt":{"type":["string","null"]},"returnedComment":{"type":["string","null"]},"declineReason":{"type":["string","null"]},"supersededBy":{"type":["string","null"]},"adviceRecord":{"type":["object","null"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"sha256":{"type":"string"},"createdAt":{"type":"string"}},"required":["id","title","sha256","createdAt"]},"adviceRecordName":{"type":"string","description":"What the record of advice is called where the account is (D175): Record of advice, Suitability report…"},"nudge":{"type":"object","properties":{"count":{"type":"number"},"lastAt":{"type":["string","null"]},"nextAt":{"type":["string","null"]}},"required":["count","lastAt","nextAt"]},"history":{"type":"array","items":{"type":"object","properties":{"state":{"type":"string"},"at":{"type":"string"},"by":{"type":"string"},"comment":{"type":"string"}},"required":["state","at","by"]}},"canApprove":{"type":"boolean","description":"This team member may approve or return it now"}},"required":["id","firmId","accountId","portfolioId","title","note","items","status","approvalsRequired","approvals","approvedByMe","needsCode","results","expiresAt","expiresInDays","views","lastViewedAt","createdAt","updatedAt","sentAt","draftedBy","rationale","costs","checks","needsSecondApproval","author","approver","approvedAt","returnedComment","declineReason","supersededBy","adviceRecord","adviceRecordName","nudge","history","canApprove"]},"ProposalCosts":{"type":["object","null"],"properties":{"currency":{"type":"string"},"buys":{"type":"string"},"sells":{"type":"string"},"fees":{"type":"string"},"fx":{"type":"string"},"turnover":{"type":"string"},"gain":{"type":"string","description":"Estimated realised gain (lots, oldest first); an estimate"},"gainLongTerm":{"type":"string"},"gainEstimated":{"type":"boolean"},"cashBefore":{"type":"string"},"cashAfter":{"type":"string"},"totalBefore":{"type":"string"},"lines":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"quantity":{"type":"string"},"price":{"type":["string","null"]},"priceCurrency":{"type":"string"},"value":{"type":"string"},"valueBase":{"type":"string"},"fee":{"type":"string"},"gain":{"type":["string","null"]},"nowBp":{"type":"number"},"afterBp":{"type":"number"},"held":{"type":"string"}},"required":["instrumentId","symbol","name","assetClass","side","quantity","price","priceCurrency","value","valueBase","fee","gain","nowBp","afterBp","held"]}}},"required":["currency","buys","sells","fees","fx","turnover","gain","gainLongTerm","gainEstimated","cashBefore","cashAfter","totalBefore","lines"]},"ProposalChecks":{"type":["object","null"],"properties":{"policyVersion":{"type":["number","null"]},"outcome":{"type":"string","enum":["pass","warn","block"]},"ranAt":{"type":"string"},"results":{"type":"array","items":{"$ref":"#/components/schemas/PolicyCheck"}},"secondApproval":{"type":"object","properties":{"enabled":{"type":"boolean"},"required":{"type":"boolean"},"threshold":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["enabled","required","threshold"]}},"required":["policyVersion","outcome","ranAt","results","secondApproval"],"description":"The firm's own; null for the client"},"PolicyCheck":{"type":"object","properties":{"key":{"type":"string"},"outcome":{"type":"string","enum":["pass","warn","block"]},"label":{"type":"string"},"detail":{"type":"string"}},"required":["key","outcome","label","detail"]},"RadarItem":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["tax","contributions","idle_cash","maturity","drift","life_event"]},"client":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"account":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"portfolioId":{"type":["string","null"]},"jurisdiction":{"type":"string"},"title":{"type":"string","description":"Why: what was found, in one line"},"basis":{"type":"string","description":"What it rests on, e.g. Cost base · Before 30 Jun"},"impact":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"},"label":{"type":"string","description":"tax saved, a year, to place, room, off target"},"estimate":{"type":"boolean","description":"An indicative estimate (shown with ≈)"}},"required":["amount","currency","label","estimate"]},"dueOn":{"type":["string","null"]},"trades":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"name":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"quantity":{"type":"string"},"approx":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]}},"required":["instrumentId","name","side","quantity","approx"]},"description":"What a draft would carry; empty: written in the builder"},"facts":{"type":"object","additionalProperties":{}},"owners":{"type":"array","items":{"type":"string"}},"status":{"type":"string","enum":["open","dismissed","snoozed"]},"snoozedUntil":{"type":["string","null"]},"proposalId":{"type":["string","null"]},"foundAt":{"type":"string"},"scannedAt":{"type":"string"}},"required":["id","kind","client","account","portfolioId","jurisdiction","title","basis","impact","dueOn","trades","facts","owners","status","snoozedUntil","proposalId","foundAt","scannedAt"]},"RadarScan":{"type":["object","null"],"properties":{"status":{"type":"string","enum":["running","done","failed"]},"trigger":{"type":"string","enum":["nightly","manual"]},"found":{"type":"number"},"startedAt":{"type":"string"},"finishedAt":{"type":["string","null"]}},"required":["status","trigger","found","startedAt","finishedAt"]},"Renewal":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["annual_review","fact_find","fee_renewal","id_expiry","annual_pack"]},"label":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"personId":{"type":"string"}},"required":["id","name","personId"]},"account":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}},"required":["id","name"]},"jurisdiction":{"type":"string"},"anchorOn":{"type":"string"},"basis":{"type":"string","description":"What it counts from, e.g. Last review 3 Dec"},"dueOn":{"type":"string"},"opensOn":{"type":"string"},"windowEndsOn":{"type":"string"},"daysToDue":{"type":"number"},"stage":{"type":"string","enum":["later","open","due","in_window","lapsed"]},"needsSignature":{"type":"boolean"},"status":{"type":"string","enum":["upcoming","prepared","sent","answered","needs_adviser","done","lapsed","dismissed"]},"note":{"type":["string","null"]},"draft":{"type":["object","null"],"properties":{"subject":{"type":"string"},"body":{"type":"string"},"by":{"type":"string","enum":["agentx","template"]},"form":{"type":["object","null"],"properties":{"title":{"type":"string"},"fields":{"type":"array","items":{"type":"string"}}},"required":["title","fields"]},"meeting":{"type":["object","null"],"properties":{"title":{"type":"string"},"minutes":{"type":"number"}},"required":["title","minutes"]},"facts":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"]}}},"required":["subject","body","by","form","meeting","facts"]},"conversationId":{"type":["string","null"]},"sentAt":{"type":["string","null"]},"sentBy":{"type":["string","null"],"enum":["agentx","person",null]},"answeredAt":{"type":["string","null"]},"answer":{"type":["string","null"]},"doneAt":{"type":["string","null"]},"onLapse":{"type":["string","null"]},"source":{"type":"string"},"facts":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"]}},"owners":{"type":"array","items":{"type":"string"}}},"required":["id","kind","label","client","account","jurisdiction","anchorOn","basis","dueOn","opensOn","windowEndsOn","daysToDue","stage","needsSignature","status","note","draft","conversationId","sentAt","sentBy","answeredAt","answer","doneAt","onLapse","source","facts","owners"]},"ProfessionalFirm":{"type":["object","null"],"properties":{"name":{"type":"string"},"country":{"type":["string","null"],"description":"Where the firm is licensed"},"licence":{"type":["string","null"]},"verified":{"type":"boolean","description":"The firm's own IDEALX account is open (D119)"},"practice":{"type":"string","enum":["advice","accounting"],"description":"advice, or accounting: an accounting practice is given view access only (D165)"}},"required":["name","country","licence","verified","practice"]},"ProfessionalInvitation":{"type":"object","properties":{"id":{"type":"string"},"accountId":{"type":"string"},"accountName":{"type":"string"},"accountType":{"type":"string"},"status":{"type":"string","enum":["pending_approval","sent","awaiting_registration","changes_proposed","active","declined","expired","cancelled","ended"]},"email":{"type":"string"},"target":{"type":"string","enum":["member","firm","unregistered"]},"firm":{"$ref":"#/components/schemas/ProfessionalFirm"},"firmId":{"type":["string","null"]},"person":{"type":["string","null"],"description":"The professional: who accepted, else who was invited"},"invitedBy":{"type":"string"},"items":{"type":"array","items":{"type":"object","properties":{"portfolioId":{"type":"string"},"portfolioName":{"type":"string"},"level":{"type":"string","enum":["view","advisory","discretionary"]},"limits":{"type":["object","null"],"properties":{"allowedAssetClasses":{"type":"array","items":{"type":"string","enum":["cash","equity","etf","fund","bond","yield_product","crypto","alternative"]}},"maxAmountPerInstruction":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"maxAmountPerDay":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"noWithdrawals":{"type":"boolean"},"noPayeeChanges":{"type":"boolean"}},"additionalProperties":false}},"required":["portfolioId","portfolioName","level","limits"]}},"originPortfolioId":{"type":["string","null"]},"approvals":{"type":"number"},"approvalsRequired":{"type":"number"},"approvedByMe":{"type":"boolean"},"counter":{"type":["object","null"],"properties":{"items":{"type":"array","items":{"type":"object","properties":{"portfolioId":{"type":"string"},"portfolioName":{"type":"string"},"level":{"type":"string","enum":["view","advisory","discretionary"]},"limits":{"type":["object","null"],"properties":{"allowedAssetClasses":{"type":"array","items":{"type":"string","enum":["cash","equity","etf","fund","bond","yield_product","crypto","alternative"]}},"maxAmountPerInstruction":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"maxAmountPerDay":{"type":"object","properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"noWithdrawals":{"type":"boolean"},"noPayeeChanges":{"type":"boolean"}},"additionalProperties":false}},"required":["portfolioId","portfolioName","level","limits"]}},"note":{"type":["string","null"]},"fee":{"type":["object","null"],"properties":{"id":{"type":"string"},"status":{"type":"string"},"scheduleName":{"type":"string"},"summary":{"type":"string"}},"required":["id","status","scheduleName","summary"]},"approvals":{"type":"number"},"approvedByMe":{"type":"boolean"}},"required":["items","note","fee","approvals","approvedByMe"],"description":"The firm's proposed changes, waiting for the customer"},"engagementId":{"type":["string","null"]},"declineReason":{"type":["string","null"]},"expiresAt":{"type":"string"},"sentAt":{"type":["string","null"]},"decidedAt":{"type":["string","null"]},"createdAt":{"type":"string"}},"required":["id","accountId","accountName","accountType","status","email","target","firm","firmId","person","invitedBy","items","originPortfolioId","approvals","approvalsRequired","approvedByMe","counter","engagementId","declineReason","expiresAt","sentAt","decidedAt","createdAt"]},"Conversation":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["firm","support","assistant"]},"subject":{"type":"string"},"firmId":{"type":["string","null"]},"personId":{"type":"string"},"status":{"type":"string","enum":["open","closed"]},"lastMessageAt":{"type":"string"},"unread":{"type":"number"}},"required":["id","kind","subject","firmId","personId","status","lastMessageAt","unread"]},"Message":{"type":"object","properties":{"id":{"type":"string"},"authorKind":{"type":"string","enum":["customer","team_member","support","assistant","system"]},"authorName":{"type":"string"},"body":{"type":"string"},"attachments":{"type":"array","items":{"type":"object","properties":{"fileId":{"type":"string"},"name":{"type":"string"},"size":{"type":"number"},"contentType":{"type":"string"}},"required":["fileId","name","size","contentType"]}},"createdAt":{"type":"string"}},"required":["id","authorKind","authorName","body","attachments","createdAt"]},"MessageCompliance":{"type":"object","properties":{"overrideReason":{"type":"string","minLength":3,"maxLength":500}}},"InstructionEntry":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["trade","transfer","withdrawal","crypto_withdrawal","fx","term"]},"accountId":{"type":"string"},"portfolioId":{"type":["string","null"]},"summary":{"type":"string"},"amount":{"type":["object","null"],"properties":{"amount":{"type":"string"},"currency":{"type":"string"}},"required":["amount","currency"]},"origin":{"type":"string","enum":["customer","firm","agent","proposal","system"]},"channel":{"type":"string","enum":["portal","console","ios","android","api","system"]},"status":{"type":"string","enum":["waiting_approval","waiting_market","processing","sent","done","failed","cancelled","expired"]},"statusLabel":{"type":"string"},"parentId":{"type":["string","null"]},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","kind","accountId","portfolioId","summary","amount","origin","channel","status","statusLabel","parentId","createdAt","updatedAt"],"description":"One request to move money or assets, from any channel (D72)"},"Conversion":{"type":"object","properties":{"id":{"type":"string"},"portfolioId":{"type":"string"},"from":{"$ref":"#/components/schemas/Money"},"to":{"$ref":"#/components/schemas/Money"},"rate":{"type":"string"},"state":{"type":"string","enum":["placing","done","failed"]},"failureReason":{"type":["string","null"]},"createdAt":{"type":"string"}},"required":["id","portfolioId","from","to","rate","state","failureReason","createdAt"]}},"parameters":{}},"paths":{"/v1/health":{"get":{"tags":["system"],"operationId":"getHealth","summary":"Service health","description":"Liveness and database reachability. No authentication.","responses":{"200":{"description":"Healthy","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Health"}}}},"503":{"description":"Degraded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Health"}}}}}}},"/v1/catalog":{"get":{"tags":["catalog"],"operationId":"getCatalog","summary":"Account types and their wizards","description":"Only jurisdictions switched on for the portal are listed. Public; cacheable.","responses":{"200":{"description":"Catalog","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/v1/accounts/{id}/strategies":{"get":{"tags":["accounts"],"operationId":"accountStrategies","summary":"The strategies this account's portfolios follow, and how close they are","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"strategies":{"type":"array","items":{"$ref":"#/components/schemas/FollowedStrategy"}}},"required":["strategies"]}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/strategies":{"get":{"tags":["console"],"operationId":"listStrategies","summary":"Your firm's strategies","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"strategies":{"type":"array","items":{"type":"object","additionalProperties":{}}}},"required":["strategies"]}}}}}}},"/v1/firms/{firmId}/strategies/universe":{"get":{"tags":["console"],"operationId":"strategyUniverse","summary":"Listed investments to build a strategy from, with fee, yield, region and liquidity","description":"The brokerage catalog (the same tradable listings as GET /v1/investments: shares, funds, bonds and digital assets) with the cockpit's facts. The firm's strategies' investments come first, then its jurisdiction's exchanges and currency: an order only, nothing is left out. Facts never add a listing.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string","maxLength":60},"required":false,"name":"q","in":"query"},{"schema":{"type":"string","enum":["all","shares","funds","bonds","digital"],"description":"all, shares, funds, bonds or digital"},"required":false,"description":"all, shares, funds, bonds or digital","name":"kind","in":"query"},{"schema":{"type":"string","maxLength":12,"description":"A market's MIC (XNYS), CRYPTO or OTC"},"required":false,"description":"A market's MIC (XNYS), CRYPTO or OTC","name":"market","in":"query"},{"schema":{"type":"string","pattern":"^[A-Za-z]{2}$","description":"Only listings on this country's exchanges"},"required":false,"description":"Only listings on this country's exchanges","name":"country","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3},"required":false,"name":"listingCurrency","in":"query"},{"schema":{"type":"string","maxLength":4000,"description":"Exactly these instrument ids, comma-separated (favourites)"},"required":false,"description":"Exactly these instrument ids, comma-separated (favourites)","name":"ids","in":"query"},{"schema":{"type":"string","enum":["Shares","Bonds","Real assets","Cash","Digital assets"]},"required":false,"name":"group","in":"query"},{"schema":{"type":"string","maxLength":40},"required":false,"name":"region","in":"query"},{"schema":{"type":["integer","null"],"minimum":0,"maximum":1000},"required":false,"name":"maxFeeBp","in":"query"},{"schema":{"type":["integer","null"],"minimum":0,"maximum":5000},"required":false,"name":"minYieldBp","in":"query"},{"schema":{"type":"string","enum":["day","week"]},"required":false,"name":"liquidity","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":100},"required":false,"name":"limit","in":"query"},{"schema":{"type":["integer","null"],"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"investments":{"type":"array","items":{"type":"object","additionalProperties":{}}},"simulated":{"type":"boolean","description":"Some facts are simulated (staging)"},"total":{"type":["number","null"],"description":"How many match; null when filtering on facts with more to read"},"more":{"type":"boolean","description":"There is a next page (offset + limit)"}},"required":["investments","simulated","total","more"]}}}}}}},"/v1/firms/{firmId}/strategies/benchmarks":{"get":{"tags":["console"],"operationId":"strategyBenchmarks","summary":"Listings a strategy can be compared with: the firm's country's indices, then world ones","description":"From the catalog's jurisdiction profile (D178), only listings the brokerage catalog has on offer. A strategy has no benchmark until the firm picks one.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"benchmarks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"symbol":{"type":"string"},"name":{"type":"string"},"currency":{"type":"string"},"index":{"type":"string","description":"The index it tracks"},"scope":{"type":"string","enum":["home","global"]}},"required":["id","symbol","name","currency","index","scope"]}}},"required":["benchmarks"]}}}}}}},"/v1/firms/{firmId}/strategies/{strategyId}":{"get":{"tags":["console"],"operationId":"getStrategy","summary":"A strategy with its versions and the portfolios following it","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"strategyId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":{}}}}}}}},"/v1/firms/{firmId}/strategies/{strategyId}/analysis":{"get":{"tags":["console"],"operationId":"analyseStrategy","summary":"Back-test, mix, liquidity and fee effect of a strategy version (D126)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"strategyId","in":"path"},{"schema":{"type":["integer","null"]},"required":false,"name":"version","in":"query"},{"schema":{"type":"string","description":"An instrument id to compare with"},"required":false,"description":"An instrument id to compare with","name":"benchmark","in":"query"},{"schema":{"type":["integer","null"],"minimum":0,"maximum":1000},"required":false,"name":"feeBp","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StrategyAnalysis"}}}}}}},"/v1/firms/{firmId}/strategies/{strategyId}/versions/diff":{"get":{"tags":["console"],"operationId":"diffStrategyVersions","summary":"Two versions compared: weights that changed and the figures before and after","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"strategyId","in":"path"},{"schema":{"type":"integer","minimum":1},"required":true,"name":"from","in":"query"},{"schema":{"type":"integer","minimum":1},"required":true,"name":"to","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":{}}}}},"404":{"description":"No such version","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/retirement/summary":{"get":{"tags":["retirement"],"operationId":"getRetirementSummary","summary":"A retirement fund at a glance: contributions by year, beneficiaries, pensions","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetirementSummary"}}}},"404":{"description":"Not a retirement fund","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/retirement":{"get":{"tags":["retirement"],"operationId":"getRetirementYear","summary":"A retirement fund's year: members, contributions, pensions and checklist","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":["integer","null"],"description":"The year the financial year ends in"},"required":false,"description":"The year the financial year ends in","name":"year","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetirementYear"}}}},"404":{"description":"Not a retirement fund","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/retirement/pack.csv":{"get":{"tags":["retirement"],"operationId":"getRetirementPack","summary":"The year as a CSV for the fund's accountant","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":["integer","null"],"description":"The year the financial year ends in"},"required":false,"description":"The year the financial year ends in","name":"year","in":"query"}],"responses":{"200":{"description":"CSV","content":{"text/csv":{"schema":{"type":"string"}}}},"404":{"description":"Not a retirement fund","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/profile":{"get":{"tags":["accounts"],"operationId":"getAccountProfile","summary":"The account's holder, the details given when it opened, and its tax details","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountProfile"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}":{"get":{"tags":["accounts"],"operationId":"getAccount","summary":"One account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"Account","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Account"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/detail":{"get":{"tags":["accounts"],"operationId":"getAccountDetail","summary":"An account with its portfolios and balances","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","enum":["client"],"description":"Console's See as client: the actions are the client's, not yours (a team member only; logged each time)"},"required":false,"description":"Console's See as client: the actions are the client's, not yours (a team member only; logged each time)","name":"as","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountDetail"}}}},"403":{"description":"See as client is for a firm's team","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/portfolios":{"post":{"tags":["accounts"],"operationId":"openPortfolio","summary":"Open another portfolio","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"}},"required":["name"]}}}},"responses":{"201":{"description":"Opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountDetail"}}}},"409":{"description":"Name taken or limit reached","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/portfolios/{portfolioId}":{"patch":{"tags":["accounts"],"operationId":"renamePortfolio","summary":"Rename a portfolio","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"portfolioId","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"}},"required":["name"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountDetail"}}}}}}},"/v1/accounts/{id}/portfolios/{portfolioId}/close":{"post":{"tags":["accounts"],"operationId":"closePortfolio","summary":"Close an empty extra portfolio (never the Primary)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"portfolioId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountDetail"}}}},"409":{"description":"Primary, or not empty","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/portfolios/{portfolioId}/activity":{"get":{"tags":["accounts"],"operationId":"portfolioActivity","summary":"Movements on a portfolio, newest first","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"portfolioId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"activity":{"type":"array","items":{"type":"object","properties":{"entryId":{"type":"string"},"kind":{"type":"string"},"description":{"type":"string"},"amount":{"$ref":"#/components/schemas/Money"},"position":{"type":["object","null"],"properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"quantity":{"type":"string"}},"required":["instrumentId","symbol","quantity"],"description":"Set when units of an investment moved (amount is then zero)"},"createdAt":{"type":"string"}},"required":["entryId","kind","description","amount","position","createdAt"]}}},"required":["activity"]}}}}}}},"/v1/accounts/{id}/transfers":{"post":{"tags":["money"],"operationId":"transferBetweenPortfolios","summary":"Move cash, or units of an investment, between two portfolios of this account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","description":"Idempotency-Key: 16-128 chars; repeat it to retry safely"},"required":true,"description":"Idempotency-Key: 16-128 chars; repeat it to retry safely","name":"idempotency-key","in":"header"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fromPortfolioId":{"type":"string"},"toPortfolioId":{"type":"string"},"amount":{"$ref":"#/components/schemas/Money"},"position":{"type":"object","properties":{"instrumentId":{"type":"string"},"quantity":{"type":"string"}},"required":["instrumentId","quantity"],"description":"Move units of an investment (cost base kept) instead of cash"},"reference":{"type":"string","maxLength":140},"note":{"type":"string","maxLength":1000,"description":"Why, in your words; kept with the record, not sent with the payment"},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/FileUpload"},"maxItems":5}},"required":["fromPortfolioId","toPortfolioId"]}}}},"responses":{"200":{"description":"Settled, or waiting for approval","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Instruction"}}}},"409":{"description":"Not enough balance, closed portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid amount","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/instructions":{"get":{"tags":["money"],"operationId":"listInstructions","summary":"Transfers and withdrawals on this account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"instructions":{"type":"array","items":{"$ref":"#/components/schemas/Instruction"}}},"required":["instructions"]}}}}}}},"/v1/accounts/{id}/transactions":{"get":{"tags":["accounts"],"operationId":"listTransactions","summary":"Account activity: one line per transaction, newest first (D138)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Only cash in this currency"},"required":false,"description":"Only cash in this currency","name":"currency","in":"query"},{"schema":{"type":"string","description":"Only this investment"},"required":false,"description":"Only this investment","name":"instrumentId","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":200},"required":false,"name":"limit","in":"query"}],"responses":{"200":{"description":"Transactions","content":{"application/json":{"schema":{"type":"object","properties":{"transactions":{"type":"array","items":{"$ref":"#/components/schemas/Transaction"}}},"required":["transactions"]}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/transactions/{txId}":{"get":{"tags":["accounts"],"operationId":"getTransaction","summary":"One transaction in plain words: what, when, amounts, fees, rate, from and to, documents","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"txId","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"The transaction","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TransactionDetail"}}}},"404":{"description":"No such transaction","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/reports/cash-statement":{"get":{"tags":["reports"],"operationId":"getCashStatement","summary":"A cash statement for one currency, like a bank statement: opening, every transaction with money in, money out and the balance, closing","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Defaults to the account's main currency"},"required":false,"description":"Defaults to the account's main currency","name":"currency","in":"query"}],"responses":{"200":{"description":"The cash statement","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CashStatement"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/reports/cash-statement.csv":{"get":{"tags":["reports"],"operationId":"getCashStatementCsv","summary":"The cash statement for bookkeeping: one row per transaction with its reference and counterparty (D138)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Defaults to the account's main currency"},"required":false,"description":"Defaults to the account's main currency","name":"currency","in":"query"}],"responses":{"200":{"description":"CSV","content":{"text/csv":{"schema":{"type":"string"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/reports/performance":{"get":{"tags":["reports"],"operationId":"getPerformance","summary":"Value over time and time-weighted returns, for the account or one portfolio","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Performance"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/reports/allocation":{"get":{"tags":["reports"],"operationId":"getAllocation","summary":"How the account (or a portfolio) splits by kind of asset and by currency","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Allocation"}}}}}}},"/v1/accounts/{id}/reports/statement":{"get":{"tags":["reports"],"operationId":"getStatement","summary":"A statement for a period: opening, every movement, closing; ?format=csv for a spreadsheet","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"string","enum":["json","csv"]},"required":false,"name":"format","in":"query"}],"responses":{"200":{"description":"The statement","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Statement"}},"text/csv":{"schema":{"type":"string"}}}}}}},"/v1/accounts/{id}/reports/tax":{"get":{"tags":["reports"],"operationId":"getTaxYear","summary":"The tax year in the account's country: sales lot by lot, and income; ?format=csv","description":"year is the year the tax year ends in (Australia 2026: 1 July 2025 to 30 June 2026). Default: the last full tax year.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"},{"schema":{"type":"string","enum":["json","csv"]},"required":false,"name":"format","in":"query"}],"responses":{"200":{"description":"The tax year","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxYear"}},"text/csv":{"schema":{"type":"string"}}}}}}},"/v1/accounts/{id}/reports/annual":{"get":{"tags":["reports"],"operationId":"getAnnualPack","summary":"The annual pack for a tax year: performance, the statement for the year, and the tax year","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnualPack"}}}}}}},"/v1/accounts/{id}/documents/statement.pdf":{"get":{"tags":["documents"],"operationId":"getStatementPdf","summary":"The cash statement for a period and one currency as a PDF, like a bank statement (one per currency the account has held)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Defaults to the account's main currency"},"required":false,"description":"Defaults to the account's main currency","name":"currency","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/confirmation.pdf":{"get":{"tags":["documents"],"operationId":"getAccountConfirmationPdf","summary":"A letter confirming the account and its details, as proof of account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/holdings.pdf":{"get":{"tags":["documents"],"operationId":"getHoldingsPdf","summary":"What the account holds now and what it is worth, by portfolio and asset class","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/holdings.csv":{"get":{"tags":["documents"],"operationId":"getHoldingsCsv","summary":"What the account holds now, line by line, as a spreadsheet (the holdings PDF's twin)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"The holdings as CSV","content":{"text/csv":{"schema":{"type":"string"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/tax.pdf":{"get":{"tags":["documents"],"operationId":"getTaxYearPdf","summary":"The tax year report as a PDF (estimated, not tax advice)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/annual.pdf":{"get":{"tags":["documents"],"operationId":"getAnnualPackPdf","summary":"The annual pack as one PDF: the year's summary, the tax year and the statement","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/documents/fees.pdf":{"get":{"tags":["documents"],"operationId":"getAccountFeesPdf","summary":"The fees charged on the account, as a PDF","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/retirement/pack.pdf":{"get":{"tags":["documents"],"operationId":"getRetirementPackPdf","summary":"A retirement fund's year (My super) as a PDF for the fund's accountant","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"integer","minimum":2000,"maximum":2100},"required":false,"name":"year","in":"query"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/instructions/{id}/receipt.pdf":{"get":{"tags":["documents"],"operationId":"getInstructionReceiptPdf","summary":"A receipt for a payment, a digital asset send or a transfer between portfolios","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/orders/{id}/confirmation.pdf":{"get":{"tags":["documents"],"operationId":"getTradeConfirmationPdf","summary":"The trade confirmation for an order that filled","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not filled yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fee-statements/{id}/statement.pdf":{"get":{"tags":["documents"],"operationId":"getFirmFeeStatementPdf","summary":"A firm's monthly fee statement as a PDF","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"The document as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounting/formats":{"get":{"tags":["accounting"],"operationId":"listAccountingFormats","summary":"Accounting software formats: the countries and account types each serves, its files and columns","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string","minLength":2,"maxLength":2},"required":false,"name":"jurisdiction","in":"query"},{"schema":{"type":"string"},"required":false,"name":"accountType","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"formats":{"type":"array","items":{"$ref":"#/components/schemas/AccountingFormat"}}},"required":["formats"]}}}}}}},"/v1/accounting/mappings/defaults":{"get":{"tags":["accounting"],"operationId":"getAccountingMappingDefaults","summary":"The suggested chart of accounts mapping for a format in a country, and the country's tax fields","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"format","in":"query"},{"schema":{"type":"string","minLength":2,"maxLength":2},"required":true,"name":"jurisdiction","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string"},"jurisdiction":{"type":"string"},"entries":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"label":{"type":"string"},"code":{"type":"string"},"name":{"type":"string"}},"required":["key","label","code","name"]}},"extras":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"appliesTo":{"type":"string"},"kind":{"type":"string"},"explain":{"type":"string"}},"required":["id","label","appliesTo","kind","explain"]}}},"required":["format","jurisdiction","entries","extras"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/accounting/transactions":{"get":{"tags":["accounting"],"operationId":"getAccountingTransactions","summary":"The account's transactions for a period in the neutral accounting model, its holdings at the end, and whether the rows add up to the ledger","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"account":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"jurisdiction":{"type":"string"},"currency":{"type":"string"},"type":{"type":"string"},"variantId":{"type":"string"},"retirement":{"type":["object","null"],"properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"]}},"required":["id","name","jurisdiction","currency","type","variantId","retirement"]},"from":{"type":"string"},"to":{"type":"string"},"rows":{"type":"array","items":{"$ref":"#/components/schemas/AccountingRow"}},"holdings":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string"},"portfolioId":{"type":"string"},"portfolioName":{"type":"string"},"instrument":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"name":{"type":"string"},"assetClass":{"type":"string"}},"required":["id","code","name","assetClass"]},"quantity":{"type":"string"},"price":{"type":["string","null"]},"currency":{"type":"string"},"value":{"type":["string","null"]},"costBase":{"type":["string","null"]},"approximate":{"type":"boolean"}},"required":["date","portfolioId","portfolioName","instrument","quantity","price","currency","value","costBase","approximate"]}},"reconciled":{"type":"boolean"},"reconciliation":{"type":"array","items":{"type":"object","properties":{"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"opening":{"type":"string"},"movements":{"type":"string"},"closing":{"type":"string"},"ok":{"type":"boolean"}},"required":["portfolioId","instrumentId","opening","movements","closing","ok"]}},"warnings":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"count":{"type":"number"}},"required":["code","message","count"]}}},"required":["account","from","to","rows","holdings","reconciled","reconciliation","warnings"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/accounting/preview":{"get":{"tags":["accounting"],"operationId":"previewAccountingExport","summary":"What an export would hold: row counts, totals, warnings and the first rows","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"format","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"profileId","in":"query"},{"schema":{"type":"string"},"required":false,"name":"portfolioId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountingPreview"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/accounting/exports":{"get":{"tags":["accounting"],"operationId":"listAccountExports","summary":"Exports you made of this account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"exports":{"type":"array","items":{"$ref":"#/components/schemas/AccountingExport"}}},"required":["exports"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounting/exports":{"get":{"tags":["accounting"],"operationId":"listAccountingExports","summary":"Your exports (a firm's for its clients), newest first; one batch with batchId","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":false,"name":"batchId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"exports":{"type":"array","items":{"$ref":"#/components/schemas/AccountingExport"}}},"required":["exports"]}}}}}}},"/v1/accounting/exports/{exportId}":{"get":{"tags":["accounting"],"operationId":"getAccountingExport","summary":"One export and its files","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"exportId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountingExport"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounting/exports/{exportId}/files/{fileId}":{"get":{"tags":["accounting"],"operationId":"downloadAccountingExportFile","summary":"Download one file of an export","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"exportId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"fileId","in":"path"}],"responses":{"200":{"description":"The file (CSV, Excel or ZIP)","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounting/profiles":{"get":{"tags":["accounting"],"operationId":"listAccountingProfiles","summary":"Your mapping profiles (a firm's with x-firm-id)","security":[{"apiKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"profiles":{"type":"array","items":{"$ref":"#/components/schemas/AccountingProfile"}}},"required":["profiles"]}}}}}}},"/v1/accounting/schedules":{"get":{"tags":["accounting"],"operationId":"listAccountingSchedules","summary":"Recurring exports","security":[{"apiKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"schedules":{"type":"array","items":{"$ref":"#/components/schemas/AccountingSchedule"}}},"required":["schedules"]}}}}}}},"/v1/firms/{firmId}/accounting/accounts":{"get":{"tags":["accounting"],"operationId":"listFirmAccountingAccounts","summary":"The accounts the firm is engaged on that this team member sees, with their type and last export","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"accounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"clientName":{"type":"string"},"accountType":{"type":"string"},"accountTypeId":{"type":"string"},"jurisdiction":{"type":"string"},"retirement":{"type":["string","null"]},"lastExport":{"type":["object","null"],"properties":{"id":{"type":"string"},"format":{"type":"string"},"to":{"type":"string"},"createdAt":{"type":"string"}},"required":["id","format","to","createdAt"]}},"required":["id","name","clientName","accountType","accountTypeId","jurisdiction","retirement","lastExport"]}}},"required":["accounts"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Not possible now","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/library":{"get":{"tags":["library"],"operationId":"listLibrary","summary":"The firm's Library: files and AgentX's outputs you can see, and the folders","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string","maxLength":100},"required":false,"name":"q","in":"query"},{"schema":{"type":"string","enum":["pdf","image","sheet","doc","text","email","media","archive","other"]},"required":false,"name":"type","in":"query"},{"schema":{"type":"string","maxLength":64},"required":false,"name":"clientId","in":"query"},{"schema":{"type":"string","maxLength":40},"required":false,"name":"tag","in":"query"},{"schema":{"type":"string","maxLength":64},"required":false,"name":"by","in":"query"},{"schema":{"type":"string","maxLength":64},"required":false,"name":"folderId","in":"query"},{"schema":{"type":"string","enum":["upload","agentx_chat","agentx_output","research_memo","client_report"]},"required":false,"name":"origin","in":"query"},{"schema":{"type":"string","enum":["true","false"],"description":"Recently deleted"},"required":false,"description":"Recently deleted","name":"deleted","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/LibraryItem"}},"folders":{"type":"array","items":{"$ref":"#/components/schemas/LibraryFolder"}}},"required":["items","folders"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/library/items/{id}":{"get":{"tags":["library"],"operationId":"getLibraryItem","summary":"One item with its versions and shares","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"item":{"$ref":"#/components/schemas/LibraryItem"},"versions":{"type":"array","items":{"$ref":"#/components/schemas/LibraryVersion"}},"shares":{"type":"array","items":{"$ref":"#/components/schemas/LibraryShare"}}},"required":["item","versions","shares"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/library/items/{id}/file":{"get":{"tags":["library"],"operationId":"downloadLibraryItem","summary":"Download the current version (or versionId); a file kept in a regional store answers with a short-lived address","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"versionId","in":"query"},{"schema":{"type":"string","enum":["1"],"description":"Show in the browser (preview)"},"required":false,"description":"Show in the browser (preview)","name":"inline","in":"query"},{"schema":{"type":"string","enum":["url"],"description":"url: answer with the bucket address as JSON instead of a redirect"},"required":false,"description":"url: answer with the bucket address as JSON instead of a redirect","name":"as","in":"query"}],"responses":{"200":{"description":"The file","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}}}},"302":{"description":"A short-lived address in the firm's regional store"},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/library/items/{id}/preview":{"get":{"tags":["library"],"operationId":"previewLibraryItem","summary":"A spreadsheet's first rows, or a document's text, to show in the Library","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":false,"name":"versionId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"sheets":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"rows":{"type":"array","items":{"type":"array","items":{"type":"string"}}}},"required":["name","rows"]}},"text":{"type":["string","null"]}},"required":["sheets","text"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Not valid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fees/settings":{"get":{"tags":["fees"],"operationId":"getFirmFeeSettings","summary":"The firm's fee settings: tax on fees, and its country's limits","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FirmFeeSettings"}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fee-schedules":{"get":{"tags":["fees"],"operationId":"listFeeSchedules","summary":"The firm's fee schedules","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"schedules":{"type":"array","items":{"$ref":"#/components/schemas/FeeSchedule"}}},"required":["schedules"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fee-agreements":{"get":{"tags":["fees"],"operationId":"listFirmFeeAgreements","summary":"Fees offered to clients and in force","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"agreements":{"type":"array","items":{"$ref":"#/components/schemas/FeeAgreement"}}},"required":["agreements"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fee-statements":{"get":{"tags":["fees"],"operationId":"listFeeStatements","summary":"Monthly statements: fees collected, IDEALX's share, tax and the net paid to the firm","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"statements":{"type":"array","items":{"$ref":"#/components/schemas/FeeStatement"}}},"required":["statements"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/fee-statements/{id}":{"get":{"tags":["fees"],"operationId":"getFeeStatement","summary":"One statement with each fee in it; ?format=csv for a spreadsheet","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","enum":["json","csv"]},"required":false,"name":"format","in":"query"}],"responses":{"200":{"description":"The statement","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeeStatementDetail"}},"text/csv":{"schema":{"type":"string"}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/fees":{"get":{"tags":["fees"],"operationId":"getAccountFees","summary":"Fees on an account: offers to answer, fees in force, and what was charged","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountFees"}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/orders/fee":{"get":{"tags":["investing"],"operationId":"previewOrderFee","summary":"The transaction fee an order would pay, before placing it","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"instrumentId","in":"query"},{"schema":{"type":"string","enum":["buy","sell"]},"required":true,"name":"side","in":"query"},{"schema":{"type":"string"},"required":true,"name":"quantity","in":"query"},{"schema":{"type":"string","enum":["market","limit"]},"required":false,"name":"type","in":"query"},{"schema":{"type":"string"},"required":false,"name":"limitPrice","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderFee"}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/currency-accounts":{"get":{"tags":["money"],"operationId":"listCurrencyAccounts","summary":"The account's currency accounts and the currencies it can ask for","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrencyAccounts"}}}}}}},"/v1/accounts/{id}/deposit-details":{"get":{"tags":["money"],"operationId":"getDepositDetails","summary":"The account details to pay into (issued on first request)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","description":"Defaults to the account's main currency"},"required":false,"description":"Defaults to the account's main currency","name":"currency","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepositDetails"}}}},"409":{"description":"No provider for this currency yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/bank-schemes":{"get":{"tags":["money"],"operationId":"listBankSchemes","summary":"The ways to pay a currency and the details each needs (the usual one first)","parameters":[{"schema":{"type":"string","minLength":3,"maxLength":3},"required":true,"name":"currency","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"schemes":{"type":"array","items":{"$ref":"#/components/schemas/BankScheme"}}},"required":["schemes"]}}}}}}},"/v1/accounts/{id}/recurring-payments":{"get":{"tags":["money"],"operationId":"listRecurringPayments","summary":"Recurring Payments of the account, newest first","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"recurringPayments":{"type":"array","items":{"$ref":"#/components/schemas/RecurringPayment"}}},"required":["recurringPayments"]}}}}}}},"/v1/accounts/{id}/recurring-payments/{recurringId}":{"get":{"tags":["money"],"operationId":"getRecurringPayment","summary":"A recurring payment and its runs, newest first","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"recurringId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/RecurringPayment"},{"type":"object","properties":{"runs":{"type":"array","items":{"$ref":"#/components/schemas/RecurringRun"}}},"required":["runs"]}],"description":"A payment repeated on a schedule from the Primary portfolio (D134)"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/investments":{"get":{"tags":["investing"],"operationId":"listInvestments","summary":"Shares, ETFs, bonds and digital assets you can buy","description":"Searched, filtered, sorted and paged on the server (D140). With `currency`, each price is also shown in it at today's middle rate (an estimate), and price and market cap sort in it.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string","enum":["equity","etf","bond","yield_product","crypto"]},"required":false,"name":"assetClass","in":"query"},{"schema":{"type":"string","enum":["all","shares","funds","bonds","digital"],"description":"A kind of the brokerage catalog instead of assetClass and types: all, shares, funds (ETFs and listed funds), bonds or digital (every security type of it)"},"required":false,"description":"A kind of the brokerage catalog instead of assetClass and types: all, shares, funds (ETFs and listed funds), bonds or digital (every security type of it)","name":"kind","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Only listings traded in this currency"},"required":false,"description":"Only listings traded in this currency","name":"listingCurrency","in":"query"},{"schema":{"type":"string","pattern":"^[A-Za-z]{2}$","description":"Show this country's exchanges first (ISO 3166-1 alpha-2): an order only, nothing is left out"},"required":false,"description":"Show this country's exchanges first (ISO 3166-1 alpha-2): an order only, nothing is left out","name":"preferCountry","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3,"description":"Show listings in this currency first: an order only"},"required":false,"description":"Show listings in this currency first: an order only","name":"preferCurrency","in":"query"},{"schema":{"type":"string","maxLength":60},"required":false,"name":"q","in":"query"},{"schema":{"type":"string","maxLength":12,"description":"A market's MIC (XNYS), CRYPTO or OTC"},"required":false,"description":"A market's MIC (XNYS), CRYPTO or OTC","name":"market","in":"query"},{"schema":{"type":"string","minLength":3,"maxLength":3},"required":false,"name":"currency","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"Security types, comma-separated (common, etf, fund, preferred, adr, warrant, bond, index, crypto…); default: common shares, ETFs and coins"},"required":false,"description":"Security types, comma-separated (common, etf, fund, preferred, adr, warrant, bond, index, crypto…); default: common shares, ETFs and coins","name":"types","in":"query"},{"schema":{"type":"string","enum":["name","price","change","marketCap","rank","relevance"],"description":"rank: digital assets by market rank, unranked last (the default when listing digital assets); relevance: closest matches to q first, then the preference (the default with preferCountry or preferCurrency)"},"required":false,"description":"rank: digital assets by market rank, unranked last (the default when listing digital assets); relevance: closest matches to q first, then the preference (the default with preferCountry or preferCurrency)","name":"sort","in":"query"},{"schema":{"type":"string","enum":["cryptocurrency","tokenized_stock","tokenized_commodity","stablecoin","meme"],"description":"Digital assets of this category only"},"required":false,"description":"Digital assets of this category only","name":"category","in":"query"},{"schema":{"type":"string","enum":["asc","desc"]},"required":false,"name":"order","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":200},"required":false,"name":"limit","in":"query"},{"schema":{"type":["integer","null"],"minimum":0},"required":false,"name":"offset","in":"query"},{"schema":{"type":"string","pattern":"^[A-Za-z]{2}$","description":"Only listings on this country's exchanges (ISO 3166-1 alpha-2)"},"required":false,"description":"Only listings on this country's exchanges (ISO 3166-1 alpha-2)","name":"country","in":"query"},{"schema":{"type":"string","enum":["true","false"],"description":"true: only listings that moved today (a previous close and a change)"},"required":false,"description":"true: only listings that moved today (a previous close and a change)","name":"moved","in":"query"},{"schema":{"type":"string","pattern":"^\\d{1,12}(\\.\\d{1,4})?$","description":"Only listings priced at least this, in `currency` when given (else their own), e.g. 1.00"},"required":false,"description":"Only listings priced at least this, in `currency` when given (else their own), e.g. 1.00","name":"minPrice","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"investments":{"type":"array","items":{"$ref":"#/components/schemas/ListedInvestment"}},"total":{"type":"number","description":"How many match, across all pages"}},"required":["investments","total"]}}}}}}},"/v1/investments/history":{"get":{"tags":["investing"],"operationId":"investmentHistory","summary":"Closing prices for several investments at once (D126), for charts and sparklines","description":"Oldest first, one close per recorded day. `simulated` is true when any of it comes from the staging path, never market data.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string","maxLength":2000,"description":"Investment ids, comma separated (at most 50)"},"required":true,"description":"Investment ids, comma separated (at most 50)","name":"ids","in":"query"},{"schema":{"type":"string","enum":["1m","3m","6m","1y","3y","5y","max"],"default":"1y"},"required":false,"name":"range","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvestmentHistory"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/investments/{id}":{"get":{"tags":["investing"],"operationId":"getInvestment","summary":"One investment with its latest price","description":"With `currency`, its price in that currency too (`shown`, an estimate at today's middle rate).","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","minLength":3,"maxLength":3},"required":false,"name":"currency","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvestmentDetail"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/orders":{"post":{"tags":["investing"],"operationId":"placeOrder","summary":"Buy or sell in a portfolio","description":"The cash (buy) or units (sell) are set aside at once. A market buy sets aside 3% above the price; what is not used comes back.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","description":"Idempotency-Key: 16-128 chars; repeat it to retry safely"},"required":true,"description":"Idempotency-Key: 16-128 chars; repeat it to retry safely","name":"idempotency-key","in":"header"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string","example":"10"},"limitPrice":{"type":"string","example":"45.10"},"linkedTo":{"type":"string","description":"An instruction this belongs with, e.g. the currency conversion that funds it"},"reason":{"type":"string","maxLength":200,"description":"A firm's own trade under a discretionary mandate: why, in one line (required then; kept with the order and audited)"}},"required":["portfolioId","instrumentId","side","type","quantity"]}}}},"responses":{"200":{"description":"Filled, working, waiting for approval, or refused by the market","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"409":{"description":"Not enough cash or units, or no price","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid quantity or price","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"tags":["investing"],"operationId":"listOrders","summary":"Orders on this account, newest first","description":"Without filters: the latest 100. With any of `status`, `from`, `to`, `assetClass`, `q`, `portfolioId`, `limit` or `offset`: filtered and paged on the server (up to 5,000 matching), with `total`.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","maxLength":200,"description":"open (still working), done (ended), or order states comma-separated (filled,cancelled…)"},"required":false,"description":"open (still working), done (ended), or order states comma-separated (filled,cancelled…)","name":"status","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Placed on or after this day (UTC)"},"required":false,"description":"Placed on or after this day (UTC)","name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Placed on or before this day (UTC)"},"required":false,"description":"Placed on or before this day (UTC)","name":"to","in":"query"},{"schema":{"type":"string","enum":["equity","etf","bond","crypto"]},"required":false,"name":"assetClass","in":"query"},{"schema":{"type":"string","maxLength":60,"description":"Name or symbol"},"required":false,"description":"Name or symbol","name":"q","in":"query"},{"schema":{"type":"string","maxLength":80},"required":false,"name":"portfolioId","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":200},"required":false,"name":"limit","in":"query"},{"schema":{"type":["integer","null"],"minimum":0},"required":false,"name":"offset","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"total":{"type":"number","description":"How many match, across all pages"}},"required":["orders","total"]}}}}}}},"/v1/orders/{id}/approve":{"post":{"tags":["investing"],"operationId":"approveOrder","summary":"Approve an order waiting for you","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"409":{"description":"Wrong state","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/orders/{id}/cancel":{"post":{"tags":["investing"],"operationId":"cancelOrder","summary":"Cancel an order that has not filled","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Order"}}}},"409":{"description":"Wrong state","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/positions":{"get":{"tags":["investing"],"operationId":"listPositions","summary":"What each portfolio owns beyond cash, with cost base and value","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"positions":{"type":"array","items":{"$ref":"#/components/schemas/Position"}}},"required":["positions"]}}}}}}},"/v1/accounts/{id}/realised-gains":{"get":{"tags":["investing"],"operationId":"listRealisedGains","summary":"Sales, lot by lot: cost, proceeds and gain","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"sales":{"type":"array","items":{"type":"object","properties":{"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"quantity":{"type":"string"},"acquiredAt":{"type":"string"},"soldAt":{"type":"string"},"cost":{"$ref":"#/components/schemas/Money"},"proceeds":{"$ref":"#/components/schemas/Money"},"gain":{"$ref":"#/components/schemas/Money"}},"required":["portfolioId","instrumentId","quantity","acquiredAt","soldAt","cost","proceeds","gain"]}}},"required":["sales"]}}}}}}},"/v1/markets/exchanges":{"get":{"tags":["investing"],"operationId":"listExchanges","summary":"Stock exchanges: hours, open now, listings here, and the rate from a currency","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string","minLength":3,"maxLength":3},"required":false,"name":"currency","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"exchanges":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}}},"required":["exchanges"]}}}}}}},"/v1/markets/digital-assets/categories":{"get":{"tags":["investing"],"operationId":"listDigitalAssetCategories","summary":"Digital asset categories with how many coins are offered in each","security":[{"apiKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"categories":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAssetCategory"}}},"required":["categories"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/markets/indices":{"get":{"tags":["investing"],"operationId":"listMarketIndices","summary":"Major market indices (view only), the person's country first, with delayed levels","security":[{"apiKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"indices":{"type":"array","items":{"$ref":"#/components/schemas/MarketIndex"}}},"required":["indices"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/markets/indices/{id}/history":{"get":{"tags":["investing"],"operationId":"marketIndexHistory","summary":"An index's line: the latest session's levels (1d), or daily closes over a month or a year","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string","minLength":1,"maxLength":40},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","enum":["1d","1m","1y"],"default":"1d"},"required":false,"name":"range","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"points":{"type":"array","items":{"$ref":"#/components/schemas/IndexPoint"}}},"required":["points"]}}}},"401":{"description":"Not signed in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such index","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/logos/{instrumentId}":{"get":{"tags":["investing"],"operationId":"getLogo","summary":"An investment's logo, from IDEALX's own store (D143)","description":"An image (PNG, JPEG, WebP or SVG). A lettermark until a logo is stored. No authentication; cached long. With `format=png` the image comes as a square PNG `size` pixels wide (default 128), for apps that cannot draw SVG (D163).","parameters":[{"schema":{"type":"string","maxLength":80},"required":true,"name":"instrumentId","in":"path"},{"schema":{"type":"string","enum":["png"]},"required":false,"name":"format","in":"query"},{"schema":{"type":"string","enum":["64","128","256"]},"required":false,"name":"size","in":"query"}],"responses":{"200":{"description":"The image","content":{"image/png":{"schema":{"type":"string","format":"binary"}},"image/svg+xml":{"schema":{"type":"string","format":"binary"}}}},"304":{"description":"Not changed"},"404":{"description":"No such investment","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/yield":{"post":{"tags":["investing"],"operationId":"startYield","summary":"Put cash from a portfolio into yield","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","description":"Idempotency-Key: 16-128 chars; repeat it to retry safely"},"required":true,"description":"Idempotency-Key: 16-128 chars; repeat it to retry safely","name":"idempotency-key","in":"header"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"amount":{"$ref":"#/components/schemas/Money"}},"required":["portfolioId","instrumentId","amount"]}}}},"responses":{"200":{"description":"Placed, or returned if the provider refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/YieldHolding"}}}},"409":{"description":"Not enough cash, or not open","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Below the smallest amount","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"tags":["investing"],"operationId":"listYield","summary":"Yield on this account, with interest so far","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"yield":{"type":"array","items":{"$ref":"#/components/schemas/YieldHolding"}}},"required":["yield"]}}}}}}},"/v1/accounts/{id}/income":{"get":{"tags":["investing"],"operationId":"listIncome","summary":"Dividends, interest, repayments and splits received","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"income":{"type":"array","items":{"type":"object","properties":{"portfolioId":{"type":"string"},"instrumentId":{"type":"string"},"kind":{"type":"string","enum":["dividend","coupon","redemption","split"]},"payDate":{"type":"string"},"units":{"type":"string"},"amount":{"allOf":[{"$ref":"#/components/schemas/Money"},{"type":["object","null"]}]},"unitsAdded":{"type":["string","null"]}},"required":["portfolioId","instrumentId","kind","payDate","units","amount","unitsAdded"]}}},"required":["income"]}}}}}}},"/v1/crypto/assets":{"get":{"tags":["crypto"],"operationId":"listCryptoAssets","summary":"The coins IDEALX holds and the networks (blockchains) each moves on, usual one first","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"assets":{"type":"array","items":{"type":"object","properties":{"instrumentId":{"type":"string"},"symbol":{"type":"string"},"networks":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","enum":["bitcoin","ethereum","base","polygon","solana"]},"name":{"type":"string"},"confirmations":{"type":"number"}},"required":["id","name","confirmations"]}}},"required":["instrumentId","symbol","networks"]}}},"required":["assets"]}}}}}}},"/v1/accounts/{id}/crypto/deposit-address":{"get":{"tags":["crypto"],"operationId":"getCryptoDepositAddress","summary":"Where to send a coin (issued on first request)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","enum":["BTC","ETH","USDC"]},"required":true,"name":"coin","in":"query"},{"schema":{"type":"string","enum":["bitcoin","ethereum","base","polygon","solana"],"description":"One of the coin's networks (GET /v1/crypto/assets); its usual one if left out"},"required":false,"description":"One of the coin's networks (GET /v1/crypto/assets); its usual one if left out","name":"network","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CryptoDepositAddress"}}}},"409":{"description":"Not available","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/crypto/deposits":{"get":{"tags":["crypto"],"operationId":"listCryptoDeposits","summary":"Coins received, including those still waiting for confirmations","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"deposits":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"coin":{"type":"string"},"quantity":{"type":"string"},"status":{"type":"string","enum":["pending","credited","unmatched"]},"confirmations":{"type":"number"},"confirmationsNeeded":{"type":"number"},"txHash":{"type":"string"},"receivedAt":{"type":"string"}},"required":["id","coin","quantity","status","confirmations","confirmationsNeeded","txHash","receivedAt"]}}},"required":["deposits"]}}}}}}},"/v1/accounts/{id}/crypto/coins":{"get":{"tags":["crypto"],"operationId":"listAccountCryptoCoins","summary":"Coins this account can receive and send, with each network's minimums and fees","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"scope":{"type":"string","enum":["all","listed"],"description":"all: every coin listed can be received, held or not, and addresses carry a memo; listed: the few coins IDEALX holds"},"coins":{"type":"array","items":{"$ref":"#/components/schemas/CryptoCoin"}}},"required":["scope","coins"]}}}}}}},"/v1/accounts/{id}/crypto/receive":{"get":{"tags":["crypto"],"operationId":"getCryptoReceive","summary":"Where to send a coin on a network, with its memo when the network needs one","description":"Any coin the account can receive, held or not. It arrives in the Primary portfolio.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","pattern":"^[A-Za-z0-9]{1,15}$"},"required":true,"name":"coin","in":"query"},{"schema":{"type":"string","pattern":"^[A-Za-z0-9_-]{2,32}$"},"required":false,"name":"network","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CryptoReceive"}}}},"409":{"description":"Not available","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/crypto/incoming":{"get":{"tags":["crypto"],"operationId":"listCryptoIncoming","summary":"Coins on their way in and received, by coin and network","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"incoming":{"type":"array","items":{"$ref":"#/components/schemas/CryptoIncoming"}}},"required":["incoming"]}}}}}}},"/v1/accounts/{id}/crypto/addresses":{"get":{"tags":["crypto"],"operationId":"listCryptoAddresses","summary":"Saved addresses to send crypto to, with network and memo","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"addresses":{"type":"array","items":{"$ref":"#/components/schemas/CryptoAddress"}}},"required":["addresses"]}}}}}}},"/v1/accounts/{id}/activity":{"get":{"tags":["accounts"],"operationId":"listActivity","summary":"Everything that happened on an account in one list, newest first: money in and out, trades, orders, transfers, coins, income and fees (D150)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional"},"required":false,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional","name":"kind","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product"},"required":false,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product","name":"assetClass","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated instrument ids"},"required":false,"description":"Comma-separated instrument ids","name":"instrumentId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"Part of a name or symbol"},"required":false,"description":"Part of a name or symbol","name":"q","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: pending, done, cancelled, failed, approval"},"required":false,"description":"Comma-separated: pending, done, cancelled, failed, approval","name":"status","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"First day (YYYY-MM-DD)"},"required":false,"description":"First day (YYYY-MM-DD)","name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Last day, included"},"required":false,"description":"Last day, included","name":"to","in":"query"},{"schema":{"type":"string","enum":["today","7d","30d","ytd","fy"],"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply"},"required":false,"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply","name":"period","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Smallest amount in the account's currency, either sign"},"required":false,"description":"Smallest amount in the account's currency, either sign","name":"amountMin","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Largest amount in the account's currency, either sign"},"required":false,"description":"Largest amount in the account's currency, either sign","name":"amountMax","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"Comma-separated currencies"},"required":false,"description":"Comma-separated currencies","name":"currency","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated"},"required":false,"description":"Comma-separated","name":"portfolioId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"The person who asked (person id)"},"required":false,"description":"The person who asked (person id)","name":"actor","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":200},"required":false,"name":"limit","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"nextCursor of a page"},"required":false,"description":"nextCursor of a page","name":"cursor","in":"query"},{"schema":{"type":"string","enum":["true","false"],"description":"false leaves out the facets (later pages need none)"},"required":false,"description":"false leaves out the facets (later pages need none)","name":"facets","in":"query"},{"schema":{"type":"string","enum":["true","false"],"description":"false leaves out the summary (later pages need none). With facets=false too, the page is read with keyset paging, up to its cursor only"},"required":false,"description":"false leaves out the summary (later pages need none). With facets=false too, the page is read with keyset paging, up to its cursor only","name":"summary","in":"query"}],"responses":{"200":{"description":"A page of the feed, the totals of everything it matches and the facets","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityPage"}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/activity.csv":{"get":{"tags":["accounts"],"operationId":"getActivityCsv","summary":"The activity feed with the same filters as a spreadsheet, newest first (at most 10000 rows)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional"},"required":false,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional","name":"kind","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product"},"required":false,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product","name":"assetClass","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated instrument ids"},"required":false,"description":"Comma-separated instrument ids","name":"instrumentId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"Part of a name or symbol"},"required":false,"description":"Part of a name or symbol","name":"q","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: pending, done, cancelled, failed, approval"},"required":false,"description":"Comma-separated: pending, done, cancelled, failed, approval","name":"status","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"First day (YYYY-MM-DD)"},"required":false,"description":"First day (YYYY-MM-DD)","name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Last day, included"},"required":false,"description":"Last day, included","name":"to","in":"query"},{"schema":{"type":"string","enum":["today","7d","30d","ytd","fy"],"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply"},"required":false,"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply","name":"period","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Smallest amount in the account's currency, either sign"},"required":false,"description":"Smallest amount in the account's currency, either sign","name":"amountMin","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Largest amount in the account's currency, either sign"},"required":false,"description":"Largest amount in the account's currency, either sign","name":"amountMax","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"Comma-separated currencies"},"required":false,"description":"Comma-separated currencies","name":"currency","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated"},"required":false,"description":"Comma-separated","name":"portfolioId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"The person who asked (person id)"},"required":false,"description":"The person who asked (person id)","name":"actor","in":"query"}],"responses":{"200":{"description":"CSV","content":{"text/csv":{"schema":{"type":"string"}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/activity/report":{"get":{"tags":["accounts"],"operationId":"getActivityReport","summary":"The filtered activity feed as a named file: a branded PDF (at most 10000 rows), CSV or Excel workbook (D152)","description":"Takes the feed's filters. The file name comes from the report's name and today's date (Content-Disposition). At most 20 reports a minute per person.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional"},"required":false,"description":"Comma-separated: deposit, withdrawal, buy, sell, order, transfer, receive, send, convert, dividend, interest, fee, adjustment, professional","name":"kind","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product"},"required":false,"description":"Comma-separated: cash, equity, etf, fund, bond, crypto, yield_product","name":"assetClass","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated instrument ids"},"required":false,"description":"Comma-separated instrument ids","name":"instrumentId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"Part of a name or symbol"},"required":false,"description":"Part of a name or symbol","name":"q","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated: pending, done, cancelled, failed, approval"},"required":false,"description":"Comma-separated: pending, done, cancelled, failed, approval","name":"status","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"First day (YYYY-MM-DD)"},"required":false,"description":"First day (YYYY-MM-DD)","name":"from","in":"query"},{"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$","description":"Last day, included"},"required":false,"description":"Last day, included","name":"to","in":"query"},{"schema":{"type":"string","enum":["today","7d","30d","ytd","fy"],"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply"},"required":false,"description":"In the account's time zone. fy: the account's country's tax year (its catalog start day); ytd: since 1 January. With from/to, both apply","name":"period","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Smallest amount in the account's currency, either sign"},"required":false,"description":"Smallest amount in the account's currency, either sign","name":"amountMin","in":"query"},{"schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Largest amount in the account's currency, either sign"},"required":false,"description":"Largest amount in the account's currency, either sign","name":"amountMax","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"Comma-separated currencies"},"required":false,"description":"Comma-separated currencies","name":"currency","in":"query"},{"schema":{"type":"string","maxLength":2000,"description":"Comma-separated"},"required":false,"description":"Comma-separated","name":"portfolioId","in":"query"},{"schema":{"type":"string","maxLength":80,"description":"The person who asked (person id)"},"required":false,"description":"The person who asked (person id)","name":"actor","in":"query"},{"schema":{"type":"string","enum":["pdf","csv","xlsx"],"description":"pdf (the default), csv or xlsx"},"required":false,"description":"pdf (the default), csv or xlsx","name":"format","in":"query"},{"schema":{"type":"string","maxLength":120,"description":"The report's name; by default one made from the filters"},"required":false,"description":"The report's name; by default one made from the filters","name":"name","in":"query"},{"schema":{"type":"string","maxLength":400,"description":"Comma-separated, in order: date, type, asset, quantity, price, amount, currency, accountAmount, status, portfolio, person, reference"},"required":false,"description":"Comma-separated, in order: date, type, asset, quantity, price, amount, currency, accountAmount, status, portfolio, person, reference","name":"columns","in":"query"},{"schema":{"type":"string","enum":["0","1","true","false"],"description":"Start with totals by currency and counts by type (PDF and Excel). Default 1"},"required":false,"description":"Start with totals by currency and counts by type (PDF and Excel). Default 1","name":"summary","in":"query"},{"schema":{"type":"string","enum":["day","month"],"description":"How the PDF groups rows; by default by day up to a month, else by month"},"required":false,"description":"How the PDF groups rows; by default by day up to a month, else by month","name":"group","in":"query"}],"responses":{"200":{"description":"The report","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}},"text/csv":{"schema":{"type":"string"}},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"No such account or portfolio","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Unknown columns, or too many rows for the format","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Too many reports in a minute","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/digital-assets/activity":{"get":{"tags":["crypto"],"operationId":"listDigitalAssetActivity","summary":"Orders on digital assets and wallet transfers, in one timeline, newest first","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string","enum":["all","orders","transfers"],"description":"orders: placed, open, filled, cancelled; transfers: received, sent, converted"},"required":false,"description":"orders: placed, open, filled, cancelled; transfers: received, sent, converted","name":"type","in":"query"},{"schema":{"type":"integer","minimum":1,"maximum":100},"required":false,"name":"limit","in":"query"},{"schema":{"type":"string","maxLength":200,"description":"nextCursor of a page"},"required":false,"description":"nextCursor of a page","name":"cursor","in":"query"},{"schema":{"type":"string","pattern":"^CRYPTO:[A-Za-z0-9._-]{1,40}$","description":"One coin's activity only (CRYPTO:BTC)"},"required":false,"description":"One coin's activity only (CRYPTO:BTC)","name":"instrumentId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAssetActivity"}},"nextCursor":{"type":["string","null"]}},"required":["items","nextCursor"]}}}},"403":{"description":"Not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/clients":{"get":{"tags":["console"],"operationId":"listClients","summary":"Clients you can see","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"clients":{"type":"array","items":{"$ref":"#/components/schemas/Client"}}},"required":["clients"]}}}}}}},"/v1/firms/{firmId}/clients/{clientId}":{"get":{"tags":["console"],"operationId":"getClient","summary":"A client with the accounts you work on and the applications you made","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"clientId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"client":{"$ref":"#/components/schemas/Client"},"engagements":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/Engagement"},{"type":"object","properties":{"accountName":{"type":"string"},"accountTypeId":{"type":"string"}},"required":["accountName","accountTypeId"]}]}},"applications":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"accountTypeId":{"type":"string"},"status":{"type":"string"},"accountId":{"type":["string","null"]},"createdAt":{"type":"string"}},"required":["id","accountTypeId","status","accountId","createdAt"]}}},"required":["client","engagements","applications"]}}}}}}},"/v1/firms/{firmId}/accounts/{accountId}/proposals":{"post":{"tags":["console"],"operationId":"createProposal","summary":"Write a proposal for a portfolio: a draft, or sent at once with `send`","description":"A draft until sent. With `send: true` it goes on at once: to a colleague when the firm's second approval applies, else to the client (rationale needed, no check may block). An Idempotency-Key header makes a retry return the same proposal.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"accountId","in":"path"},{"schema":{"type":"string"},"required":false,"name":"idempotency-key","in":"header"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"portfolioId":{"type":"string"},"title":{"type":"string","minLength":3,"maxLength":120},"note":{"type":"string","maxLength":2000},"items":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["order"]},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string"},"limitPrice":{"type":"string"},"amount":{"type":"string","pattern":"^\\d{1,12}(\\.\\d{1,8})?$","description":"Instead of quantity: an amount in the investment's currency"}},"required":["kind","instrumentId","side","type"]},"minItems":1,"maxItems":20},"rationale":{"type":"object","properties":{"objective":{"type":"string","maxLength":2000},"recommendation":{"type":"string","maxLength":4000},"alternatives":{"type":"string","maxLength":2000},"draftedBy":{"type":"string","enum":["agentx","person"]}},"required":["recommendation"]},"expiresInDays":{"type":"integer","minimum":1,"maximum":30},"send":{"type":"boolean"}},"required":["portfolioId","title","items"]}}}},"responses":{"201":{"description":"Written","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Proposal"}}}},"403":{"description":"No mandate allows it","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/proposals":{"get":{"tags":["console"],"operationId":"listFirmProposals","summary":"Proposals your firm sent","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":false,"name":"accountId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"proposals":{"type":"array","items":{"$ref":"#/components/schemas/Proposal"}}},"required":["proposals"]}}}}}}},"/v1/firms/{firmId}/proposals/{proposalId}/withdraw":{"post":{"tags":["console"],"operationId":"withdrawProposal","summary":"Withdraw a proposal: a draft, one waiting for approval, or one the client has not answered","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"proposalId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Proposal"}}}}}}},"/v1/firms/{firmId}/radar":{"get":{"tags":["console"],"operationId":"firmRadar","summary":"Opportunities in the firm's book, ranked by money at stake","description":"Tax-loss harvesting (by the country's rules), contribution room near the tax year's end, idle cash, maturities, drift outside bands, milestone birthdays and hints in clients' messages. Scanned nightly and on demand; each reader sees only the clients they may. Estimates are indicative.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string","enum":["tax","contributions","idle_cash","maturity","drift","life_event"]},"required":false,"name":"kind","in":"query"},{"schema":{"type":"string","enum":["true","false"],"description":"Only clients you work with"},"required":false,"description":"Only clients you work with","name":"mine","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"total":{"type":"number"},"counts":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["tax","contributions","idle_cash","maturity","drift","life_event"]},"count":{"type":"number"}},"required":["kind","count"]}},"items":{"type":"array","items":{"$ref":"#/components/schemas/RadarItem"}},"lastScan":{"$ref":"#/components/schemas/RadarScan"}},"required":["total","counts","items","lastScan"]}}}},"403":{"description":"Not an advice role","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/radar/{itemId}":{"get":{"tags":["console"],"operationId":"firmRadarItem","summary":"One opportunity","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"itemId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RadarItem"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/renewals":{"get":{"tags":["console"],"operationId":"firmRenewals","summary":"What comes round for the firm's clients, by due day","description":"Annual reviews, fact-finds, ongoing fee renewals where the country requires them, ID document expiry and the yearly pack, from the country's rules and each client's dates; open ones by default, or a status, a kind or one client (every status).","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"anyOf":[{"type":"string","enum":["upcoming","prepared","sent","answered","needs_adviser","done","lapsed","dismissed"]},{"type":"string","enum":["open"]}]},"required":false,"name":"status","in":"query"},{"schema":{"type":"string","enum":["annual_review","fact_find","fee_renewal","id_expiry","annual_pack"]},"required":false,"name":"kind","in":"query"},{"schema":{"type":"string","maxLength":64},"required":false,"name":"clientId","in":"query"},{"schema":{"type":"string","enum":["true","false"]},"required":false,"name":"mine","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"today":{"type":"string"},"items":{"type":"array","items":{"$ref":"#/components/schemas/Renewal"}},"counts":{"type":"object","properties":{"needsAdviser":{"type":"number"},"prepared":{"type":"number"},"sent":{"type":"number"},"answered":{"type":"number"},"dueIn30":{"type":"number"}},"required":["needsAdviser","prepared","sent","answered","dueIn30"]},"lastPass":{"type":["object","null"],"properties":{"status":{"type":"string","enum":["running","done","failed"]},"trigger":{"type":"string","enum":["nightly","manual"]},"found":{"type":"number"},"prepared":{"type":"number"},"sent":{"type":"number"},"escalated":{"type":"number"},"startedAt":{"type":"string"},"finishedAt":{"type":["string","null"]}},"required":["status","trigger","found","prepared","sent","escalated","startedAt","finishedAt"]}},"required":["today","items","counts","lastPass"]}}}}}}},"/v1/firms/{firmId}/renewals/{id}":{"get":{"tags":["console"],"operationId":"firmRenewal","summary":"One renewal","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Renewal"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/proposals/{proposalId}":{"get":{"tags":["console"],"operationId":"getFirmProposal","summary":"One proposal: trades, costs, rationale, checks, history and the record of advice","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"proposalId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Proposal"}}}},"404":{"description":"No such proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"tags":["console"],"operationId":"updateProposal","summary":"Change a draft: trades, title, message, rationale, expiry","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"proposalId","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":3,"maxLength":120},"note":{"type":"string","maxLength":2000},"items":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["order"]},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string"},"limitPrice":{"type":"string"},"amount":{"type":"string","pattern":"^\\d{1,12}(\\.\\d{1,8})?$","description":"Instead of quantity: an amount in the investment's currency"}},"required":["kind","instrumentId","side","type"]},"minItems":1,"maxItems":20},"rationale":{"type":"object","properties":{"objective":{"type":"string","maxLength":2000},"recommendation":{"type":"string","maxLength":4000},"alternatives":{"type":"string","maxLength":2000},"draftedBy":{"type":"string","enum":["agentx","person"]}},"required":["recommendation"]},"expiresInDays":{"type":"integer","minimum":1,"maximum":30}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Proposal"}}}},"409":{"description":"Not a draft any more","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/proposals/{proposalId}/submit":{"post":{"tags":["console"],"operationId":"submitProposal","summary":"Send a draft: to a colleague for second approval when the firm's policy says so, else to the client","description":"The rationale must be written and no check may block. A conduct block (D196: wording, suitability, recency) may be passed with a reason where the firm allows overrides; mandate and advice policy blocks never. Sending freezes the record of advice (PDF, immutable) and supersedes older open proposals for the same portfolio.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"proposalId","in":"path"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"override":{"type":"object","properties":{"reason":{"type":"string","minLength":3,"maxLength":500}},"required":["reason"]}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Proposal"}}}},"409":{"description":"A check blocks it, or it is not a draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"No rationale","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/proposals/check":{"post":{"tags":["console"],"operationId":"checkProposal","summary":"Dry run: costs, tax estimate and checks for trades, and whether a second approval applies","description":"Checks run against the advice policy and the client's restrictions, data owned by compliance: inside the mandate, client restrictions, concentration, mix by kind, product suitability for the account type, cash after trades. Each says pass, warn or block, with the policy version. Writes nothing.","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"portfolioId":{"type":"string"},"items":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["order"]},"instrumentId":{"type":"string"},"side":{"type":"string","enum":["buy","sell"]},"type":{"type":"string","enum":["market","limit"]},"quantity":{"type":"string"},"limitPrice":{"type":"string"},"amount":{"type":"string","pattern":"^\\d{1,12}(\\.\\d{1,8})?$","description":"Instead of quantity: an amount in the investment's currency"}},"required":["kind","instrumentId","side","type"]},"minItems":1,"maxItems":20},"accountId":{"type":"string"},"purpose":{"type":"string","enum":["proposal","trade"]},"rationale":{"type":"object","properties":{"objective":{"type":"string","maxLength":2000},"recommendation":{"type":"string","maxLength":4000},"alternatives":{"type":"string","maxLength":2000},"draftedBy":{"type":"string","enum":["agentx","person"]}}},"note":{"type":"string","maxLength":2000}},"required":["portfolioId","items","accountId"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"costs":{"$ref":"#/components/schemas/ProposalCosts"},"checks":{"$ref":"#/components/schemas/ProposalChecks"}},"required":["costs","checks"]}}}},"403":{"description":"No mandate allows proposals here","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/proposals/{proposalId}/advice-record.pdf":{"get":{"tags":["console"],"operationId":"getFirmAdviceRecordPdf","summary":"The record of advice frozen when the proposal was sent","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"proposalId","in":"path"}],"responses":{"200":{"description":"The record of advice as a PDF","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Not sent yet, or no such proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/invitations":{"get":{"tags":["console"],"operationId":"firmProfessionalInvitations","summary":"Customers' invitations to you (or to the firm, for admins): the customer, account type, portfolios and access","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"invitations":{"type":"array","items":{"$ref":"#/components/schemas/ProfessionalInvitation"}}},"required":["invitations"]}}}}}}},"/v1/firms/{firmId}/conversations":{"get":{"tags":["console"],"operationId":"listFirmConversations","summary":"Conversations with your clients","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":false,"name":"personId","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"conversations":{"type":"array","items":{"$ref":"#/components/schemas/Conversation"}}},"required":["conversations"]}}}}}},"post":{"tags":["console"],"operationId":"startFirmConversation","summary":"Write to a client (they see it in IDEALX)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"personId":{"type":"string"},"subject":{"type":"string"},"body":{"type":"string"},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/FileUpload"},"maxItems":5},"compliance":{"$ref":"#/components/schemas/MessageCompliance"}},"required":["personId","subject","body"]}}}},"responses":{"201":{"description":"Started","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Conversation"}}}},"409":{"description":"A compliance check stopped it","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/firms/{firmId}/conversations/{id}":{"get":{"tags":["console"],"operationId":"getFirmConversation","summary":"A conversation with a client (marks it read for the team)","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"conversation":{"$ref":"#/components/schemas/Conversation"},"messages":{"type":"array","items":{"$ref":"#/components/schemas/Message"}}},"required":["conversation","messages"]}}}}}}},"/v1/firms/{firmId}/conversations/{id}/messages":{"post":{"tags":["console"],"operationId":"replyFirmConversation","summary":"Reply to a client","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"firmId","in":"path"},{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"body":{"type":"string"},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/FileUpload"},"maxItems":5},"compliance":{"$ref":"#/components/schemas/MessageCompliance"}},"required":["body"]}}}},"responses":{"201":{"description":"Sent","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Message"}}}},"409":{"description":"A compliance check stopped it","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/register":{"get":{"tags":["accounts"],"operationId":"listAccountInstructions","summary":"Every instruction on this account (trades, transfers, payments…), whoever made it","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"instructions":{"type":"array","items":{"$ref":"#/components/schemas/InstructionEntry"}}},"required":["instructions"]}}}}}}},"/v1/fx/pairs":{"get":{"tags":["money"],"operationId":"fxPairs","summary":"Which currencies convert into which, right now","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"pairs":{"type":"array","items":{"type":"object","properties":{"base":{"type":"string"},"quote":{"type":"string"}},"required":["base","quote"]}}},"required":["pairs"]}}}}}}},"/v1/fx/quote":{"get":{"tags":["money"],"operationId":"fxQuote","summary":"What an amount converts to, or (with want) what it costs to receive an amount","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"from","in":"query"},{"schema":{"type":"string"},"required":true,"name":"to","in":"query"},{"schema":{"type":"string"},"required":false,"name":"amount","in":"query"},{"schema":{"type":"string"},"required":false,"name":"want","in":"query"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"pay":{"$ref":"#/components/schemas/Money"},"receive":{"$ref":"#/components/schemas/Money"},"rate":{"type":"string"},"pair":{"type":"string"},"asOf":{"type":"string"},"marginIncluded":{"type":"boolean","description":"The rate includes IDEALX's margin (D109)"}},"required":["pay","receive","rate","pair","asOf","marginIncluded"]}}}},"409":{"description":"No rate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/accounts/{id}/fx":{"post":{"tags":["money"],"operationId":"convertCurrency","summary":"Convert cash in a portfolio from one currency to another","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"},{"schema":{"type":"string"},"required":true,"name":"idempotency-key","in":"header"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"portfolioId":{"type":"string"},"from":{"$ref":"#/components/schemas/Money"},"to":{"type":"string"}},"required":["portfolioId","from","to"]}}}},"responses":{"200":{"description":"Converted, or returned if the provider refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Conversion"}}}},"409":{"description":"Not enough cash or no rate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"tags":["money"],"operationId":"listConversions","summary":"Currency conversions on this account","security":[{"apiKey":[]}],"parameters":[{"schema":{"type":"string"},"required":true,"name":"id","in":"path"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"conversions":{"type":"array","items":{"$ref":"#/components/schemas/Conversion"}}},"required":["conversions"]}}}}}}}},"webhooks":{"account.opened":{"post":{"tags":["webhooks"],"summary":"account.opened","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"account.opened"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"approval.waiting":{"post":{"tags":["webhooks"],"summary":"approval.waiting","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"approval.waiting"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"crypto.failed":{"post":{"tags":["webhooks"],"summary":"crypto.failed","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"crypto.failed"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"crypto.received":{"post":{"tags":["webhooks"],"summary":"crypto.received","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"crypto.received"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"crypto.sent":{"post":{"tags":["webhooks"],"summary":"crypto.sent","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"crypto.sent"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"deposit.credited":{"post":{"tags":["webhooks"],"summary":"deposit.credited","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"deposit.credited"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"order.expired":{"post":{"tags":["webhooks"],"summary":"order.expired","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"order.expired"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"order.updated":{"post":{"tags":["webhooks"],"summary":"order.updated","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"order.updated"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"withdrawal.failed":{"post":{"tags":["webhooks"],"summary":"withdrawal.failed","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"withdrawal.failed"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}},"withdrawal.settled":{"post":{"tags":["webhooks"],"summary":"withdrawal.settled","parameters":[{"schema":{"type":"string","description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>"},"required":true,"description":"t=<unix time>,v1=<hex HMAC-SHA256 of `<t>.<raw body>` with the endpoint's secret>","name":"idealx-signature","in":"header"},{"schema":{"type":"string","example":"withdrawal.settled"},"required":true,"name":"idealx-event","in":"header"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Received: answer 2xx within ten seconds"}}}}}}