MyRacePass API

Overview

Resources

Introduction

Overview

Promoters and Drivers on MRP Plus plans are eligible (add-on price may apply) to use the REST-based Application Programming Interface (API) to query their MyRacePass data. One HTTP Verb is supported: GET. The Resources sections will include detailed samples of Request bodies and Responses.

Version 2.0

Resource Request Format

Resources such as news, schedules, results, etc, are accessible via the following request structure:
https://api.myracepass.com/v2/{resource}/[parameters]

parameters will be included in the query string

Verbs

One HTTP verb will be supported in version 2, GET - requests data

Authentication

The API key can be passed in the request query string as parameter “key”
Example:
https://api.myracepass.com/v2/{resource}/?key={xxxxxxxxxxxxx}

JQuery Call Back

If your solution requires a JQuery callback function you can pass the parameter of jsoncallback can be passed with each call. This will wrap the response in the call back function.
Example
https://api.myracepass.com/v2/{resource}/[parameters]&jsoncallback=callBackName

Request Caching

The API will be heavily cached. Any request with the same parameters will cache for a pre-determined amount of time. A flag will be available to allow developers to poll new data, but over use of polling will be considered abuse.

Each response contains a "RequestCached: [1,0]" field to indicate if the response is from cache (1) or fresh data (0).

All responses contain a "RequestCachedTicks" field to indicate the time in ticks the request was cached. From Microsoft: "A single tick represents one hundred nanoseconds or one ten-millionth of a second. There are 10,000 ticks in a millisecond, or 10 million ticks in a second. The value of this property represents the number of 100-nanosecond intervals that have elapsed since 12:00:00 midnight, January 1, 0001"

Polling Data
If you know data is outdated, new data can be polled with a "PollData" parameter. This will force the response to be rebuilt with fresh data.
Example
https://api.myracepass.com/v2/{resource}/[parameters]&PollData=true

Request Response

All API responses will return JSON data.

Each response will contain a key value pair of “RequestValid: [0,1]” A value of 1 is a valid request, while a value of 0 is a invalid request. All invalid requests will contain an “ErrorMessage” parameter containing error data.

Data Types

Data types used for parameters

NameDescription
INT Interger
STRING Alphanumeric string
IMGSIZE Structured width and height value for images.
Example 200x150 = 200px wide and 150 px tall. (Image will be no bigger than either dimension)
A “s” can be placed at the beginning to signify a strict image size (the image will be returned exactly that size).
Example s200x150
DATE Date formatted mm-dd-yyyy

Shopping Cart Update Cart ()

Loading...