openapi: 3.1.0 info: title: The Racing Australia Pro Plan API version: 1.4.3 x-logo: url: https://www.theracingapi.com/static/images/logo_padded.png description: High performance API for horse racing statistical modelling, application development and web content. Complete coverage of UK, Irish and Hong Kong horse racing. contact: url: https://www.theracingapi.com/ x-generated-from: official-openapi-spec servers: - url: https://api.theracingapi.com description: Production server tags: - name: Pro Plan paths: /v1/courses/regions: get: tags: - Pro Plan summary: The Racing API Regions description:

Get a list of regions, with region codes.

Min. Required PlanFree
Rate Limit1 requests per second
operationId: regions_v1_courses_regions_get responses: '200': description: Successful Response content: application/json: schema: items: $ref: '#/components/schemas/Region' type: array title: Response Regions V1 Courses Regions Get '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' security: - HTTPBasic: [] x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/courses/regions ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/courses/regions" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/courses/regions?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/courses/regions'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/courses/regions\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/courses/regions?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/courses/regions?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/courses: get: tags: - Pro Plan summary: The Racing API Courses description:

Get a list of courses, with course ids and regions.

Min. Required PlanFree
Rate Limit1 requests per second
operationId: courses_v1_courses_get security: - HTTPBasic: [] parameters: - name: region_codes in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Regions description: Filter courses by region codes. Get the full list here. examples: - gb - ire description: Filter courses by region codes. Get the full list here. responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/CoursesPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/courses ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/courses" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/courses?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/courses'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/courses\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/courses?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/courses?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/dams/search: get: tags: - Pro Plan summary: The Racing API Dam Search description:

Search dams by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: dam_search_v1_dams_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Dams' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/dams/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/dams/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/dams/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/dams/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/dams/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/dams/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/dams/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/dams/{dam_id}/results: get: tags: - Pro Plan summary: The Racing API Dam Progeny Results description:

Get full historical results for a dam's progeny

Min. Required PlanPro
Rate Limit5 requests per second

ℹ️ To view a dam's own racing results, use the horse results endpoint, repacing the 'dam_' id prefix with 'hrs_'.

operationId: dam_progeny_results_v1_dams__dam_id__results_get security: - HTTPBasic: [] parameters: - name: dam_id in: path required: true schema: type: string title: Dam Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/dams/{dam_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/dams/{dam_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/dams/{dam_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/dams/{dam_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/dams/{dam_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/dams/{dam_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/dams/{dam_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/dams/{dam_id}/analysis/classes: get: tags: - Pro Plan summary: The Racing API Dam Progeny Class Analysis description:

Get dam progeny statistics by race class

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: dam_progeny_class_analysis_v1_dams__dam_id__analysis_classes_get security: - HTTPBasic: [] parameters: - name: dam_id in: path required: true schema: type: string title: Dam Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/DamClassAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/classes?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/dams/{dam_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Dam Progeny Distance Analysis description:

Get dam progeny statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: dam_progeny_distance_analysis_v1_dams__dam_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: dam_id in: path required: true schema: type: string title: Dam Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/DamDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/dams/{dam_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/damsires/search: get: tags: - Pro Plan summary: The Racing API Damsire Search description:

Search damsires by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: damsire_search_v1_damsires_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Damsires' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/damsires/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/damsires/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/damsires/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/damsires/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/damsires/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/damsires/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/damsires/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/damsires/{damsire_id}/results: get: tags: - Pro Plan summary: The Racing API Damsire Grandoffspring Results description:

Get full historical results for a damsire's grandoffspring

Min. Required PlanPro
Rate Limit5 requests per second

ℹ️ To view a damsire's own racing results, use the horse results endpoint, repacing the 'dsi_' id prefix with 'hrs_'.

operationId: damsire_grandoffspring_results_v1_damsires__damsire_id__results_get security: - HTTPBasic: [] parameters: - name: damsire_id in: path required: true schema: type: string title: Damsire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/damsires/{damsire_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/damsires/{damsire_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/damsires/{damsire_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/damsires/{damsire_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/damsires/{damsire_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/damsires/{damsire_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/damsires/{damsire_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/damsires/{damsire_id}/analysis/classes: get: tags: - Pro Plan summary: The Racing API Damsire Grandoffspring Class Analysis description:

Get damsire grandoffspring statistics by race class

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: damsire_grandoffspring_class_analysis_v1_damsires__damsire_id__analysis_classes_get security: - HTTPBasic: [] parameters: - name: damsire_id in: path required: true schema: type: string title: Damsire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/DamsireClassAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/classes?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/damsires/{damsire_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Damsire Grandoffspring Distance Analysis description:

Get damsire grandoffspring statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: damsire_grandoffspring_distance_analysis_v1_damsires__damsire_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: damsire_id in: path required: true schema: type: string title: Damsire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/DamsireDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/damsires/{damsire_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/horses/search: get: tags: - Pro Plan summary: The Racing API Horse Search description:

Search horses by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: horse_search_v1_horses_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Horses' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/horses/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/horses/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/horses/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/horses/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/horses/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/horses/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/horses/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/horses/{horse_id}/results: get: tags: - Pro Plan summary: The Racing API Horse Results description:

Get full historical results for a horse

Min. Required PlanPro
Rate Limit5 requests per second
operationId: horse_results_v1_horses__horse_id__results_get security: - HTTPBasic: [] parameters: - name: horse_id in: path required: true schema: type: string title: Horse Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/horses/{horse_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/horses/{horse_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/horses/{horse_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/horses/{horse_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/horses/{horse_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/horses/{horse_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/horses/{horse_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/horses/{horse_id}/analysis/distance-times: get: tags: - Pro Plan summary: The Racing API Horse Distance Time Analysis description:

Get horse statistics by race distance, with breakdowns of times.

Min. Required PlanBasic
Rate Limit5 requests per second
operationId: horse_distance_time_analysis_v1_horses__horse_id__analysis_distance_times_get security: - HTTPBasic: [] parameters: - name: horse_id in: path required: true schema: type: string title: Horse Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/HorseDistanceTimeAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/horses/{horse_id}/analysis/distance-times?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/horses/{horse_id}/standard: get: tags: - Pro Plan summary: The Racing API Horse Standard description:

Get a basic horse profile

Min. Required PlanStandard
Rate Limit5 requests per second

ℹ️ You may also get profiles for a sire/dam/damsire using this endpoint by replacing their id prefix with 'hrs_'

operationId: horse_standard_v1_horses__horse_id__standard_get security: - HTTPBasic: [] parameters: - name: horse_id in: path required: true schema: type: string title: Horse Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Horse' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/horses/{horse_id}/standard ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/horses/{horse_id}/standard" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/horses/{horse_id}/standard?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/horses/{horse_id}/standard'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/horses/{horse_id}/standard\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/horses/{horse_id}/standard?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/horses/{horse_id}/standard?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/horses/{horse_id}/pro: get: tags: - Pro Plan summary: The Racing API Horse Pro description:

Get a detailed horse profile including dob, sex, color and breeder.

Min. Required PlanPro
Rate Limit5 requests per second

ℹ️ You may also get profiles for a sire/dam/damsire using this endpoint by replacing their id prefix with 'hrs_'

ℹ️ If a detailed profile for a horse can't be found, a basic profile may still be found using the Horse Standard endpoint

operationId: horse_pro_v1_horses__horse_id__pro_get security: - HTTPBasic: [] parameters: - name: horse_id in: path required: true schema: type: string title: Horse Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/HorsePro' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/horses/{horse_id}/pro ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/horses/{horse_id}/pro" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/horses/{horse_id}/pro?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/horses/{horse_id}/pro'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/horses/{horse_id}/pro\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/horses/{horse_id}/pro?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/horses/{horse_id}/pro?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/search: get: tags: - Pro Plan summary: The Racing API Jockey Search description:

Search jockeys by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: jockey_search_v1_jockeys_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Jockeys' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/{jockey_id}/results: get: tags: - Pro Plan summary: The Racing API Jockey Results description:

Get full historical results for a jockey

Min. Required PlanPro
Rate Limit5 requests per second
operationId: jockey_results_v1_jockeys__jockey_id__results_get security: - HTTPBasic: [] parameters: - name: jockey_id in: path required: true schema: type: string title: Jockey Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/{jockey_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/{jockey_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/{jockey_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/{jockey_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/{jockey_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/{jockey_id}/analysis/courses: get: tags: - Pro Plan summary: The Racing API Jockey Course Analysis description:

Get jockey statistics by course

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: jockey_course_analysis_v1_jockeys__jockey_id__analysis_courses_get security: - HTTPBasic: [] parameters: - name: jockey_id in: path required: true schema: type: string title: Jockey Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/JockeyCourseAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/courses?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/{jockey_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Jockey Distance Analysis description:

Get jockey statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: jockey_distance_analysis_v1_jockeys__jockey_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: jockey_id in: path required: true schema: type: string title: Jockey Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/JockeyDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/{jockey_id}/analysis/owners: get: tags: - Pro Plan summary: The Racing API Jockey Owner Analysis description:

Get jockey statistics by owner

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: jockey_owner_analysis_v1_jockeys__jockey_id__analysis_owners_get security: - HTTPBasic: [] parameters: - name: jockey_id in: path required: true schema: type: string title: Jockey Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/JockeyOwnerAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/owners?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/jockeys/{jockey_id}/analysis/trainers: get: tags: - Pro Plan summary: The Racing API Jockey Trainer Analysis description:

Get jockey statistics by trainer

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: jockey_trainer_analysis_v1_jockeys__jockey_id__analysis_trainers_get security: - HTTPBasic: [] parameters: - name: jockey_id in: path required: true schema: type: string title: Jockey Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/JockeyTrainerAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/jockeys/{jockey_id}/analysis/trainers?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/odds/{race_id}/{horse_id}: get: tags: - Pro Plan summary: The Racing API Odds Runner description:

Get detailed pre-race runner odds data, including price movements, for UK and Irish racing.

Min. Required PlanPro
Rate Limit5 requests per second

ℹ️ Price movements, displayed in the 'history' fields, are available for runners in races from 2025-03-17 onwards.

operationId: odds_runner_v1_odds__race_id___horse_id__get security: - HTTPBasic: [] parameters: - name: race_id in: path required: true schema: type: string title: Race Id - name: horse_id in: path required: true schema: type: string title: Horse Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/RaceRunnerOdds' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/odds/{race_id}/{horse_id} ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/odds/{race_id}/{horse_id}?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/search: get: tags: - Pro Plan summary: The Racing API Owner Search description:

Search owners by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: owner_search_v1_owners_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Owners' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/{owner_id}/results: get: tags: - Pro Plan summary: The Racing API Owner Results description:

Get full historical results for an owner

Min. Required PlanPro
Rate Limit5 requests per second
operationId: owner_results_v1_owners__owner_id__results_get security: - HTTPBasic: [] parameters: - name: owner_id in: path required: true schema: type: string title: Owner Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/{owner_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/{owner_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/{owner_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/{owner_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/{owner_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/{owner_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/{owner_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/{owner_id}/analysis/courses: get: tags: - Pro Plan summary: The Racing API Owner Course Analysis description:

Get owner statistics by course

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: owner_course_analysis_v1_owners__owner_id__analysis_courses_get security: - HTTPBasic: [] parameters: - name: owner_id in: path required: true schema: type: string title: Owner Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OwnerCourseAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/courses?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/{owner_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Owner Distance Analysis description:

Get owner statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: owner_distance_analysis_v1_owners__owner_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: owner_id in: path required: true schema: type: string title: Owner Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OwnerDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/{owner_id}/analysis/jockeys: get: tags: - Pro Plan summary: The Racing API Owner Jockey Analysis description:

Get owner statistics by jockey

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: owner_jockey_analysis_v1_owners__owner_id__analysis_jockeys_get security: - HTTPBasic: [] parameters: - name: owner_id in: path required: true schema: type: string title: Owner Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OwnerJockeyAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/jockeys?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/owners/{owner_id}/analysis/trainers: get: tags: - Pro Plan summary: The Racing API Owner Trainer Analysis description:

Get owner statistics by trainer

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: owner_trainer_analysis_v1_owners__owner_id__analysis_trainers_get security: - HTTPBasic: [] parameters: - name: owner_id in: path required: true schema: type: string title: Owner Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OwnerTrainerAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/owners/{owner_id}/analysis/trainers?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/racecards/pro: get: tags: - Pro Plan summary: The Racing API Racecards Pro description:

Get future and historical racecards, including runner odds for UK & Irish racing.

Min. Required PlanPro
Rate Limit2 requests per second

ℹ️ Historical racecards are available from 2023-01-23, when our tracking began. Future racecards are available up to 1 week in advance.

operationId: racecards_pro_v1_racecards_pro_get security: - HTTPBasic: [] parameters: - name: date in: query required: false schema: anyOf: - type: string - type: 'null' title: Date description: Query racecards by date with format YYYY-MM-DD (e.g 2023-04-05) description: Query racecards by date with format YYYY-MM-DD (e.g 2023-04-05) - name: region_codes in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Regions description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course_ids in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Courses description: Query by course ids. Get the full list here. description: Query by course ids. Get the full list here. - name: limit in: query required: false schema: anyOf: - type: integer maximum: 500 minimum: 1 - type: 'null' title: Limit default: 500 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 500 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/RacecardsOddsProPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/racecards/pro ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/racecards/pro" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/racecards/pro?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/racecards/pro'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/racecards/pro\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/racecards/pro?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/racecards/pro?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/racecards/big-races: get: tags: - Pro Plan summary: The Racing API Racecards Big Races description:

Get detailed racecards for future big races and main events, such as Cheltenham, The Grand National and The Derby.

Min. Required PlanStandard
Rate Limit2 requests per second
operationId: racecards_big_races_v1_racecards_big_races_get security: - HTTPBasic: [] parameters: - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Date must be today or greater, defaults to today.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Date must be today or greater, defaults to today.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region_codes in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Regions description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course_ids in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Courses description: Query by course ids. Get the full list here. description: Query by course ids. Get the full list here. - name: limit in: query required: false schema: anyOf: - type: integer maximum: 500 minimum: 1 - type: 'null' title: Limit default: 500 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 500 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/RacecardsOddsPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/racecards/big-races ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/racecards/big-races" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/racecards/big-races?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/racecards/big-races'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/racecards/big-races\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/racecards/big-races?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/racecards/big-races?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/racecards/summaries: get: tags: - Pro Plan summary: The Racing API Racecards Summaries description:

Get racecard summaries by date

Min. Required PlanBasic
Rate Limit5 requests per second
operationId: racecards_summaries_v1_racecards_summaries_get security: - HTTPBasic: [] parameters: - name: date in: query required: false schema: anyOf: - type: string - type: 'null' title: Date description: Query racecard summaries by date with format YYYY-MM-DD (e.g 2023-04-05) default: '2026-05-03' description: Query racecard summaries by date with format YYYY-MM-DD (e.g 2023-04-05) - name: region_codes in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Regions description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course_ids in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' title: Courses description: Query by course ids. Get the full list here. description: Query by course ids. Get the full list here. responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/RacecardsSummary' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/racecards/summaries ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/racecards/summaries" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/racecards/summaries?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/racecards/summaries'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/racecards/summaries\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/racecards/summaries?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/racecards/summaries?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/racecards/{race_id}/pro: get: tags: - Pro Plan summary: The Racing API Race Pro description:

Get a race, including runner odds for UK & Ireland races only.

Min. Required PlanPro
Rate Limit5 requests per second
operationId: race_pro_v1_racecards__race_id__pro_get security: - HTTPBasic: [] parameters: - name: race_id in: path required: true schema: type: string title: Race Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/RacecardOddsPro' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/racecards/{race_id}/pro ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/racecards/{race_id}/pro" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/racecards/{race_id}/pro?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/racecards/{race_id}/pro'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/racecards/{race_id}/pro\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/racecards/{race_id}/pro?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/racecards/{race_id}/pro?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/results: get: tags: - Pro Plan summary: The Racing API Results description: '

Get historic results for all races in the last 12 months

Min. Required PlanStandard
Rate Limit5 requests per second
Add-ons[Optional] Core database historical results add-on: users on the Pro Plan can pay a one-time fee of £499 to remove the 12 month restriction and access over 30 years of results from this endpoint. Contact support@theracingapi.com for information.

Efficiently querying and exporting results data

While the parameters for this endpoint allow for a wide date range to be set (utilising ''start_date'' and ''end_date''), the necessary use of ''skip'' to access all results for a wide date range query will reduce perfomance the larger that range is.

ℹ️ The most efficient way to query results data over time is to build a list of dates within your date range, then make queries for each date in that list. A sample python script outlining this method can be viewed here: https://gist.github.com/theracingapi/4d492dbdba58c2072fe4f98ee090126f

' operationId: results_v1_results_get security: - HTTPBasic: [] parameters: - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Limited to up to 365 days in the past; pro plan users can purchase the historical results add-on to remove this limitation and query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Limited to up to 365 days in the past; pro plan users can purchase the historical results add-on to remove this limitation and query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/results/today: get: tags: - Pro Plan summary: The Racing API Results Today description:

Get today's results

Min. Required PlanBasic
Rate Limit5 requests per second
operationId: results_today_v1_results_today_get security: - HTTPBasic: [] parameters: - name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description:

Query results by region codes. Get the full list here.

title: Region description:

Query results by region codes. Get the full list here.

- name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsBasicPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/results/today ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/results/today" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/results/today?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/results/today'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/results/today\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/results/today?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/results/today?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/results/{race_id}: get: tags: - Pro Plan summary: The Racing API Result description:

Get a result

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: result_v1_results__race_id__get security: - HTTPBasic: [] parameters: - name: race_id in: path required: true schema: type: string title: Race Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultStandard' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/results/{race_id} ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/results/{race_id}" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/results/{race_id}?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/results/{race_id}'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/results/{race_id}\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/results/{race_id}?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/results/{race_id}?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/sires/search: get: tags: - Pro Plan summary: The Racing API Sire Search description:

Search sires by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: sire_search_v1_sires_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Sires' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/sires/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/sires/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/sires/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/sires/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/sires/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/sires/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/sires/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/sires/{sire_id}/results: get: tags: - Pro Plan summary: The Racing API Sire Progeny Results description:

Get full historical results for a sire's progeny

Min. Required PlanPro
Rate Limit5 requests per second

ℹ️ To view a sire's own racing results, use the horse results endpoint, repacing the 'sir_' id prefix with 'hrs_'.

operationId: sire_progeny_results_v1_sires__sire_id__results_get security: - HTTPBasic: [] parameters: - name: sire_id in: path required: true schema: type: string title: Sire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/sires/{sire_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/sires/{sire_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/sires/{sire_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/sires/{sire_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/sires/{sire_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/sires/{sire_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/sires/{sire_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/sires/{sire_id}/analysis/classes: get: tags: - Pro Plan summary: The Racing API Sire Progeny Class Analysis description:

Get sire progeny statistics by race class

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: sire_progeny_class_analysis_v1_sires__sire_id__analysis_classes_get security: - HTTPBasic: [] parameters: - name: sire_id in: path required: true schema: type: string title: Sire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/SireClassAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/classes?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/sires/{sire_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Sire Progeny Distance Analysis description:

Get sire progeny statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: sire_progeny_distance_analysis_v1_sires__sire_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: sire_id in: path required: true schema: type: string title: Sire Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/SireDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/sires/{sire_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/search: get: tags: - Pro Plan summary: The Racing API Trainer Search description:

Search trainers by name

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_search_v1_trainers_search_get security: - HTTPBasic: [] parameters: - name: name in: query required: true schema: type: string title: Name responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Trainers' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/search ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/search" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/search?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/search'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/search\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/search?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/search?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/results: get: tags: - Pro Plan summary: The Racing API Trainer Results description:

Get full historical results for a trainer

Min. Required PlanPro
Rate Limit5 requests per second
operationId: trainer_results_v1_trainers__trainer_id__results_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

Default: 365 days ago. Can query back to 1988-01-01.

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

Default: Today's date. Maximum range between start and end date is 365 days.

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' - name: limit in: query required: false schema: anyOf: - type: integer maximum: 100 minimum: 1 - type: 'null' title: Limit default: 50 - name: skip in: query required: false schema: anyOf: - type: integer maximum: 20000 - type: 'null' title: Skip default: 0 responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ResultsStandardPage' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/results ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/results" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/results?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/results'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/results\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/results?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/results?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/analysis/horse-age: get: tags: - Pro Plan summary: The Racing API Trainer Horse Age Analysis description:

Get trainer statistics by horse age

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_horse_age_analysis_v1_trainers__trainer_id__analysis_horse_age_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/TrainerHorseAgeAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/horse-age?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/analysis/courses: get: tags: - Pro Plan summary: The Racing API Trainer Course Analysis description:

Get trainer statistics by course

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_course_analysis_v1_trainers__trainer_id__analysis_courses_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/TrainerCourseAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/courses?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/analysis/distances: get: tags: - Pro Plan summary: The Racing API Trainer Distance Analysis description:

Get trainer statistics by race distance

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_distance_analysis_v1_trainers__trainer_id__analysis_distances_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/TrainerDistanceAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/distances?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/analysis/jockeys: get: tags: - Pro Plan summary: The Racing API Trainer Jockey Analysis description:

Get trainer statistics by jockey

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_jockey_analysis_v1_trainers__trainer_id__analysis_jockeys_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/TrainerJockeyAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/jockeys?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK /v1/trainers/{trainer_id}/analysis/owners: get: tags: - Pro Plan summary: The Racing API Trainer Owner Analysis description:

Get trainer statistics by owner

Min. Required PlanStandard
Rate Limit5 requests per second
operationId: trainer_owner_analysis_v1_trainers__trainer_id__analysis_owners_get security: - HTTPBasic: [] parameters: - name: trainer_id in: path required: true schema: type: string title: Trainer Id - name: start_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

title: Start Date description:

Query from date with format YYYY-MM-DD, e.g. 2020-01-01

- name: end_date in: query required: false schema: anyOf: - type: string - type: 'null' description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

title: End Date description:

Query to date with format YYYY-MM-DD, e.g. 2020-01-01

- name: region in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' title: Region description: '

Query by region codes. Get the full list here.

Note: If the course query parameter is specified, this will be ignored.

' - name: course in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Query by course ids. Get the full list here. title: Course description: Query by course ids. Get the full list here. - name: type in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' title: Type description: '

Query by race type

Options: chase, flat, hurdle, nh_flat

' - name: going in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' title: Going description: '

Query by going

Options: fast, firm, good, good_to_firm, good_to_soft, good_to_yielding, hard, heavy, holding, muddy, sloppy, slow, soft, soft_to_heavy, standard, standard_to_fast, standard_to_slow, very_soft, yielding, yielding_to_soft

' - name: race_class in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' title: Race Class description: '

Query by class

Options: class_1, class_2, class_3, class_4, class_5, class_6, class_7

' - name: min_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by minimum race distance (yards)

title: Min Distance Y description:

Query by minimum race distance (yards)

- name: max_distance_y in: query required: false schema: anyOf: - type: integer - type: 'null' description:

Query by maximum race distance (yards)

title: Max Distance Y description:

Query by maximum race distance (yards)

- name: age_band in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' title: Age Band description: '

Query by age band

Options: 10yo+, 2-3yo, 2yo, 2yo+, 3-4yo, 3-5yo, 3-6yo, 3yo, 3yo+, 4-5yo, 4-6yo, 4-7yo, 4-8yo, 4yo, 4yo+, 5-6yo, 5-7yo, 5-8yo, 5yo, 5yo+, 6-7yo, 6yo, 6yo+, 7yo+, 8yo+, 9yo+

' - name: sex_restriction in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' title: Sex Restriction description: '

Query by sex restriction

Options: c&f, c&g, f, f&m, m, m&g

' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/TrainerOwnerAnalysis' '404': description: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' x-codeSamples: - lang: Shell source: 'curl -u USERNAME:PASSWORD https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners ' label: cURL - lang: Python source: 'import requests from requests.auth import HTTPBasicAuth url = "https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners" params = {} response = requests.request("GET", url, auth=HTTPBasicAuth(''USERNAME'',''PASSWORD''), params=params) print(response.json())' label: Python3 - lang: PHP source: "" label: PHP - lang: JavaScript source: "const username = 'USERNAME';\nconst password = 'PASSWORD';\nconst credentials = btoa(`${username}:${password}`);\n\nconst params = new URLSearchParams({});\nconst url = `https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners?${params}`;\n\nfetch(url, {\n method: 'GET',\n headers: {\n 'Authorization': `Basic ${credentials}`\n }\n})\n.then(response => response.json())\n.then(data => console.log(data))\n.catch(error => console.error('Error:', error));" label: Node.js - lang: Ruby source: 'require ''net/http'' require ''uri'' require ''json'' params = {} uri = URI(''https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners'') uri.query = URI.encode_www_form(params) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true request = Net::HTTP::Get.new(uri) request.basic_auth(''USERNAME'', ''PASSWORD'') response = http.request(request) puts JSON.parse(response.body)' label: Ruby - lang: Java source: "import java.net.http.*;\nimport java.util.Base64;\nimport java.util.Map;\n\nMap params = Map.of();\nString credentials = Base64.getEncoder()\n .encodeToString(\"USERNAME:PASSWORD\".getBytes());\n\nHttpClient client = HttpClient.newHttpClient();\nHttpRequest request = HttpRequest.newBuilder()\n .uri(URI.create(\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners\"))\n .header(\"Authorization\", \"Basic \" + credentials)\n .build();\n\nHttpResponse response = client.send(\n request, HttpResponse.BodyHandlers.ofString());\nSystem.out.println(response.body());" label: Java - lang: Go source: "package main\n\nimport (\n \"fmt\"\n \"io\"\n \"net/http\"\n \"net/url\"\n)\n\nfunc main() {\n params := url.Values{}\n url := \"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners?\" + params.Encode()\n\n client := &http.Client{}\n req, _ := http.NewRequest(\"GET\", url, nil)\n req.SetBasicAuth(\"USERNAME\", \"PASSWORD\")\n\n resp, _ := client.Do(req)\n defer resp.Body.Close()\n body, _ := io.ReadAll(resp.Body)\n fmt.Println(string(body))\n}" label: Go - lang: C# source: "using System.Net.Http.Headers;\nusing System.Text;\nusing System.Web;\n\nvar params_ = HttpUtility.ParseQueryString(string.Empty);\nvar url = $\"https://api.theracingapi.com/v1/trainers/{trainer_id}/analysis/owners?{params_}\";\n\nvar client = new HttpClient();\nvar credentials = Convert.ToBase64String(\n Encoding.ASCII.GetBytes(\"USERNAME:PASSWORD\"));\nclient.DefaultRequestHeaders.Authorization =\n new AuthenticationHeaderValue(\"Basic\", credentials);\n\nvar response = await client.GetAsync(url);\nvar content = await response.Content.ReadAsStringAsync();\nConsole.WriteLine(content);" label: .NET x-microcks-operation: delay: 0 dispatcher: FALLBACK components: schemas: app__models__dams__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: -5.5 1st: 8 2nd: 6 3rd: 5 4th: 4 a/e: 0.85 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 50 win_%: 0.16 ResultBasic: properties: race_id: type: string title: Race Id date: type: string title: Date region: type: string title: Region course: type: string title: Course course_id: type: string title: Course Id 'off': type: string title: 'Off' off_dt: anyOf: - type: string - type: 'null' title: Off Dt default: '' race_name: type: string title: Race Name type: type: string title: Type class: type: string title: Class pattern: type: string title: Pattern rating_band: type: string title: Rating Band age_band: type: string title: Age Band sex_rest: type: string title: Sex Rest dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F going: type: string title: Going surface: anyOf: - type: string - type: 'null' title: Surface default: '' jumps: anyOf: - type: string - type: 'null' title: Jumps default: '' runners: items: $ref: '#/components/schemas/app__models__result__RunnerBasic' type: array title: Runners winning_time_detail: anyOf: - type: string - type: 'null' title: Winning Time Detail default: '' comments: anyOf: - type: string - type: 'null' title: Comments default: '' non_runners: anyOf: - type: string - type: 'null' title: Non Runners default: '' tote_win: anyOf: - type: string - type: 'null' title: Tote Win default: '' tote_pl: anyOf: - type: string - type: 'null' title: Tote Pl default: '' tote_ex: anyOf: - type: string - type: 'null' title: Tote Ex default: '' tote_csf: anyOf: - type: string - type: 'null' title: Tote Csf default: '' tote_tricast: anyOf: - type: string - type: 'null' title: Tote Tricast default: '' tote_trifecta: anyOf: - type: string - type: 'null' title: Tote Trifecta default: '' type: object required: - race_id - date - region - course - course_id - 'off' - race_name - type - class - pattern - rating_band - age_band - sex_rest - dist - dist_y - dist_m - dist_f - going - runners title: ResultBasic example: age_band: 4yo+ class: '' comments: '' course: Ballinrobe (IRE) course_id: crs_4550 date: '2025-08-11' dist: 2m7f dist_f: 23f dist_m: '4625' dist_y: '5058' going: Good jumps: 12 hurdles non_runners: Diamonds Diva (reserve), Great Rainbow (reserve), Loughrask Rainbow (reserve) 'off': '8:25' off_dt: '2025-08-11T20:25:00+01:00' pattern: '' race_id: rac_11715730 race_name: J.J. Burke Peugeot Handicap Hurdle rating_band: 0-100 region: IRE runners: - age: '8' btn: '0' comment: Held up in rear - headway 3 out - went third after 2 out - challenging when not fluent last - led home turn - ridden clear final furlong(op 13/2) dam: Save Me The Waltz (FR) dam_id: dam_4189605 damsire: Halling damsire_id: dsi_675241 draw: '' headgear: v horse: Mephisto (IRE) horse_id: hrs_19359270 jockey: Shane Fitzgerald jockey_claim_lbs: '0' jockey_id: jky_302916 number: '2' or: '98' ovr_btn: '0' owner: Restricted Movement Syndicate owner_id: own_1204876 position: '1' prize: €5900 rpr: '105' sex: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Kendargent (FR) sire_id: sir_4514419 sp: 15/2 sp_dec: '8.50' time: '5:44.90' trainer: Gerard Keane trainer_id: trn_86382 tsr: '64' weight: 11-12 weight_lbs: '166' sex_rest: '' surface: Turf tote_csf: €300.55 tote_ex: €253.10 tote_pl: €2.30 €5.80 €4.20 tote_tricast: €5228.29 tote_trifecta: '' tote_win: €8.50 type: Hurdle winning_time_detail: 5m 44.90s (slow by 7.90s) Sires: properties: search_results: items: $ref: '#/components/schemas/Sire' type: array title: Search Results type: object required: - search_results title: Sires example: search_results: - id: sir_5344171 name: Frankel (GB) - id: sir_3722383 name: Galileo (IRE) app__models__damsires__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: -10.5 1st: 25 2nd: 20 3rd: 18 4th: 15 a/e: 0.95 dist: 1m2f dist_f: 10f dist_m: '2012' dist_y: '2200' runners: 150 win_%: 0.17 app__models__jockeys__Jockey: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Jockey example: id: jky_257379 name: William Buick Damsires: properties: search_results: items: $ref: '#/components/schemas/Damsire' type: array title: Search Results type: object required: - search_results title: Damsires example: search_results: - id: dsi_296611 name: Danehill - id: dsi_3527125 name: Dansili (GB) app__models__trainers__Course: properties: course: type: string title: Course course_id: type: string title: Course Id region: type: string title: Region runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - course - course_id - region - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Course example: 1_pl: 15.5 1st: 45 2nd: 30 3rd: 25 4th: 20 a/e: 1.05 course: Newmarket course_id: crs_988 region: GB runners: 200 win_%: 0.23 TrainerOwnerAnalysis: properties: id: type: string title: Id trainer: type: string title: Trainer total_runners: type: integer title: Total Runners owners: items: $ref: '#/components/schemas/app__models__trainers__Owner' type: array title: Owners query: items: items: {} type: array type: array title: Query type: object required: - id - trainer - total_runners - owners - query title: TrainerOwnerAnalysis example: id: trn_255042 owners: - 1_pl: 25.0 1st: 120 2nd: 80 3rd: 60 4th: 40 a/e: 1.02 owner: Godolphin owner_id: own_199380 runners: 500 win_%: 0.24 query: - - trainer_id - trn_255042 total_runners: 1862 trainer: Charlie Appleby HorseDistanceTimeAnalysis: properties: id: type: string title: Id horse: type: string title: Horse sire: type: string title: Sire sire_id: type: string title: Sire Id dam: type: string title: Dam dam_id: type: string title: Dam Id damsire: type: string title: Damsire damsire_id: type: string title: Damsire Id total_runs: type: integer title: Total Runs distances: items: $ref: '#/components/schemas/Distances' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - horse - sire - sire_id - dam - dam_id - damsire - damsire_id - total_runs - distances - query title: HorseDistanceTimeAnalysis example: dam: Green Vision (IRE) dam_id: dam_5639200 damsire: Green Desert damsire_id: dsi_2126159 distances: - 1_pl: -5.0 1st: 1 2nd: 2 3rd: 0 4th: 0 a/e: 0.5 dist: 6f dist_f: 6f dist_m: '1225' dist_y: '1340' runs: 11 times: - course: Chelmsford (AW) date: '2022-04-28' going: Standard position: '7' region: GB time: '1:11.94' win_%: 0.09 horse: Princess Shabnam (IRE) id: hrs_25481624 query: - - horse_id - hrs_25481624 sire: Gregorian (IRE) sire_id: sir_5494055 total_runs: 16 TrainerJockeyAnalysis: properties: id: type: string title: Id trainer: type: string title: Trainer total_runners: type: integer title: Total Runners jockeys: items: $ref: '#/components/schemas/app__models__trainers__Jockey' type: array title: Jockeys query: items: items: {} type: array type: array title: Query type: object required: - id - trainer - total_runners - jockeys - query title: TrainerJockeyAnalysis example: id: trn_255042 jockeys: - 1_pl: 50.62 1st: 260 2nd: 148 3rd: 143 4th: 88 a/e: 1.01 jockey: William Buick jockey_id: jky_257379 runners: 1038 win_%: 0.25 query: - - trainer_id - trn_255042 total_runners: 1862 trainer: Charlie Appleby JockeyDistanceAnalysis: properties: id: type: string title: Id jockey: type: string title: Jockey total_rides: type: integer title: Total Rides distances: items: $ref: '#/components/schemas/app__models__jockeys__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - jockey - total_rides - distances - query title: JockeyDistanceAnalysis example: distances: - 1_pl: -119.96 1st: 117 2nd: 86 3rd: 72 4th: 64 a/e: 0.95 dist: 1m dist_f: 8f dist_m: '1638' dist_y: '1791' rides: 681 win_%: 0.17 id: jky_257379 jockey: William Buick query: - - jockey_id - jky_257379 total_rides: 3742 ResultsStandardPage: properties: results: anyOf: - items: $ref: '#/components/schemas/ResultStandard' type: array - type: 'null' title: Results total: type: integer title: Total limit: type: integer title: Limit skip: type: integer title: Skip query: items: items: {} type: array type: array title: Query type: object required: - results - total - limit - skip - query title: ResultsStandardPage RacecardOddsPro: properties: race_id: type: string title: Race Id course: type: string title: Course course_id: type: string title: Course Id date: type: string title: Date off_time: type: string title: Off Time off_dt: anyOf: - type: string - type: 'null' title: Off Dt default: '' race_name: type: string title: Race Name distance_round: type: string title: Distance Round distance: type: string title: Distance distance_f: type: string title: Distance F region: type: string title: Region pattern: type: string title: Pattern sex_restriction: anyOf: - type: string - type: 'null' title: Sex Restriction default: '' race_class: type: string title: Race Class type: type: string title: Type age_band: type: string title: Age Band rating_band: type: string title: Rating Band prize: type: string title: Prize field_size: type: string title: Field Size going_detailed: anyOf: - type: string - type: 'null' title: Going Detailed rail_movements: anyOf: - type: string - type: 'null' title: Rail Movements stalls: anyOf: - type: string - type: 'null' title: Stalls weather: anyOf: - type: string - type: 'null' title: Weather going: type: string title: Going surface: anyOf: - type: string - type: 'null' title: Surface jumps: anyOf: - type: string - type: 'null' title: Jumps default: '' runners: items: $ref: '#/components/schemas/RunnerOddsPro' type: array title: Runners big_race: anyOf: - type: boolean - type: 'null' title: Big Race default: false is_abandoned: anyOf: - type: boolean - type: 'null' title: Is Abandoned default: false tip: anyOf: - type: string - type: 'null' title: Tip default: '' verdict: anyOf: - type: string - type: 'null' title: Verdict default: '' betting_forecast: anyOf: - type: string - type: 'null' title: Betting Forecast default: '' race_status: anyOf: - type: string - type: 'null' title: Race Status default: '' type: object required: - race_id - course - course_id - date - off_time - race_name - distance_round - distance - distance_f - region - pattern - race_class - type - age_band - rating_band - prize - field_size - going_detailed - rail_movements - stalls - weather - going - surface - runners title: RacecardOddsPro example: age_band: 3yo+ betting_forecast: 6/4 Majestic Valour, 9/2 Sea Diamond, 6/1 Autumn Vibes, 7/1 Lucky Ranger big_race: false course: Sha Tin course_id: crs_10816 date: '2026-01-11' distance: 6f distance_f: '6.0' distance_round: 6f field_size: '12' going: Good going_detailed: 'TURF: GOOD TO FIRM' is_abandoned: false jumps: '' off_dt: '2026-01-11T05:00:00+00:00' off_time: '5:00' pattern: '' prize: £62,459 race_class: '' race_id: rac_11845223 race_name: Wu Kai Sha Handicap (Div I) (Class 4) (3yo+) (Course C+3) (Turf) race_status: '' rail_movements: '' rating_band: '' region: HK runners: - age: '9' breeder: Scea Haras De Saint Pair colour: b/br comment: Much better known as a miler but begins the new campaign on a very tempting mark dam: Trois Lunes dam_id: dam_5583571 dam_region: FR damsire: Manduro damsire_id: dsi_4247215 damsire_region: GER dob: '2014-02-27' draw: '9' form: 60500- headgear: '' headgear_run: '' horse: Trais Fluors horse_id: hrs_8192583 jockey: Rose Dawes(5) jockey_id: jky_301152 last_run: '192' lbs: '139' medical: [] number: '2' odds: - bookmaker: Bet365 decimal: '4.33' ew_denom: '5' ew_places: '3' fractional: 10/3 history: [] updated: '2023-05-02 12:36:43' - bookmaker: Betfair Exchange decimal: '4.5' ew_denom: '' ew_places: '' fractional: 7/2 history: [] updated: '2023-05-02 12:36:43' ofr: '74' owner: M Channon owner_id: own_31504 past_results_flags: [] prev_owners: - change_date: '2021-09-06' owner: Lee Harris owner_id: own_1182044 - change_date: '2021-03-22' owner: Robert Ng owner_id: own_466920 prev_trainers: - change_date: '2023-03-24' trainer: Mick Channon trainer_id: trn_42084 - change_date: '2021-03-22' trainer: K J Condon trainer_id: trn_137160 - change_date: '2019-10-23' trainer: A Fabre trainer_id: trn_9837 quotes: - course: Sandown course_id: crs_1404 date: '2021-06-12' distance_f: '8' distance_y: '1760' horse: Trais Fluors horse_id: hrs_8192583 quote: He was suited by the better ground here, which was key - Silvestre de Sousa, rider. race: Play Coral Racing-Super-Series For Free Handicap race_id: rac_10204649 region: GB rpr: '85' sex: gelding sex_code: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Dansili sire_id: sir_3527125 sire_region: GB spotlight: Steadily regressive 9yo who is much better known as a miler and ended last season with two down-the-field runs; begins the new campaign on a tempting mark, though, and can't be ruled out. stable_tour: [] trainer: Jack Channon trainer_14_days: percent: '31' runs: '16' wins: '5' trainer_id: trn_361449 trainer_location: West Ilsley, Berks trainer_rtf: '71' ts: '83' wind_surgery: '' wind_surgery_run: '' sex_restriction: '' stalls: '' surface: Turf tip: Majestic Valour type: Flat verdict: This looks a good opportunity for promising 4yo MAJESTIC VALOUR to get back to winning ways. weather: '' RaceRunnerOddsHistory: properties: changed_at: type: string title: Changed At fractional: type: string title: Fractional decimal: type: string title: Decimal type: object required: - changed_at - fractional - decimal title: RaceRunnerOddsHistory example: changed_at: '2025-04-22T13:34:00+01:00' decimal: '6.5' fractional: 11/2 TrainerHorseAgeAnalysis: properties: id: type: string title: Id trainer: type: string title: Trainer total_runners: type: integer title: Total Runners horse_ages: items: $ref: '#/components/schemas/HorseAges' type: array title: Horse Ages query: items: items: {} type: array type: array title: Query type: object required: - id - trainer - total_runners - horse_ages - query title: TrainerHorseAgeAnalysis example: horse_ages: - 1_pl: -0.68 1st: 156 2nd: 106 3rd: 87 4th: 60 a/e: 0.99 horse_age: '3' runners: 749 win_%: 0.21 - 1_pl: 18.12 1st: 124 2nd: 61 3rd: 68 4th: 39 a/e: 1.02 horse_age: '2' runners: 439 win_%: 0.28 id: trn_255042 query: - - trainer_id - trn_255042 total_runners: 1862 trainer: Charlie Appleby Distances: properties: dist: type: string title: Distance dist_y: type: string title: Distance yards dist_m: type: string title: Distance metres dist_f: type: string title: Distance furlongs times: items: $ref: '#/components/schemas/TimesGoing' type: array title: Times runs: type: integer title: Runs 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - times - runs - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distances example: 1_pl: -5.0 1st: 1 2nd: 2 3rd: 0 4th: 0 a/e: 0.5 dist: 6f dist_f: 6f dist_m: '1225' dist_y: '1340' runs: 11 times: - course: Chelmsford (AW) date: '2022-04-28' going: Standard position: '7' region: GB time: '1:11.94' win_%: 0.09 TimesGoing: properties: date: type: string title: Date region: type: string title: Region course: type: string title: Course time: type: string title: Time going: type: string title: Going position: type: string title: Position type: object required: - date - region - course - time - going - position title: TimesGoing example: course: Chelmsford (AW) date: '2022-04-28' going: Standard position: '7' region: GB time: '1:11.94' SireDistanceAnalysis: properties: id: type: string title: Id sire: type: string title: Sire total_runners: type: integer title: Total Runners distances: items: $ref: '#/components/schemas/app__models__sires__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - sire - total_runners - distances - query title: SireDistanceAnalysis example: distances: - 1_pl: 5.83 1st: 4 2nd: 10 3rd: 5 4th: 5 a/e: 0.45 dist: 7f dist_f: 7f dist_m: '1400.0' dist_y: '1540' runners: 75 win_%: 0.05 id: sir_5245191 query: - - sire_id - sir_5245191 sire: Excelebration (IRE) total_runners: 303 OddsHistory: properties: bookmaker: type: string title: Bookmaker fractional: type: string title: Fractional decimal: type: string title: Decimal ew_places: type: string title: Ew Places ew_denom: type: string title: Ew Denom updated: type: string title: Updated history: anyOf: - items: {} type: array - type: 'null' title: History default: [] type: object required: - bookmaker - fractional - decimal - ew_places - ew_denom - updated title: OddsHistory example: bookmaker: Bet365 decimal: '6.0' ew_denom: '5' ew_places: '3' fractional: 5/1 history: - changed_at: '2026-02-06T12:00:00+00:00' decimal: '7.0' fractional: 6/1 updated: '2026-02-06 13:30:00' app__models__owners__Course: properties: course: type: string title: Course course_id: type: string title: Course Id region: type: string title: Region runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - course - course_id - region - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Course example: 1_pl: 15.0 1st: 100 2nd: 80 3rd: 60 4th: 50 a/e: 1.02 course: Newmarket course_id: crs_988 region: GB runners: 500 win_%: 0.2 app__models__result__RunnerBasic: properties: horse_id: type: string title: Horse Id horse: type: string title: Horse sp: type: string title: Sp sp_dec: type: string title: Sp Dec number: type: string title: Number position: type: string title: Position draw: type: string title: Draw btn: type: string title: Btn ovr_btn: type: string title: Ovr Btn age: type: string title: Age sex: type: string title: Sex weight: type: string title: Weight weight_lbs: type: string title: Weight Lbs headgear: type: string title: Headgear time: type: string title: Time or: type: string title: Or rpr: type: string title: Rpr tsr: type: string title: Tsr prize: type: string title: Prize jockey: type: string title: Jockey jockey_claim_lbs: anyOf: - type: string - type: 'null' title: Jockey Claim Lbs default: '0' jockey_id: type: string title: Jockey Id trainer: type: string title: Trainer trainer_id: type: string title: Trainer Id owner: type: string title: Owner owner_id: type: string title: Owner Id sire: type: string title: Sire sire_id: type: string title: Sire Id dam: type: string title: Dam dam_id: type: string title: Dam Id damsire: type: string title: Damsire damsire_id: type: string title: Damsire Id comment: type: string title: Comment silk_url: anyOf: - type: string - type: 'null' title: Silk Url default: '' type: object required: - horse_id - horse - sp - sp_dec - number - position - draw - btn - ovr_btn - age - sex - weight - weight_lbs - headgear - time - or - rpr - tsr - prize - jockey - jockey_id - trainer - trainer_id - owner - owner_id - sire - sire_id - dam - dam_id - damsire - damsire_id - comment title: RunnerBasic example: age: '8' btn: '0' comment: Held up in rear - headway 3 out - went third after 2 out - challenging when not fluent last - led home turn - ridden clear final furlong(op 13/2) dam: Save Me The Waltz (FR) dam_id: dam_4189605 damsire: Halling damsire_id: dsi_675241 draw: '' headgear: v horse: Mephisto (IRE) horse_id: hrs_19359270 jockey: Shane Fitzgerald jockey_claim_lbs: '0' jockey_id: jky_302916 number: '2' or: '98' ovr_btn: '0' owner: Restricted Movement Syndicate owner_id: own_1204876 position: '1' prize: €5900 rpr: '105' sex: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Kendargent (FR) sire_id: sir_4514419 sp: 15/2 sp_dec: '8.50' time: '5:44.90' trainer: Gerard Keane trainer_id: trn_86382 tsr: '64' weight: 11-12 weight_lbs: '166' SireClassAnalysis: properties: id: type: string title: Id sire: type: string title: Sire total_runners: type: integer title: Total Runners classes: items: $ref: '#/components/schemas/app__models__sires__Class' type: array title: Classes query: items: items: {} type: array type: array title: Query type: object required: - id - sire - total_runners - classes - query title: SireClassAnalysis example: classes: - 1_pl: -35.97 1st: 15 2nd: 23 3rd: 24 4th: 27 a/e: 0.53 class: Class 2 runners: 225 win_%: 0.07 - 1_pl: -5.0 1st: 7 2nd: 10 3rd: 9 4th: 12 a/e: 0.79 class: Class 1 runners: 78 win_%: 0.09 id: sir_5245191 query: - - race_class - class_1 - - race_class - class_2 - - sire_id - sir_5245191 sire: Excelebration (IRE) total_runners: 303 OwnerDistanceAnalysis: properties: id: type: string title: Id owner: type: string title: Owner total_runners: type: integer title: Total Runners distances: items: $ref: '#/components/schemas/app__models__owners__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - owner - total_runners - distances - query title: OwnerDistanceAnalysis example: distances: - 1_pl: 10.27 1st: 239 2nd: 144 3rd: 163 4th: 114 a/e: 0.99 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 1279 win_%: 0.19 id: own_199380 owner: Godolphin query: - - owner_id - own_199380 total_runners: 5938 app__models__dams__Class: properties: class: type: string title: Class runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - class - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Class example: 1_pl: -2.0 1st: 5 2nd: 4 3rd: 3 4th: 2 a/e: 0.9 class: Class 1 runners: 30 win_%: 0.17 app__models__sires__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: 5.83 1st: 4 2nd: 10 3rd: 5 4th: 5 a/e: 0.45 dist: 7f dist_f: 7f dist_m: '1400.0' dist_y: '1540' runners: 75 win_%: 0.05 app__models__racecards__RunnerOdds: properties: horse_id: type: string title: Horse Id horse: type: string title: Horse dob: anyOf: - type: string - type: 'null' title: Dob age: anyOf: - type: string - type: 'null' title: Age sex: anyOf: - type: string - type: 'null' title: Sex sex_code: anyOf: - type: string - type: 'null' title: Sex Code colour: anyOf: - type: string - type: 'null' title: Colour region: anyOf: - type: string - type: 'null' title: Region breeder: anyOf: - type: string - type: 'null' title: Breeder dam: type: string title: Dam dam_id: type: string title: Dam Id dam_region: anyOf: - type: string - type: 'null' title: Dam Region default: '' sire: type: string title: Sire sire_id: type: string title: Sire Id sire_region: anyOf: - type: string - type: 'null' title: Sire Region default: '' damsire: type: string title: Damsire damsire_id: type: string title: Damsire Id damsire_region: anyOf: - type: string - type: 'null' title: Damsire Region default: '' trainer: type: string title: Trainer trainer_id: type: string title: Trainer Id trainer_location: anyOf: - type: string - type: 'null' title: Trainer Location default: '' trainer_14_days: anyOf: - $ref: '#/components/schemas/RunnerTrainer14Days' - type: 'null' default: {} owner: type: string title: Owner owner_id: type: string title: Owner Id prev_trainers: anyOf: - items: $ref: '#/components/schemas/RunnerPrevTrainer' type: array - type: 'null' title: Prev Trainers default: [] prev_owners: anyOf: - items: $ref: '#/components/schemas/RunnerPrevOwner' type: array - type: 'null' title: Prev Owners default: [] comment: anyOf: - type: string - type: 'null' title: Comment default: '' spotlight: anyOf: - type: string - type: 'null' title: Spotlight default: '' quotes: anyOf: - items: $ref: '#/components/schemas/RunnerQuote' type: array - type: 'null' title: Quotes default: [] stable_tour: anyOf: - items: $ref: '#/components/schemas/RunnerStableTour' type: array - type: 'null' title: Stable Tour default: [] medical: anyOf: - items: $ref: '#/components/schemas/RunnerMedical' type: array - type: 'null' title: Medical default: [] number: type: string title: Number draw: type: string title: Draw headgear: anyOf: - type: string - type: 'null' title: Headgear default: '' headgear_run: anyOf: - type: string - type: 'null' title: Headgear Run default: '' wind_surgery: anyOf: - type: string - type: 'null' title: Wind Surgery default: '' wind_surgery_run: anyOf: - type: string - type: 'null' title: Wind Surgery Run default: '' past_results_flags: anyOf: - items: type: string type: array - type: 'null' title: Past Results Flags default: [] lbs: type: string title: Lbs ofr: type: string title: Ofr rpr: type: string title: Rpr ts: type: string title: Ts jockey: type: string title: Jockey jockey_id: type: string title: Jockey Id silk_url: anyOf: - type: string - type: 'null' title: Silk Url default: '' last_run: type: string title: Last Run form: anyOf: - type: string - type: 'null' title: Form trainer_rtf: anyOf: - type: string - type: 'null' title: Trainer Rtf odds: anyOf: - items: $ref: '#/components/schemas/OddsNoHistory' type: array - type: 'null' title: Odds default: [] type: object required: - horse_id - horse - dob - age - sex - sex_code - colour - region - breeder - dam - dam_id - sire - sire_id - damsire - damsire_id - trainer - trainer_id - owner - owner_id - number - draw - lbs - ofr - rpr - ts - jockey - jockey_id - last_run - form - trainer_rtf title: RunnerOdds example: age: '6' breeder: Tada Nobutaka colour: b comment: Very useful in his prime but seems to have lost his way this year dam: Lerici dam_id: dam_4823441 dam_region: USA damsire: Woodman damsire_id: dsi_2126229 damsire_region: USA dob: '2017-04-22' draw: '8' form: 3-7880 headgear: '' headgear_run: '' horse: Pistoletto horse_id: hrs_18092480 jockey: Adam Tracey(7) jockey_id: jky_301290 last_run: '25' lbs: '140' medical: [] number: '1' odds: - bookmaker: Bet365 decimal: '9' ew_denom: '5' ew_places: '3' fractional: '8' updated: '2023-05-02 12:36:43' - bookmaker: Paddy Power decimal: '8.5' ew_denom: '5' ew_places: '3' fractional: 15/2 updated: '2023-05-02 12:36:43' ofr: '75' owner: J A Thompson & S Russell owner_id: own_1227828 past_results_flags: [] prev_owners: - change_date: '2021-08-07' owner: G McGladery, J A Thompson & S Russell owner_id: own_1191676 prev_trainers: - change_date: '2020-09-26' trainer: A P O'Brien trainer_id: trn_71802 quotes: - course: Newmarket course_id: crs_988 date: '2019-10-11' distance_f: '5' distance_y: '1100' horse: Pistoletto horse_id: hrs_18092480 quote: He travelled nicely into the race - Kevin Buckley. race: Cornwallis Stakes (Group 3) race_id: rac_9618089 region: USA rpr: '82' sex: gelding sex_code: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: War Front sire_id: sir_4544750 sire_region: USA spotlight: Very useful in his prime but seems to have lost his way this year; sure to appreciate today's ease in grade. stable_tour: [] trainer: John Ryan trainer_14_days: percent: '0' runs: '5' wins: '0' trainer_id: trn_160758 trainer_location: Newmarket, Suffolk trainer_rtf: '' ts: '81' wind_surgery: '' wind_surgery_run: '' app__models__trainers__Owner: properties: owner_id: type: string title: Owner Id owner: type: string title: Owner runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - owner_id - owner - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Owner example: 1_pl: 25.0 1st: 120 2nd: 80 3rd: 60 4th: 40 a/e: 1.02 owner: Godolphin owner_id: own_199380 runners: 500 win_%: 0.24 app__models__trainers__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: -59.87 1st: 77 2nd: 43 3rd: 52 4th: 32 a/e: 0.93 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 373 win_%: 0.21 app__models__trainers__Trainer: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Trainer example: id: trn_255042 name: Charlie Appleby RunnerMedical: properties: date: anyOf: - type: string - type: 'null' title: Date default: '' type: anyOf: - type: string - type: 'null' title: Type default: '' type: object title: RunnerMedical example: date: '2024-06-15' type: Wind surgery RaceRunnerOddsBookmakers: properties: bookmaker: anyOf: - type: string - type: 'null' title: Bookmaker default: '' fractional: anyOf: - type: string - type: 'null' title: Fractional default: '' decimal: anyOf: - type: string - type: 'null' title: Decimal default: '' ew_places: anyOf: - type: string - type: 'null' title: Ew Places default: '' ew_denom: anyOf: - type: string - type: 'null' title: Ew Denom default: '' updated: anyOf: - type: string - type: 'null' title: Updated default: '' history: anyOf: - items: $ref: '#/components/schemas/RaceRunnerOddsHistory' type: array - type: 'null' title: History default: [] type: object title: RaceRunnerOddsBookmakers example: bookmaker: Bet365 decimal: '6' ew_denom: '5' ew_places: '4' fractional: 5/1 history: - changed_at: '2025-04-22T13:34:00+01:00' decimal: '6.5' fractional: 11/2 - changed_at: '2025-04-22T13:28:00+01:00' decimal: '5.5' fractional: 9/2 updated: '2025-04-22 13:30:26' RunnerPrevOwner: properties: owner: anyOf: - type: string - type: 'null' title: Owner default: '' owner_id: anyOf: - type: string - type: 'null' title: Owner Id default: '' change_date: anyOf: - type: string - type: 'null' title: Change Date default: '' type: object title: RunnerPrevOwner example: change_date: '2024-01-15' owner: Previous Racing Ltd owner_id: own_123456 Region: properties: region: type: string title: Region region_code: type: string title: Region Code type: object required: - region - region_code title: Region example: region: Great Britain region_code: gb OwnerJockeyAnalysis: properties: id: type: string title: Id owner: type: string title: Owner total_runners: type: integer title: Total Runners jockeys: items: $ref: '#/components/schemas/app__models__owners__Jockey' type: array title: Jockeys query: items: items: {} type: array type: array title: Query type: object required: - id - owner - total_runners - jockeys - query title: OwnerJockeyAnalysis example: id: own_199380 jockeys: - 1_pl: 40.0 1st: 150 2nd: 90 3rd: 80 4th: 60 a/e: 1.02 jockey: William Buick jockey_id: jky_257379 runners: 600 win_%: 0.25 owner: Godolphin query: - - owner_id - own_199380 total_runners: 5938 HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError RunnerPrevTrainer: properties: trainer: anyOf: - type: string - type: 'null' title: Trainer default: '' trainer_id: anyOf: - type: string - type: 'null' title: Trainer Id default: '' change_date: anyOf: - type: string - type: 'null' title: Change Date default: '' type: object title: RunnerPrevTrainer example: change_date: '2024-03-01' trainer: John Smith trainer_id: trn_123456 RaceRunnerOdds: properties: race_id: type: string title: Race Id horse_id: type: string title: Horse Id horse: type: string title: Horse odds: anyOf: - items: $ref: '#/components/schemas/RaceRunnerOddsBookmakers' type: array - type: 'null' title: Odds default: [] type: object required: - race_id - horse_id - horse title: RaceRunnerOdds example: horse: Spartan Arrow horse_id: hrs_30314725 odds: - bookmaker: Bet365 decimal: '6' ew_denom: '5' ew_places: '4' fractional: 5/1 history: - changed_at: '2025-04-22T13:34:00+01:00' decimal: '6.5' fractional: 11/2 updated: '2025-04-22 13:30:26' race_id: rac_11588863 app__models__damsires__Class: properties: class: type: string title: Class runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - class - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Class example: 1_pl: -15.0 1st: 30 2nd: 25 3rd: 22 4th: 18 a/e: 0.88 class: Class 1 runners: 200 win_%: 0.15 RunnerOddsPro: properties: horse_id: type: string title: Horse Id horse: type: string title: Horse dob: anyOf: - type: string - type: 'null' title: Dob age: anyOf: - type: string - type: 'null' title: Age sex: anyOf: - type: string - type: 'null' title: Sex sex_code: anyOf: - type: string - type: 'null' title: Sex Code colour: anyOf: - type: string - type: 'null' title: Colour region: anyOf: - type: string - type: 'null' title: Region breeder: anyOf: - type: string - type: 'null' title: Breeder dam: type: string title: Dam dam_id: type: string title: Dam Id dam_region: anyOf: - type: string - type: 'null' title: Dam Region default: '' sire: type: string title: Sire sire_id: type: string title: Sire Id sire_region: anyOf: - type: string - type: 'null' title: Sire Region default: '' damsire: type: string title: Damsire damsire_id: type: string title: Damsire Id damsire_region: anyOf: - type: string - type: 'null' title: Damsire Region default: '' trainer: type: string title: Trainer trainer_id: type: string title: Trainer Id trainer_location: anyOf: - type: string - type: 'null' title: Trainer Location default: '' trainer_14_days: anyOf: - $ref: '#/components/schemas/RunnerTrainer14Days' - type: 'null' default: {} owner: type: string title: Owner owner_id: type: string title: Owner Id prev_trainers: anyOf: - items: $ref: '#/components/schemas/RunnerPrevTrainer' type: array - type: 'null' title: Prev Trainers default: [] prev_owners: anyOf: - items: $ref: '#/components/schemas/RunnerPrevOwner' type: array - type: 'null' title: Prev Owners default: [] comment: anyOf: - type: string - type: 'null' title: Comment default: '' spotlight: anyOf: - type: string - type: 'null' title: Spotlight default: '' quotes: anyOf: - items: $ref: '#/components/schemas/RunnerQuote' type: array - type: 'null' title: Quotes default: [] stable_tour: anyOf: - items: $ref: '#/components/schemas/RunnerStableTour' type: array - type: 'null' title: Stable Tour default: [] medical: anyOf: - items: $ref: '#/components/schemas/RunnerMedical' type: array - type: 'null' title: Medical default: [] number: type: string title: Number draw: type: string title: Draw headgear: anyOf: - type: string - type: 'null' title: Headgear default: '' headgear_run: anyOf: - type: string - type: 'null' title: Headgear Run default: '' wind_surgery: anyOf: - type: string - type: 'null' title: Wind Surgery default: '' wind_surgery_run: anyOf: - type: string - type: 'null' title: Wind Surgery Run default: '' past_results_flags: anyOf: - items: type: string type: array - type: 'null' title: Past Results Flags default: [] lbs: type: string title: Lbs ofr: type: string title: Ofr rpr: type: string title: Rpr ts: type: string title: Ts jockey: type: string title: Jockey jockey_id: type: string title: Jockey Id silk_url: anyOf: - type: string - type: 'null' title: Silk Url default: '' last_run: type: string title: Last Run form: anyOf: - type: string - type: 'null' title: Form trainer_rtf: anyOf: - type: string - type: 'null' title: Trainer Rtf odds: anyOf: - items: $ref: '#/components/schemas/OddsHistory' type: array - type: 'null' title: Odds default: [] type: object required: - horse_id - horse - dob - age - sex - sex_code - colour - region - breeder - dam - dam_id - sire - sire_id - damsire - damsire_id - trainer - trainer_id - owner - owner_id - number - draw - lbs - ofr - rpr - ts - jockey - jockey_id - last_run - form - trainer_rtf title: RunnerOddsPro example: age: '9' breeder: Scea Haras De Saint Pair colour: b/br comment: Much better known as a miler but begins the new campaign on a very tempting mark dam: Trois Lunes dam_id: dam_5583571 dam_region: FR damsire: Manduro damsire_id: dsi_4247215 damsire_region: GER dob: '2014-02-27' draw: '9' form: 60500- headgear: '' headgear_run: '' horse: Trais Fluors horse_id: hrs_8192583 jockey: Rose Dawes(5) jockey_id: jky_301152 last_run: '192' lbs: '139' medical: [] number: '2' odds: - bookmaker: Bet365 decimal: '4.33' ew_denom: '5' ew_places: '3' fractional: 10/3 history: [] updated: '2023-05-02 12:36:43' - bookmaker: Betfair Exchange decimal: '4.5' ew_denom: '' ew_places: '' fractional: 7/2 history: [] updated: '2023-05-02 12:36:43' ofr: '74' owner: M Channon owner_id: own_31504 past_results_flags: [] prev_owners: - change_date: '2021-09-06' owner: Lee Harris owner_id: own_1182044 - change_date: '2021-03-22' owner: Robert Ng owner_id: own_466920 prev_trainers: - change_date: '2023-03-24' trainer: Mick Channon trainer_id: trn_42084 - change_date: '2021-03-22' trainer: K J Condon trainer_id: trn_137160 - change_date: '2019-10-23' trainer: A Fabre trainer_id: trn_9837 quotes: - course: Sandown course_id: crs_1404 date: '2021-06-12' distance_f: '8' distance_y: '1760' horse: Trais Fluors horse_id: hrs_8192583 quote: He was suited by the better ground here, which was key - Silvestre de Sousa, rider. race: Play Coral Racing-Super-Series For Free Handicap race_id: rac_10204649 region: GB rpr: '85' sex: gelding sex_code: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Dansili sire_id: sir_3527125 sire_region: GB spotlight: Steadily regressive 9yo who is much better known as a miler and ended last season with two down-the-field runs; begins the new campaign on a tempting mark, though, and can't be ruled out. stable_tour: [] trainer: Jack Channon trainer_14_days: percent: '31' runs: '16' wins: '5' trainer_id: trn_361449 trainer_location: West Ilsley, Berks trainer_rtf: '71' ts: '83' wind_surgery: '' wind_surgery_run: '' app__models__owners__Owner: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Owner example: id: own_199380 name: Godolphin HorseAges: properties: horse_age: type: string title: Horse Age runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - horse_age - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: HorseAges example: 1_pl: -0.68 1st: 156 2nd: 106 3rd: 87 4th: 60 a/e: 0.99 horse_age: '3' runners: 749 win_%: 0.21 TrainerDistanceAnalysis: properties: id: type: string title: Id trainer: type: string title: Trainer total_runners: type: integer title: Total Runners distances: items: $ref: '#/components/schemas/app__models__trainers__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - trainer - total_runners - distances - query title: TrainerDistanceAnalysis example: distances: - 1_pl: -59.87 1st: 77 2nd: 43 3rd: 52 4th: 32 a/e: 0.93 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 373 win_%: 0.21 id: trn_255042 query: - - trainer_id - trn_255042 total_runners: 1862 trainer: Charlie Appleby ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type input: title: Input ctx: type: object title: Context type: object required: - loc - msg - type title: ValidationError RunnerStandard: properties: horse_id: type: string title: Horse Id horse: type: string title: Horse sp: type: string title: Sp sp_dec: type: string title: Sp Dec bsp: anyOf: - type: string - type: 'null' title: Bsp default: '' number: type: string title: Number position: type: string title: Position draw: type: string title: Draw btn: type: string title: Btn ovr_btn: type: string title: Ovr Btn age: type: string title: Age sex: type: string title: Sex weight: type: string title: Weight weight_lbs: type: string title: Weight Lbs headgear: type: string title: Headgear time: type: string title: Time or: type: string title: Or rpr: type: string title: Rpr tsr: type: string title: Tsr prize: type: string title: Prize jockey: type: string title: Jockey jockey_claim_lbs: anyOf: - type: string - type: 'null' title: Jockey Claim Lbs default: '0' jockey_id: type: string title: Jockey Id trainer: type: string title: Trainer trainer_id: type: string title: Trainer Id owner: type: string title: Owner owner_id: type: string title: Owner Id sire: type: string title: Sire sire_id: type: string title: Sire Id dam: type: string title: Dam dam_id: type: string title: Dam Id damsire: type: string title: Damsire damsire_id: type: string title: Damsire Id comment: type: string title: Comment silk_url: anyOf: - type: string - type: 'null' title: Silk Url default: '' type: object required: - horse_id - horse - sp - sp_dec - number - position - draw - btn - ovr_btn - age - sex - weight - weight_lbs - headgear - time - or - rpr - tsr - prize - jockey - jockey_id - trainer - trainer_id - owner - owner_id - sire - sire_id - dam - dam_id - damsire - damsire_id - comment title: RunnerStandard example: age: '8' bsp: '11.26' btn: '0' comment: Held up in rear - headway 3 out - went third after 2 out - challenging when not fluent last - led home turn - ridden clear final furlong(op 13/2) dam: Save Me The Waltz (FR) dam_id: dam_4189605 damsire: Halling damsire_id: dsi_675241 draw: '' headgear: v horse: Mephisto (IRE) horse_id: hrs_19359270 jockey: Shane Fitzgerald jockey_claim_lbs: '0' jockey_id: jky_302916 number: '2' or: '98' ovr_btn: '0' owner: Restricted Movement Syndicate owner_id: own_1204876 position: '1' prize: €5900 rpr: '105' sex: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Kendargent (FR) sire_id: sir_4514419 sp: 15/2 sp_dec: '8.50' time: '5:44.90' trainer: Gerard Keane trainer_id: trn_86382 tsr: '64' weight: 11-12 weight_lbs: '166' app__models__owners__Trainer: properties: trainer_id: type: string title: Trainer Id trainer: type: string title: Trainer runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - trainer_id - trainer - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Trainer example: 1_pl: 50.0 1st: 200 2nd: 120 3rd: 100 4th: 80 a/e: 1.05 runners: 800 trainer: Charlie Appleby trainer_id: trn_255042 win_%: 0.25 Horse: properties: id: type: string title: Id dam: anyOf: - type: string - type: 'null' title: Dam default: '' dam_id: anyOf: - type: string - type: 'null' title: Dam Id default: '' damsire: anyOf: - type: string - type: 'null' title: Damsire default: '' damsire_id: anyOf: - type: string - type: 'null' title: Damsire Id default: '' name: anyOf: - type: string - type: 'null' title: Name default: '' sire: anyOf: - type: string - type: 'null' title: Sire default: '' sire_id: anyOf: - type: string - type: 'null' title: Sire Id default: '' type: object required: - id title: Horse example: dam: Kind (IRE) dam_id: dam_4087006 damsire: Danehill damsire_id: dsi_296611 id: hrs_5344171 name: Frankel (GB) sire: Galileo (IRE) sire_id: sir_3722383 ResultStandard: properties: race_id: type: string title: Race Id date: type: string title: Date region: type: string title: Region course: type: string title: Course course_id: type: string title: Course Id 'off': type: string title: 'Off' off_dt: anyOf: - type: string - type: 'null' title: Off Dt default: '' race_name: type: string title: Race Name type: type: string title: Type class: type: string title: Class pattern: type: string title: Pattern rating_band: type: string title: Rating Band age_band: type: string title: Age Band sex_rest: type: string title: Sex Rest dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F going: type: string title: Going surface: anyOf: - type: string - type: 'null' title: Surface default: '' jumps: anyOf: - type: string - type: 'null' title: Jumps default: '' runners: items: $ref: '#/components/schemas/RunnerStandard' type: array title: Runners winning_time_detail: anyOf: - type: string - type: 'null' title: Winning Time Detail default: '' comments: anyOf: - type: string - type: 'null' title: Comments default: '' non_runners: anyOf: - type: string - type: 'null' title: Non Runners default: '' tote_win: anyOf: - type: string - type: 'null' title: Tote Win default: '' tote_pl: anyOf: - type: string - type: 'null' title: Tote Pl default: '' tote_ex: anyOf: - type: string - type: 'null' title: Tote Ex default: '' tote_csf: anyOf: - type: string - type: 'null' title: Tote Csf default: '' tote_tricast: anyOf: - type: string - type: 'null' title: Tote Tricast default: '' tote_trifecta: anyOf: - type: string - type: 'null' title: Tote Trifecta default: '' type: object required: - race_id - date - region - course - course_id - 'off' - race_name - type - class - pattern - rating_band - age_band - sex_rest - dist - dist_y - dist_m - dist_f - going - runners title: ResultStandard example: age_band: 4yo+ class: '' comments: '' course: Ballinrobe (IRE) course_id: crs_4550 date: '2025-08-11' dist: 2m7f dist_f: 23f dist_m: '4625' dist_y: '5058' going: Good jumps: 12 hurdles non_runners: Diamonds Diva (reserve), Great Rainbow (reserve), Loughrask Rainbow (reserve) 'off': '8:25' off_dt: '2025-08-11T20:25:00+01:00' pattern: '' race_id: rac_11715730 race_name: J.J. Burke Peugeot Handicap Hurdle rating_band: 0-100 region: IRE runners: - age: '8' bsp: '11.26' btn: '0' comment: Held up in rear - headway 3 out - went third after 2 out - challenging when not fluent last - led home turn - ridden clear final furlong(op 13/2) dam: Save Me The Waltz (FR) dam_id: dam_4189605 damsire: Halling damsire_id: dsi_675241 draw: '' headgear: v horse: Mephisto (IRE) horse_id: hrs_19359270 jockey: Shane Fitzgerald jockey_claim_lbs: '0' jockey_id: jky_302916 number: '2' or: '98' ovr_btn: '0' owner: Restricted Movement Syndicate owner_id: own_1204876 position: '1' prize: €5900 rpr: '105' sex: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: Kendargent (FR) sire_id: sir_4514419 sp: 15/2 sp_dec: '8.50' time: '5:44.90' trainer: Gerard Keane trainer_id: trn_86382 tsr: '64' weight: 11-12 weight_lbs: '166' sex_rest: '' surface: Turf tote_csf: €300.55 tote_ex: €253.10 tote_pl: €2.30 €5.80 €4.20 tote_tricast: €5228.29 tote_trifecta: '' tote_win: €8.50 type: Hurdle winning_time_detail: 5m 44.90s (slow by 7.90s) HorsePro: properties: id: type: string title: Id breeder: anyOf: - type: string - type: 'null' title: Breeder default: '' colour: anyOf: - type: string - type: 'null' title: Colour default: '' colour_code: anyOf: - type: string - type: 'null' title: Colour Code default: '' dam: anyOf: - type: string - type: 'null' title: Dam default: '' dam_id: anyOf: - type: string - type: 'null' title: Dam Id default: '' damsire: anyOf: - type: string - type: 'null' title: Damsire default: '' damsire_id: anyOf: - type: string - type: 'null' title: Damsire Id default: '' dob: anyOf: - type: string - type: 'null' title: Dob default: '' name: anyOf: - type: string - type: 'null' title: Name default: '' sex: anyOf: - type: string - type: 'null' title: Sex default: '' sex_code: anyOf: - type: string - type: 'null' title: Sex Code default: '' sire: anyOf: - type: string - type: 'null' title: Sire default: '' sire_id: anyOf: - type: string - type: 'null' title: Sire Id default: '' type: object required: - id title: HorsePro example: breeder: Juddmonte Farms Ltd colour: b colour_code: B dam: Kind (IRE) dam_id: dam_4087006 damsire: Danehill damsire_id: dsi_296611 dob: '2008-02-11' id: hrs_5344171 name: Frankel (GB) sex: horse sex_code: H sire: Galileo (IRE) sire_id: sir_3722383 RacecardSummary: properties: date: type: string title: Date region: type: string title: Region course_id: type: string title: Course Id course: type: string title: Course race_id: type: string title: Race Id race_name: type: string title: Race Name race_class: type: string title: Race Class off_time: type: string title: Off Time off_dt: anyOf: - type: string - type: 'null' title: Off Dt default: '' big_race: anyOf: - type: boolean - type: 'null' title: Big Race default: false is_abandoned: anyOf: - type: boolean - type: 'null' title: Is Abandoned default: false type: object required: - date - region - course_id - course - race_id - race_name - race_class - off_time title: RacecardSummary example: big_race: false course: Bahrain course_id: crs_22594 date: '2026-02-06' is_abandoned: false off_dt: '2026-02-06T14:00:00+00:00' off_time: '2:00' race_class: '' race_id: rac_11868129 race_name: Race 3 (Conditions Race) (Turf) region: BHR app__models__owners__Jockey: properties: jockey_id: type: string title: Jockey Id jockey: type: string title: Jockey runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - jockey_id - jockey - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Jockey example: 1_pl: 40.0 1st: 150 2nd: 90 3rd: 80 4th: 60 a/e: 1.02 jockey: William Buick jockey_id: jky_257379 runners: 600 win_%: 0.25 RunnerStableTour: properties: quote: anyOf: - type: string - type: 'null' title: Quote default: '' type: object title: RunnerStableTour example: quote: He's been working well at home and we're hopeful. Damsire: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Damsire example: id: dsi_296611 name: Danehill Trainers: properties: search_results: items: $ref: '#/components/schemas/app__models__trainers__Trainer' type: array title: Search Results type: object required: - search_results title: Trainers example: search_results: - id: trn_30735 name: William Haggas - id: trn_91413 name: David Pipe Sire: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Sire example: id: sir_5344171 name: Frankel (GB) CoursesPage: properties: courses: items: $ref: '#/components/schemas/app__models__courses__Course' type: array title: Courses total: type: integer title: Total type: object required: - courses - total title: CoursesPage OwnerCourseAnalysis: properties: id: type: string title: Id owner: type: string title: Owner total_runners: type: integer title: Total Runners courses: items: $ref: '#/components/schemas/app__models__owners__Course' type: array title: Courses query: items: items: {} type: array type: array title: Query type: object required: - id - owner - total_runners - courses - query title: OwnerCourseAnalysis example: courses: - 1_pl: 15.0 1st: 100 2nd: 80 3rd: 60 4th: 50 a/e: 1.02 course: Newmarket course_id: crs_988 region: GB runners: 500 win_%: 0.2 id: own_199380 owner: Godolphin query: - - owner_id - own_199380 total_runners: 5938 Dams: properties: search_results: items: $ref: '#/components/schemas/Dam' type: array title: Search Results type: object required: - search_results title: Dams example: search_results: - id: dam_4087006 name: Kind (IRE) - id: dam_5297166 name: Homepage (GB) DamDistanceAnalysis: properties: id: type: string title: Id dam: type: string title: Dam total_runners: type: integer title: Total Runners distances: items: $ref: '#/components/schemas/app__models__dams__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - dam - total_runners - distances - query title: DamDistanceAnalysis example: dam: Danehill Destiny (IRE) distances: - 1_pl: -5.5 1st: 8 2nd: 6 3rd: 5 4th: 4 a/e: 0.85 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 50 win_%: 0.16 id: dam_5741323 query: - - dam_id - dam_5741323 total_runners: 45 app__models__jockeys__Trainer: properties: trainer_id: type: string title: Trainer Id trainer: type: string title: Trainer rides: type: integer title: Rides 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - trainer_id - trainer - rides - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Trainer example: 1_pl: 50.62 1st: 260 2nd: 148 3rd: 143 4th: 88 a/e: 1.01 rides: 1038 trainer: Charlie Appleby trainer_id: trn_255042 win_%: 0.25 DamsireClassAnalysis: properties: id: type: string title: Id damsire: type: string title: Damsire total_runners: type: integer title: Total Runners classes: items: $ref: '#/components/schemas/app__models__damsires__Class' type: array title: Classes query: items: items: {} type: array type: array title: Query type: object required: - id - damsire - total_runners - classes - query title: DamsireClassAnalysis example: classes: - 1_pl: -15.0 1st: 30 2nd: 25 3rd: 22 4th: 18 a/e: 0.88 class: Class 1 runners: 200 win_%: 0.15 damsire: Sadler's Wells id: dsi_3247825 query: - - damsire_id - dsi_3247825 total_runners: 500 app__models__jockeys__Owner: properties: owner_id: type: string title: Owner Id owner: type: string title: Owner rides: type: integer title: Rides 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - owner_id - owner - rides - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Owner example: 1_pl: 45.0 1st: 200 2nd: 120 3rd: 100 4th: 80 a/e: 1.05 owner: Godolphin owner_id: own_199380 rides: 800 win_%: 0.25 RacecardsOddsPage: properties: racecards: items: $ref: '#/components/schemas/RacecardOdds' type: array title: Racecards total: type: integer title: Total limit: type: integer title: Limit skip: type: integer title: Skip query: items: items: {} type: array type: array title: Query type: object required: - racecards - total - limit - skip - query title: RacecardsOddsPage JockeyTrainerAnalysis: properties: id: type: string title: Id jockey: type: string title: Jockey total_rides: type: integer title: Total Rides trainers: items: $ref: '#/components/schemas/app__models__jockeys__Trainer' type: array title: Trainers query: items: items: {} type: array type: array title: Query type: object required: - id - jockey - total_rides - trainers - query title: JockeyTrainerAnalysis example: id: jky_257379 jockey: William Buick query: - - jockey_id - jky_257379 total_rides: 3742 trainers: - 1_pl: 50.62 1st: 260 2nd: 148 3rd: 143 4th: 88 a/e: 1.01 rides: 1038 trainer: Charlie Appleby trainer_id: trn_255042 win_%: 0.25 Dam: properties: id: type: string title: Id name: anyOf: - type: string - type: 'null' title: Name type: object required: - id - name title: Dam example: id: dam_4087006 name: Kind (IRE) app__models__trainers__Jockey: properties: jockey_id: type: string title: Jockey Id jockey: type: string title: Jockey runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - jockey_id - jockey - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Jockey example: 1_pl: 50.62 1st: 260 2nd: 148 3rd: 143 4th: 88 a/e: 1.01 jockey: William Buick jockey_id: jky_257379 runners: 1038 win_%: 0.25 RunnerTrainer14Days: properties: runs: anyOf: - type: string - type: 'null' title: Runs default: '' wins: anyOf: - type: string - type: 'null' title: Wins default: '' percent: anyOf: - type: string - type: 'null' title: Percent default: '' type: object title: RunnerTrainer14Days example: percent: '20' runs: '25' wins: '5' ResultsBasicPage: properties: results: anyOf: - items: $ref: '#/components/schemas/ResultBasic' type: array - type: 'null' title: Results total: type: integer title: Total limit: type: integer title: Limit skip: type: integer title: Skip query: items: items: {} type: array type: array title: Query type: object required: - results - total - limit - skip - query title: ResultsBasicPage DamClassAnalysis: properties: id: type: string title: Id dam: type: string title: Dam total_runners: type: integer title: Total Runners classes: items: $ref: '#/components/schemas/app__models__dams__Class' type: array title: Classes query: items: items: {} type: array type: array title: Query type: object required: - id - dam - total_runners - classes - query title: DamClassAnalysis example: classes: - 1_pl: -2.0 1st: 5 2nd: 4 3rd: 3 4th: 2 a/e: 0.9 class: Class 1 runners: 30 win_%: 0.17 dam: Danehill Destiny (IRE) id: dam_5741323 query: - - dam_id - dam_5741323 total_runners: 45 JockeyCourseAnalysis: properties: id: type: string title: Id jockey: type: string title: Jockey total_rides: type: integer title: Total Rides courses: items: $ref: '#/components/schemas/app__models__jockeys__Course' type: array title: Courses query: items: items: {} type: array type: array title: Query type: object required: - id - jockey - total_rides - courses - query title: JockeyCourseAnalysis example: courses: - 1_pl: 12.47 1st: 144 2nd: 72 3rd: 86 4th: 68 a/e: 1.09 course: Newmarket course_id: crs_988 region: GB rides: 716 win_%: 0.2 id: jky_257379 jockey: William Buick query: - - jockey_id - jky_257379 total_rides: 3742 RunnerQuote: properties: date: anyOf: - type: string - type: 'null' title: Date default: '' horse: anyOf: - type: string - type: 'null' title: Horse default: '' horse_id: anyOf: - type: string - type: 'null' title: Horse Id default: '' race: anyOf: - type: string - type: 'null' title: Race default: '' race_id: anyOf: - type: string - type: 'null' title: Race Id default: '' course: anyOf: - type: string - type: 'null' title: Course default: '' course_id: anyOf: - type: string - type: 'null' title: Course Id default: '' distance_f: anyOf: - type: string - type: 'null' title: Distance F default: '' distance_y: anyOf: - type: string - type: 'null' title: Distance Y default: '' quote: anyOf: - type: string - type: 'null' title: Quote default: '' type: object title: RunnerQuote example: course: Ascot course_id: crs_52 date: '2024-06-15' distance_f: 12f distance_y: '2640' horse: Frankel horse_id: hrs_5344171 quote: He ran a great race and showed his class. race: King George VI race_id: rac_12345678 OwnerTrainerAnalysis: properties: id: type: string title: Id owner: type: string title: Owner total_runners: type: integer title: Total Runners trainers: items: $ref: '#/components/schemas/app__models__owners__Trainer' type: array title: Trainers query: items: items: {} type: array type: array title: Query type: object required: - id - owner - total_runners - trainers - query title: OwnerTrainerAnalysis example: id: own_199380 owner: Godolphin query: - - owner_id - own_199380 total_runners: 5938 trainers: - 1_pl: 50.0 1st: 200 2nd: 120 3rd: 100 4th: 80 a/e: 1.05 runners: 800 trainer: Charlie Appleby trainer_id: trn_255042 win_%: 0.25 RacecardOdds: properties: race_id: type: string title: Race Id course: type: string title: Course course_id: type: string title: Course Id date: type: string title: Date off_time: type: string title: Off Time off_dt: anyOf: - type: string - type: 'null' title: Off Dt default: '' race_name: type: string title: Race Name distance_round: type: string title: Distance Round distance: type: string title: Distance distance_f: type: string title: Distance F region: type: string title: Region pattern: type: string title: Pattern sex_restriction: anyOf: - type: string - type: 'null' title: Sex Restriction default: '' race_class: type: string title: Race Class type: type: string title: Type age_band: type: string title: Age Band rating_band: type: string title: Rating Band prize: type: string title: Prize field_size: type: string title: Field Size going_detailed: anyOf: - type: string - type: 'null' title: Going Detailed rail_movements: anyOf: - type: string - type: 'null' title: Rail Movements stalls: anyOf: - type: string - type: 'null' title: Stalls weather: anyOf: - type: string - type: 'null' title: Weather going: type: string title: Going surface: anyOf: - type: string - type: 'null' title: Surface jumps: anyOf: - type: string - type: 'null' title: Jumps default: '' runners: items: $ref: '#/components/schemas/app__models__racecards__RunnerOdds' type: array title: Runners big_race: anyOf: - type: boolean - type: 'null' title: Big Race default: false is_abandoned: anyOf: - type: boolean - type: 'null' title: Is Abandoned default: false tip: anyOf: - type: string - type: 'null' title: Tip default: '' verdict: anyOf: - type: string - type: 'null' title: Verdict default: '' betting_forecast: anyOf: - type: string - type: 'null' title: Betting Forecast default: '' race_status: anyOf: - type: string - type: 'null' title: Race Status default: '' type: object required: - race_id - course - course_id - date - off_time - race_name - distance_round - distance - distance_f - region - pattern - race_class - type - age_band - rating_band - prize - field_size - going_detailed - rail_movements - stalls - weather - going - surface - runners title: RacecardOdds example: age_band: 4yo+ betting_forecast: 3/1 Snowthorn, 4/1 King Alloy, 6/1 I P O Bros, 10/1 Team Happy big_race: false course: Brighton course_id: crs_182 date: '2023-05-02' distance: 6f210y distance_f: '7.0' distance_round: 7f field_size: '9' going: Good To Firm going_detailed: '' is_abandoned: false jumps: '' off_dt: '2023-05-02T13:50:00+01:00' off_time: '1:50' pattern: '' prize: £4,606 race_class: Class 5 race_id: rac_10880272 race_name: At The Races App Form Study Apprentice Handicap race_status: '' rail_movements: '' rating_band: 0-75 region: GB runners: - age: '6' breeder: Tada Nobutaka colour: b comment: Very useful in his prime but seems to have lost his way this year dam: Lerici dam_id: dam_4823441 dam_region: USA damsire: Woodman damsire_id: dsi_2126229 damsire_region: USA dob: '2017-04-22' draw: '8' form: 3-7880 headgear: '' headgear_run: '' horse: Pistoletto horse_id: hrs_18092480 jockey: Adam Tracey(7) jockey_id: jky_301290 last_run: '25' lbs: '140' medical: [] number: '1' odds: - bookmaker: Bet365 decimal: '9' ew_denom: '5' ew_places: '3' fractional: '8' updated: '2023-05-02 12:36:43' - bookmaker: Paddy Power decimal: '8.5' ew_denom: '5' ew_places: '3' fractional: 15/2 updated: '2023-05-02 12:36:43' ofr: '75' owner: J A Thompson & S Russell owner_id: own_1227828 past_results_flags: [] prev_owners: - change_date: '2021-08-07' owner: G McGladery, J A Thompson & S Russell owner_id: own_1191676 prev_trainers: - change_date: '2020-09-26' trainer: A P O'Brien trainer_id: trn_71802 quotes: - course: Newmarket course_id: crs_988 date: '2019-10-11' distance_f: '5' distance_y: '1100' horse: Pistoletto horse_id: hrs_18092480 quote: He travelled nicely into the race - Kevin Buckley. race: Cornwallis Stakes (Group 3) race_id: rac_9618089 region: USA rpr: '82' sex: gelding sex_code: G silk_url: https://www.url-for-silk.com/svg/456789.svg sire: War Front sire_id: sir_4544750 sire_region: USA spotlight: Very useful in his prime but seems to have lost his way this year; sure to appreciate today's ease in grade. stable_tour: [] trainer: John Ryan trainer_14_days: percent: '0' runs: '5' wins: '0' trainer_id: trn_160758 trainer_location: Newmarket, Suffolk trainer_rtf: '' ts: '81' wind_surgery: '' wind_surgery_run: '' sex_restriction: '' stalls: '' surface: Turf tip: Team Happy type: Flat verdict: Many of these arrive with something to prove but TEAM HAPPY has shown signs of a revival lately and might exploit a good mark. weather: '' app__models__owners__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: 10.27 1st: 239 2nd: 144 3rd: 163 4th: 114 a/e: 0.99 dist: 1m dist_f: 8f dist_m: '1609' dist_y: '1760' runners: 1279 win_%: 0.19 app__models__sires__Class: properties: class: type: string title: Class runners: type: integer title: Runners 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - class - runners - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Class example: 1_pl: -35.97 1st: 15 2nd: 23 3rd: 24 4th: 27 a/e: 0.53 class: Class 2 runners: 225 win_%: 0.07 Jockeys: properties: search_results: items: $ref: '#/components/schemas/app__models__jockeys__Jockey' type: array title: Search Results type: object required: - search_results title: Jockeys example: search_results: - id: jky_257379 name: William Buick - id: jky_265896 name: Harry Bentley Horses: properties: search_results: items: $ref: '#/components/schemas/Horse' type: array title: Search Results type: object required: - search_results title: Horses example: search_results: - dam: Kind (IRE) dam_id: dam_4087006 damsire: Danehill damsire_id: dsi_296611 id: hrs_5344171 name: Frankel (GB) sire: Galileo (IRE) sire_id: sir_3722383 - dam: February Sun (GB) dam_id: dam_5505549 damsire: Monsun (GER) damsire_id: dsi_593768 id: hrs_33375363 name: Sunny Frankel (GB) sire: Frankel (GB) sire_id: sir_5344171 app__models__jockeys__Distance: properties: dist: type: string title: Dist dist_y: type: string title: Dist Y dist_m: type: string title: Dist M dist_f: type: string title: Dist F rides: type: integer title: Rides 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - dist - dist_y - dist_m - dist_f - rides - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Distance example: 1_pl: -119.96 1st: 117 2nd: 86 3rd: 72 4th: 64 a/e: 0.95 dist: 1m dist_f: 8f dist_m: '1638' dist_y: '1791' rides: 681 win_%: 0.17 DamsireDistanceAnalysis: properties: id: type: string title: Id damsire: type: string title: Damsire total_runners: type: integer title: Total Runners distances: items: $ref: '#/components/schemas/app__models__damsires__Distance' type: array title: Distances query: items: items: {} type: array type: array title: Query type: object required: - id - damsire - total_runners - distances - query title: DamsireDistanceAnalysis example: damsire: Sadler's Wells distances: - 1_pl: -10.5 1st: 25 2nd: 20 3rd: 18 4th: 15 a/e: 0.95 dist: 1m2f dist_f: 10f dist_m: '2012' dist_y: '2200' runners: 150 win_%: 0.17 id: dsi_3247825 query: - - damsire_id - dsi_3247825 total_runners: 500 Owners: properties: search_results: items: $ref: '#/components/schemas/app__models__owners__Owner' type: array title: Search Results type: object required: - search_results title: Owners example: search_results: - id: own_199380 name: Godolphin - id: own_724272 name: Miss J Deadman & S Barrow app__models__jockeys__Course: properties: course: type: string title: Course course_id: type: string title: Course Id region: type: string title: Region rides: type: integer title: Rides 1st: type: integer title: 1st place finishes 2nd: type: integer title: 2nd place finishes 3rd: type: integer title: 3rd place finishes 4th: type: integer title: 4th place finishes a/e: type: number title: Actual/expected win_%: type: number title: Win percentage (decimal) 1_pl: type: number title: One unit p/l at SP type: object required: - course - course_id - region - rides - 1st - 2nd - 3rd - 4th - a/e - win_% - 1_pl title: Course example: 1_pl: 12.47 1st: 144 2nd: 72 3rd: 86 4th: 68 a/e: 1.09 course: Newmarket course_id: crs_988 region: GB rides: 716 win_%: 0.2 app__models__courses__Course: properties: id: type: string title: Id course: type: string title: Course region_code: type: string title: Region Code region: type: string title: Region type: object required: - id - course - region_code - region title: Course example: course: Ascot id: crs_52 region: Great Britain region_code: gb TrainerCourseAnalysis: properties: id: type: string title: Id trainer: type: string title: Trainer total_runners: type: integer title: Total Runners courses: items: $ref: '#/components/schemas/app__models__trainers__Course' type: array title: Courses query: items: items: {} type: array type: array title: Query type: object required: - id - trainer - total_runners - courses - query title: TrainerCourseAnalysis example: courses: - 1_pl: 15.5 1st: 45 2nd: 30 3rd: 25 4th: 20 a/e: 1.05 course: Newmarket course_id: crs_988 region: GB runners: 200 win_%: 0.23 id: trn_255042 query: - - trainer_id - trn_255042 total_runners: 1862 trainer: Charlie Appleby RacecardsOddsProPage: properties: racecards: items: $ref: '#/components/schemas/RacecardOddsPro' type: array title: Racecards total: type: integer title: Total limit: type: integer title: Limit skip: type: integer title: Skip query: items: items: {} type: array type: array title: Query type: object required: - racecards - total - limit - skip - query title: RacecardsOddsProPage JockeyOwnerAnalysis: properties: id: type: string title: Id jockey: type: string title: Jockey total_rides: type: integer title: Total Rides owners: items: $ref: '#/components/schemas/app__models__jockeys__Owner' type: array title: Owners query: items: items: {} type: array type: array title: Query type: object required: - id - jockey - total_rides - owners - query title: JockeyOwnerAnalysis example: id: jky_257379 jockey: William Buick owners: - 1_pl: 45.0 1st: 200 2nd: 120 3rd: 100 4th: 80 a/e: 1.05 owner: Godolphin owner_id: own_199380 rides: 800 win_%: 0.25 query: - - jockey_id - jky_257379 total_rides: 3742 OddsNoHistory: properties: bookmaker: type: string title: Bookmaker fractional: type: string title: Fractional decimal: type: string title: Decimal ew_places: type: string title: Ew Places ew_denom: type: string title: Ew Denom updated: type: string title: Updated type: object required: - bookmaker - fractional - decimal - ew_places - ew_denom - updated title: OddsNoHistory example: bookmaker: Bet365 decimal: '6.0' ew_denom: '5' ew_places: '3' fractional: 5/1 updated: '2026-02-06 13:30:00' RacecardsSummary: properties: racecard_summaries: items: $ref: '#/components/schemas/RacecardSummary' type: array title: Racecard Summaries query: items: items: {} type: array type: array title: Query type: object required: - racecard_summaries - query title: RacecardsSummary example: query: - - date - '2026-02-06' racecard_summaries: - big_race: false course: Bahrain course_id: crs_22594 date: '2026-02-06' is_abandoned: false off_dt: '2026-02-06T14:00:00+00:00' off_time: '2:00' race_class: '' race_id: rac_11868129 race_name: Race 3 (Conditions Race) (Turf) region: BHR - big_race: false course: Bangor-on-Dee course_id: crs_104 date: '2026-02-06' is_abandoned: true off_dt: '2026-02-06T13:25:00+00:00' off_time: '1:25' race_class: Class 4 race_id: rac_62443901 race_name: Alfa Aggregates Products Mares' Handicap Chase region: GB securitySchemes: HTTPBasic: type: http scheme: basic x-tagGroups: - name: Get Started tags: - Introduction - Authentication - Endpoint Overview - Rate Limits - Changelog - name: Core API tags: - Courses - Dams - Damsires - Horses - Jockeys - Odds - Owners - Racecards - Results - Sires - Trainers - name: Core API (by plan level) tags: - Free Plan - Basic Plan - Standard Plan - Pro Plan - name: Regional APIs tags: - Australia - North America