GPS Data

get

The GPS Data (GET v1/me/sport/activities/{activityId}/gps) endpoint provides GPS data for the user's Activities. Each Activity has a unique Activity ID you can use to get any available GPS data for that Activity. GPS details include coordinates for latitude, longitude, and elevation.

The GPS data for an Activity allows you to create devices or apps that present the Activity in a useful context for the user. For example, you can use the GPS data associated with a RUN Activity to display a map of the user’s run. Nike+ provides the GPS data as an array (waypoints) of key-value pairs (see RESPONSE BODY FIELDS below).

Test Console

Request

GEThttps://api.nike.com/v1/me/sport/activities/{activityId}/gps

QUERY PARAMETERS

Note: The {activityId} path parameter in the endpoint URL is the unique Activity identifier for the requested Activity.

Name Type Required? Description
access_token String Yes User's access token

Sample Request

https://api.nike.com/v1/me/sport/activities/2683000000011936851080007062707485942202/gps?access_token={access token}

Response

Response Body JSON Schema

RESPONSE BODY FIELDS

Distances and weights are returned in metric units (see Metric Types for more information). Dates and times are returned in UTC following ISO8601 standard formats.
Name Type Description
links Array List of links to related resources (see the HATEOAS page for more information)
elevationLoss Number Total elevation loss over all the provided coordinates
elevationGain Number Total elevation gain over all the provided coordinates
elevationMax Number Maximum elevation value
elevationMin Number Minimum elevation value
intervalMetric Number Interval in which the GPS coordinate values were sampled
intervalUnit String Unit of the metric's interval value (metrics[n].intervalMetric), e.g., "SEC" for seconds
waypoints Array of Objects
GPS coordinates
waypoints[n].latitude Number Latitude value of this GPS coordinate
waypoints[n].longitude Number Longitude value of this GPS coordinate
waypoints[n].elevation Number Elevation value of this GPS coordinate

Sample Response Body

{
    "links": [
        {
            "rel": "self",
            "href": "https://api.nike.com/v1/me/sport/activities/2683000000011936851080007062707485942202/gps"
        },
        {
            "rel": "activity",
            "href": "https://api.nike.com/v1/me/sport/activities/2683000000011936851080007062707485942202"
        }
    ],
    "elevationLoss": 65.70621,
    "elevationGain": 65.80545,
    "elevationMax": 13.911795,
    "elevationMin": 0.69595414,
    "intervalMetric": 10,
    "intervalUnit": "SEC",
    "waypoints": [
        {
            "latitude": 45.526386,
            "longitude": -122.6702,
            "elevation": 7.9260945
        },
        {
            "latitude": 45.526386,
            "longitude": -122.6702,
            "elevation": 7.9260945
        },
        {
            "latitude": 45.52639,
            "longitude": -122.670204,
            "elevation": 7.9367223
        },
        {
            "latitude": 45.526398,
            "longitude": -122.670204,
            "elevation": 7.949546
        },
        {
            "latitude": 45.52641,
            "longitude": -122.67021,
            "elevation": 7.977135
        }
    ]
}

Error Codes

Please refer to Error Codes and Responses