horseracingapi.co.uk

One race's upset score

Every plan, free key included

One race judged by the upset rules.

GEThttps://api.horseracingapi.co.uk/v1/upsets/{race_id}
Try itruns against the real API with your key
Get a free key
GET /v1/upsets/{race_id}
Examplea real answer from 2026-10-29
{
    "data": {
        "race_id": "rc_0aa1c4st",
        "meeting_id": "mt_yzs5rm2b",
        "course_id": "cr_239y20yw",
        "course": "Abu Dhabi",
        "country": "UAE",
        "region": "UAE",
        "date": "2026-10-29",
        "off_time": "13:01:21",
        "name": "Race 1 - Al Ghadeer Handicap",
        "runners": 11,
        "is_upset": false,
        "shock_score": 0,
        "why": [],
        "rules": [],
        "winner": {
            "horse_id": "hs_x73ps4xh",
            "horse": "Af Saqara",
            "jockey_id": "jk_xr618k8m",
            "jockey": "Bernardo Pinheiro",
            "trainer_id": "tr_j3qtz590",
            "trainer": "Ernst Oertel"
        },
        "winner_price": {
            "price": "7/1",
            "decimal": 8,
            "source": "sp"
        },
        "favourite": {
            "horse_id": "hs_ngjpqrbn",
            "horse": "Es Khairiyah",
            "position": 4
        },
        "favourite_price": {
            "price": "7/4",
            "decimal": 2.75
        },
        "rating_gap": null
    },
    "meta": {
        "request_id": "c12477664e18f0a6",
        "plan": "complete",
        "window": "January 2017 to the next 3 days",
        "data_as_of": "2026-10-30T09:26:03+00:00"
    }
}
  

Parameters

NameInTypeRequiredWhat it does
race_idpathidyesOur id for the race, as other answers give it (rc_ and eight characters).

Returns

One record in data. Every answer carries meta: request_id, plan, window and data_as_of.

FieldTypeHolds
race_idstringOur id for the race.
meeting_idstringOur id for the meeting.
course_idstringOur id for the course.
coursestringThe course name.
countrystringENG, Scot, Wale or Nort.
regionstringGB, or NORT for Northern Ireland.
datestringThe UK racing day, YYYY-MM-DD.
off_timestringWhen the race actually went off, by the racecourse clock; null until it has.
namestringThe name, as raced: the race title on a race.
runnersintegerThe runners, or how many there were.
is_upsetboolean
shock_scoreintegerHow big an upset, 0 to 100.
whyarrayWhy it counts as an upset.
rulesarray
winnerobject
winner.horse_idstringOur id for the horse.
winner.horsestringThe horse's name.
winner.jockey_idstringOur id for the jockey.
winner.jockeystringThe jockey's name.
winner.trainer_idstringOur id for the trainer.
winner.trainerstringThe trainer's name.
winner_priceobjectThe winner's price. Null on the free key.
winner_price.pricestring
winner_price.decimalinteger
winner_price.sourcestring
favouriteobjectWhether it started favourite. Null on the free key.
favourite.horse_idstringOur id for the horse.
favourite.horsestringThe horse's name.
favourite.positionintegerWhere it finished; null for a non-finisher.
favourite_priceobjectThe favourite's price. Null on the free key.
favourite_price.pricestring
favourite_price.decimalnumber
rating_gapnull or value

Errors

CodeStatusWhen
unauthorized401No key was sent, or the key is not one of ours.
outside_plan_window403The day asked for is outside what your plan reads. The answer gives your window and the day you asked for.
bad_request400A value is the wrong shape: a date that is not YYYY-MM-DD, a cursor that is not ours, or a key sent in the address.
unknown_parameter422A parameter this endpoint does not take. The answer lists the ones it does.
not_found404No record has that id, or it is not British or Northern Irish racing.
rate_limited429Too many calls this minute for your plan.
quota_exceeded429Your plan's calls for the month are used. The answer says when they reset.