{"openapi":"3.1.0","info":{"title":"Polyrank API","description":"Skill analytics for Polymarket traders — calibration (Brier), alpha-vs-mid, risk-adjusted return across ~2.8M wallets. Anonymous `/v1/public/*` teaser namespace plus session- or API-key-authed `/v1/*` routes.","version":"1.0.0","contact":{"name":"Polyrank","url":"https://docs.polyrank.app"}},"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"API key: `Authorization: Bearer pk_live_…` (mint at polyrank.app/api-keys)"},"sessionCookie":{"type":"apiKey","in":"cookie","name":"__Secure-polyrank_sid","description":"Browser session cookie set by the sign-in flow"}},"schemas":{}},"paths":{"/v1/auth/siwe/nonce":{"post":{"tags":["auth"],"description":"Issue a SIWE nonce. Single-use, 5-minute TTL.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"nonce":{"type":"string"},"expires_at":{"type":"string"}},"required":["nonce","expires_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-siwe-nonce","summary":"POST /v1/auth/siwe/nonce"}},"/v1/auth/siwe/verify":{"post":{"tags":["auth"],"description":"Verify a SIWE message + signature. Issues a session cookie on success.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","maxLength":4096},"signature":{"type":"string","pattern":"^0x[a-fA-F0-9]+$"},"turnkey_session":{"type":"string","minLength":1,"maxLength":4096}},"required":["message","signature"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]},"user_id":{"type":"string"},"eoa":{"type":"string"},"expires_at":{"type":"string"}},"required":["ok","user_id","eoa","expires_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-siwe-verify","summary":"POST /v1/auth/siwe/verify"}},"/v1/auth/magic/start":{"post":{"tags":["auth"],"description":"Send a magic-link email. Rate-limited per IP + per email.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","maxLength":254,"format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},"next":{"type":"string","maxLength":512,"pattern":"^\\/(?![/\\\\])"}},"required":["email"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]},"dev_link":{"type":"string"}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-magic-start","summary":"POST /v1/auth/magic/start"}},"/v1/auth/magic/callback":{"get":{"tags":["auth"],"description":"Consume a magic-link token. Issues a session cookie + redirects to /.","parameters":[{"schema":{"type":"string"},"in":"query","name":"token","required":true}],"responses":{"302":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-auth-magic-callback","summary":"GET /v1/auth/magic/callback"}},"/v1/auth/logout":{"post":{"tags":["auth"],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-logout","summary":"POST /v1/auth/logout"}},"/v1/auth/logout-all":{"post":{"tags":["auth"],"description":"Revoke all sessions for the current user (sign out everywhere).","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]},"revoked":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["ok","revoked"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-logout-all","summary":"POST /v1/auth/logout-all"}},"/v1/auth/me":{"get":{"tags":["auth"],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"user":{"anyOf":[{"type":"object","properties":{"user_id":{"type":"string"},"eoa":{"anyOf":[{"type":"string"},{"type":"null"}]},"email":{"anyOf":[{"type":"string"},{"type":"null"}]},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"},"claimed_proxy_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"primary_claimed_proxy":{"anyOf":[{"type":"string"},{"type":"null"}]},"is_founding":{"type":"boolean"}},"required":["user_id","eoa","email","display_name","x_username","created_at","claimed_proxy_count","primary_claimed_proxy","is_founding"],"additionalProperties":false},{"type":"null"}]}},"required":["user"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-auth-me","summary":"GET /v1/auth/me"},"patch":{"tags":["auth"],"description":"Update the current user’s display name, email, and/or X handle.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"display_name":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}]},"email":{"anyOf":[{"type":"string","maxLength":254,"format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"user":{"type":"object","properties":{"user_id":{"type":"string"},"eoa":{"anyOf":[{"type":"string"},{"type":"null"}]},"email":{"anyOf":[{"type":"string"},{"type":"null"}]},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"}},"required":["user_id","eoa","email","display_name","x_username","created_at"],"additionalProperties":false}},"required":["user"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"patch-auth-me","summary":"PATCH /v1/auth/me"},"delete":{"tags":["auth"],"description":"Permanently delete (anonymize) your account. Irreversible.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"confirm":{"type":"boolean","enum":[true]}},"required":["confirm"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean","enum":[true]}},"required":["deleted"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-auth-me","summary":"DELETE /v1/auth/me"}},"/v1/auth/me/export":{"get":{"tags":["auth"],"description":"Export all of your account data as JSON (GDPR).","responses":{"200":{"description":"Default Response"}},"operationId":"get-auth-me-export","summary":"GET /v1/auth/me/export"}},"/v1/auth/ws-token":{"post":{"tags":["auth"],"description":"Exchange the session cookie for a short-lived WSS JWT.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"token":{"type":"string"},"expires_in":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["token","expires_in"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-auth-ws-token","summary":"POST /v1/auth/ws-token"}},"/v1/rankings/custom":{"post":{"tags":["rankings"],"description":"Compute a composite ranking over the wallet cohort with user-supplied weights and filters. The composite score is a weighted sum of percentile ranks across the chosen metrics; weights are auto-normalized. Paid feature (Builder).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight"]}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"]}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"]}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"limit":{"default":100,"type":"integer","minimum":1,"maximum":500},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"include_breakdown":{"default":false,"type":"boolean"},"extra_metrics":{"maxItems":60,"type":"array","items":{"type":"string"}},"sort_by":{"default":"composite","type":"string","maxLength":80},"sort_dir":{"default":"desc","type":"string","enum":["desc","asc"]}},"required":["weights"],"additionalProperties":false}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"proxy_wallet":{"type":"string"},"user_id":{"type":"string"},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"wallets":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"realized_pnl":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false}},"required":["proxy_wallet","realized_pnl","lifetime_volume_usdc","trade_count","win_rate_pct"],"additionalProperties":false}},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"composite_score":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"realized_pnl":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"breakdown":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"number"}}},"required":["rank","proxy_wallet","composite_score","lifetime_volume_usdc","realized_pnl","trade_count","markets_traded","win_rate_pct","brier","last_trade_at"],"additionalProperties":false}},"total_rows":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"cohort_size":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"normalized_weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"number"}},"gated_out_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"query_ms":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"rows_capped_at":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["rows","total_rows","cohort_size","normalized_weights","gated_out_count","query_ms","snapshot_age_seconds"],"additionalProperties":false}}}}},"operationId":"post-rankings-custom","summary":"POST /v1/rankings/custom","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/rankings/presets":{"get":{"tags":["rankings"],"description":"List the 10 named launch presets seeded in the database.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"presets":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"sort_order":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight","window"],"additionalProperties":false}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"],"additionalProperties":false}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"],"additionalProperties":false}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["version","weights","filters","na_policy","preset_id","created_via_preset_id"],"additionalProperties":false}},"required":["id","name","description","sort_order","config"],"additionalProperties":false}}},"required":["presets"],"additionalProperties":false}}}}},"operationId":"get-rankings-presets","summary":"GET /v1/rankings/presets","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/rankings/preset/{slug}":{"get":{"tags":["rankings"],"description":"Top-N for a named preset. Cached for 60 seconds. Optional active_within_days / best_category / sort_by overrides.","parameters":[{"schema":{"default":100,"type":"integer","minimum":1,"maximum":500},"in":"query","name":"limit","required":false},{"schema":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"in":"query","name":"offset","required":false},{"schema":{"default":false,"type":"boolean"},"in":"query","name":"include_breakdown","required":false},{"schema":{"type":"integer","minimum":1,"maximum":3650},"in":"query","name":"active_within_days","required":false},{"schema":{"type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"in":"query","name":"best_category","required":false},{"schema":{"default":"composite","type":"string","maxLength":80},"in":"query","name":"sort_by","required":false},{"schema":{"default":"desc","type":"string","enum":["desc","asc"]},"in":"query","name":"sort_dir","required":false},{"schema":{"type":"string","maxLength":64,"pattern":"^[a-z0-9-]+$"},"in":"path","name":"slug","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"proxy_wallet":{"type":"string"},"user_id":{"type":"string"},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"wallets":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"realized_pnl":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false}},"required":["proxy_wallet","realized_pnl","lifetime_volume_usdc","trade_count","win_rate_pct"],"additionalProperties":false}},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"composite_score":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"realized_pnl":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"breakdown":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"number"}}},"required":["rank","proxy_wallet","composite_score","lifetime_volume_usdc","realized_pnl","trade_count","markets_traded","win_rate_pct","brier","last_trade_at"],"additionalProperties":false}},"total_rows":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"cohort_size":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"normalized_weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"number"}},"gated_out_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"query_ms":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"rows_capped_at":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["rows","total_rows","cohort_size","normalized_weights","gated_out_count","query_ms","snapshot_age_seconds"],"additionalProperties":false}}}}},"operationId":"get-rankings-preset","summary":"GET /v1/rankings/preset/{slug}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/rankings/saved":{"get":{"tags":["rankings"],"description":"List the authenticated user's saved rankings.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rankings":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"type":"string"},"is_public":{"type":"boolean"},"public_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight","window"],"additionalProperties":false}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"],"additionalProperties":false}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"],"additionalProperties":false}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["version","weights","filters","na_policy","preset_id","created_via_preset_id"],"additionalProperties":false},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","is_public","public_slug","config","created_at","updated_at"],"additionalProperties":false}}},"required":["rankings"],"additionalProperties":false}}}}},"operationId":"get-rankings-saved","summary":"GET /v1/rankings/saved","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["rankings"],"description":"Save a custom Builder ranking. Set is_public to publish it at a shareable public slug.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight"]}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"]}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"]}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":80},"is_public":{"default":false,"type":"boolean"}},"required":["weights","name"],"additionalProperties":false}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"type":"string"},"is_public":{"type":"boolean"},"public_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight","window"],"additionalProperties":false}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"],"additionalProperties":false}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"],"additionalProperties":false}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["version","weights","filters","na_policy","preset_id","created_via_preset_id"],"additionalProperties":false},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","is_public","public_slug","config","created_at","updated_at"],"additionalProperties":false}}}}},"operationId":"post-rankings-saved","summary":"POST /v1/rankings/saved","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/rankings/saved/{id}":{"get":{"tags":["rankings"],"description":"Fetch one saved ranking (owner only).","parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"type":"string"},"is_public":{"type":"boolean"},"public_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight","window"],"additionalProperties":false}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"],"additionalProperties":false}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"],"additionalProperties":false}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["version","weights","filters","na_policy","preset_id","created_via_preset_id"],"additionalProperties":false},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","is_public","public_slug","config","created_at","updated_at"],"additionalProperties":false}}}}},"operationId":"get-rankings-saved-2","summary":"GET /v1/rankings/saved/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"patch":{"tags":["rankings"],"description":"Update a saved ranking (owner only): rename, re-configure, or (un)publish.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":80},"is_public":{"type":"boolean"},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight"]}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"]}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"]}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["weights"],"additionalProperties":false}},"additionalProperties":false}}}},"parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"type":"string"},"is_public":{"type":"boolean"},"public_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"config":{"type":"object","properties":{"version":{"default":1,"type":"number","enum":[1]},"weights":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"object","properties":{"weight":{"type":"number","minimum":0,"maximum":1000,"description":"Relative weight; will be auto-normalized."},"window":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"required":["weight","window"],"additionalProperties":false}},"filters":{"default":{},"type":"object","properties":{"min_trades":{"type":"integer","minimum":0,"maximum":1000000},"min_volume_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"min_resolved":{"type":"integer","minimum":0,"maximum":1000000},"min_active_days":{"type":"integer","minimum":0,"maximum":10000},"min_realized_pnl":{"description":"Lifetime FIFO cash P&L floor in USDC. Set to 0 to exclude losing wallets.","type":"number"},"min_profit_factor":{"description":"Profit factor floor (gross profit / gross loss). 1.0 = break-even, > 1 = profitable.","type":"number","minimum":0,"maximum":1000},"min_win_rate_pct":{"description":"Win rate floor in % (resolved positions only). Excludes lucky-spray patterns (0% win rate + occasional big winner). Set to 5 for the default-preset shape.","type":"number","minimum":0,"maximum":100},"max_roi_pct":{"description":"ROI % ceiling. Polymarket's minimum price is 0.1¢ (1000× max payout), so any wallet with ROI > 99,900% likely received CTF shares via ERC1155 Transfer (airdrop/promo) — we cannot account for shares acquired outside fills. Default-preset uses 9900 (100× max payout, conservative).","type":"number"},"since_date":{"description":"ISO-8601 date — only consider wallets first active on/after this date.","type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"categories":{"type":"array","items":{"type":"string","enum":["POLITICS","SPORTS","CRYPTO","CULTURE","MENTIONS","WEATHER","ECONOMICS","TECH","FINANCE"]}},"market_kinds":{"type":"array","items":{"type":"string","enum":["binary","negrisk"]}},"exchange_versions":{"type":"array","items":{"type":"string","enum":["v1","v2"]}},"exclude_bonders":{"description":"Exclude entries with implied probability > 0.85 — the \"bonder\" arbitrage.","default":false,"type":"boolean"},"smart_money_tags_any_of":{"description":"Require the wallet to carry at least one of these tags.","type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"follower_count_max":{"description":"Hidden-gems filter: cap follower count.","type":"integer","minimum":0,"maximum":9007199254740991},"active_within_days":{"description":"Only wallets whose last trade is within this many days — surface currently-active traders.","type":"integer","minimum":1,"maximum":3650},"first_trade_within_days":{"description":"Only wallets whose FIRST trade is within this many days — surface newer accounts (Rising Sharps).","type":"integer","minimum":1,"maximum":3650},"max_volume_usdc":{"description":"Lifetime volume ceiling — for \"hidden gems\" / small-footprint filtering.","type":"number","minimum":0,"maximum":1000000000000},"skill_gates":{"description":"Require the wallet to be in the top (100 − min_pctile)% of each metric (lifetime percentile). Powers \"gate on skill, then rank by profit\" — every preset shows only traders who are genuinely skilled on its dimension.","maxItems":8,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min_pctile":{"type":"number","minimum":0,"maximum":100}},"required":["metric","min_pctile"],"additionalProperties":false}},"best_category":{"description":"Only wallets whose strongest (best-calibrated) category is this one — e.g. \"best Sports/Politics/Crypto traders\".","type":"string","enum":["Crypto","Stocks","Sports","Tennis","Esports","Politics","World","Weather","Pop Culture","Tech","Finance","Mentions"]},"metric_filters":{"description":"Raw-value range gates on any displayable metric at the LIFETIME window (absolute, vs skill_gates which are relative top-X%). NULL semantics: a filter on metric X only keeps wallets where X is measured — unmeasured (NULL/NaN) wallets are excluded (min_profit_factor is the one legacy NULL-passes exception). Windowed raw filters are deferred (they would need wallet_metrics_<w> joins).","maxItems":12,"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"min":{"type":"number"},"max":{"type":"number"}},"required":["metric"],"additionalProperties":false}}},"additionalProperties":false},"na_policy":{"default":"exclude","type":"string","enum":["exclude","neutral_50"]},"preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]},"created_via_preset_id":{"default":null,"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["version","weights","filters","na_policy","preset_id","created_via_preset_id"],"additionalProperties":false},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","is_public","public_slug","config","created_at","updated_at"],"additionalProperties":false}}}}},"operationId":"patch-rankings-saved","summary":"PATCH /v1/rankings/saved/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["rankings"],"description":"Delete a saved ranking (owner only).","parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"}},"required":["deleted"],"additionalProperties":false}}}}},"operationId":"delete-rankings-saved","summary":"DELETE /v1/rankings/saved/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/metrics/catalog":{"get":{"tags":["metrics"],"description":"The full metric catalog (count is dynamic). Each entry has id, name, description, category, direction, cost, longTailed flag, minN, supportedWindows. Single source of truth.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"version":{"type":"string"},"count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"metrics":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"category":{"type":"string"},"direction":{"type":"string"},"cost":{"type":"string"},"longTailed":{"type":"boolean"},"minN":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"sampleSizeColumn":{"type":"string"},"supportedWindows":{"type":"array","items":{"type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"displayableWindows":{"type":"array","items":{"type":"string","enum":["lifetime","90d","30d","7d","24h"]}},"defaultWindow":{"type":"string","enum":["lifetime","90d","30d","7d","24h"]},"compositeNeutralDefault":{"type":"boolean"},"advanced":{"type":"boolean"},"cluster":{"type":"string"}},"required":["id","name","description","category","direction","cost","longTailed","minN","sampleSizeColumn","supportedWindows","displayableWindows","defaultWindow","compositeNeutralDefault","advanced"],"additionalProperties":false}}},"required":["version","count","metrics"],"additionalProperties":false}}}}},"operationId":"get-metrics-catalog","summary":"GET /v1/metrics/catalog","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/metrics/coverage":{"get":{"tags":["metrics"],"description":"Per-metric coverage: wallets with a finite (measured) value per displayable metric, over the n_trades > 0 ranking cohort. Cached 1 hour.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"cohort":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"coverage":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}},"required":["cohort","coverage"],"additionalProperties":false}}}}},"operationId":"get-metrics-coverage","summary":"GET /v1/metrics/coverage","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/metrics/distribution/{metric}":{"get":{"tags":["metrics"],"parameters":[{"schema":{"default":"lifetime","type":"string","enum":["lifetime","90d","30d","7d","24h"]},"in":"query","name":"window","required":false},{"schema":{"type":"string"},"in":"path","name":"metric","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"metric":{"type":"string"},"window":{"type":"string","enum":["lifetime","90d","30d","7d","24h"]},"snapshot_date":{"type":"string"},"p1":{"type":"number"},"p5":{"type":"number"},"p10":{"type":"number"},"p25":{"type":"number"},"p50":{"type":"number"},"p75":{"type":"number"},"p90":{"type":"number"},"p95":{"type":"number"},"p99":{"type":"number"},"mean":{"type":"number"},"stdev":{"type":"number"},"n_wallets_eligible":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["metric","window","snapshot_date","p1","p5","p10","p25","p50","p75","p90","p95","p99","mean","stdev","n_wallets_eligible"],"additionalProperties":false}}}}},"operationId":"get-metrics-distribution","summary":"GET /v1/metrics/distribution/{metric}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}":{"get":{"tags":["trader"],"description":"Trader profile — every metric value, every percentile rank, plus display enrichment. Full-metric depth is a paid feature; Free gets the public teaser (/v1/public/trader).","parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"metrics_lifetime":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"number"},{"type":"null"}]}},"percentiles_lifetime":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"number"},{"type":"null"}]}},"first_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"},"bio":{"anyOf":[{"type":"string"},{"type":"null"}]},"eoa":{"anyOf":[{"type":"string"},{"type":"null"}]},"claimed":{"type":"boolean"},"claimed_by_me":{"type":"boolean"},"founding":{"type":"boolean"}},"required":["username","pseudonym","profile_image","x_username","verified","bio","eoa","claimed","claimed_by_me","founding"],"additionalProperties":false},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"metrics_windows":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"object","properties":{"realized_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"volume_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"roi_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_trades":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["realized_pnl","volume_usdc","roi_pct","n_trades"],"additionalProperties":false},{"type":"null"}]}},"user_id":{"type":"string"},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"scope":{"type":"string","enum":["combined","wallet"]},"wallets":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"realized_pnl":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"is_primary":{"type":"boolean"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false}},"required":["proxy_wallet","realized_pnl","lifetime_volume_usdc","trade_count","win_rate_pct","is_primary"],"additionalProperties":false}}},"required":["proxy_wallet","metrics_lifetime","percentiles_lifetime","first_trade_at","last_trade_at","trade_count","markets_traded","display","snapshot_age_seconds"],"additionalProperties":false}}}},"304":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader","summary":"GET /v1/trader/{proxy}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/trades":{"get":{"tags":["trader"],"description":"Paginated trade history. Cursor-based. Paid feature (metrics_full).","parameters":[{"schema":{"type":"string"},"in":"query","name":"cursor","required":false,"description":"Opaque cursor from previous response."},{"schema":{"default":50,"type":"integer","minimum":1,"maximum":200},"in":"query","name":"limit","required":false},{"schema":{"default":"both","type":"string","enum":["maker","taker","both"]},"in":"query","name":"side","required":false},{"schema":{"type":"string","enum":["combined","wallet"]},"in":"query","name":"scope","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"tx_hash":{"type":"string"},"block_time":{"type":"string"},"block_number":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"condition_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcome_side":{"type":"string","enum":["YES","NO","NA"]},"is_buy":{"type":"boolean"},"side":{"type":"string","enum":["maker","taker"]},"price":{"type":"number"},"size_shares":{"type":"number"},"notional_usdc":{"type":"number"},"fee_paid":{"type":"number"},"status":{"anyOf":[{"type":"string","enum":["OPEN","CLOSED","WON","LOST","REDEEMABLE"]},{"type":"null"}]},"exchange_version":{"type":"string"},"exchange_kind":{"type":"string"}},"required":["tx_hash","block_time","block_number","condition_id","market_title","market_slug","outcome_side","is_buy","side","price","size_shares","notional_usdc","fee_paid","status","exchange_version","exchange_kind"],"additionalProperties":false}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]},"has_more":{"type":"boolean"}},"required":["rows","next_cursor","has_more"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-trades","summary":"GET /v1/trader/{proxy}/trades","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/positions":{"get":{"tags":["trader"],"description":"Open/closed positions for a trader. Paid feature (metrics_full).","parameters":[{"schema":{"default":"open","type":"string","enum":["open","closed","all"]},"in":"query","name":"status","required":false},{"schema":{"default":100,"type":"integer","minimum":1,"maximum":500},"in":"query","name":"limit","required":false},{"schema":{"default":0,"type":"integer","minimum":0,"maximum":200000},"in":"query","name":"offset","required":false},{"schema":{"type":"string","enum":["combined","wallet"]},"in":"query","name":"scope","required":false},{"schema":{"default":"value","type":"string","enum":["value","pnl"]},"in":"query","name":"sort","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"outcome_token_id":{"type":"string"},"condition_id":{"type":"string"},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcome_side":{"type":"string","enum":["YES","NO","NA"]},"shares_held":{"type":"number"},"avg_cost":{"type":"number"},"cost_basis":{"type":"number"},"current_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"current_value":{"type":"number"},"realized_pnl":{"type":"number"},"unrealized_pnl":{"type":"number"},"total_pnl":{"type":"number"},"pct_return":{"anyOf":[{"type":"number"},{"type":"null"}]},"resolved":{"type":"boolean"},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"status":{"type":"string","enum":["OPEN","CLOSED","WON","LOST","REDEEMABLE"]},"redeemable":{"type":"boolean"}},"required":["outcome_token_id","condition_id","market_title","market_slug","outcome_side","shares_held","avg_cost","cost_basis","current_mid","current_value","realized_pnl","unrealized_pnl","total_pnl","pct_return","resolved","winner_outcome","status","redeemable"],"additionalProperties":false}},"total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["rows","total"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-positions","summary":"GET /v1/trader/{proxy}/positions","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/activity":{"get":{"tags":["trader"],"description":"Unified activity feed — trades + settlements (redeems) + splits/merges/converts. Paid feature (metrics_full).","parameters":[{"schema":{"default":"all","type":"string","enum":["all","trade","settlement","other"]},"in":"query","name":"kind","required":false},{"schema":{"default":50,"type":"integer","minimum":1,"maximum":200},"in":"query","name":"limit","required":false},{"schema":{"default":0,"type":"integer","minimum":0,"maximum":200000},"in":"query","name":"offset","required":false},{"schema":{"type":"string","enum":["combined","wallet"]},"in":"query","name":"scope","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"ts":{"type":"string"},"type":{"type":"string","enum":["BUY","SELL","REDEEM","Split","Merge","Convert"]},"condition_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcome_side":{"type":"string","enum":["YES","NO","NA"]},"price":{"anyOf":[{"type":"number"},{"type":"null"}]},"shares":{"type":"number"},"usdc":{"type":"number"},"tx_hash":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["ts","type","condition_id","market_title","market_slug","outcome_side","price","shares","usdc","tx_hash"],"additionalProperties":false}},"has_more":{"type":"boolean"}},"required":["rows","has_more"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-activity","summary":"GET /v1/trader/{proxy}/activity","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/calibration":{"get":{"tags":["trader"],"description":"Trader reliability diagram: 10 predicted-vs-observed bins.","parameters":[{"schema":{"type":"string","enum":["combined","wallet"]},"in":"query","name":"scope","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"bins":{"minItems":10,"maxItems":10,"type":"array","items":{"type":"object","properties":{"bin_idx":{"type":"integer","minimum":0,"maximum":9},"bin_label":{"type":"string"},"predicted_mean":{"type":"number"},"observed_rate":{"anyOf":[{"type":"number"},{"type":"null"}]},"n":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bin_idx","bin_label","predicted_mean","observed_rate","n"],"additionalProperties":false}},"n_total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","bins","n_total"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-calibration","summary":"GET /v1/trader/{proxy}/calibration","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/pnl_curve":{"get":{"tags":["trader"],"description":"Daily cumulative P&L from FIFO position lifecycle. Paid feature (metrics_full).","parameters":[{"schema":{"type":"string","enum":["combined","wallet"]},"in":"query","name":"scope","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"points":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"daily_pnl_usdc":{"type":"number"},"cum_pnl_usdc":{"type":"number"}},"required":["day","daily_pnl_usdc","cum_pnl_usdc"],"additionalProperties":false}},"realized_pnl_total":{"type":"number"},"rebasing":{"type":"boolean"}},"required":["proxy_wallet","points","realized_pnl_total","rebasing"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-pnlcurve","summary":"GET /v1/trader/{proxy}/pnl_curve","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/compare":{"get":{"tags":["compare"],"description":"Side-by-side comparison of 2-4 traders. Paid feature (Compare).","parameters":[{"schema":{"type":"string"},"in":"query","name":"addrs","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"traders":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"metrics":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"number"},{"type":"null"}]}},"percentiles":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"number"},{"type":"null"}]}},"rank_in_default_preset":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"first_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","display","metrics","percentiles","rank_in_default_preset","first_trade_at","last_trade_at","trade_count","markets_traded"],"additionalProperties":false}},"winners":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]}},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["traders","winners","snapshot_age_seconds"],"additionalProperties":false}}}},"304":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-compare","summary":"GET /v1/compare","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}":{"get":{"tags":["market"],"description":"Per-market summary: consensus snapshot, last-24h flow + positioning counts.","parameters":[{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_category":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"event_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"event_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"close_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"game_start_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"listed_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"end_date":{"anyOf":[{"type":"string"},{"type":"null"}]},"resolved":{"type":"boolean"},"market_state":{"type":"string","enum":["LIVE","RESOLVING","RESOLVED","DORMANT"]},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"current_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"best_bid":{"anyOf":[{"type":"number"},{"type":"null"}]},"best_ask":{"anyOf":[{"type":"number"},{"type":"null"}]},"final_pre_resolution_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"last_24h_volume_usdc":{"type":"number"},"last_24h_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"positioner_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"smart_money_positioner_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"consensus_latest":{"anyOf":[{"type":"object","properties":{"ts":{"type":"string"},"polyrank_consensus_yes":{"type":"number"},"market_mid":{"type":"number"},"volume_weighted_yes":{"anyOf":[{"type":"number"},{"type":"null"}]},"top10_smart_money_yes":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_positioners":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["ts","polyrank_consensus_yes","market_mid","volume_weighted_yes","top10_smart_money_yes","n_positioners"],"additionalProperties":false},{"type":"null"}]},"consensus_24h":{"type":"array","items":{"type":"object","properties":{"ts":{"type":"string"},"polyrank_consensus_yes":{"type":"number"},"market_mid":{"type":"number"},"volume_weighted_yes":{"anyOf":[{"type":"number"},{"type":"null"}]},"top10_smart_money_yes":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_positioners":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["ts","polyrank_consensus_yes","market_mid","volume_weighted_yes","top10_smart_money_yes","n_positioners"],"additionalProperties":false}},"flow_24h":{"type":"array","items":{"type":"object","properties":{"bucket_ts":{"type":"string"},"total_volume_usdc":{"type":"number"},"yes_buy_volume_usdc":{"type":"number"},"no_buy_volume_usdc":{"type":"number"},"fills_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bucket_ts","total_volume_usdc","yes_buy_volume_usdc","no_buy_volume_usdc","fills_count"],"additionalProperties":false}},"mid_history_24h":{"type":"array","items":{"type":"object","properties":{"bucket_ts":{"type":"string"},"mid":{"type":"number"}},"required":["bucket_ts","mid"],"additionalProperties":false}},"siblings":{"type":"array","items":{"type":"object","properties":{"condition_id":{"type":"string"},"title":{"type":"string"},"current_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"resolved":{"type":"boolean"}},"required":["condition_id","title","current_mid","resolved"],"additionalProperties":false}},"skill_analytics_enabled":{"type":"boolean"},"liquidity":{"anyOf":[{"type":"object","properties":{"best_bid":{"type":"number"},"best_ask":{"type":"number"},"mid":{"type":"number"},"spread":{"type":"number"},"spread_pct":{"type":"number"},"bid_size":{"type":"number"},"ask_size":{"type":"number"},"bid_value_usd":{"type":"number"},"ask_value_usd":{"type":"number"},"bid_depth_usd":{"type":"number"},"ask_depth_usd":{"type":"number"},"book_imbalance":{"anyOf":[{"type":"number"},{"type":"null"}]},"depth_band_cents":{"type":"number"}},"required":["best_bid","best_ask","mid","spread","spread_pct","bid_size","ask_size","bid_value_usd","ask_value_usd","bid_depth_usd","ask_depth_usd","book_imbalance","depth_band_cents"],"additionalProperties":false},{"type":"null"}]},"book_depth_enabled":{"type":"boolean"},"marks_as_of":{"anyOf":[{"type":"string"},{"type":"null"}]},"book_stale":{"type":"boolean"}},"required":["condition_id","market_title","market_category","market_slug","event_slug","event_title","close_time","game_start_time","listed_at","end_date","resolved","market_state","winner_outcome","current_mid","best_bid","best_ask","final_pre_resolution_mid","last_24h_volume_usdc","last_24h_fills","positioner_count","smart_money_positioner_count","consensus_latest","consensus_24h","flow_24h","mid_history_24h","siblings","skill_analytics_enabled","liquidity","book_depth_enabled","marks_as_of","book_stale"],"additionalProperties":false}}}}},"operationId":"get-market","summary":"GET /v1/market/{conditionId}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/positioning":{"get":{"tags":["market"],"description":"Per-market positioning panel with smart-money tags and unrealized P&L.","parameters":[{"schema":{"default":100,"type":"integer","minimum":1,"maximum":500},"in":"query","name":"limit","required":false},{"schema":{"default":false,"type":"boolean"},"in":"query","name":"smart_money_only","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"rows":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"outcome_side":{"type":"string","enum":["YES","NO"]},"shares_held":{"type":"number"},"avg_entry_price":{"type":"number"},"notional_at_entry":{"type":"number"},"unrealized_pnl":{"type":"number"},"realized_pnl":{"type":"number"},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]},"brier_pctile":{"anyOf":[{"type":"number"},{"type":"null"}]},"smart_money_tags":{"type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"display_pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_time":{"type":"string"}},"required":["proxy_wallet","outcome_side","shares_held","avg_entry_price","notional_at_entry","unrealized_pnl","realized_pnl","brier","brier_pctile","smart_money_tags","display_pseudonym","last_trade_time"],"additionalProperties":false}},"total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"smart_money_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"positions_as_of":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["condition_id","rows","total","smart_money_count","positions_as_of"],"additionalProperties":false}}}}},"operationId":"get-market-positioning","summary":"GET /v1/market/{conditionId}/positioning","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/holders":{"get":{"tags":["market"],"description":"Top current holders of a market (canonical avg-cost lineage) with live value + P&L.","parameters":[{"schema":{"default":25,"type":"integer","minimum":1,"maximum":100},"in":"query","name":"limit","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"rows":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcome_side":{"type":"string","enum":["YES","NO"]},"shares_held":{"type":"number"},"avg_cost":{"type":"number"},"current_value":{"type":"number"},"unrealized_pnl":{"type":"number"}},"required":["proxy_wallet","display_name","outcome_side","shares_held","avg_cost","current_value","unrealized_pnl"],"additionalProperties":false}},"positions_as_of":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["condition_id","rows","positions_as_of"],"additionalProperties":false}}}}},"operationId":"get-market-holders","summary":"GET /v1/market/{conditionId}/holders","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/flow":{"get":{"tags":["market"],"description":"5-min flow buckets for the trailing window (max 168h = 7d).","parameters":[{"schema":{"default":24,"type":"integer","minimum":1,"maximum":168},"in":"query","name":"hours","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"buckets":{"type":"array","items":{"type":"object","properties":{"bucket_ts":{"type":"string"},"total_volume_usdc":{"type":"number"},"yes_buy_volume_usdc":{"type":"number"},"no_buy_volume_usdc":{"type":"number"},"fills_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bucket_ts","total_volume_usdc","yes_buy_volume_usdc","no_buy_volume_usdc","fills_count"],"additionalProperties":false}},"window_hours":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["condition_id","buckets","window_hours"],"additionalProperties":false}}}}},"operationId":"get-market-flow","summary":"GET /v1/market/{conditionId}/flow","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/flow/cohort":{"get":{"tags":["market"],"description":"Skill-attributed flow: net YES-equivalent exposure flow by trader-skill cohort (5-min buckets).","parameters":[{"schema":{"default":24,"type":"integer","minimum":1,"maximum":72},"in":"query","name":"hours","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"window_hours":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"buckets":{"type":"array","items":{"type":"object","properties":{"bucket_ts":{"type":"string"},"smart_net_yes_usdc":{"type":"number"},"crowd_net_yes_usdc":{"type":"number"},"smart_buy_usdc":{"type":"number"},"smart_sell_usdc":{"type":"number"},"crowd_buy_usdc":{"type":"number"},"crowd_sell_usdc":{"type":"number"},"smart_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"crowd_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bucket_ts","smart_net_yes_usdc","crowd_net_yes_usdc","smart_buy_usdc","smart_sell_usdc","crowd_buy_usdc","crowd_sell_usdc","smart_fills","crowd_fills"],"additionalProperties":false}},"headline":{"type":"object","properties":{"smart_net_yes_usdc":{"type":"number"},"crowd_net_yes_usdc":{"type":"number"},"smart_gross_usdc":{"type":"number"},"crowd_gross_usdc":{"type":"number"},"smart_wallets":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"crowd_wallets":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"smart_buy_yes_share":{"anyOf":[{"type":"number"},{"type":"null"}]},"smart_lean":{"type":"string","enum":["YES","NO","BALANCED"]},"diverges":{"type":"boolean"}},"required":["smart_net_yes_usdc","crowd_net_yes_usdc","smart_gross_usdc","crowd_gross_usdc","smart_wallets","crowd_wallets","smart_buy_yes_share","smart_lean","diverges"],"additionalProperties":false},"as_of":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["condition_id","window_hours","buckets","headline","as_of"],"additionalProperties":false}}}}},"operationId":"get-market-flow-cohort","summary":"GET /v1/market/{conditionId}/flow/cohort","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/concentration":{"get":{"tags":["market"],"description":"Holder concentration: top-1/5/10 share + HHI per side, plus smart-money share of open interest.","parameters":[{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"sides":{"type":"array","items":{"type":"object","properties":{"side":{"type":"string","enum":["YES","NO"]},"n_holders":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"total_shares":{"type":"number"},"top1_share":{"type":"number"},"top5_share":{"type":"number"},"top10_share":{"type":"number"},"hhi":{"type":"number"},"smart_share":{"type":"number"}},"required":["side","n_holders","total_shares","top1_share","top5_share","top10_share","hhi","smart_share"],"additionalProperties":false}},"as_of":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["condition_id","sides","as_of"],"additionalProperties":false}}}}},"operationId":"get-market-concentration","summary":"GET /v1/market/{conditionId}/concentration","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/resolution-risk":{"get":{"tags":["market"],"description":"Dispute-risk score (Low/Elevated/High + reasons) + live UMA settlement state.","parameters":[{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"level":{"type":"string","enum":["low","elevated","high"]},"score":{"type":"number"},"reasons":{"type":"array","items":{"type":"string"}},"version":{"type":"string"},"ever_disputed":{"type":"boolean"},"dispute_events":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"adapter":{"anyOf":[{"type":"string","enum":["v2","v3"]},{"type":"null"}]},"settlement":{"anyOf":[{"type":"object","properties":{"state":{"type":"string","enum":["none","proposed","expired","disputed","settled","dvm"]},"proposed_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","TIE"]},{"type":"null"}]},"proposer":{"anyOf":[{"type":"string"},{"type":"null"}]},"disputer":{"anyOf":[{"type":"string"},{"type":"null"}]},"bond_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"liveness_ends":{"anyOf":[{"type":"string"},{"type":"null"}]},"settleable":{"type":"boolean"},"in_dvm":{"type":"boolean"},"polled_at":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["state","proposed_outcome","proposer","disputer","bond_usdc","liveness_ends","settleable","in_dvm","polled_at"],"additionalProperties":false},{"type":"null"}]}},"required":["condition_id","level","score","reasons","version","ever_disputed","dispute_events","adapter","settlement"],"additionalProperties":false}}}}},"operationId":"get-market-resolution-risk","summary":"GET /v1/market/{conditionId}/resolution-risk","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/fills":{"get":{"tags":["market"],"description":"Recent fills for a market (cursor-paginated, descending block_time).","parameters":[{"schema":{"default":50,"type":"integer","minimum":1,"maximum":200},"in":"query","name":"limit","required":false},{"schema":{"type":"string"},"in":"query","name":"cursor","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"rows":{"type":"array","items":{"type":"object","properties":{"tx_hash":{"type":"string"},"block_time":{"type":"string"},"block_number":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"taker_proxy":{"type":"string"},"maker_proxy":{"type":"string"},"outcome_side":{"type":"string","enum":["YES","NO"]},"price":{"type":"number"},"size_shares":{"type":"number"},"notional_usdc":{"type":"number"},"exchange_version":{"type":"string"}},"required":["tx_hash","block_time","block_number","taker_proxy","maker_proxy","outcome_side","price","size_shares","notional_usdc","exchange_version"],"additionalProperties":false}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["condition_id","rows","next_cursor"],"additionalProperties":false}}}}},"operationId":"get-market-fills","summary":"GET /v1/market/{conditionId}/fills","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/stats":{"get":{"tags":["market"],"description":"All-time market stats: volume, traders, YES/NO split, lifespan, top traders.","parameters":[{"schema":{"default":10,"type":"integer","minimum":1,"maximum":50},"in":"query","name":"top","required":false},{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"total_volume_usdc":{"type":"number"},"total_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"unique_traders":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"avg_trade_size_usdc":{"type":"number"},"yes_volume_usdc":{"type":"number"},"no_volume_usdc":{"type":"number"},"open_interest_shares":{"type":"number"},"first_trade_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"resolved":{"type":"boolean"},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"resolution_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"time_to_resolution_hours":{"anyOf":[{"type":"number"},{"type":"null"}]},"top_traders":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"volume_usdc":{"type":"number"},"fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","display_name","volume_usdc","fills"],"additionalProperties":false}}},"required":["condition_id","total_volume_usdc","total_fills","unique_traders","avg_trade_size_usdc","yes_volume_usdc","no_volume_usdc","open_interest_shares","first_trade_time","last_trade_time","resolved","winner_outcome","resolution_time","time_to_resolution_hours","top_traders"],"additionalProperties":false}}}}},"operationId":"get-market-stats","summary":"GET /v1/market/{conditionId}/stats","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/market/{conditionId}/recap":{"get":{"tags":["market"],"description":"Resolution recap: outcome, settlement provenance, who-called-it-early, winners/losers, smart-money hit-rate.","parameters":[{"schema":{"type":"string","pattern":"^0x[a-fA-F0-9]{64}$"},"in":"path","name":"conditionId","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"resolved":{"type":"boolean"},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"resolved_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"oracle":{"anyOf":[{"type":"string"},{"type":"null"}]},"oracle_label":{"type":"string"},"source":{"type":"string"},"resolution_tx":{"anyOf":[{"type":"string"},{"type":"null"}]},"final_pre_resolution_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"total_won":{"type":"number"},"total_lost":{"type":"number"},"n_traders":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"top_winners":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"realized_pnl":{"type":"number"},"shares_won":{"type":"number"},"entry_price":{"anyOf":[{"type":"number"},{"type":"null"}]},"first_entry_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"smart_money_tags":{"type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["proxy_wallet","display_name","realized_pnl","shares_won","entry_price","first_entry_time","smart_money_tags","brier"],"additionalProperties":false}},"top_losers":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"realized_pnl":{"type":"number"},"shares_won":{"type":"number"},"entry_price":{"anyOf":[{"type":"number"},{"type":"null"}]},"first_entry_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"smart_money_tags":{"type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["proxy_wallet","display_name","realized_pnl","shares_won","entry_price","first_entry_time","smart_money_tags","brier"],"additionalProperties":false}},"early_callers":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"realized_pnl":{"type":"number"},"shares_won":{"type":"number"},"entry_price":{"anyOf":[{"type":"number"},{"type":"null"}]},"first_entry_time":{"anyOf":[{"type":"string"},{"type":"null"}]},"smart_money_tags":{"type":"array","items":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]}},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["proxy_wallet","display_name","realized_pnl","shares_won","entry_price","first_entry_time","smart_money_tags","brier"],"additionalProperties":false}},"smart_money":{"type":"object","properties":{"n_held":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"n_winning_side":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hit_rate":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["n_held","n_winning_side","hit_rate"],"additionalProperties":false}},"required":["condition_id","resolved","winner_outcome","resolved_time","oracle","oracle_label","source","resolution_tx","final_pre_resolution_mid","total_won","total_lost","n_traders","top_winners","top_losers","early_callers","smart_money"],"additionalProperties":false}}}}},"operationId":"get-market-recap","summary":"GET /v1/market/{conditionId}/recap","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/search":{"get":{"tags":["search"],"description":"Universal resolver: address / condition_id / token_id / username / market text → ranked results.","parameters":[{"schema":{"type":"string","minLength":1,"maxLength":120},"in":"query","name":"q","required":true},{"schema":{"default":8,"type":"integer","minimum":1,"maximum":20},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"query":{"type":"string"},"kind":{"type":"string","enum":["address","condition_id","token_id","text","empty"]},"results":{"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","enum":["trader"]},"proxy_wallet":{"type":"string"},"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"},"total_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"volume":{"anyOf":[{"type":"number"},{"type":"null"}]},"has_metrics":{"type":"boolean"}},"required":["type","proxy_wallet","username","pseudonym","display_name","verified","total_pnl","volume","has_metrics"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["market"]},"condition_id":{"type":"string"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"title":{"anyOf":[{"type":"string"},{"type":"null"}]},"category":{"anyOf":[{"type":"string"},{"type":"null"}]},"resolved":{"type":"boolean"},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"token_side":{"anyOf":[{"type":"string","enum":["YES","NO"]},{"type":"null"}]}},"required":["type","condition_id","slug","title","category","resolved","winner_outcome"],"additionalProperties":false}]}}},"required":["query","kind","results"],"additionalProperties":false}}}}},"operationId":"get-search","summary":"GET /v1/search","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/stats/overview":{"get":{"tags":["stats"],"description":"Public platform totals for the landing page (coarse aggregates only).","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"wallets":{"anyOf":[{"type":"number"},{"type":"null"}]},"trades":{"anyOf":[{"type":"number"},{"type":"null"}]},"markets":{"anyOf":[{"type":"number"},{"type":"null"}]},"metrics":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"since_year":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["wallets","trades","markets","metrics","since_year"],"additionalProperties":false}}}}},"operationId":"get-stats-overview","summary":"GET /v1/stats/overview"}},"/v1/trader/{proxy}/tags":{"get":{"tags":["trader"],"description":"Smart-money tags for a trader (whale, sharp, early_bird, contrarian, toxic).","parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"tags":{"type":"array","items":{"type":"object","properties":{"tag":{"type":"string","enum":["whale","sharp","early_bird","contrarian","toxic"]},"score":{"type":"number"},"rationale":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"required":["tag","score","rationale"],"additionalProperties":false}},"current_metrics":{"anyOf":[{"type":"object","properties":{"lifetime_volume_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]},"counter_consensus_alpha":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_contrarian_fills":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_resolved":{"anyOf":[{"type":"number"},{"type":"null"}]},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["lifetime_volume_usdc","brier","counter_consensus_alpha","n_contrarian_fills","n_resolved","win_rate_pct"],"additionalProperties":false},{"type":"null"}]},"computed_at":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["proxy_wallet","tags","current_metrics","computed_at"],"additionalProperties":false}}}},"304":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-tags","summary":"GET /v1/trader/{proxy}/tags","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/trader/{proxy}/playbook":{"get":{"tags":["trader"],"description":"Trader Playbook: best categories, win rate by stake bucket, entry timing, position-size discipline, co-traders. Paid feature (metrics_full).","parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"best_categories":{"type":"array","items":{"type":"object","properties":{"category":{"type":"string"},"n_trades":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"n_resolved":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"type":"number"},"pnl_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"brier":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["category","n_trades","n_resolved","win_rate_pct","pnl_usdc","brier"],"additionalProperties":false}},"win_rate_by_stake_bucket":{"type":"array","items":{"type":"object","properties":{"bucket_label":{"type":"string"},"n":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"type":"number"}},"required":["bucket_label","n","win_rate_pct"],"additionalProperties":false}},"entry_timing":{"type":"object","properties":{"median_lifetime_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"n_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"alpha_when_early":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["median_lifetime_pct","n_fills","alpha_when_early"],"additionalProperties":false},"position_sizing":{"type":"object","properties":{"mean_notional":{"type":"number"},"cv":{"anyOf":[{"type":"number"},{"type":"null"}]},"max_notional":{"type":"number"}},"required":["mean_notional","cv","max_notional"],"additionalProperties":false},"co_traders":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"shared_markets":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","shared_markets"],"additionalProperties":false}}},"required":["proxy_wallet","best_categories","win_rate_by_stake_bucket","entry_timing","position_sizing","co_traders"],"additionalProperties":false}}}},"304":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-trader-playbook","summary":"GET /v1/trader/{proxy}/playbook","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/api-keys":{"get":{"tags":["api_keys"],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prefix":{"type":"string"},"label":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_used_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"},"revoked_at":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["id","prefix","label","last_used_at","created_at","revoked_at"],"additionalProperties":false}}},"required":["rows"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-api-keys","summary":"GET /v1/api-keys","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["api_keys"],"description":"Mint a new API key. The cleartext secret is returned ONCE.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"label":{"type":"string","minLength":1,"maxLength":80}}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"prefix":{"type":"string"},"secret":{"type":"string","description":"Cleartext API key — shown ONCE; copy now or rotate."},"label":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"}},"required":["id","prefix","secret","label","created_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-api-keys","summary":"POST /v1/api-keys","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/api-keys/{id}":{"delete":{"tags":["api_keys"],"parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"204":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-api-keys","summary":"DELETE /v1/api-keys/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/webhooks":{"get":{"tags":["webhooks"],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"target_url":{"type":"string"},"event_types":{"type":"array","items":{"type":"string"}},"filter_json":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"active":{"type":"boolean"},"created_at":{"type":"string"}},"required":["id","target_url","event_types","filter_json","active","created_at"],"additionalProperties":false}}},"required":["rows"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-webhooks","summary":"GET /v1/webhooks","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["webhooks"],"description":"Create a webhook subscription. The signing_secret is returned ONCE.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"target_url":{"type":"string","pattern":"^https:\\/\\/"},"event_types":{"minItems":1,"maxItems":3,"type":"array","items":{"type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]}},"filter_json":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"required":["target_url","event_types"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"target_url":{"type":"string"},"signing_secret":{"type":"string","description":"HMAC secret — shown ONCE. Store it; you cannot retrieve it later."},"event_types":{"type":"array","items":{"type":"string"}}},"required":["id","target_url","signing_secret","event_types"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-webhooks","summary":"POST /v1/webhooks","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/webhooks/{id}":{"put":{"tags":["webhooks"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"active":{"type":"boolean"},"event_types":{"type":"array","items":{"type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]}},"filter_json":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}}}}},"parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"no_changes":{"type":"boolean"}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"put-webhooks","summary":"PUT /v1/webhooks/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["webhooks"],"parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"204":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-webhooks","summary":"DELETE /v1/webhooks/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/webhooks/{id}/test":{"post":{"tags":["webhooks"],"description":"Emit a synthetic test event onto the delivery queue.","parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"test_event_id":{"type":"string"}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-webhooks-test","summary":"POST /v1/webhooks/{id}/test","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/profile/claims":{"get":{"tags":["profile"],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"claims":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"proof_method":{"type":"string","enum":["direct_eoa_match","safe_owner"]},"siwe_eoa":{"type":"string"},"claimed_at":{"type":"string"}},"required":["proxy_wallet","proof_method","siwe_eoa","claimed_at"],"additionalProperties":false}}},"required":["claims"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-profile-claims","summary":"GET /v1/profile/claims","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/profile/claimable":{"get":{"tags":["profile"],"parameters":[{"schema":{"type":"string"},"in":"query","name":"signer","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"signer":{"type":"string"},"proxies":{"type":"array","items":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"method":{"type":"string","enum":["direct_eoa_match","safe_owner"]},"claimed_by_me":{"type":"boolean"},"claimed_by_other":{"type":"boolean"}},"required":["proxy_wallet","method","claimed_by_me","claimed_by_other"],"additionalProperties":false}}},"required":["signer","proxies"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-profile-claimable","summary":"GET /v1/profile/claimable","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/profile/claim/{proxy}/eligibility":{"get":{"tags":["profile"],"parameters":[{"schema":{"type":"string"},"in":"query","name":"signer","required":false},{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"enabled":{"type":"boolean"},"eligible":{"type":"boolean"},"method":{"anyOf":[{"type":"string","enum":["direct_eoa_match","safe_owner"]},{"type":"null"}]},"reason":{"type":"string"},"claimed_by_me":{"type":"boolean"},"claimed_by_other":{"type":"boolean"}},"required":["enabled","eligible","method","reason","claimed_by_me","claimed_by_other"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-profile-claim-eligibility","summary":"GET /v1/profile/claim/{proxy}/eligibility","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/profile/claim/{proxy}/challenge":{"post":{"tags":["profile"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"signer":{"type":"string"}},"required":["signer"]}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-profile-claim-challenge","summary":"POST /v1/profile/claim/{proxy}/challenge","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/profile/claim/{proxy}":{"post":{"tags":["profile"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","minLength":1,"maxLength":4000},"signature":{"type":"string","pattern":"^0x[0-9a-fA-F]+$"}},"required":["message","signature"]}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]},"proxy_wallet":{"type":"string"},"method":{"type":"string","enum":["direct_eoa_match","safe_owner"]}},"required":["ok","proxy_wallet","method"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-profile-claim","summary":"POST /v1/profile/claim/{proxy}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["profile"],"parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-profile-claim","summary":"DELETE /v1/profile/claim/{proxy}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/alerts":{"get":{"tags":["alerts"],"description":"List the caller's alert rules (watchlist).","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rules":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"anyOf":[{"type":"string"},{"type":"null"}]},"event_type":{"type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]},"filter":{"type":"object","properties":{"trader_proxy":{},"condition_id":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$"},"min_size_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"tags_any":{"maxItems":10,"type":"array","items":{"type":"string"}},"signal_types":{"maxItems":10,"type":"array","items":{"type":"string"}}},"additionalProperties":false},"channels":{"type":"array","items":{"type":"string","enum":["in_app","email","browser_push"]}},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","event_type","filter","channels","active","created_at","updated_at"],"additionalProperties":false}}},"required":["rules"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-alerts","summary":"GET /v1/alerts","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["alerts"],"description":"Create an alert rule. trader.fill watches a wallet; min_size_usdc thresholds it.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","maxLength":80},"event_type":{"default":"trader.fill","type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]},"filter":{"type":"object","properties":{"trader_proxy":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"condition_id":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$"},"min_size_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"tags_any":{"maxItems":10,"type":"array","items":{"type":"string"}},"signal_types":{"maxItems":10,"type":"array","items":{"type":"string"}}},"additionalProperties":false},"channels":{"default":["in_app"],"minItems":1,"type":"array","items":{"type":"string","enum":["in_app","email","browser_push"]}},"active":{"default":true,"type":"boolean"}}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"anyOf":[{"type":"string"},{"type":"null"}]},"event_type":{"type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]},"filter":{"type":"object","properties":{"trader_proxy":{},"condition_id":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$"},"min_size_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"tags_any":{"maxItems":10,"type":"array","items":{"type":"string"}},"signal_types":{"maxItems":10,"type":"array","items":{"type":"string"}}},"additionalProperties":false},"channels":{"type":"array","items":{"type":"string","enum":["in_app","email","browser_push"]}},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","event_type","filter","channels","active","created_at","updated_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-alerts","summary":"POST /v1/alerts","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/alerts/{id}":{"patch":{"tags":["alerts"],"description":"Update an alert rule (owner only).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}]},"filter":{"type":"object","properties":{"trader_proxy":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"condition_id":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$"},"min_size_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"tags_any":{"maxItems":10,"type":"array","items":{"type":"string"}},"signal_types":{"maxItems":10,"type":"array","items":{"type":"string"}}},"additionalProperties":false},"channels":{"minItems":1,"type":"array","items":{"type":"string","enum":["in_app","email","browser_push"]}},"active":{"type":"boolean"}},"additionalProperties":false}}}},"parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"name":{"anyOf":[{"type":"string"},{"type":"null"}]},"event_type":{"type":"string","enum":["trader.fill","market.resolved","signal.smart_money"]},"filter":{"type":"object","properties":{"trader_proxy":{},"condition_id":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$"},"min_size_usdc":{"type":"number","minimum":0,"maximum":1000000000000},"tags_any":{"maxItems":10,"type":"array","items":{"type":"string"}},"signal_types":{"maxItems":10,"type":"array","items":{"type":"string"}}},"additionalProperties":false},"channels":{"type":"array","items":{"type":"string","enum":["in_app","email","browser_push"]}},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","event_type","filter","channels","active","created_at","updated_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"patch-alerts","summary":"PATCH /v1/alerts/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["alerts"],"description":"Delete an alert rule (owner only).","parameters":[{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"}},"required":["deleted"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-alerts","summary":"DELETE /v1/alerts/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/notifications":{"get":{"tags":["alerts"],"description":"Recent notifications (newest first) + unread count.","parameters":[{"schema":{"default":30,"type":"integer","minimum":1,"maximum":100},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"notifications":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"type":{"type":"string"},"title":{"type":"string"},"body":{"anyOf":[{"type":"string"},{"type":"null"}]},"data":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"read_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"}},"required":["id","type","title","body","data","read_at","created_at"],"additionalProperties":false}},"unread_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["notifications","unread_count"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-notifications","summary":"GET /v1/notifications","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/notifications/unread-count":{"get":{"tags":["alerts"],"description":"Cheap unread-count poll for the notification bell.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"unread_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["unread_count"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-notifications-unread-count","summary":"GET /v1/notifications/unread-count","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/notifications/read":{"post":{"tags":["alerts"],"description":"Mark notifications read (by id, or all).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"anyOf":[{"maxItems":200,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"type":"string","enum":["all"]}]}},"required":["ids"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"updated":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["updated"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-notifications-read","summary":"POST /v1/notifications/read","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/notifications/prefs":{"get":{"tags":["alerts"],"description":"Notification channel preferences.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"in_app":{"type":"boolean"},"email":{"type":"boolean"},"browser_push":{"type":"boolean"}},"required":["in_app","email","browser_push"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-notifications-prefs","summary":"GET /v1/notifications/prefs","security":[{"apiKey":[]},{"sessionCookie":[]}]},"put":{"tags":["alerts"],"description":"Update notification channel preferences (upsert).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"in_app":{"type":"boolean"},"email":{"type":"boolean"},"browser_push":{"type":"boolean"}},"additionalProperties":false}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"in_app":{"type":"boolean"},"email":{"type":"boolean"},"browser_push":{"type":"boolean"}},"required":["in_app","email","browser_push"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"put-notifications-prefs","summary":"PUT /v1/notifications/prefs","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/follows":{"get":{"tags":["follows"],"description":"The authenticated user's follows (traders + markets).","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"follows":{"type":"array","items":{"type":"object","properties":{"target_type":{"type":"string","enum":["trader","market"]},"target_id":{"type":"string"},"notify":{"type":"boolean"},"created_at":{"type":"string"}},"required":["target_type","target_id","notify","created_at"],"additionalProperties":false}}},"required":["follows"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-follows","summary":"GET /v1/follows","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["follows"],"description":"Follow a trader or market. notify=true (default) enables big-fill alerts.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"target_type":{"type":"string","enum":["trader","market"]},"target_id":{"type":"string"},"notify":{"default":true,"type":"boolean"}},"required":["target_type","target_id"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"target_type":{"type":"string","enum":["trader","market"]},"target_id":{"type":"string"},"notify":{"type":"boolean"},"created_at":{"type":"string"}},"required":["target_type","target_id","notify","created_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-follows","summary":"POST /v1/follows","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/follows/recent-fills":{"get":{"tags":["follows"],"description":"Recent large fills from the caller's followed wallets (live-feed backfill).","parameters":[{"schema":{"default":40,"type":"integer","minimum":1,"maximum":60},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"fills":{"type":"array","items":{"type":"object","properties":{"taker":{"type":"string"},"usdc_size":{"type":"number"},"token_id":{"type":"string"},"taker_side":{"type":"string","enum":["buy","sell"]},"outcome_side":{"type":"string","enum":["YES","NO"]},"price":{"type":"number"},"ts":{"type":"number"},"tx_hash":{"type":"string"}},"required":["taker","usdc_size","token_id","taker_side","outcome_side","price","ts","tx_hash"],"additionalProperties":false}}},"required":["fills"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-follows-recent-fills","summary":"GET /v1/follows/recent-fills","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/follows/{type}/{id}":{"patch":{"tags":["follows"],"description":"Toggle the notify bell on a follow (owner only).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"notify":{"type":"boolean"}},"required":["notify"]}}}},"parameters":[{"schema":{"type":"string","enum":["trader","market"]},"in":"path","name":"type","required":true},{"schema":{"type":"string"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"target_type":{"type":"string","enum":["trader","market"]},"target_id":{"type":"string"},"notify":{"type":"boolean"},"created_at":{"type":"string"}},"required":["target_type","target_id","notify","created_at"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"patch-follows","summary":"PATCH /v1/follows/{type}/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["follows"],"description":"Unfollow (owner only).","parameters":[{"schema":{"type":"string","enum":["trader","market"]},"in":"path","name":"type","required":true},{"schema":{"type":"string"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"}},"required":["deleted"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-follows","summary":"DELETE /v1/follows/{type}/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/push/vapid-public-key":{"get":{"tags":["push"],"description":"The VAPID applicationServerKey for PushManager.subscribe (null if push is unconfigured).","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"key":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["key"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-push-vapid-public-key","summary":"GET /v1/push/vapid-public-key","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/push/subscribe":{"post":{"tags":["push"],"description":"Register a browser push subscription.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"endpoint":{"type":"string","maxLength":2000,"format":"uri"},"keys":{"type":"object","properties":{"p256dh":{"type":"string","maxLength":500},"auth":{"type":"string","maxLength":500}},"required":["p256dh","auth"]}},"required":["endpoint","keys"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean","enum":[true]}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-push-subscribe","summary":"POST /v1/push/subscribe","security":[{"apiKey":[]},{"sessionCookie":[]}]},"delete":{"tags":["push"],"description":"Remove a browser push subscription.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"endpoint":{"type":"string","maxLength":2000,"format":"uri"}},"required":["endpoint"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"boolean"}},"required":["deleted"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"delete-push-subscribe","summary":"DELETE /v1/push/subscribe","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/me":{"get":{"tags":["referral"],"description":"Your referral code, link, lifetime earnings, funnel + projection basis.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string"},"link":{"type":"string"},"rate":{"type":"number"},"payout_threshold_usdc":{"type":"number"},"referred_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"paying_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"views":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"accrued_usdc":{"type":"number"},"paid_usdc":{"type":"number"},"pending_usdc":{"type":"number"},"annual_value_per_referral_usdc":{"type":"number"},"has_pending_payout":{"type":"boolean"},"milestones_claimed":{"type":"array","items":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}},"required":["code","link","rate","payout_threshold_usdc","referred_count","paying_count","views","accrued_usdc","paid_usdc","pending_usdc","annual_value_per_referral_usdc","has_pending_payout","milestones_claimed"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-referral-me","summary":"GET /v1/referral/me","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/resolve/{code}":{"get":{"tags":["referral"],"description":"Check whether a referral code resolves to a real referrer (public).","parameters":[{"schema":{"type":"string","minLength":3,"maxLength":32},"in":"path","name":"code","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"code":{"type":"string"}},"required":["valid","code"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-referral-resolve","summary":"GET /v1/referral/resolve/{code}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/code":{"patch":{"tags":["referral"],"description":"Set a custom referral code (must be available + appropriate).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","minLength":3,"maxLength":20}},"required":["code"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"code":{"type":"string"},"link":{"type":"string"}},"required":["ok","code","link"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"patch-referral-code","summary":"PATCH /v1/referral/code","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/commissions":{"get":{"tags":["referral"],"description":"Your referral commission ledger (most recent first).","parameters":[{"schema":{"default":50,"type":"integer","minimum":1,"maximum":200},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"commissions":{"type":"array","items":{"type":"object","properties":{"created_at":{"type":"string"},"provider":{"type":"string"},"gross_amount_usdc":{"type":"number"},"rate":{"type":"number"},"commission_usdc":{"type":"number"},"status":{"type":"string"}},"required":["created_at","provider","gross_amount_usdc","rate","commission_usdc","status"],"additionalProperties":false}}},"required":["commissions"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-referral-commissions","summary":"GET /v1/referral/commissions","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/payouts":{"get":{"tags":["referral"],"description":"Your withdrawal/payout history.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"payouts":{"type":"array","items":{"type":"object","properties":{"amount_usdc":{"type":"number"},"status":{"type":"string"},"payout_wallet":{"anyOf":[{"type":"string"},{"type":"null"}]},"tx_ref":{"anyOf":[{"type":"string"},{"type":"null"}]},"requested_at":{"type":"string"}},"required":["amount_usdc","status","payout_wallet","tx_ref","requested_at"],"additionalProperties":false}}},"required":["payouts"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-referral-payouts","summary":"GET /v1/referral/payouts","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/payout-request":{"post":{"tags":["referral"],"description":"Request a USDC withdrawal of your pending balance (processed manually).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"wallet":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"}}}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"amount_usdc":{"type":"number"}},"required":["ok","amount_usdc"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-referral-payout-request","summary":"POST /v1/referral/payout-request","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/track-view":{"post":{"tags":["referral"],"description":"Increment a referral link view counter (public, best-effort).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","minLength":3,"maxLength":32}},"required":["code"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"}},"required":["ok"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-referral-track-view","summary":"POST /v1/referral/track-view","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/referral/bind":{"post":{"tags":["referral"],"description":"Bind a referral code to the (newly signed-up) caller. First-touch, immutable.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","minLength":3,"maxLength":32}},"required":["code"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"bound":{"type":"boolean"},"reason":{"type":"string","enum":["bound","self","invalid_code","already_bound","not_new"]}},"required":["bound","reason"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-referral-bind","summary":"POST /v1/referral/bind","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/redeem/{code}":{"get":{"tags":["redeem"],"description":"Preview a comp-invite code (public). Does not consume it.","parameters":[{"schema":{"type":"string","minLength":4,"maxLength":40},"in":"path","name":"code","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["ok","redeemed","expired","invalid"]},"plan_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"months":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["status","plan_id","months"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-redeem","summary":"GET /v1/redeem/{code}","security":[{"apiKey":[]},{"sessionCookie":[]}]},"post":{"tags":["redeem"],"description":"Redeem a comp-invite code → grant a free comp subscription (single-use).","parameters":[{"schema":{"type":"string","minLength":4,"maxLength":40},"in":"path","name":"code","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"plan_id":{"type":"string"},"months":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"current_period_end":{"type":"string"}},"required":["ok","plan_id","months","current_period_end"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-redeem","summary":"POST /v1/redeem/{code}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/feedback":{"post":{"tags":["feedback"],"description":"Submit in-app feedback (bug / feature request / general) with optional attachments.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"type":{"type":"string","enum":["bug","feature","general"]},"message":{"type":"string","minLength":4,"maxLength":4000},"path":{"type":"string","maxLength":512},"attachments":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","maxLength":200},"content_b64":{"type":"string","maxLength":2900000}},"required":["filename","content_b64"]}}},"required":["type","message"]}}}},"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"id":{"type":"string"},"attachments":{"type":"number"}},"required":["ok","id","attachments"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"post-feedback","summary":"POST /v1/feedback","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/feedback/attachments/{id}":{"get":{"tags":["feedback"],"description":"Stream a feedback attachment via its signed email link.","parameters":[{"schema":{"type":"string","maxLength":200},"in":"query","name":"t","required":false},{"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response"}},"operationId":"get-feedback-attachments","summary":"GET /v1/feedback/attachments/{id}","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/public/referrer":{"get":{"tags":["public"],"description":"Resolve an invite code to the inviter’s public display name / X handle.","parameters":[{"schema":{"type":"string","minLength":1,"maxLength":64},"in":"query","name":"code","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"display_name":{"anyOf":[{"type":"string"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["display_name","x_username"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-referrer","summary":"GET /v1/public/referrer"}},"/v1/public/movers":{"get":{"tags":["public"],"description":"Daily-refreshing skill-rank climbers/fallers over a sliding lookback window.","parameters":[{"schema":{"default":"polyrank-default","type":"string","minLength":1,"maxLength":64},"in":"query","name":"preset","required":false},{"schema":{"default":7,"type":"integer","minimum":1,"maximum":30},"in":"query","name":"lookback_days","required":false},{"schema":{"default":5,"type":"integer","minimum":1,"maximum":10},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"preset":{"type":"string"},"as_of":{"anyOf":[{"type":"string"},{"type":"null"}]},"since":{"anyOf":[{"type":"string"},{"type":"null"}]},"lookback_days":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"movers_up":{"type":"array","items":{"type":"object","properties":{"tid":{"type":"string"},"wallet_label":{"type":"string"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"prev_rank":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"composite_score":{"type":"number"}},"required":["tid","wallet_label","display","rank","prev_rank","composite_score"],"additionalProperties":false}},"movers_down":{"type":"array","items":{"type":"object","properties":{"tid":{"type":"string"},"wallet_label":{"type":"string"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"prev_rank":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"composite_score":{"type":"number"}},"required":["tid","wallet_label","display","rank","prev_rank","composite_score"],"additionalProperties":false}}},"required":["preset","as_of","since","lookback_days","movers_up","movers_down"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-movers","summary":"GET /v1/public/movers"}},"/v1/public/trader/{proxy}":{"get":{"tags":["public"],"description":"Public teaser: identity + commodity P&L/volume/win-rate + composite rank. Deep skill metrics, trades, and positions are gated.","parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"rank":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"composite_score":{"anyOf":[{"type":"number"},{"type":"null"}]},"total_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"realized_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"pnl_under_review":{"type":"boolean"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"percentiles":{"type":"object","properties":{"total_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"realized_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"lifetime_volume_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["total_pnl","realized_pnl","lifetime_volume_usdc","win_rate_pct"],"additionalProperties":false},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"x_username":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"},"eoa":{"anyOf":[{"type":"string"},{"type":"null"}]},"claimed":{"type":"boolean"},"founding":{"type":"boolean"}},"required":["username","pseudonym","profile_image","x_username","verified","eoa","claimed","founding"],"additionalProperties":false},"first_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"locked_metric_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","rank","composite_score","total_pnl","realized_pnl","pnl_under_review","lifetime_volume_usdc","trade_count","markets_traded","win_rate_pct","percentiles","display","first_trade_at","last_trade_at","locked_metric_count","snapshot_age_seconds"],"additionalProperties":false}}}},"304":{"description":"Default Response"},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-trader","summary":"GET /v1/public/trader/{proxy}"}},"/v1/public/trader/{proxy}/calibration":{"get":{"tags":["public"],"description":"Public reliability diagram: 10 predicted-vs-observed bins.","parameters":[{"schema":{"type":"string"},"in":"path","name":"proxy","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"},"bins":{"minItems":10,"maxItems":10,"type":"array","items":{"type":"object","properties":{"bin_idx":{"type":"integer","minimum":0,"maximum":9},"bin_label":{"type":"string"},"predicted_mean":{"type":"number"},"observed_rate":{"anyOf":[{"type":"number"},{"type":"null"}]},"n":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bin_idx","bin_label","predicted_mean","observed_rate","n"],"additionalProperties":false}},"n_total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["proxy_wallet","bins","n_total"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-trader-calibration","summary":"GET /v1/public/trader/{proxy}/calibration"}},"/v1/public/market/{id}":{"get":{"tags":["public"],"description":"Public market teaser: consensus + Polyrank-vs-mid delta + 24h totals + top-5 holders. Full positioning/flow/fills are gated.","parameters":[{"schema":{"type":"string","minLength":1,"maxLength":160},"in":"path","name":"id","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"condition_id":{"type":"string"},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_category":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"end_date":{"anyOf":[{"type":"string"},{"type":"null"}]},"resolved":{"type":"boolean"},"market_state":{"type":"string","enum":["LIVE","RESOLVING","RESOLVED","DORMANT"]},"winner_outcome":{"anyOf":[{"type":"string","enum":["YES","NO","INVALID"]},{"type":"null"}]},"current_mid":{"anyOf":[{"type":"number"},{"type":"null"}]},"last_24h_volume_usdc":{"type":"number"},"last_24h_fills":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"positioner_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"smart_money_positioner_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"consensus_latest":{"anyOf":[{"type":"object","properties":{"polyrank_consensus_yes":{"type":"number"},"market_mid":{"type":"number"},"n_positioners":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["polyrank_consensus_yes","market_mid","n_positioners"],"additionalProperties":false},{"type":"null"}]},"top_holders":{"type":"array","items":{"type":"object","properties":{"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"outcome_side":{"type":"string","enum":["YES","NO"]},"shares_held":{"type":"number"}},"required":["pseudonym","outcome_side","shares_held"],"additionalProperties":false}},"locked":{"type":"object","properties":{"positioning":{"type":"boolean"},"flow":{"type":"boolean"},"fills":{"type":"boolean"}},"required":["positioning","flow","fills"],"additionalProperties":false},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["condition_id","market_title","market_category","market_slug","end_date","resolved","market_state","winner_outcome","current_mid","last_24h_volume_usdc","last_24h_fills","positioner_count","smart_money_positioner_count","consensus_latest","top_holders","locked","snapshot_age_seconds"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-market","summary":"GET /v1/public/market/{id}"}},"/v1/public/leaderboard":{"get":{"tags":["public"],"description":"Public leaderboard teaser: top-N rows + commodity columns. Per-metric sort, windows, the Builder, and rows beyond 25 are gated.","parameters":[{"schema":{"default":"polyrank-default","type":"string","maxLength":64,"pattern":"^[a-z0-9-]+$"},"in":"query","name":"preset","required":false},{"schema":{"default":25,"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"preset":{"type":"string"},"rows":{"type":"array","items":{"type":"object","properties":{"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"tid":{"type":"string"},"wallet_label":{"type":"string"},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"composite_score":{"type":"number"},"total_pnl":{"type":"number"},"win_rate_pct":{"type":"number"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["rank","tid","wallet_label","display","composite_score","total_pnl","win_rate_pct","lifetime_volume_usdc","trade_count"],"additionalProperties":false}},"total_cohort":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["preset","rows","total_cohort","snapshot_age_seconds"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-leaderboard","summary":"GET /v1/public/leaderboard"}},"/v1/public/ranking/{slug}":{"get":{"tags":["public"],"description":"A published custom ranking by public slug. Masked top-25 + the ranking definition. The Builder, deep metrics, and full list are gated.","parameters":[{"schema":{"type":"string","pattern":"^[a-z0-9-]{1,128}$"},"in":"path","name":"slug","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"slug":{"type":"string"},"name":{"type":"string"},"author":{"anyOf":[{"type":"string"},{"type":"null"}]},"weights":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"window":{"type":"string"},"weight_pct":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["id","name","window","weight_pct"],"additionalProperties":false}},"filters":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"],"additionalProperties":false}},"rows":{"type":"array","items":{"type":"object","properties":{"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"tid":{"type":"string"},"wallet_label":{"type":"string"},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified"],"additionalProperties":false},"composite_score":{"type":"number"},"realized_pnl":{"type":"number"},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["rank","tid","wallet_label","display","composite_score","realized_pnl","win_rate_pct","lifetime_volume_usdc","trade_count"],"additionalProperties":false}},"total_cohort":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"locked_metric_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["slug","name","author","weights","filters","rows","total_cohort","locked_metric_count","snapshot_age_seconds"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-ranking","summary":"GET /v1/public/ranking/{slug}"}},"/v1/public/trades/top-roi":{"get":{"tags":["public"],"description":"The biggest return-on-cost (\"highest ROI\") resolved trades on Polymarket. Masked identity; public trade facts.","parameters":[{"schema":{"default":50,"type":"integer","minimum":1,"maximum":100},"in":"query","name":"limit","required":false},{"schema":{"type":"string","maxLength":40},"in":"query","name":"category","required":false},{"schema":{"type":"integer","minimum":1,"maximum":3650},"in":"query","name":"since_days","required":false},{"schema":{"default":"roi","type":"string","enum":["roi","profit","cost","entry","recency"]},"in":"query","name":"sort","required":false},{"schema":{"default":"desc","type":"string","enum":["desc","asc"]},"in":"query","name":"dir","required":false}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"trades":{"type":"array","items":{"type":"object","properties":{"rank":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"tid":{"type":"string"},"wallet_label":{"type":"string"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["username","pseudonym"],"additionalProperties":false},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"category":{"anyOf":[{"type":"string"},{"type":"null"}]},"cost_usdc":{"type":"number"},"profit_usdc":{"type":"number"},"roi_x":{"type":"number"},"entry_price":{"type":"number"},"resolved_at":{"type":"string"}},"required":["rank","tid","wallet_label","display","market_title","market_slug","category","cost_usdc","profit_usdc","roi_x","entry_price","resolved_at"],"additionalProperties":false}}},"required":["trades"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-trades-top-roi","summary":"GET /v1/public/trades/top-roi"}},"/v1/public/founding":{"get":{"tags":["public"],"description":"Founding Trader offer status: seats left, deadline, locked prices.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"active":{"type":"boolean"},"eligible":{"type":"boolean"},"seats_total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"seats_taken":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"seats_left":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"deadline":{"anyOf":[{"type":"string"},{"type":"null"}]},"prices":{"type":"object","properties":{"founding_monthly_usd":{"type":"number"},"founding_annual_usd":{"type":"number"},"regular_monthly_usd":{"type":"number"},"regular_annual_usd":{"type":"number"}},"required":["founding_monthly_usd","founding_annual_usd","regular_monthly_usd","regular_annual_usd"],"additionalProperties":false}},"required":["active","eligible","seats_total","seats_taken","seats_left","deadline","prices"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-founding","summary":"GET /v1/public/founding"}},"/v1/public/pulse":{"get":{"tags":["public"],"description":"Landing live section: big wins (realized profit, winners only), sharp money moving, trending markets, consensus divergence.","responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"big_wins":{"type":"array","items":{"type":"object","properties":{"tid":{"type":"string"},"wallet_label":{"type":"string"},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"profit_usdc":{"type":"number"},"redeemed_usdc":{"type":"number"},"outcome":{"type":"string","enum":["YES","NO"]},"banked_at":{"type":"string"}},"required":["tid","wallet_label","pseudonym","market_title","market_slug","profit_usdc","redeemed_usdc","outcome","banked_at"],"additionalProperties":false}},"sharp_moves":{"type":"array","items":{"type":"object","properties":{"tid":{"type":"string"},"wallet_label":{"type":"string"},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"notional_usdc":{"type":"number"},"is_buy":{"type":"boolean"},"price":{"type":"number"},"outcome_side":{"type":"string","enum":["YES","NO"]},"filled_at":{"type":"string"}},"required":["tid","wallet_label","pseudonym","market_title","market_slug","notional_usdc","is_buy","price","outcome_side","filled_at"],"additionalProperties":false}},"recent_big_trades":{"type":"array","items":{"type":"object","properties":{"tid":{"type":"string"},"wallet_label":{"type":"string"},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"notional_usdc":{"type":"number"},"price":{"type":"number"},"outcome_side":{"type":"string","enum":["YES","NO"]},"filled_at":{"type":"string"}},"required":["tid","wallet_label","pseudonym","market_title","market_slug","notional_usdc","price","outcome_side","filled_at"],"additionalProperties":false}},"trending_markets":{"type":"array","items":{"type":"object","properties":{"condition_id":{"type":"string"},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"category":{"anyOf":[{"type":"string"},{"type":"null"}]},"volume_1h_usdc":{"type":"number"},"n_fills_1h":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"latest_mid":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["condition_id","market_title","market_slug","category","volume_1h_usdc","n_fills_1h","latest_mid"],"additionalProperties":false}},"consensus_divergence":{"type":"array","items":{"type":"object","properties":{"condition_id":{"type":"string"},"market_title":{"anyOf":[{"type":"string"},{"type":"null"}]},"market_slug":{"anyOf":[{"type":"string"},{"type":"null"}]},"category":{"anyOf":[{"type":"string"},{"type":"null"}]},"polyrank_yes":{"type":"number"},"market_mid":{"type":"number"},"divergence_pct":{"type":"number"},"n_positioners":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["condition_id","market_title","market_slug","category","polyrank_yes","market_mid","divergence_pct","n_positioners"],"additionalProperties":false}}},"required":["big_wins","sharp_moves","recent_big_trades","trending_markets","consensus_divergence"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-pulse","summary":"GET /v1/public/pulse"}},"/v1/public/t/{tid}":{"get":{"tags":["public"],"description":"Masked trader teaser by opaque id: commodity stats + calibration access, identity middle-hidden. Sign in to resolve the wallet.","parameters":[{"schema":{"type":"string","minLength":20,"maxLength":64},"in":"path","name":"tid","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"rank":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"composite_score":{"anyOf":[{"type":"number"},{"type":"null"}]},"total_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"realized_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"pnl_under_review":{"type":"boolean"},"lifetime_volume_usdc":{"type":"number"},"trade_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"markets_traded":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]},"percentiles":{"type":"object","properties":{"total_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"realized_pnl":{"anyOf":[{"type":"number"},{"type":"null"}]},"lifetime_volume_usdc":{"anyOf":[{"type":"number"},{"type":"null"}]},"win_rate_pct":{"anyOf":[{"type":"number"},{"type":"null"}]}},"required":["total_pnl","realized_pnl","lifetime_volume_usdc","win_rate_pct"],"additionalProperties":false},"first_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"last_trade_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"locked_metric_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"snapshot_age_seconds":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"wallet_count":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"tid":{"type":"string"},"wallet_label":{"type":"string"},"display":{"type":"object","properties":{"username":{"anyOf":[{"type":"string"},{"type":"null"}]},"pseudonym":{"anyOf":[{"type":"string"},{"type":"null"}]},"profile_image":{"anyOf":[{"type":"string"},{"type":"null"}]},"verified":{"type":"boolean"},"founding":{"type":"boolean"}},"required":["username","pseudonym","profile_image","verified","founding"],"additionalProperties":false}},"required":["rank","composite_score","total_pnl","realized_pnl","pnl_under_review","lifetime_volume_usdc","trade_count","markets_traded","win_rate_pct","percentiles","first_trade_at","last_trade_at","locked_metric_count","snapshot_age_seconds","tid","wallet_label","display"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-t","summary":"GET /v1/public/t/{tid}"}},"/v1/public/t/{tid}/calibration":{"get":{"tags":["public"],"description":"Reliability diagram for a masked trader id.","parameters":[{"schema":{"type":"string","minLength":20,"maxLength":64},"in":"path","name":"tid","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"bins":{"minItems":10,"maxItems":10,"type":"array","items":{"type":"object","properties":{"bin_idx":{"type":"integer","minimum":0,"maximum":9},"bin_label":{"type":"string"},"predicted_mean":{"type":"number"},"observed_rate":{"anyOf":[{"type":"number"},{"type":"null"}]},"n":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["bin_idx","bin_label","predicted_mean","observed_rate","n"],"additionalProperties":false}},"n_total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"tid":{"type":"string"}},"required":["bins","n_total","tid"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-public-t-calibration","summary":"GET /v1/public/t/{tid}/calibration"}},"/v1/t/{tid}/resolve":{"get":{"tags":["public"],"description":"Resolve an opaque trader id to its wallet address. Requires a session.","parameters":[{"schema":{"type":"string","minLength":20,"maxLength":64},"in":"path","name":"tid","required":true}],"responses":{"200":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"proxy_wallet":{"type":"string"}},"required":["proxy_wallet"],"additionalProperties":false}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"401":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"403":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"404":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"409":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"429":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}},"500":{"description":"Default Response","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"reason":{"type":"string"},"issues":{"type":"array","items":{}},"trace_id":{"type":"string"}},"required":["error"],"additionalProperties":false}}}}},"operationId":"get-t-resolve","summary":"GET /v1/t/{tid}/resolve","security":[{"apiKey":[]},{"sessionCookie":[]}]}},"/v1/public/newsletter/subscribe":{"post":{"tags":["public"],"description":"Subscribe to the weekly Smart-Money Report (double opt-in: a confirmation email is sent).","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","maxLength":254,"format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"required":["email"]}}}},"responses":{"200":{"description":"Default Response"}},"operationId":"post-public-newsletter-subscribe","summary":"POST /v1/public/newsletter/subscribe"}},"/v1/public/newsletter/confirm":{"get":{"tags":["public"],"description":"Confirm a newsletter subscription (link from the confirmation email).","parameters":[{"schema":{"type":"string","minLength":16,"maxLength":1024},"in":"query","name":"token","required":true}],"responses":{"200":{"description":"Default Response"}},"operationId":"get-public-newsletter-confirm","summary":"GET /v1/public/newsletter/confirm"}},"/v1/public/reports/smart-money":{"get":{"tags":["public"],"description":"Archive of published Weekly Smart-Money Reports (newest first).","parameters":[{"schema":{"default":52,"type":"integer","minimum":1,"maximum":104},"in":"query","name":"limit","required":false}],"responses":{"200":{"description":"Default Response"}},"operationId":"get-public-reports-smart-money","summary":"GET /v1/public/reports/smart-money"}},"/v1/public/reports/smart-money/{week}":{"get":{"tags":["public"],"description":"One Weekly Smart-Money Report: auto-generated payload + founder intro.","parameters":[{"schema":{"type":"string","pattern":"^\\d{4}-w\\d{2}$"},"in":"path","name":"week","required":true}],"responses":{"200":{"description":"Default Response"}},"operationId":"get-public-reports-smart-money-2","summary":"GET /v1/public/reports/smart-money/{week}"}}},"servers":[{"url":"https://api.polyrank.app"}],"tags":[{"name":"alerts","description":"","x-displayName":"alerts"},{"name":"api_keys","description":"Mint, list, and revoke pk_live_… API keys (session auth only).","x-displayName":"API keys"},{"name":"auth","description":"Sign-in flows (SIWE, magic link, Turnkey) and WSS token minting.","x-displayName":"Auth"},{"name":"compare","description":"Side-by-side trader comparison.","x-displayName":"Compare"},{"name":"feedback","description":"","x-displayName":"feedback"},{"name":"follows","description":"","x-displayName":"follows"},{"name":"market","description":"Market consensus, positioning, holders, flow, fills, and stats.","x-displayName":"Markets"},{"name":"metrics","description":"Metric definitions and population distributions.","x-displayName":"Metrics catalog"},{"name":"profile","description":"","x-displayName":"profile"},{"name":"public","description":"Anonymous teaser namespace — free, cached, no API key required.","x-displayName":"Public (no auth)"},{"name":"push","description":"","x-displayName":"push"},{"name":"rankings","description":"Preset leaderboards and the custom Ranking Builder.","x-displayName":"Rankings"},{"name":"redeem","description":"","x-displayName":"redeem"},{"name":"referral","description":"","x-displayName":"referral"},{"name":"search","description":"Universal search across traders and markets.","x-displayName":"Search"},{"name":"stats","description":"Aggregate platform totals.","x-displayName":"Platform stats"},{"name":"trader","description":"Per-wallet skill profiles, trades, positions, calibration, P&L curve, playbook.","x-displayName":"Traders"},{"name":"webhooks","description":"Webhook subscription CRUD, signing, and test deliveries.","x-displayName":"Webhooks"}]}