Created
June 17, 2021 16:15
-
-
Save pirasalbe/c90de06bb8dad339b85982746258a7e0 to your computer and use it in GitHub Desktop.
Fitbit Auth and Devices calls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"info": { | |
"_postman_id": "6a0bbf5d-4abf-45d3-830a-f69d63292acd", | |
"name": "Fitbit", | |
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" | |
}, | |
"item": [ | |
{ | |
"name": "Check token", | |
"request": { | |
"method": "POST", | |
"header": [], | |
"body": { | |
"mode": "urlencoded", | |
"urlencoded": [ | |
{ | |
"key": "token", | |
"value": "", | |
"type": "text" | |
} | |
] | |
}, | |
"url": { | |
"raw": "https://api.fitbit.com/1.1/oauth2/introspect", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": ["1.1", "oauth2", "introspect"] | |
} | |
}, | |
"response": [] | |
}, | |
{ | |
"name": "Devices", | |
"request": { | |
"method": "GET", | |
"header": [], | |
"url": { | |
"raw": "https://api.fitbit.com/1/user/-/devices.json", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": ["1", "user", "-", "devices.json"] | |
} | |
}, | |
"response": [] | |
}, | |
{ | |
"name": "Locales", | |
"request": { | |
"method": "GET", | |
"header": [], | |
"url": { | |
"raw": "https://api.fitbit.com/1/foods/locales.json", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": ["1", "foods", "locales.json"] | |
} | |
}, | |
"response": [] | |
}, | |
{ | |
"name": "Get Alarms", | |
"request": { | |
"method": "GET", | |
"header": [], | |
"url": { | |
"raw": "https://api.fitbit.com/1/user/-/devices/tracker/{{device}}/alarms.json", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": [ | |
"1", | |
"user", | |
"-", | |
"devices", | |
"tracker", | |
"{{device}}", | |
"alarms.json" | |
] | |
} | |
}, | |
"response": [] | |
}, | |
{ | |
"name": "Update Alarm", | |
"request": { | |
"method": "POST", | |
"header": [], | |
"body": { | |
"mode": "urlencoded", | |
"urlencoded": [ | |
{ | |
"key": "time", | |
"value": "08:20+02:00", | |
"type": "text" | |
}, | |
{ | |
"key": "enabled", | |
"value": "true", | |
"type": "text" | |
}, | |
{ | |
"key": "recurring", | |
"value": "true", | |
"type": "text" | |
}, | |
{ | |
"key": "weekDays", | |
"value": "MONDAY,TUESDAY,WEDNESDAY,THURSDAY,FRIDAY", | |
"type": "text" | |
}, | |
{ | |
"key": "snoozeLength", | |
"value": "5", | |
"type": "text" | |
}, | |
{ | |
"key": "snoozeCount", | |
"value": "3", | |
"type": "text" | |
} | |
] | |
}, | |
"url": { | |
"raw": "https://api.fitbit.com/1/user/-/devices/tracker/{{device}}/alarms/{{alarm}}.json", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": [ | |
"1", | |
"user", | |
"-", | |
"devices", | |
"tracker", | |
"{{device}}", | |
"alarms", | |
"{{alarm}}.json" | |
], | |
"query": [ | |
{ | |
"key": "time", | |
"value": "17%3A55%2002%3A00", | |
"disabled": true | |
}, | |
{ | |
"key": "enabled", | |
"value": "true", | |
"disabled": true | |
}, | |
{ | |
"key": "recurring", | |
"value": "false", | |
"disabled": true | |
}, | |
{ | |
"key": "weekDays", | |
"value": "THURSDAY", | |
"disabled": true | |
}, | |
{ | |
"key": "snoozeLength", | |
"value": "9", | |
"disabled": true | |
}, | |
{ | |
"key": "snoozeCount", | |
"value": "3", | |
"disabled": true | |
} | |
] | |
} | |
}, | |
"response": [] | |
}, | |
{ | |
"name": "Create Alarm", | |
"request": { | |
"method": "POST", | |
"header": [ | |
{ | |
"key": "Accept", | |
"value": "application/json", | |
"type": "text" | |
} | |
], | |
"body": { | |
"mode": "urlencoded", | |
"urlencoded": [ | |
{ | |
"key": "time", | |
"value": "17:35+02:00", | |
"type": "text" | |
}, | |
{ | |
"key": "enabled", | |
"value": "true", | |
"type": "text" | |
}, | |
{ | |
"key": "recurring", | |
"value": "false", | |
"type": "text" | |
}, | |
{ | |
"key": "weekDays", | |
"value": "THURSDAY", | |
"type": "text" | |
} | |
] | |
}, | |
"url": { | |
"raw": "https://api.fitbit.com/1/user/-/devices/tracker/{{device}}/alarms.json", | |
"protocol": "https", | |
"host": ["api", "fitbit", "com"], | |
"path": [ | |
"1", | |
"user", | |
"-", | |
"devices", | |
"tracker", | |
"{{device}}", | |
"alarms.json" | |
], | |
"query": [ | |
{ | |
"key": "time", | |
"value": "17:35+02:00", | |
"disabled": true | |
}, | |
{ | |
"key": "enabled", | |
"value": "true", | |
"disabled": true | |
}, | |
{ | |
"key": "recurring", | |
"value": "false", | |
"disabled": true | |
}, | |
{ | |
"key": "weekDays", | |
"value": "THURSDAY", | |
"disabled": true | |
}, | |
{ | |
"key": "snoozeLength", | |
"value": "9", | |
"disabled": true | |
}, | |
{ | |
"key": "snoozeCount", | |
"value": "3", | |
"disabled": true | |
} | |
] | |
} | |
}, | |
"response": [] | |
} | |
], | |
"auth": { | |
"type": "bearer", | |
"bearer": [ | |
{ | |
"key": "token", | |
"value": "", | |
"type": "string" | |
} | |
] | |
}, | |
"event": [ | |
{ | |
"listen": "prerequest", | |
"script": { | |
"type": "text/javascript", | |
"exec": [""] | |
} | |
}, | |
{ | |
"listen": "test", | |
"script": { | |
"type": "text/javascript", | |
"exec": [""] | |
} | |
} | |
], | |
"variable": [ | |
{ | |
"key": "device", | |
"value": "" | |
}, | |
{ | |
"key": "alarm", | |
"value": "" | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment