Pokerai API
v0.2.0Browse postflop cache coverage and read Flop, Turn and River GTO strategy for study.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
preflop_versions List preflop strategy versions
The selectable preflop_version values (id + human label) and which is the default. Free (no quota). Call this before assuming a version id.
preflop_strategy Preflop GTO strategy for a hand
GTO mixed strategy (fold/call/raise frequencies + sizes) for a specific hand facing a preflop action line, 6-max 100bb. Charges 1 presolved quota. The situation (RFI/3-bet/4-bet/...) is derived from the actions.
| Parameter | Type | Description |
|---|---|---|
hero * | string | hero position: UTG / MP / CO / BTN / SB / BB |
hole_cards * | string | hero's two cards, e.g. 'AhKh' |
preflop_actions * | array | full action sequence including blinds, e.g. [{position:'SB',action:'small blind',amount:0.5},{position:'BB',action:'big blind',amount:1},{position:'UTG',action:'raise',amount:3}] |
preflop_version | string | chart-set id from preflop_versions; omit for the default |
preflop_range Whole preflop range for a spot
The full 169-hand-type range (fold/call/raise per hand type: AA, AKs, AKo, ...) for a position + action line. No hole_cards. Charges 1 presolved quota (one call, not 169).
| Parameter | Type | Description |
|---|---|---|
hero * | string | the position whose range you want: UTG / MP / CO / BTN / SB / BB |
preflop_actions * | array | action sequence incl. blinds; the range is for `hero` acting after these actions |
preflop_version | string | chart-set id from preflop_versions; omit for the default |
table_size | string | defaults to '6max' |
flop_tree Flop decision tree
Starting ranges + every decision node for a flop spot. In the response each node has `node`, its path (e.g. root/CHECK), and `token`; pass `token` as the `node` argument of flop_node. Charges 1 presolved quota. Single-street (for turn/river use the solver tools).
| Parameter | Type | Description |
|---|---|---|
board * | string | the 3 flop cards, e.g. '2c2h2s' |
positions * | object | roles→positions. SRP: {hero,raiser,caller}; 3BET/4BET: {hero,raiser,three_bettor}; LIMP: {hero,limper} (hero or limper must be BB) |
pot_type * | string | |
flop_version | string | flop dataset id, same values as preflop_versions; omit for the default dataset (6max). Some boards have no data in the default dataset: the call returns 404 and still charges 1 presolved quota, so ret… |
flop_node Flop node strategy
Strategy at one flop decision-tree node. Pass a `node` token minted by flop_tree. With hole_cards → that hand's mixed strategy at the node; omit → the node's whole-range strategy. Free (token-gated).
| Parameter | Type | Description |
|---|---|---|
node * | string | node token from flop_tree |
hole_cards | string | optional hero hand, e.g. 'AdKd' |
postflop_cache_coverage Browse persistent postflop cache coverage
List cached preset roots for one preflop pack and exact flop spelling. Free for all valid API keys. For another page, pass next_cursor with the original pack and board, even if items is empty. A null next_cursor ends pagination. Select a returned item only when needed for a strategy query.
| Parameter | Type | Description |
|---|---|---|
board * | string | three cards without separators, e.g. '2c2d2h' |
preflop_pack * | string | preflop pack ID from preflop_versions or coverage |
cursor | string | opaque next_cursor returned for the same pack and board |
limit | integer |
postflop_cache_query Read cached Flop, Turn or River strategy
Builder/Pro only. Pass a coverage item for a Flop root, or pass a returned token as node to continue. Follow a returned child token to reach an action or chance node. To deal a street, pass the chance node's token plus only the requested turn_card or river_card. Require explicit user intent before each root or deal: each costs one cache query after admission, even if the read misses or fails. A token-only continuation (optionally with hole_cards) is free. Use the returned cache_quota receipt when present. Do not retry automatically or fall back to a solve.
| Parameter | Type | Description |
|---|---|---|
board | string | three cards without separators, e.g. '2c2d2h' |
hole_cards | string | optional hero hand, e.g. 'AdKd' |
node | string | opaque token from postflop_cache_query |
positions | object | Copy positions from a coverage item. SRP needs raiser and caller, 3BET/4BET need raiser and three_bettor, LIMP needs caller and checker (plus hero in all cases). |
pot_type | string | |
preflop_pack | string | preflop pack ID from preflop_versions or coverage |
river_card | deal at a Turn chance node, e.g. 'Qh' | |
turn_card | string | deal at a Flop chance node, e.g. 'Td' |