-
Notifications
You must be signed in to change notification settings - Fork 0
API Documentation
boh1996 edited this page Mar 6, 2013
·
19 revisions
Append the GET parameter token to a request string, and set the value to the current users token, to authenticate with the API.
GET computer/:id:
Request:
GET computer/263
Result:
{
"result": {
"id": 263,
"identifier": "Llamarius",
"created_time": "1361831029",
"last_updated": "1361831028.5848"
....
},
"error_code": null,
"error": null,
"status": true
}
- &fields to select which data properties to load and show
GET computers/:organization_id:
Request:
GET computers/2?fields=id,last_updated&computers=15,263
Result:
{
"result": [
{
"id": "15",
"last_updated": "1362240375.5673"
},
{
"id": "263",
"last_updated": "1361831028.5848"
}
],
"error_code": null,
"error": null,
"status": true
}
- &fields to select which data properties to load and show
- &computers select which computers to load
- &limit set the max number of computers to return
- &offset set the select offset to use
GET user/:id:
Returns data about the 🆔'th user, if the current user has access to that data
GET user/me
Returns data about the current user who owns the sent token
Request:
GET user/me
Result:
{
"result": {
"id": 1,
"organizations": [
{
"id": 2,
"name": "Illution",
"employees": [
"1",
"2",
"3",
"5",
"4"
]
}
],
"email": "support@illution.dk",
"name": "Bo Thomsen"
},
"error_code": null,
"error": null,
"status": true
}
- &fields select the data properties to load and output
GET token/:token;
This endpoint returns "true" or "false" if the USER_AGENT header is set to "CI/Windows" or "CI/Android", if not a proper response is returned.
Request:
GET token/4pMFRVfKEr0s8XGHhm3pH5q5UcdOIpTaBzkGgjyPhLm5jtCGW6wdzcYK62YEhsei
Result:
{
"result": {
"id": "171",
"token": "4pMFRVfKEr0s8XGHhm3pH5q5UcdOIpTaBzkGgjyPhLm5jtCGW6wdzcYK62YEhsei",
"offline": "1",
"time_to_live": 0
},
"error_code": null,
"error": null,
"status": true
}