Assessing a seasonal return
Some horses run well fresh and some need a run. This says which, for this horse, as far as its record can support.
Documentation / Horses & pedigree
/v1/horses/{horse_id}/layoff
Performance split by days since the last run.
Send your key in the X-API-Key header, or as
?key= if your tool cannot set one. A date outside your plan's window returns
403 outside_window naming the window, never an empty array.
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| horse_id | path | string | yes | Opaque horse identifier. |
curl https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff \ -H "X-API-Key: $AHR_KEY"
$ch = curl_init('https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff'); curl_setopt_array($ch, [ CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => ['X-API-Key: ' . getenv('AHR_KEY')], ]); $data = json_decode(curl_exec($ch), true)['data'];
const res = await fetch( 'https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff', { headers: { 'X-API-Key': process.env.AHR_KEY } } ); const { meta, data } = await res.json();
import os, requests r = requests.get( "https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff", headers={"X-API-Key": os.environ["AHR_KEY"]}, ).json()
curl https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff?key=$AHR_KEY
$url = 'https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff' . '?key=$AHR_KEY'; $data = json_decode(file_get_contents($url), true)['data'];
const res = await fetch( 'https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff?key=$AHR_KEY' ); const { meta, data } = await res.json();
import os, requests r = requests.get( "https://api.apihorseracing.com/v1/horses/hs_V8JGH6/layoff?key=$AHR_KEY", ).json()
{ "meta": { "request_id": "5119fd85d7e4a9b9", "data_as_of": "2026-09-12T05:10:27+00:00", "plan": "analyst", "window": "2017 → upcoming", "count": 5 }, "data": { "horse_id": "hs_V8JGH6", "horse": "The Galloping Bear", "window": { "from": null, "to": null, "note": "The whole archive. Your plan sets no date limit." }, "overall": { "runs": 17, "priced": 17, "first": 4, "second": 2, "third": 1, "fourth": 0, "win_pct": 0.2353, "top3_pct": 0.4118, "expected_wins": 2.41, "a_e": 1.657, "a_e_range": [ 0.033, 3.281 ], "a_e_beats_market": false, "significant": false, "low_sample": true, "pl_1pt": 7.56, "roi_pct": 44.47 }, "by": "layoff", "layoff": [ { "layoff": "8-27 days", "runs": 6, "priced": 6, "first": 2, "second": 0, "third": 0, "fourth": 0, "win_pct": 0.3333, "top3_pct": 0.3333, "expected_wins": 1.11, "a_e": 1.808, "a_e_range": [ 0, 4.314 ], "a_e_beats_market": false, "significant": false, "low_sample": true, "pl_1pt": 1.23, "roi_pct": 20.46 }, { "layoff": "28-90 days", "runs": 5, "priced": 5, "first": 1, "second": 2, "third": 0, "fourth": 0, "win_pct": 0.2, "top3_pct": 0.6, "expected_wins": 0.4, "a_e": 2.501, "a_e_range": [ 0, 7.404 ], "a_e_beats_market": false, "significant": false, "low_sample": true, "pl_1pt": 8, "roi_pct": 160 }, "… 3 more" ] } }
A real response from /v1/horses/hs_V8JGH6/layoff,
captured by calling the live API rather than written by hand.
Each field is described once and rendered on every endpoint that returns it, so the wording cannot drift between pages.
| Field | Type | What it is |
|---|---|---|
| horse_id | string | Opaque horse identifier. |
| horse | string | Horse name. |
| window | string | How far back and forward that plan can read. |
| runs | integer | Rides in the slice, priced or not. |
| priced | integer | Rides carrying a starting price. A/E and the profit figures use these; runs is the wider count. |
| first | integer | Wins. |
| second | integer | Seconds. Positions are returned separately so you apply your own place terms. |
| third | integer | Thirds. |
| fourth | integer | Fourths. |
| win_pct | number | Wins over runs. The number everyone quotes and the one that tells you least. |
| top3_pct | number | First, second or third over runs. Not a place strike rate; place terms vary. |
| expected_wins | number | Wins the market implied, summed over the slice. |
| a_e | number | Actual wins over expected. Above 1.00 means winning more often than the prices said. |
| a_e_range | array | Ninety five percent interval on A/E. If it spans 1.00 the figure is not evidence of anything. |
| a_e_beats_market | boolean | True only where the whole interval sits above 1.00. |
| significant | boolean | Whether the interval excludes 1.00 in either direction. |
| low_sample | boolean | Fewer than five expected wins. Treat A/E as noise. |
| pl_1pt | number | One point on every runner, settled at starting price. |
| roi_pct | number | Level stakes return. Backing everything loses more than the book margin, because equal stakes overweight the longshots. |
| Code | Status | When |
|---|---|---|
| unauthorized | 401 | No key, or one we do not recognise. Check the header name and that the key has not been rotated from your account page. |
| upgrade_required | 403 | The endpoint returns computed statistics and your plan does not include them. The body names every plan that does reach it, so you never have to look it up. |
| not_found | 404 | The identifier is well formed but nothing has it. Distinct from invalid_id, which means the identifier itself is wrong. |
| invalid_id | 422 | The prefix does not match the kind of thing the path expects, or the identifier is malformed. A horse id passed where a race is wanted lands here rather than returning the wrong race. |
| rate_limited | 429 | Past your per-minute rate. Retry-After is set, and X-RateLimit-Remaining tells you where you stand on every successful response too. |
| server_error | 500 | Ours, not yours. Every response carries a request_id; quote it and we can find the exact request. |
A real request from your browser straight to
api.apihorseracing.com with
your own key. Nothing is proxied and nothing is logged by this page.
Remembered in this browser so you do not paste it on every page. Forget it
How this horse has run after different lengths of time off, in bands: within a week, one to four weeks, one to three months, three to six, and over six.
Each band carries the full statistics block, so you get A/E rather than a bare strike rate. That distinction matters here more than almost anywhere: a horse returning from six months off is usually priced accordingly, and a strike rate alone cannot tell you whether the market has over-corrected.
For one horse the bands will almost never be significant. Use /v1/analysis/layoff for the population answer and this endpoint for the individual pattern.
Some horses run well fresh and some need a run. This says which, for this horse, as far as its record can support.
A horse that has won twice off a long break is a different proposition from one that has never done it.