{
  "openapi": "3.1.0",
  "info": {
    "title": "Burokku API",
    "version": "1",
    "description": "Read your Burokku portfolio: net worth, holdings, DeFi, perp and prediction market positions, liquidation risk, profit and loss, activity and alerts. Two writes only notify or watch: a price alert, and a watched address. Nothing in this API can trade, swap, send or sign. The same nine operations are the Burokku connector’s tools for AI apps."
  },
  "servers": [
    {
      "url": "https://api.burokku.app/v1",
      "description": "Production"
    }
  ],
  "security": [
    {
      "oauth2": [
        "portfolio.read"
      ]
    },
    {
      "apiKey": []
    }
  ],
  "tags": [
    {
      "name": "Portfolio",
      "description": "Net worth, holdings, positions, liquidation risk and profit and loss."
    },
    {
      "name": "Activity",
      "description": "Transactions and trades, newest first."
    },
    {
      "name": "Alerts",
      "description": "The account’s alerts, and price alerts that only notify."
    },
    {
      "name": "Accounts",
      "description": "Public addresses added watch-only."
    }
  ],
  "paths": {
    "/portfolio": {
      "get": {
        "operationId": "portfolio_summary",
        "summary": "Portfolio summary",
        "description": "Use this when the user asks what their crypto portfolio is worth, how it changed over the last 24 hours, or how it splits between wallets, DeFi, perps and prediction markets. Returns net worth, the 24-hour change, each account with its value, the ten largest holdings and how many risks need attention. Pass account or bundle to look at one account or one group of accounts.",
        "tags": [
          "Portfolio"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "portfolio_summary",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "account",
            "in": "query",
            "required": false,
            "description": "One account, by its name as Burokku shows it (over REST, its id also works). Leave out for every account.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          },
          {
            "name": "bundle",
            "in": "query",
            "required": false,
            "description": "One bundle (a group of accounts), by its name. Leave out for every account.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PortfolioSummary"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad-input",
                    "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "description": "No account or bundle by that name or id.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not-found",
                    "message": "There’s no account named “Ledger”. Your accounts: Main wallet, Binance."
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/holdings": {
      "get": {
        "operationId": "holdings",
        "summary": "Holdings",
        "description": "Use this when the user asks which tokens they hold, how much of a token they have, or where a token is held. Returns each token with its price, 24-hour and 7-day change, amount, value, share of net worth and the accounts and chains holding it, largest first. Filter by symbol, account or chain; page with cursor.",
        "tags": [
          "Portfolio"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "holdings",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "symbol",
            "in": "query",
            "required": false,
            "description": "A token symbol, like ETH.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 21,
              "pattern": "^\\$?[A-Za-z0-9.]{1,20}$"
            }
          },
          {
            "name": "account",
            "in": "query",
            "required": false,
            "description": "One account, by its name as Burokku shows it (over REST, its id also works). Leave out for every account.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          },
          {
            "name": "chain",
            "in": "query",
            "required": false,
            "description": "One chain, by name or id (Ethereum, base, Solana…).",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 40
            }
          },
          {
            "name": "min_usd",
            "in": "query",
            "required": false,
            "description": "Leave out tokens worth less than this, in US dollars (not applied with symbol).",
            "schema": {
              "default": 1,
              "type": "number",
              "minimum": 0,
              "maximum": 1000000000
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 40,
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "description": "The next_cursor of the previous page.",
            "schema": {
              "type": "string",
              "maxLength": 40,
              "pattern": "^[A-Za-z0-9_-]+$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Holdings"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "bad-input": {
                    "value": {
                      "error": {
                        "code": "bad-input",
                        "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                      }
                    }
                  },
                  "bad-cursor": {
                    "value": {
                      "error": {
                        "code": "bad-cursor",
                        "message": "That cursor isn’t one Burokku gave. Leave it out to start from the first page."
                      }
                    }
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "description": "No account or bundle by that name or id.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not-found",
                    "message": "There’s no account named “Ledger”. Your accounts: Main wallet, Binance."
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/positions": {
      "get": {
        "operationId": "positions",
        "summary": "Positions",
        "description": "Use this when the user asks about their DeFi positions (lending, liquidity, staking, vaults), open perpetual futures, or prediction market shares. Returns for DeFi the protocol, supplied and borrowed tokens, APY, health factor and unclaimed rewards; for perps the market, side, size, entry, mark and liquidation prices, leverage, unrealised PnL and distance to liquidation; for predictions the market, outcome held, shares, average and current price, value, PnL and when it resolves.",
        "tags": [
          "Portfolio"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "positions",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "kind",
            "in": "query",
            "required": false,
            "schema": {
              "default": "all",
              "type": "string",
              "enum": [
                "defi",
                "perps",
                "predictions",
                "all"
              ]
            }
          },
          {
            "name": "account",
            "in": "query",
            "required": false,
            "description": "One account, by its name as Burokku shows it (over REST, its id also works). Leave out for every account.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          },
          {
            "name": "protocol",
            "in": "query",
            "required": false,
            "description": "One protocol or venue, by name (Aave, Hyperliquid, Polymarket…).",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 60
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Positions"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad-input",
                    "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "description": "No account or bundle by that name or id.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not-found",
                    "message": "There’s no account named “Ledger”. Your accounts: Main wallet, Binance."
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/risk/liquidation": {
      "get": {
        "operationId": "liquidation_risk",
        "summary": "Liquidation risk",
        "description": "Use this when the user asks whether a loan or a perp is close to liquidation. Returns loans whose health factor is under health_factor_below, lowest first, with how far prices can fall before liquidation and the liquidation price where one collateral token decides it; and perps within perp_within_pct of their liquidation price, nearest first. Empty lists mean nothing is that close.",
        "tags": [
          "Portfolio"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "liquidation_risk",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "health_factor_below",
            "in": "query",
            "required": false,
            "schema": {
              "default": 1.5,
              "type": "number",
              "minimum": 1,
              "maximum": 10
            }
          },
          {
            "name": "perp_within_pct",
            "in": "query",
            "required": false,
            "description": "Percent between the mark and the liquidation price.",
            "schema": {
              "default": 15,
              "type": "number",
              "minimum": 0.1,
              "maximum": 100
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LiquidationRisk"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad-input",
                    "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/pnl": {
      "get": {
        "operationId": "pnl",
        "summary": "Profit and loss",
        "description": "Use this when the user asks how their net worth or profit and loss moved over a period. Returns the change in dollars and percent, the high, the low and up to 13 points; for 1D, 1W and 1M also what drove it (coins, accounts, realised perp PnL, funding and fees); and unrealised PnL on holdings whose cost Burokku knows. These are not tax figures.",
        "tags": [
          "Portfolio"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "pnl",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "range",
            "in": "query",
            "required": false,
            "schema": {
              "default": "1D",
              "type": "string",
              "enum": [
                "1D",
                "1W",
                "1M",
                "1Y",
                "All"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Pnl"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad-input",
                    "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/activity": {
      "get": {
        "operationId": "activity",
        "summary": "Activity",
        "description": "Use this when the user asks about their recent transactions: swaps, sends and receipts, bridges, approvals, staking, perp trades or funding. Returns rows newest first with what happened, the account, chain, value in dollars, realised PnL and fees, status and time, over up to 90 days. Filter by kind or account; page with cursor.",
        "tags": [
          "Activity"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "activity",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "parameters": [
          {
            "name": "days",
            "in": "query",
            "required": false,
            "schema": {
              "default": 30,
              "type": "integer",
              "minimum": 1,
              "maximum": 90
            }
          },
          {
            "name": "kind",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "swap",
                "send",
                "receive",
                "bridge",
                "approve",
                "stake",
                "claim",
                "revoke",
                "mint",
                "call",
                "perp",
                "funding",
                "move"
              ]
            }
          },
          {
            "name": "account",
            "in": "query",
            "required": false,
            "description": "One account, by its name as Burokku shows it (over REST, its id also works). Leave out for every account.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "default": 20,
              "type": "integer",
              "minimum": 1,
              "maximum": 50
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "description": "The next_cursor of the previous page.",
            "schema": {
              "type": "string",
              "maxLength": 40,
              "pattern": "^[A-Za-z0-9_-]+$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Activity"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "bad-input": {
                    "value": {
                      "error": {
                        "code": "bad-input",
                        "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                      }
                    }
                  },
                  "bad-cursor": {
                    "value": {
                      "error": {
                        "code": "bad-cursor",
                        "message": "That cursor isn’t one Burokku gave. Leave it out to start from the first page."
                      }
                    }
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "description": "No account or bundle by that name or id.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not-found",
                    "message": "There’s no account named “Ledger”. Your accounts: Main wallet, Binance."
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/alerts": {
      "get": {
        "operationId": "list_alerts",
        "summary": "Alerts",
        "description": "Use this when the user asks which Burokku alerts they have. Returns each alert with what it watches, whether it is on, where it notifies and how many times it has fired.",
        "tags": [
          "Alerts"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.read"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "list_alerts",
        "x-mcp-annotations": {
          "readOnlyHint": true,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListAlerts"
                }
              }
            }
          },
          "400": {
            "description": "A value is missing, of the wrong type or out of range.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad-input",
                    "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      },
      "post": {
        "operationId": "create_price_alert",
        "summary": "Create a price alert",
        "description": "Use this only when the user asks to be alerted when a token’s price goes above or below a level. Creates a price alert in their Burokku account that notifies them in Burokku, and by email, push or Telegram where those are set up. It never trades. Returns the alert as created.",
        "tags": [
          "Alerts"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.write"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "create_price_alert",
        "x-mcp-annotations": {
          "readOnlyHint": false,
          "destructiveHint": false,
          "idempotentHint": false,
          "openWorldHint": false
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePriceAlertInput"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatePriceAlert"
                }
              }
            }
          },
          "400": {
            "description": "The request isn’t valid, or Burokku refuses the input.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "bad-input": {
                    "value": {
                      "error": {
                        "code": "bad-input",
                        "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                      }
                    }
                  },
                  "bad-json": {
                    "value": {
                      "error": {
                        "code": "bad-json",
                        "message": "Send the body as JSON, up to 10 KB."
                      }
                    }
                  },
                  "unknown-asset": {
                    "value": {
                      "error": {
                        "code": "unknown-asset",
                        "message": "DOGEX isn’t a token Burokku tracks prices for."
                      }
                    }
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              },
              "WWW-Authenticate": {
                "description": "With an OAuth token lacking `portfolio.write`: an RFC 6750 challenge with error=\"insufficient_scope\" and scope=\"portfolio.read portfolio.write\", so the app can ask for it.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Refused. With a key or OAuth token that can only read, `insufficient-scope` (for an OAuth token, with a `WWW-Authenticate` challenge so the app can ask for `portfolio.write`; neither carries the rate headers, since the call never ran). Without an account (an anonymous connection), `account-required` with a sign-in link. Over the plan’s alerts, `plan-limit`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "insufficient-scope": {
                    "value": {
                      "error": {
                        "code": "insufficient-scope",
                        "message": "This key or connection can only read. Make a key, or connect again, with permission to watch addresses and set alerts."
                      }
                    }
                  },
                  "account-required": {
                    "value": {
                      "error": {
                        "code": "account-required",
                        "message": "Alerts need a Burokku account. Sign in at https://app.burokku.app/oauth/claim?c=… to set one; the addresses you added come with you."
                      }
                    }
                  }
                }
              }
            }
          },
          "413": {
            "description": "The body is over 10 KB.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "too-large",
                    "message": "Send the body as JSON, up to 10 KB."
                  }
                }
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    },
    "/accounts/watch": {
      "post": {
        "operationId": "add_watch_address",
        "summary": "Watch an address",
        "description": "Use this only when the user asks Burokku to track or watch a wallet address. Adds a public address (EVM, Solana or Bitcoin; or a Hyperliquid, Lighter or Aster account by its EVM address, with venue) to their portfolio as watch-only. Never pass a private key or recovery phrase. Its balances are read in the background, so the answer has refreshing: true and later reads include them.",
        "tags": [
          "Accounts"
        ],
        "security": [
          {
            "oauth2": [
              "portfolio.write"
            ]
          },
          {
            "apiKey": []
          }
        ],
        "x-mcp-tool": "add_watch_address",
        "x-mcp-annotations": {
          "readOnlyHint": false,
          "destructiveHint": false,
          "idempotentHint": true,
          "openWorldHint": false
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddWatchAddressInput"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AddWatchAddress"
                }
              }
            }
          },
          "400": {
            "description": "The request isn’t valid, or Burokku refuses the input.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "bad-input": {
                    "value": {
                      "error": {
                        "code": "bad-input",
                        "message": "Some of what was asked isn’t valid: limit: Too big: expected number to be <=100"
                      }
                    }
                  },
                  "bad-json": {
                    "value": {
                      "error": {
                        "code": "bad-json",
                        "message": "Send the body as JSON, up to 10 KB."
                      }
                    }
                  },
                  "not-address": {
                    "value": {
                      "error": {
                        "code": "not-address",
                        "message": "That isn’t a wallet address Burokku can watch. Give an EVM (0x…), Solana or Bitcoin address; exchanges are connected in the Burokku app."
                      }
                    }
                  },
                  "secret": {
                    "value": {
                      "error": {
                        "code": "secret",
                        "message": "That looks like a private key or recovery phrase. Never share it with anyone, Burokku included. Add the wallet by its public address instead."
                      }
                    }
                  }
                }
              }
            },
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "headers": {
              "X-RateLimit-Limit": {
                "$ref": "#/components/headers/X-RateLimit-Limit"
              },
              "X-RateLimit-Remaining": {
                "$ref": "#/components/headers/X-RateLimit-Remaining"
              },
              "X-RateLimit-Reset": {
                "$ref": "#/components/headers/X-RateLimit-Reset"
              },
              "WWW-Authenticate": {
                "description": "With an OAuth token lacking `portfolio.write`: an RFC 6750 challenge with error=\"insufficient_scope\" and scope=\"portfolio.read portfolio.write\", so the app can ask for it.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Refused. With a key or OAuth token that can only read, `insufficient-scope` (for an OAuth token, with a `WWW-Authenticate` challenge so the app can ask for `portfolio.write`; neither carries the rate headers, since the call never ran). Without an account (an anonymous connection), `account-required` with a sign-in link. Over the plan’s alerts, `plan-limit`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "examples": {
                  "insufficient-scope": {
                    "value": {
                      "error": {
                        "code": "insufficient-scope",
                        "message": "This key or connection can only read. Make a key, or connect again, with permission to watch addresses and set alerts."
                      }
                    }
                  },
                  "account-required": {
                    "value": {
                      "error": {
                        "code": "account-required",
                        "message": "Without an account, Burokku watches up to 3 addresses. Sign in at https://app.burokku.app/oauth/claim?c=… to add more."
                      }
                    }
                  }
                }
              }
            }
          },
          "413": {
            "description": "The body is over 10 KB.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "too-large",
                    "message": "Send the body as JSON, up to 10 KB."
                  }
                }
              }
            }
          },
          "423": {
            "$ref": "#/components/responses/Locked"
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          },
          "500": {
            "$ref": "#/components/responses/ServerError"
          },
          "503": {
            "$ref": "#/components/responses/Off"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "description": "OAuth 2.1 for apps that act for a Burokku user: the authorization code grant with PKCE (S256) required of every client. Clients use a Client ID Metadata Document, or register at /oauth/register (at most 20 registrations an hour from one network). Set `resource` to https://api.burokku.app/v1: a token issued for the MCP server (the default without `resource`) is refused here with a 401 (`invalid-token`); a token is for one resource, so authorize once for each and refresh with the same `resource` (another gets `invalid_target`). Every grant includes portfolio.read. Authorization server metadata: https://app.burokku.app/.well-known/oauth-authorization-server; this API’s protected resource metadata: https://api.burokku.app/.well-known/oauth-protected-resource/v1. Access tokens last 1 hour; each refresh returns a new refresh token (use the newest), and one unused for 30 days lapses. OAuth errors are JSON, `{ error, error_description }`.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://app.burokku.app/oauth/authorize",
            "tokenUrl": "https://app.burokku.app/oauth/token",
            "refreshUrl": "https://app.burokku.app/oauth/token",
            "scopes": {
              "portfolio.read": "Read balances, positions, activity and alerts. Every grant has it.",
              "portfolio.write": "Create price alerts and add watched addresses.",
              "offline_access": "Get a refresh token, to stay connected past the access token’s hour."
            }
          }
        }
      },
      "apiKey": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "bk_live_…",
        "description": "A personal API key (`bk_live_` and 43 more characters), sent as `Authorization: Bearer bk_live_…`. A key reads only, unless it was made with write. Never put a key in a URL."
      }
    },
    "responses": {
      "Unauthorized": {
        "description": "No token (`unauthorized`), or a key or token that isn’t valid: made up, expired, revoked or issued for the MCP server (`invalid-token`). The `WWW-Authenticate` header says the same (`error=\"invalid_token\"` when a token was sent) and names this API’s protected resource metadata. No rate headers: the account isn’t known.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "examples": {
              "unauthorized": {
                "value": {
                  "error": {
                    "code": "unauthorized",
                    "message": "Send an API key or an access token as a Bearer token in the Authorization header."
                  }
                }
              },
              "invalid-token": {
                "value": {
                  "error": {
                    "code": "invalid-token",
                    "message": "This API key or access token isn’t valid. It may have expired or been revoked."
                  }
                }
              }
            }
          }
        },
        "headers": {
          "WWW-Authenticate": {
            "description": "For example: Bearer realm=\"OAuth\", resource_metadata=\"https://api.burokku.app/.well-known/oauth-protected-resource/v1\", error=\"invalid_token\", scope=\"portfolio.read portfolio.write offline_access\"",
            "schema": {
              "type": "string"
            }
          }
        }
      },
      "Locked": {
        "description": "The account is locked (Settings → Security). Every call is refused until it’s unlocked, before anything is counted.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": {
                "code": "LOCKED",
                "message": "Your account is locked. Security changes are on hold for 24 hours from when it was locked."
              }
            }
          }
        },
        "headers": {
          "X-RateLimit-Limit": {
            "$ref": "#/components/headers/X-RateLimit-Limit"
          },
          "X-RateLimit-Remaining": {
            "$ref": "#/components/headers/X-RateLimit-Remaining"
          },
          "X-RateLimit-Reset": {
            "$ref": "#/components/headers/X-RateLimit-Reset"
          }
        }
      },
      "RateLimited": {
        "description": "Over a limit: 30 calls a minute per account (`rate-limited`, `Retry-After: 60`), or the plan’s calls for the UTC day, shared with the connector (`daily-limit`, which links only the pricing page; `Retry-After` is the seconds until the UTC day ends). Reads also count against the account’s read budget, which answers `rate-limited` with `Retry-After: 60`. A refused call isn’t counted, and the `X-RateLimit-*` headers still describe the day.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "examples": {
              "rate-limited": {
                "value": {
                  "error": {
                    "code": "rate-limited",
                    "message": "Too many calls in a minute. Try again in a minute."
                  }
                }
              },
              "daily-limit": {
                "value": {
                  "error": {
                    "code": "daily-limit",
                    "message": "This account has used today’s 100 calls from AI apps and the API; they start again at midnight UTC. Plans with more are at https://burokku.app/pricing"
                  }
                }
              }
            }
          }
        },
        "headers": {
          "Retry-After": {
            "$ref": "#/components/headers/Retry-After"
          },
          "X-RateLimit-Limit": {
            "$ref": "#/components/headers/X-RateLimit-Limit"
          },
          "X-RateLimit-Remaining": {
            "$ref": "#/components/headers/X-RateLimit-Remaining"
          },
          "X-RateLimit-Reset": {
            "$ref": "#/components/headers/X-RateLimit-Reset"
          }
        }
      },
      "ServerError": {
        "description": "Something failed on Burokku’s side. Try again in a minute.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": {
                "code": "server-error",
                "message": "Something went wrong on Burokku’s side. Try again in a minute."
              }
            }
          }
        },
        "headers": {
          "X-RateLimit-Limit": {
            "$ref": "#/components/headers/X-RateLimit-Limit"
          },
          "X-RateLimit-Remaining": {
            "$ref": "#/components/headers/X-RateLimit-Remaining"
          },
          "X-RateLimit-Reset": {
            "$ref": "#/components/headers/X-RateLimit-Reset"
          }
        }
      },
      "Off": {
        "description": "Burokku for AI apps and the API is switched off for now.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            },
            "example": {
              "error": {
                "code": "off",
                "message": "Burokku for AI apps and the API isn’t available right now. Try again later."
              }
            }
          }
        },
        "headers": {
          "X-RateLimit-Limit": {
            "$ref": "#/components/headers/X-RateLimit-Limit"
          },
          "X-RateLimit-Remaining": {
            "$ref": "#/components/headers/X-RateLimit-Remaining"
          },
          "X-RateLimit-Reset": {
            "$ref": "#/components/headers/X-RateLimit-Reset"
          }
        }
      }
    },
    "headers": {
      "X-RateLimit-Limit": {
        "description": "The plan’s calls a day, shared by the REST API and the connector. Always the daily quota, never the per-minute limit or the read budget. On every answer from an operation, successes and errors alike, both 429s included; not on a 401, or an answer about the request itself (an unknown path, 405, 413, `bad-json`, a 403 for scope).",
        "schema": {
          "type": "integer"
        }
      },
      "X-RateLimit-Remaining": {
        "description": "Calls left today, after this call if it counted. Only calls that run are counted, and it never says more than is left.",
        "schema": {
          "type": "integer"
        }
      },
      "X-RateLimit-Reset": {
        "description": "When the count starts again: the end of the UTC day, in Unix epoch seconds.",
        "schema": {
          "type": "integer"
        }
      },
      "Retry-After": {
        "description": "Seconds to wait: until the UTC day ends for `daily-limit`, 60 for `rate-limited`.",
        "schema": {
          "type": "integer"
        }
      }
    },
    "schemas": {
      "Error": {
        "type": "object",
        "description": "Burokku’s errors: a code to branch on and a sentence that says what happened and what to do, in the language of the request’s Accept-Language (English when it names none Burokku speaks).",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "What went wrong, for code to branch on: bad-input, bad-json, bad-cursor, unknown-asset, not-address, secret, account-required, plan-limit, insufficient-scope, not-found, LOCKED, method-not-allowed, too-large, rate-limited, daily-limit, off or server-error; a 400 or 403 without its own code comes as bad-request or forbidden. New codes may be added."
              },
              "message": {
                "type": "string",
                "description": "What happened and what to do, for a person to read. Don’t parse it."
              }
            },
            "required": [
              "code",
              "message"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "error"
        ],
        "additionalProperties": false
      },
      "PortfolioSummary": {
        "type": "object",
        "properties": {
          "net_worth_usd": {
            "type": "number"
          },
          "in_wallets_usd": {
            "type": "number"
          },
          "in_defi_usd": {
            "type": "number"
          },
          "in_perps_usd": {
            "description": "Perp margin and open PnL; null without a perp account.",
            "type": [
              "number",
              "null"
            ]
          },
          "in_predictions_usd": {
            "description": "Prediction market shares; null without any.",
            "type": [
              "number",
              "null"
            ]
          },
          "change_24h_usd": {
            "type": [
              "number",
              "null"
            ]
          },
          "change_24h_pct": {
            "anyOf": [
              {
                "type": "number",
                "description": "Percent (12.5 is 12.5%)."
              },
              {
                "type": "null"
              }
            ]
          },
          "accounts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "kind": {
                  "type": "string",
                  "description": "wallet, watch (watch-only address), exchange, manual (added by hand) or trading."
                },
                "provider": {
                  "type": "string",
                  "description": "The wallet app, exchange or venue (watch for a watched address)."
                },
                "address": {
                  "description": "Its address (shortened in the connector unless typed in the call); null for an exchange connected with a key.",
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "value_usd": {
                  "type": "number"
                }
              },
              "required": [
                "name",
                "kind",
                "provider",
                "address",
                "value_usd"
              ],
              "additionalProperties": false
            }
          },
          "top_holdings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "symbol": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "value_usd": {
                  "type": "number"
                },
                "share_pct": {
                  "type": "number",
                  "description": "Percent (12.5 is 12.5%)."
                },
                "change_24h_pct": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "Percent (12.5 is 12.5%)."
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "required": [
                "symbol",
                "name",
                "value_usd",
                "share_pct",
                "change_24h_pct"
              ],
              "additionalProperties": false
            }
          },
          "needs_attention": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991,
            "description": "How many risks Burokku flags (perps near liquidation, risky loans, heavy leverage, concentration)."
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "net_worth_usd",
          "in_wallets_usd",
          "in_defi_usd",
          "in_perps_usd",
          "in_predictions_usd",
          "change_24h_usd",
          "change_24h_pct",
          "accounts",
          "top_holdings",
          "needs_attention",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "Holdings": {
        "type": "object",
        "properties": {
          "total_usd": {
            "type": "number",
            "description": "What the tokens matching the filters are worth together."
          },
          "net_worth_usd": {
            "type": "number"
          },
          "tokens": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "symbol": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "real_world": {
                  "description": "A tokenized real-world asset: what it tracks and who issued it.",
                  "type": "object",
                  "properties": {
                    "kind": {
                      "type": "string"
                    },
                    "tracks": {
                      "type": "string"
                    },
                    "issuer": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "kind",
                    "tracks",
                    "issuer"
                  ],
                  "additionalProperties": false
                },
                "price_usd": {
                  "type": "number"
                },
                "change_24h_pct": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "Percent (12.5 is 12.5%)."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "change_7d_pct": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "Percent (12.5 is 12.5%)."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "amount": {
                  "type": "number"
                },
                "value_usd": {
                  "type": "number"
                },
                "share_of_net_worth_pct": {
                  "type": "number",
                  "description": "Percent (12.5 is 12.5%)."
                },
                "by_account": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "account": {
                        "type": "string"
                      },
                      "account_id": {
                        "description": "REST only: a stable opaque id.",
                        "type": "string"
                      },
                      "chain": {
                        "type": "string"
                      },
                      "amount": {
                        "type": "number"
                      },
                      "value_usd": {
                        "type": "number"
                      }
                    },
                    "required": [
                      "account",
                      "chain",
                      "amount",
                      "value_usd"
                    ],
                    "additionalProperties": false
                  },
                  "description": "Where it is held, largest first (at most 6)."
                }
              },
              "required": [
                "symbol",
                "name",
                "price_usd",
                "change_24h_pct",
                "amount",
                "value_usd",
                "share_of_net_worth_pct",
                "by_account"
              ],
              "additionalProperties": false
            }
          },
          "total_tokens": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991,
            "description": "How many tokens match the filters, across every page."
          },
          "next_cursor": {
            "description": "Pass as cursor for the next page; null on the last page.",
            "type": [
              "string",
              "null"
            ]
          },
          "note": {
            "type": "string"
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "total_usd",
          "net_worth_usd",
          "tokens",
          "total_tokens",
          "next_cursor",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "Positions": {
        "type": "object",
        "properties": {
          "defi": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "protocol": {
                  "type": "string"
                },
                "type": {
                  "type": "string",
                  "description": "Lending, Liquidity, Staking, Yield or Vault."
                },
                "label": {
                  "type": "string"
                },
                "chain": {
                  "type": "string"
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "value_usd": {
                  "type": "number",
                  "description": "Net of debt."
                },
                "pnl_usd": {
                  "type": "number"
                },
                "apy_pct": {
                  "type": "number",
                  "description": "Percent (12.5 is 12.5%)."
                },
                "supplied": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "symbol": {
                        "type": "string"
                      },
                      "amount": {
                        "type": "number"
                      },
                      "usd": {
                        "type": "number"
                      }
                    },
                    "required": [
                      "symbol",
                      "amount",
                      "usd"
                    ],
                    "additionalProperties": false
                  }
                },
                "borrowed": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "symbol": {
                        "type": "string"
                      },
                      "amount": {
                        "type": "number"
                      },
                      "usd": {
                        "type": "number"
                      }
                    },
                    "required": [
                      "symbol",
                      "amount",
                      "usd"
                    ],
                    "additionalProperties": false
                  }
                },
                "health_factor": {
                  "type": "number"
                },
                "unclaimed_rewards_usd": {
                  "type": "number"
                }
              },
              "required": [
                "protocol",
                "type",
                "label",
                "chain",
                "account",
                "value_usd"
              ],
              "additionalProperties": false
            }
          },
          "perps": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "market": {
                  "type": "string"
                },
                "ticker": {
                  "description": "A builder-deployed market’s ticker on its venue.",
                  "type": "string"
                },
                "dex": {
                  "description": "The builder-deployed exchange it trades on.",
                  "type": "string"
                },
                "side": {
                  "type": "string",
                  "enum": [
                    "Long",
                    "Short"
                  ]
                },
                "venue": {
                  "type": "string"
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "size": {
                  "type": "number"
                },
                "entry": {
                  "type": "number"
                },
                "mark": {
                  "type": "number"
                },
                "liquidation": {
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "leverage": {
                  "type": "number"
                },
                "notional_usd": {
                  "type": "number"
                },
                "pnl_usd": {
                  "type": "number",
                  "description": "Unrealised, since the position opened."
                },
                "distance_to_liquidation_pct": {
                  "type": "number",
                  "description": "Percent (12.5 is 12.5%)."
                }
              },
              "required": [
                "market",
                "side",
                "venue",
                "size",
                "entry",
                "mark",
                "liquidation",
                "leverage",
                "notional_usd",
                "pnl_usd"
              ],
              "additionalProperties": false
            }
          },
          "predictions": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "venue": {
                  "type": "string"
                },
                "market": {
                  "type": "string",
                  "description": "What the market asks."
                },
                "outcome": {
                  "type": "string",
                  "description": "The answer and side the shares back."
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "shares": {
                  "type": "number"
                },
                "average_price_usd": {
                  "description": "What each share cost on average, when the venue says.",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "price_usd": {
                  "type": "number"
                },
                "value_usd": {
                  "type": "number"
                },
                "pnl_usd": {
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "resolves_at": {
                  "anyOf": [
                    {
                      "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))$"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "claimable": {
                  "type": "boolean",
                  "description": "Won, waiting to be claimed on the venue."
                }
              },
              "required": [
                "venue",
                "market",
                "outcome",
                "account",
                "shares",
                "average_price_usd",
                "price_usd",
                "value_usd",
                "pnl_usd",
                "resolves_at",
                "claimable"
              ],
              "additionalProperties": false
            }
          },
          "more": {
            "description": "How many more of each were left out (at most 40 of each are listed).",
            "type": "object",
            "properties": {
              "defi": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "perps": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "predictions": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "defi",
              "perps",
              "predictions"
            ],
            "additionalProperties": false
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "LiquidationRisk": {
        "type": "object",
        "properties": {
          "loans": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "protocol": {
                  "type": "string"
                },
                "label": {
                  "type": "string"
                },
                "chain": {
                  "type": "string"
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "health_factor": {
                  "type": "number"
                },
                "collateral_usd": {
                  "type": "number"
                },
                "debt_usd": {
                  "type": "number"
                },
                "price_drop_to_liquidation_pct": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "Percent (12.5 is 12.5%)."
                    },
                    {
                      "type": "null"
                    }
                  ],
                  "description": "How far prices can fall before it is liquidated; null when no fall would liquidate it."
                },
                "liquidation_price": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "symbol": {
                          "type": "string"
                        },
                        "price_usd": {
                          "type": "number"
                        },
                        "now_usd": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "symbol",
                        "price_usd",
                        "now_usd"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "null"
                    }
                  ],
                  "description": "Where one collateral token decides it: its price at liquidation and now."
                }
              },
              "required": [
                "protocol",
                "label",
                "chain",
                "account",
                "health_factor",
                "collateral_usd",
                "debt_usd",
                "price_drop_to_liquidation_pct",
                "liquidation_price"
              ],
              "additionalProperties": false
            }
          },
          "perps": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "market": {
                  "type": "string"
                },
                "side": {
                  "type": "string",
                  "enum": [
                    "Long",
                    "Short"
                  ]
                },
                "venue": {
                  "type": "string"
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "mark": {
                  "type": "number"
                },
                "liquidation": {
                  "type": "number"
                },
                "distance_pct": {
                  "type": "number",
                  "description": "Percent (12.5 is 12.5%)."
                },
                "notional_usd": {
                  "type": "number"
                },
                "leverage": {
                  "type": "number"
                }
              },
              "required": [
                "market",
                "side",
                "venue",
                "mark",
                "liquidation",
                "distance_pct",
                "notional_usd",
                "leverage"
              ],
              "additionalProperties": false
            }
          },
          "nothing_near": {
            "type": "boolean"
          },
          "note": {
            "type": "string"
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "loans",
          "perps",
          "nothing_near",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "Pnl": {
        "type": "object",
        "properties": {
          "range": {
            "type": "string",
            "enum": [
              "1D",
              "1W",
              "1M",
              "1Y",
              "All"
            ]
          },
          "start_usd": {
            "type": [
              "number",
              "null"
            ]
          },
          "end_usd": {
            "type": "number"
          },
          "change_usd": {
            "type": [
              "number",
              "null"
            ]
          },
          "change_pct": {
            "anyOf": [
              {
                "type": "number",
                "description": "Percent (12.5 is 12.5%)."
              },
              {
                "type": "null"
              }
            ]
          },
          "high_usd": {
            "type": [
              "number",
              "null"
            ]
          },
          "low_usd": {
            "type": [
              "number",
              "null"
            ]
          },
          "points": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "at": {
                  "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))$"
                },
                "usd": {
                  "type": "number"
                }
              },
              "required": [
                "at",
                "usd"
              ],
              "additionalProperties": false
            }
          },
          "drivers": {
            "description": "1D, 1W and 1M only.",
            "type": "object",
            "properties": {
              "by_source": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "kind": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "usd": {
                      "type": "number"
                    },
                    "venue": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "kind",
                    "name",
                    "usd"
                  ],
                  "additionalProperties": false
                }
              },
              "coins": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "symbol": {
                      "type": "string"
                    },
                    "usd": {
                      "type": "number"
                    },
                    "pct": {
                      "type": "number",
                      "description": "Percent (12.5 is 12.5%)."
                    }
                  },
                  "required": [
                    "symbol",
                    "usd",
                    "pct"
                  ],
                  "additionalProperties": false
                }
              },
              "perps": {
                "type": "object",
                "properties": {
                  "realised_usd": {
                    "type": "number"
                  },
                  "funding_usd": {
                    "type": "number"
                  },
                  "fees_usd": {
                    "type": "number"
                  },
                  "open_unrealised_usd": {
                    "type": "number"
                  }
                },
                "required": [
                  "realised_usd",
                  "funding_usd",
                  "fees_usd"
                ],
                "additionalProperties": false
              },
              "fees": {
                "type": "object",
                "properties": {
                  "network_usd": {
                    "type": "number"
                  },
                  "perp_trading_usd": {
                    "type": "number"
                  },
                  "bots_usd": {
                    "type": "number"
                  },
                  "funding_paid_usd": {
                    "type": "number"
                  },
                  "total_usd": {
                    "type": "number"
                  }
                },
                "required": [
                  "network_usd",
                  "perp_trading_usd",
                  "bots_usd",
                  "funding_paid_usd",
                  "total_usd"
                ],
                "additionalProperties": false
              },
              "activity_from": {
                "description": "The activity read reaches back only to here: realised PnL and fees before it are not counted.",
                "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))$"
              }
            },
            "required": [
              "coins",
              "fees"
            ],
            "additionalProperties": false
          },
          "unrealised": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "pnl_usd": {
                    "type": "number"
                  },
                  "cost_usd": {
                    "type": "number"
                  },
                  "roi_pct": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "Percent (12.5 is 12.5%)."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "coverage_pct": {
                    "type": "number",
                    "description": "Share of holdings (by value, stablecoins aside) whose cost is known."
                  },
                  "by_holding": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "symbol": {
                          "type": "string"
                        },
                        "pnl_usd": {
                          "type": "number"
                        },
                        "cost_usd": {
                          "type": "number"
                        },
                        "roi_pct": {
                          "anyOf": [
                            {
                              "type": "number",
                              "description": "Percent (12.5 is 12.5%)."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "partial": {
                          "type": "boolean",
                          "description": "Only part of what is held has a known cost."
                        }
                      },
                      "required": [
                        "symbol",
                        "pnl_usd",
                        "cost_usd",
                        "roi_pct",
                        "partial"
                      ],
                      "additionalProperties": false
                    },
                    "description": "The holdings with a known cost, largest PnL first (at most 10)."
                  }
                },
                "required": [
                  "pnl_usd",
                  "cost_usd",
                  "roi_pct",
                  "coverage_pct",
                  "by_holding"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ],
            "description": "Unrealised PnL on holdings whose cost Burokku knows; null when none is known."
          },
          "note": {
            "type": "string"
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "range",
          "start_usd",
          "end_usd",
          "change_usd",
          "change_pct",
          "high_usd",
          "low_usd",
          "points",
          "unrealised",
          "note",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "Activity": {
        "type": "object",
        "properties": {
          "rows": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "kind": {
                  "type": "string",
                  "enum": [
                    "swap",
                    "send",
                    "receive",
                    "bridge",
                    "approve",
                    "stake",
                    "claim",
                    "revoke",
                    "mint",
                    "call",
                    "perp",
                    "funding",
                    "move"
                  ]
                },
                "what": {
                  "type": "string"
                },
                "account": {
                  "type": "string"
                },
                "account_id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "chain": {
                  "type": "string"
                },
                "usd": {
                  "type": "number"
                },
                "realised_pnl_usd": {
                  "type": "number"
                },
                "trading_fee_usd": {
                  "type": "number"
                },
                "network_fee_usd": {
                  "type": "number"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "confirmed",
                    "pending",
                    "failed"
                  ]
                },
                "when": {
                  "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))$"
                },
                "hash": {
                  "description": "REST only: the transaction hash, for on-chain rows.",
                  "type": "string"
                }
              },
              "required": [
                "kind",
                "what",
                "account",
                "chain",
                "status",
                "when"
              ],
              "additionalProperties": false
            }
          },
          "read_reaches_back_to": {
            "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))$"
          },
          "next_cursor": {
            "description": "Pass as cursor for the next page; null on the last page.",
            "type": [
              "string",
              "null"
            ]
          },
          "note": {
            "type": "string"
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "rows",
          "next_cursor",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "ListAlerts": {
        "type": "object",
        "properties": {
          "alerts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "REST only: a stable opaque id.",
                  "type": "string"
                },
                "kind": {
                  "type": "string",
                  "description": "The alert template (price, move, health, liquidation…)."
                },
                "watches": {
                  "type": "string",
                  "description": "What it watches, in the user’s language."
                },
                "on": {
                  "type": "boolean"
                },
                "starter": {
                  "type": "boolean",
                  "description": "One of the alerts Burokku suggests, not switched on by the user yet."
                },
                "channels": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": [
                      "inapp",
                      "email",
                      "push",
                      "telegram"
                    ]
                  }
                },
                "fired": {
                  "type": "integer",
                  "minimum": -9007199254740991,
                  "maximum": 9007199254740991,
                  "description": "How many times it has fired."
                }
              },
              "required": [
                "kind",
                "watches",
                "on",
                "starter",
                "channels",
                "fired"
              ],
              "additionalProperties": false
            }
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "alerts",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "CreatePriceAlert": {
        "type": "object",
        "properties": {
          "alert": {
            "type": "object",
            "properties": {
              "id": {
                "description": "REST only: a stable opaque id.",
                "type": "string"
              },
              "kind": {
                "type": "string",
                "description": "The alert template (price, move, health, liquidation…)."
              },
              "watches": {
                "type": "string",
                "description": "What it watches, in the user’s language."
              },
              "on": {
                "type": "boolean"
              },
              "starter": {
                "type": "boolean",
                "description": "One of the alerts Burokku suggests, not switched on by the user yet."
              },
              "channels": {
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "inapp",
                    "email",
                    "push",
                    "telegram"
                  ]
                }
              },
              "fired": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991,
                "description": "How many times it has fired."
              },
              "asset": {
                "type": "string"
              },
              "direction": {
                "type": "string",
                "enum": [
                  "above",
                  "below"
                ]
              },
              "level_usd": {
                "type": "number"
              }
            },
            "required": [
              "kind",
              "watches",
              "on",
              "starter",
              "channels",
              "fired",
              "asset",
              "direction",
              "level_usd"
            ],
            "additionalProperties": false
          },
          "manage_path": {
            "type": "string",
            "description": "Where the alert is managed in Burokku."
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "alert",
          "manage_path",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "CreatePriceAlertInput": {
        "type": "object",
        "properties": {
          "asset": {
            "type": "string",
            "minLength": 1,
            "maxLength": 21,
            "pattern": "^\\$?[A-Za-z0-9.]{1,20}$",
            "description": "A token symbol, like ETH."
          },
          "direction": {
            "type": "string",
            "enum": [
              "above",
              "below"
            ]
          },
          "level_usd": {
            "type": "number",
            "exclusiveMinimum": 0,
            "maximum": 1000000000000,
            "description": "The price, in US dollars."
          }
        },
        "required": [
          "asset",
          "direction",
          "level_usd"
        ]
      },
      "AddWatchAddress": {
        "type": "object",
        "properties": {
          "account": {
            "type": "object",
            "properties": {
              "id": {
                "description": "REST only: a stable opaque id.",
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "kind": {
                "type": "string",
                "enum": [
                  "watch",
                  "exchange"
                ]
              },
              "network": {
                "type": "string",
                "description": "evm, solana, bitcoin, or the venue."
              },
              "address": {
                "type": "string"
              }
            },
            "required": [
              "name",
              "kind",
              "network",
              "address"
            ],
            "additionalProperties": false
          },
          "added": {
            "type": "boolean",
            "description": "False when Burokku already watched it."
          },
          "read_at": {
            "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))$",
            "description": "When these figures were read (ISO 8601, UTC)."
          },
          "refreshing": {
            "type": "boolean",
            "description": "True while Burokku reads the accounts again behind this answer; a later call has newer figures."
          },
          "currency": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "description": "The currency the account shows money in (USD, EUR, JPY…)."
              },
              "per_usd": {
                "type": "number",
                "exclusiveMinimum": 0,
                "description": "Units of that currency per US dollar, to convert the *_usd figures."
              }
            },
            "required": [
              "code",
              "per_usd"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "account",
          "added",
          "read_at",
          "refreshing",
          "currency"
        ],
        "additionalProperties": false
      },
      "AddWatchAddressInput": {
        "type": "object",
        "properties": {
          "address": {
            "type": "string",
            "minLength": 1,
            "maxLength": 300,
            "description": "The public address, as the user gave it."
          },
          "name": {
            "description": "What to call the account.",
            "type": "string",
            "minLength": 1,
            "maxLength": 60
          },
          "venue": {
            "description": "Read the address as an account on this perp exchange.",
            "type": "string",
            "enum": [
              "hyperliquid",
              "lighter",
              "aster"
            ]
          }
        },
        "required": [
          "address"
        ]
      }
    }
  }
}
