Gym API
Here are the various things you can do with the Gym API. Check in the top right for the different protocols.
Example Request
PUT /v1/gyms/
{
id: 2,
ratings: '1/5'
}
GET /v1/gyms/3
Example Response
{
data:
[{
"gid": "ChIJZ1O7Q5ZLW4YR7I9vD_QwZIU",
"id": 3,
"latitude": 30.222399,
"location": "4625 W. William Cannon Dr., Building 1, Austin",
"longitude": -97.8435931,
"name": "24 Hour Fitness",
"price_level": 0,
"ratings": 3.8
}]
}
Example Request
GET /v1/gyms/2
POST /v1/gyms
{
name: 'Iron Kingdom',
ratings: '5/5',
location: '1083 North Corner Drive, Austin, TX',
pricing: '36$ annually'
}
DELETE /v1/gyms/
{
id: 3
}
Example Response
{
img: 'https://9968c6ef49dc043599a5-e151928c3d69a5a4a2d07a8bf3efa90a.ssl.cf2.rackcdn.com/28263.jpg',
name: 'Hyde Park Gym',
ratings: '4.9/5',
location: '4125 Guadalupe St, Austin, TX 78751',
pricing: '$49.50/month'
}
Response Status 201:
{
data: {
uri: /v1/gyms/3
}
}
Response Status 202:
{
data: {
uri: /v1/gym/2
}
}
Response Status 202.