# 0xArchive Terminal > A web trading terminal for Hyperliquid (including HIP-3 markets) and Lighter. Charts, order flow, the order book over time, positioning, BTC options and scripts, with all market data from 0xArchive's archive and live feeds, and a paper account to practise on. ## What it has - **Charts**: candles, footprint (who opened and closed at each price) and TPO. Studies such as the order book heatmap, liquidation heatmap, volume profiles, CVD, delta heatmap, trade intent and VWAP, and indicators (`find_indicators` lists them all). Drawing tools and price alerts. - **Order flow**: the order book or DOM ladder, the trades tape filtered by size, wallets working a large order (market clips or refilling icebergs), and the order-flow regime. - **Positioning**: every account against the largest positions, long and short, winners against losers, and USDC onto and off Hyperliquid. - **Scanning markets**: In play (every market of a venue ranked live by its move and positioning), watchlists, factor baskets, idiosyncratic movers, the HIP-3 gap scanner and the economic calendar. - **BTC options**: dealers' gamma, charm and vanna by price and time. - **Planning and research**: the Game plan (the market's levels, each with an alert, and the day's written plan) and Backtest (rules found in a market's history, judged against noise). - **Scripts**: indicators written in TypeScript (or Pine), script panels with their own tables, stat tiles and graphs, strategies with a Strategy report after fees, slippage and funding, and portfolio strategies that trade one account across many markets. The scripting reference is indexed in [scripting/llms.txt](https://terminal.0xarchive.io/scripting/llms.txt), each part a file of its own, so an agent reads only what its script needs. - **Paper trading**: an order ticket (market, limit, stop and take, sized by amount or by risk) and a paper account with positions, working orders, fills and funding. - **Views**: built-in views for each trading style and the reader's own, each shared or backed up as a file. The page also works on a phone. ## Finding your way around The terminal is one page. An agent can set it up two ways: by calling its commands (below), which is faster and exact, or through labelled controls it can reach from the accessibility tree: - **Search** (the field in the top bar, or Cmd/Ctrl+K) finds markets, views, panels, studies, scripts and settings. - **Charts** are drawn on a canvas. Each chart's accessible description, a hidden text summary beside it, says the market, the span on screen with its high and low, the last price, every drawing with its prices and the armed price alerts. The legend above each chart lists its studies and their values as text. - **Drawings**: pick a tool from the rail at the left, click on the chart, then type an exact price in the floating toolbar's price field (horizontal line, horizontal ray, cross line, price label). - **Panels**: each panel's options menu (the ... button) has Maximise, Move and Close. Move starts a keyboard move: arrow keys split beside a panel, Space adds it as a tab, Tab picks the next panel, Enter moves it, Esc cancels. - **Price alerts**: the Alerts button in the top bar, per market. ## Commands for agents Call these instead of clicking. In the page, `await window.oxterminal.run(name, args)` answers `{ ok: true, ... }` or `{ ok: false, error }`, and `window.oxterminal.commands` lists each with its arguments as JSON Schema. Where the browser offers WebMCP (`document.modelContext`), the same commands are registered as tools, with `run_steps` for a list. While commands run, the terminal shows the reader the plan: what is done and what is left. None of them trades. An agent outside the browser (Claude Code, Codex, Cursor and the like) runs the same commands through 0xArchive's hosted MCP server, `https://mcp.0xarchive.io/mcp`. Connected to the reader's 0xArchive account with the `mcp:terminal.read` and `mcp:terminal.write` scopes, its terminal tools act on the Terminal tab the reader has open and signed in, the one they last had in front; with no tab open, the agent is told to open one. The terminal names the agent on the plan it shows the reader. Setup: [MCP server](https://docs.0xarchive.io/mcp-server). **Before setting anything up, read how to decide what to build** (also `window.oxterminal.guide` and the `read_guide` command): Work out what would help most, then build only that. Every step below applies to every request. A view is a document. read_view gives it, write_view sets it: to add, remove or change anything on a view, read it, change the document, and write it back. Write a new view (leave out "view") unless the person asked to change a view they have; then read that one, change only what they asked, and write it back with its view. undo takes back the last change. 1. Understand the ask. What decision is the person making? Over what holding period: seconds, hours, days, weeks? Across one market or many? How fast must they react? If the ask is vague, take the likeliest reading and say which you took. Example: "a trend following workspace" means holding for days to weeks, judged on higher timeframes, across a list of candidates. 2. Read the terminal before changing it. Call get_state for the views and the screen's size, and read_view for what a view holds. Answers can be long: keep them in a variable and print only the part you need. 3. Choose the fewest panels that serve the ask. Every panel must answer a question the person asks while doing this kind of trading. Hold one panel per job: one list of markets (a view holds one), one tape, one book. Leave out what belongs to another kind of trading, even if a preset has it. Example: a trades feed, a DOM ladder or a session Game plan serves an intraday trader, not someone holding for weeks. 4. Choose timeframes from the holding period. Usually a context timeframe, a decision timeframe and an entry timeframe, a step or two apart, and only as many charts as the screen holds. Charts of one market on several timeframes share a colour link, so picking another market moves them together. Example: for a hold of weeks, 1w, 1d and 4h; for a scalp, 15m, 5m and 1m. 5. Keep charts clean. Nothing by default. A chart shows candles and nothing else until the document names more. Add a study or indicator only if it changes a decision for this ask, and say what each one is for. Look up names and settings with find_indicators rather than the Indicators dialog. Keep settings at the defaults unless there is a reason. Example: an intraday VWAP, session ranges or economic events do not help judge a weekly trend. 6. Fit the screen. Plan from the workspace size get_state reports and the minimum sizes read_guide lists. Never put a panel under its minimum; write_view refuses a layout that would, and says what fits. Give the most room to the chart the decisions are made on. When the panels do not fit, put the less used ones in tabs or leave them out, rather than shrinking everything. 7. Let the terminal rank the markets. Put In play on the view, sorted by the column that matches the style, with only the columns that style reads, and say why. It keeps the list in order as the market moves, and a pick moves the charts linked to it. Example: a scalper needs deep books and markets moving now, so 24h volume with 1h change and 1h liquidations beside it; a trend follower, open interest building over 24h, with 4h and 24h change. A watchlist is for markets the person names. 8. Write once, then check. Send the whole view as one write_view. Its answer comes once the charts have their bars and indicators and the book, tape, watchlist and In play their data, and lists every change it made; then read_view, and confirm in live that every panel has data: true and nothing appears that you did not ask for. If the answer names something unfinished, the view exists: wait a few seconds and read_view, and finish it with another write only if it is wrong; never build it twice. 9. Report. Say what you built or changed, what each part is for, what you left out and why, and anything you assumed. Offer the next useful step, and say undo takes it back. **A view is a document.** `read_view` gives the view in front (or one named) as a tree of rows, columns, tabs and panels; `write_view` sets a view to a tree, sized to the screen, and answers with every change it made in words; `undo` takes the last change back (a write, a level, an alert, removed marks, a view opened or deleted), never over the reader's own change since. To add, remove or change anything, read, change the document, and write it back with its `view`; leave `view` out, with a `name`, for a new view. A view is a tree of { row: [...] }, { column: [...] }, { tabs: [panels] } and panels; any part may carry size, its share of its row or column (such as 0.6). Panels: { panel: "chart", symbol, venue, interval, type: candles|footprint|tpo, studies: ["Volume", "VWAP", ...], indicators: [{ indicator: "Key Levels", settings: { "Daily": true } }] } (a chart shows candles alone unless studies or indicators name more, and everything named shows; settings by label, the defaults left out; a view read lists only what each chart draws, and a study or indicator the reader hid stays hidden when the document leaves it out); { panel: "book", view: book|ladder }; { panel: "watchlist", list: "its name", symbols: [...] } for markets the person names; { panel: "inplay", venue: hl|hip3|lighter, sort: a column, dir: desc|asc, columns: [...] }, every market of a venue kept in order live by its sort (columns: chg, rel, doi, state, flow and liqs at 1h, 4h or 24h, such as "liqs:1h", and adr, idio, volume (24h), funding and oi; the sorted column is always shown, and what is left out stays as it was); any other panel by id or name (read_guide lists them with their minimum sizes). Any panel but a watchlist or In play may carry link: own (its own market, a chart's default), focus (the focused chart's, the default for the rest) or a colour "1" to "6" (one market shared by the colour: charts of one market on several timeframes share a colour, so picking a market moves them together). A chart in a colour drives it, a market picked on it moving the colour, unless it carries role: "follows", when a pick moves only that chart. A panel read from a view carries its id: keep it to keep that panel, leave it out for a new one. A view holds one list of markets. A new view for holding trends over days to weeks, on a screen that fits two charts across: ```js await window.oxterminal.run('write_view', { name: 'Trends', layout: { row: [ { size: 0.78, column: [ { panel: 'chart', symbol: 'BTC', interval: '1d', indicators: [{ indicator: 'EMA', settings: { Length: 50 } }, { indicator: 'EMA', settings: { Length: 200 } }] }, { row: [ { panel: 'chart', symbol: 'BTC', interval: '1w' }, { panel: 'chart', symbol: 'BTC', interval: '4h', indicators: [{ indicator: 'ADX' }] }, ] }, ] }, { panel: 'inplay', sort: 'doi:24h', columns: ['doi:24h', 'chg:4h', 'chg:24h'] }, ] }, }); ``` Then, to drop the 200 EMA and put the 4h chart on 1h, change the document and write it back: ```js const v = await window.oxterminal.run('read_view'); const daily = v.layout.row[0].column[0]; daily.indicators = daily.indicators.filter((item) => item.settings?.Length !== 200); v.layout.row[0].column[1].row[1].interval = '1h'; await window.oxterminal.run('write_view', { view: v.view, layout: v.layout }); ``` Several commands run the same way as one: `run([{ name, args }, ...])` checks every step first, then runs them in order and stops at the first that fails. - `get_state`: The view in front, every view by name (marked yours, or built by an agent here), the market and interval in front, the workspace's size in pixels and how many charts fit, and the watchlists. read_view gives what a view holds. - `read_guide`: How to decide what to build for a request, the view document's format, every command with its arguments, and every panel with its minimum size: read it once before setting anything up. - `read_view`(view): A view as a document, the one in front when none is named: { view (its name, unique), id, kind (preset, yours, or agent: built by an agent in this tab), layout, live }. The view document is as described above. live is read-only: for the view in front, each chart's last price, its legend's values, the prices its indicators label (levels, such as Key Levels' PDH), and its drawings and alerts, each with the id remove_marks takes; and the book (bid, ask), the tape (newest print) the watchlist (how many markets are priced) and In play (its top rows, each with the sorted column as it shows it), each with data: whether what it shows has arrived. - `write_view`(view, name, layout, kind, live): Set a view to a document: a new view (give name, leave out view) or the one named in view (as read_view gave it, changed). Only what the document names is on the view, sized to the screen; refused, with what fits, when a panel would be under its minimum. It answers with every change it made, in words. The view document is as described above. Read read_guide first. - `undo`: Take back the last change: a view written (one it changed goes back to how it was, one it made is deleted), a level drawn, an alert set, marks removed, a view opened or deleted. Each undo takes back one more. A change the person has since made their own (a view they edited, a line they moved) stays as they have it, and undo says so. - `open_view`(view): Bring a view to the front by name or id, such as Prep, Trend, Scalp or one built here. - `delete_view`(view): Delete a view an agent built in this tab, by name or id, with the watchlist it made for it. A view the person made, or a preset, cannot be deleted here. - `find_indicators`(query): Look up the indicators and studies a chart can show, by words such as "key levels", "trend", "volume profile" or "vwap": each with its name, whether it goes in a chart's indicators or its studies, its category and what it shows; an exact name also lists its settings with their defaults. With no query, every name by category. - `draw_level`(price, at, interval, kind): Draw a horizontal line (or a ray from the newest bar) on a chart of the market in front: at an exact price, or at the high or low of what that chart shows. - `add_price_alert`(price, at, interval, condition): Arm a price alert on the market in front, on every chart of it: cross (either way), above (at or over) or below (at or under), at a price or at the high or low of what a chart shows. For a level an indicator draws (yesterday's high, a weekly open), read its price from read_view's live levels. It fires while a tab of the terminal is open. - `remove_marks`(drawings, alerts): Remove drawings and price alerts from the market in front, by the ids read_view's live lists them under. ## Open by link Every link opens the terminal on a market, an interval and a view: - `symbol`: the market, such as `BTC`, `SOL` or a HIP-3 market like `xyz:GOLD`. - `venue`: `hyperliquid` (the default) or `lighter`. - `interval`: `1m`, `5m`, `15m`, `30m`, `1h`, `4h`, `1d`, `1w`. - `view`: one of the views below. Example: https://terminal.0xarchive.io/?symbol=SOL&interval=1h&view=prep ## Views - [Overview](https://terminal.0xarchive.io/?view=overview): The chart, with the venue’s markets by their move over the crowd’s positioning - [Scalp](https://terminal.0xarchive.io/?view=scalp): A big 5-minute footprint of who opened and closed at each price, beside the ladder to trade from - [Prep](https://terminal.0xarchive.io/?view=prep): Three timeframes of one market beside In play and the Game plan: context, entry, candidates and the plan on one screen - [Trend](https://terminal.0xarchive.io/?view=trend): The daily, weekly and 4-hour of one market, beside every market ranked by its daily trend - [Whales](https://terminal.0xarchive.io/?view=flow): The book’s walls and large orders on the chart, over who is working orders, with the largest positions and the big prints - [Factors](https://terminal.0xarchive.io/?view=factors): The factor baskets, their holdings, what is moving on its own, and USDC flows - [2 charts](https://terminal.0xarchive.io/?view=charts-2): Two charts side by side, with the book and tape of the focused one - [4 charts](https://terminal.0xarchive.io/?view=charts-4): Four charts in a grid, with the book and tape of the focused one - [Backtest](https://terminal.0xarchive.io/?view=backtest): Search a market’s history for the conditions that came before profitable trades, judged against noise - [Trade](https://terminal.0xarchive.io/?view=trading): The chart with your positions and orders under it, the book, and the order ticket: the screen to trade from ## Docs - [Terminal docs](https://docs.0xarchive.io/terminal): guides and the scripting reference. - [Scripting reference for AI](https://terminal.0xarchive.io/scripting/llms.txt): an index of the script API, guides, diagnostic codes, examples and built-ins, each part a file of its own with its size. ## Optional - [Scripting reference in one file](https://terminal.0xarchive.io/llms-full.txt): every part of the scripting index together, about 140,000 tokens. - [Saved state](https://docs.0xarchive.io/terminal/guides/state): what the terminal keeps in this browser.