API documentation

Some of our data is available via a publicly accessible JSON API

Calendar

Read calendar items

Returns a list of calendar items with brief details about each
GET
View
/calendar/items/?filters

Request parameters

FieldTypeRequiredDescription
whenstringoptionalFilter by time period. Values: past or future
typestring or
integer
optionalFilter by item type. Values: (see calendar item types - view)

Response parameters

FieldTypeDescription
object[ ]Object array
calendar_idintegerThe calendar item ID
start_datedateStart date
modifieddatetimeTime of most recent modification
namestringName
uristringAPI URI to get more details

Read calendar item types

Returns a list of calendar item types
GET
View
/calendar/types/

Request parameters

None

Response parameters

FieldTypeDescription
object[ ]Object array
typeintegerType ID
typenamestringType name

Read calendar item

Returns detailed information about a particular item in the calendar
GET
View
/calendar/items/:id

Request parameters

FieldTypeRequiredDescription
idintegerrequiredThe calendar item ID

Response parameters

FieldTypeDescription
calendar_idintegerThe calendar item ID
namestringName
location_namestringName of the place
location_latnumberLocation latitude
location_lonnumberLocation longitude
location_zoomintegerOpenStreetMap zoom level
location_markerboolDisplay a marker at the location. false indicates location is only approximate
start_datedateStart date
start_timetimeStart time
end_datedateEnd date
end_timetimeEnd time
clubstringName of the organising club
item_typestringCalendar item type
modifieddatetimeTime of most recent modification
descriptionstringItem description
bofobjectObject containing BOF information
typestringBOF item type: race or activity
idintegerBOF item ID
links[ ]object[ ]List of hyperlinks (object array)
textstringHyperlink text
hrefstringHyperlink URI
typestringHyperlink type

Maps

Read map locations

Returns a list of our mapped areas and polygons showing the area
GET
View
/maps/

Request parameters

None

Response parameters

FieldTypeDescription
object[ ]Object array
areastringArea name
polystringEPSG:3857 (Web Mercator) polygon coordinates. String contains numeric array

British Orienteering

The British Orienteering website has an API, although it is somewhat limited. Unfortunately there is no documentation on the British Orienteering website, so details are being published here with the hope that they are useful to someone. Most of these details come from Paul Frost's post on Nopesport

Fixtures calendar

Returns a list of future fixtures with limited information about each one. It would appear that fixtures greater than one year into the future are not returned
GET
View
http://www.britishorienteering.org.uk/fixturesjson.php?filters

Request parameters

FieldTypeRequiredDescription
assocstringoptionalFilter by regional orienteering association
clubstringoptionalFilter by orienteering club. Comma separate to use several
levelstringoptionalFilter by fixture level. Values: int a b c d act. Comma separate to use several
Other request parameters may exist but due to a complete lack of documentation by British Orienteering they are not known

Response parameters

FieldTypeDescription
object[ ]Object array
datedateDate of fixture
titlestringFixture name
linkstringURI of fixture page on British Orienteering website
venuestringFixture location
nearest_townstringNearest town
grid_refstringOS Grid Reference
clubstringOrganising orienteering club
assocstringRegional orienteering association
levelstringFixture level
postcodestringFixture postcode
numberstringBritish Orienteering database ID

Fabian4

Fabian4 does not (yet?) offer an API. These methods fetch the entries list from the Fabian4 website, scrape the page to extract details and return it in JSON format. As a result of the fetching and processing required they are therefore very slow

Race entries

Returns a count of the number of entries, as a total and per course/class
GET
View
/fabian4/entries/:raceid/
GET
View
/fabian4/entries/:raceid/day/:daynumber/

Request parameters

FieldTypeRequiredDescription
raceidintegerrequiredThe Fabian4 race ID
daynumberintegeroptionalThe day of the competition

Response parameters

FieldTypeDescription
totalintegerTotal number of entries for all days of a competition
daystring or
integer
Either all or
The day requested in the URI
entriesintegerEntries for the particular day (or all days if day not specified)
namestringName of the race as shown on Fabian4
coursesobjectObject containing counts of the entries per course/class
courseintegerEntries on the course/class

Routegadget

Routegadget has a number of API methods available. There is no written documentation from Routegadget UK, but the API PHP source code is available on Github

Read races

This method is a bit pointless - see the read stats method instead
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=events

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (events)

Response parameters

FieldTypeDescription
dataobjectRoot object
eventsobject[ ]Object array
idintegerID
mapidintegerID of map used
suffixstringID of map used
formatintegerFormat (meaning unknown)
namestringName
datedateDate
clubstringOrganising club
typestringType (meaning unknown)
lockedboolLock status
commentstringDescription
API versionstringCurrent version of the API

Read stats

Returns a list of races
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=stats

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (stats)

Response parameters

This method returns the same data as the Read races method, as well as some additional data
FieldTypeDescription
dataobjectRoot object
eventsobject[ ]Object array
resultsintegerNumber of results
coursesintegerNumber of courses
routesintegerNumber of routes

Read courses

Returns a list of the courses, with control codes and coordinates
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=courses&id=:id

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (courses)
idintegerrequiredRace ID

Response parameters

FieldTypeDescription
dataobjectRoot object
coursesobject[ ]Object array
course_idintegerCourse ID
namestringCourse name
codesstring[ ]String array, containing control codes
xposinteger[ ]Integer array, containing control x-coordinates
yposinteger[ ]Integer array, containing control y-coordinates
API versionstringCurrent version of the API

Read results

Returns a list of results, with splits times
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=results&id=:id

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (results)
idintegerrequiredRace ID

Response parameters

FieldTypeDescription
dataobjectRoot object
resultsobject[ ]Object array
resultidintegerCourse ID
courseidintegerCourse ID
coursenamestringCourse name
namestringCompetitor name
starttimeintegerStart time (seconds after midnight)
positionstringEmpty string ""
statusstringEmpty string ""
timetime or
string
Finish time or
Indication of course non-completion
splitsinteger[ ]Integer array, containing splits times in seconds
API versionstringCurrent version of the API

Read maps

Returns a list of maps
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=maps

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (maps)

Response parameters

FieldTypeDescription
dataobjectRoot object
mapsobject[ ]Object array
mapidintegerMap ID
namestringMap name
georeferencedboolMap georeferenced
API versionstringCurrent version of the API

Read tracks

Returns a list of tracks
GET
View
http://www.cuoc.routegadget.co.uk/rg2/rg2api.php?type=tracks&id=:id

Request parameters

FieldTypeRequiredDescription
typestringrequiredTell the API what type of information to return (tracks)
idintegerrequiredRace ID

Response parameters

FieldTypeDescription
dataobjectRoot object
routesobject[ ]Object array
idintegerResult ID (corresponds to resultid in read results)
ystringString of comma separated values containing route y-coordinates. First coordinate is absolute, the rest are relative to the previous coordinate
xstringString of comma separated values containing route x-coordinates. First coordinate is absolute, the rest are relative to the previous coordinate
API versionstringCurrent version of the API