{"openapi":"3.1.0","info":{"title":"Aegis Public API","description":"Public, subscription-billed AML API. Send `Authorization: Bearer aeg_<key>` on every call.  See the user kabinet at https://app.aegis-kyt.com/account?tab=api to generate a key.","version":"2.0.0"},"servers":[{"url":"https://api.aegis-kyt.com/v2","description":"Production"}],"paths":{"/health":{"get":{"tags":["v2-public"],"summary":"Liveness probe","operationId":"health_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Health Health Get"}}}}}}},"/networks":{"get":{"tags":["v2-public"],"summary":"Network + provider matrix","description":"Which networks each provider supports.  Refreshes every 60s; use it to validate inputs before paying for a call.  `quota_cost` is a LEGACY field from the retired unit-quota billing model and is not what you are charged — real prices are per-endpoint, in credits (1 credit = 1 USDT of top-up: check-address 1 credit, check-transfer 1, screen 0.1), listed in `providers.Aegis.prices_credits` (same numbers as `prices_usd`) and returned as `billing.credits_charged` (= `charged_usd`) on each call.","operationId":"networks_networks_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Networks Networks Get"}}}}}}},"/check-address":{"post":{"tags":["v2-public"],"summary":"Aegis full 4-tier verdict (SDN + consensus + 1-hop + BFS) — submit","description":"Submits an address for the full Aegis Tier 0..4 pipeline (SDN + consensus + 1-hop + BFS).  Always returns **202** immediately with a `check_id` — this endpoint never blocks waiting for the engine.  Fetch the verdict from `GET /v2/check-address/{check_id}/result` (poll every few seconds; typical completion is 5-90s, occasionally longer on a cold BFS).  Billing fires once, on first successful delivery of the result — polling before completion, or polling again after, never charges twice.\n\nAegis-only: third-party KYT providers are no longer selectable at this surface — when the on-chain graph is sparse they run under the hood via the Aegis fallback waterfall (opt-in).  Supported on BSC/ETH/TRON.\n\nSend `Idempotency-Key: <token>` header to make retries safe — resubmitting the same key returns the SAME check_id instead of starting a duplicate job.","operationId":"check_address_check_address_post","security":[{"ApiKeyBearer":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckAddressRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Check Address Check Address Post"}}}},"202":{"description":"Check queued — poll GET /v2/check-address/{check_id}/result"},"502":{"description":"Idempotent replay landed on a failed check (no charge)"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/check-address/{check_id}/result":{"get":{"tags":["v2-public"],"summary":"Fetch the check-address result (charged once on success)","description":"Fetches a check-address result by check_id.  Returns 200 with the verdict (charged once, on first successful delivery — repeated polls before or after never re-charge), 202 if still running, 502 if the check failed (no charge), 404 if the check_id is unknown or not owned by the caller.","operationId":"check_address_result_check_address__check_id__result_get","security":[{"ApiKeyBearer":[]}],"parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Check Address Result Check Address  Check Id  Result Get"}}}},"202":{"description":"Still running — poll again in a few seconds"},"404":{"description":"Unknown check_id or not owned by the caller"},"502":{"description":"Check failed (no charge)"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/screen":{"post":{"tags":["v2-public"],"summary":"Cheap labels + consensus risk (Tier 0+1+2)","description":"Returns per-source labels and aggregated consensus risk in one call.  Stops after Aegis Tier 0+1+2 (SDN lookup + consensus view) — no 1-hop graph traversal, no BFS.  Billing is per your plan / commercial agreement.\n\nDesigned for high-volume B2B integrations (wallet apps, exchanges) running a pre-send screen on every user-typed address.  For the full 4-tier verdict use `/v2/check-address`.\n\nSend `Idempotency-Key: <token>` header to make retries safe — replays within 24h return the cached response without re-charging.","operationId":"check_address_light_screen_post","security":[{"ApiKeyBearer":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckAddressLightRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Check Address Light Screen Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/check-transfer":{"post":{"tags":["v2-public"],"summary":"Transaction Check (KYT): decode + Tier 4 BFS + policy — submit","description":"Decodes an inbound transaction, runs AML exposure analysis on each sender via Tier 4 BFS, applies the Aegis Standard policy to the USD-weighted composite, and returns PolicyAlerts.  Billing is per your plan / commercial agreement.\n\nAlways returns **202** immediately with `{check_id, retry_url}` — this endpoint never blocks.  Fetch the verdict from `GET /v2/transfer/{check_id}/result` (poll every few seconds).  Charge-on-success, billed once regardless of how many times you poll: no charge on a parse/RPC failure.\n\nAvailable to every key.  Users in an organization/subgroup get that tenant's policy overrides and alert routing; everyone else is checked against the platform's base policy.","operationId":"check_transfer_check_transfer_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckTransferRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Check Transfer Check Transfer Post"}}}},"202":{"description":"Check queued — poll GET /v2/transfer/{check_id}/result"},"502":{"description":"Idempotent replay landed on a failed check (no charge)"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"ApiKeyBearer":[]}]}},"/transfer/{check_id}/result":{"get":{"tags":["v2-public"],"summary":"Free KYT poll — fetch the check-transfer result (charged once on success)","description":"Fetches a tx_check result by check_id.  Returns 200 with the verdict (charged once on first successful delivery — the sync submit and this endpoint bill exactly once between them), 202 if still running, 502 if the check failed (no charge), 404 if the check_id is unknown or not owned by the caller.","operationId":"transfer_result_transfer__check_id__result_get","security":[{"ApiKeyBearer":[]}],"parameters":[{"name":"check_id","in":"path","required":true,"schema":{"type":"string","title":"Check Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Transfer Result Transfer  Check Id  Result Get"}}}},"202":{"description":"Still running — poll again in a few seconds"},"404":{"description":"Unknown check_id or not owned by the caller"},"502":{"description":"Check failed (no charge)"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/balance":{"get":{"tags":["v2-public"],"summary":"Current account balance (free)","description":"Returns the API key's remaining credit balance, month-to-date spend and monthly cap (1 credit = 1 USDT of top-up; `balance_credits` / `monthly_spent_credits` / `monthly_cap_credits` carry the same values as the `*_usd` fields).  Free, read-only, no charge — call it any time to show the client their remaining grant without making a paid request.","operationId":"get_account_balance_balance_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Account Balance Balance Get"}}}}},"security":[{"ApiKeyBearer":[]}]}},"/me/usage":{"get":{"tags":["v2-public"],"summary":"API key usage history + balance","description":"Returns the same data the user-facing kabinet shows under /account → API tab.  Single source of truth: rows from `user_api_usage`; the `billing` block is always the ledger shape (`model: \"ledger\"`, amounts in `*_usd` fields, 1 credit = 1 USDT), from the same source as `GET /v2/balance`.  The `model: \"quota\"` shape this endpoint used to be able to return was retired with the unit-quota billing model on 2026-08-08 and is never emitted.","operationId":"me_usage_me_usage_get","security":[{"ApiKeyBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Limit"}},{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"ISO date; only rows with created_at >= since","title":"Since"},"description":"ISO date; only rows with created_at >= since"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"title":"Response Me Usage Me Usage Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CheckAddressLightRequest":{"properties":{"address":{"type":"string","maxLength":120,"minLength":1,"title":"Address","description":"On-chain wallet.  EVM is lowercased internally; TRON/BTC/SOL preserved.","examples":["TScSLnUodZVsgoGchZspDoimDjDB9bwqVv","0x21a31ee1afc51d94c2efccaa2092ad1028285549"]},"network":{"type":"string","maxLength":20,"minLength":1,"title":"Network","description":"Chain identifier (BSC, ETH, TRON, TON). See `/v2/networks` for allowed values.","examples":["TRON","ETH"]}},"type":"object","required":["address","network"],"title":"CheckAddressLightRequest"},"CheckAddressRequest":{"properties":{"address":{"type":"string","maxLength":120,"minLength":1,"title":"Address","description":"On-chain wallet.  EVM is lowercased internally; TRON/BTC/SOL preserved.","examples":["TScSLnUodZVsgoGchZspDoimDjDB9bwqVv","0x21a31ee1afc51d94c2efccaa2092ad1028285549"]},"network":{"type":"string","maxLength":20,"minLength":1,"title":"Network","description":"Chain identifier (BSC, ETH, TRON, TON). See `/v2/networks` for allowed values.","examples":["TRON","ETH"]}},"type":"object","required":["address","network"],"title":"CheckAddressRequest"},"CheckTransferRequest":{"properties":{"chain":{"type":"string","maxLength":20,"minLength":1,"title":"Chain","description":"ETH | BSC | POLYGON | BASE | ARBITRUM | TRON | TON.","examples":["TRON","ETH"]},"tx_hash":{"type":"string","maxLength":80,"minLength":1,"title":"Tx Hash","description":"Transaction hash (0x-prefixed 32-byte hex, or TRON 64-hex).","examples":["0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"]}},"type":"object","required":["chain","tx_hash"],"title":"CheckTransferRequest"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"ApiKeyBearer":{"type":"http","description":"Your `aeg_…` API key from the dashboard (Account → API tab).","scheme":"bearer"}}}}