Token generation
Data requests
Get Users Válasz
[
{"id":2,"name":"Nagy László"},
{"id":3,"name":"Teszt User"},
{"id":4,"name":"Teszt User Kettő"}
]
Get presets Kérés
{"trainer_id":"2"}
Get presets Válasz
[
{"id":4,"presetname":"Kardio","training_type_id":2,"training_type":"Cardio Mode","programtime":1200,"impulsetime":20,"breaktime":10,"depth":400,"frequency":8,"amplification":0,"created":"2017-11-08 17:27:55","modified":"2017-11-08 18:27:56"},
{"id":3,"presetname":"Kardio11","training_type_id":2,"training_type":"Cardio Mode","programtime":1200,"impulsetime":20,"breaktime":10,"depth":400,"frequency":8,"amplification":0,"created":"2017-11-08 17:26:43","modified":"2017-11-08 18:28:17"},
{"id":1,"presetname":"Quick cardio","training_type_id":2,"training_type":"Cardio Mode","programtime":1200,"impulsetime":20,"breaktime":10,"depth":400,"frequency":10,"amplification":0,"created":"2017-10-31 14:56:32","modified":"2017-11-08 18:17:42"},
{"id":2,"presetname":"Strength Test","training_type_id":1,"training_type":"Strength Mode","programtime":1200,"impulsetime":6,"breaktime":2,"depth":350,"frequency":70,"amplification":0,"created":"2017-10-31 14:56:32","modified":"2017-10-31 14:56:37"}
]
Get Users Kérés
{"id":"3"}
Get User Data Válasz
{
"id":3,
"username":"teszt@teszt.hu",
"fullname":"Teszt User",
"franchise_id":2,
"number_of_trainings":4
}
Set Training Params
Kérés
{
"training_id":"3",
"preset_id":"1",
"active_interval":"4",
"resting_interval":"2",
"frequency":"80",
"impulse_depth":"400",
"amplification":"0",
"elapsed_programtime":"600",
"programtime":"600",
"ch1":"23",
"ch2":"23",
"ch3":"45",
"ch4":"32",
"ch5":"25",
"ch6":"13",
"ch7":"24",
"ch8":"22",
"ch9":"43",
"ch10":"22",
"ch11":"32",
"ch12":"23",
"master":"65"
}
Válasz
{"status":true}
Set preset
Csak ha PresetID 0!!
Kérés
{
"trainer_id":"2",
"preset_id":0,
"local_preset_id":"LOCAL00001",
"presetname":"Teszt preset",
"training_type_id":"1",
"programtime":"1200",
"impulsetime":"6",
"breaktime":"4",
"depth":"300",
"frequency":"100",
"amplification":"0"
}
Válasz
{
"status":true,
"local_preset_id":"LOCAL00001"
}
Get Last Training
Get Training Types
Get Last Training Kérés
{"client_id":"3"}
Get Last Training Válasz
{
"preset_id": 1,
"programtime": 600,
"active_interval": 4,
"resting_interval": 2,
"frequency": 80,
"impulse_depth": 400,
"amplification": 0,
"ch1": 23,
"ch2": 23,
"ch3": 45,
"ch4": 32,
"ch5": 25,
"ch6": 13,
"ch7": 24,
"ch8": 22,
"ch9": 43,
"ch10": 22,
"ch11": 32,
"ch12": 23,
"master": 65
}
Get Training Types Válasz
[{
"id": 1,
"name": "Strength Mode",
"icon": "training-strength",
"defaultSettings": [{
"id": 1,
"name": "Program Time",
"min": 1,
"max": 30,
"unit": "min",
"step": 1,
"value": 20
}, {
"id": 2,
"name": "Impulse Duration",
"min": 1,
"max": 20,
"unit": "sec",
"step": 1,
"value": 3
}, {
"id": 3,
"name": "Impulse Pause",
"min": 1,
"max": 10,
"unit": "sec",
"step": 1,
"value": 2
}, {
"id": 4,
"name": "Impulse Ampl.",
"min": 0,
"max": 1,
"unit": "sec",
"step": 0.5,
"value": 0.5
}, {
"id": 5,
"name": "Impulse Freq.",
"min": 1,
"max": 100,
"unit": "Hz",
"step": 1,
"value": 80
}, {
"id": 6,
"name": "Impulse Depth",
"min": 50,
"max": 400,
"unit": "µs",
"step": 50,
"value": 350
}
]
}, {
"id": 2,
"name": "Cardio Mode",
"icon": "training-cardio",
"defaultSettings": [{
"id": 1,
"name": "Program Time",
"min": 1,
"max": 30,
"unit": "min",
"step": 1,
"value": 20
}, {
"id": 2,
"name": "Impulse Duration",
"min": 1,
"max": 20,
"unit": "sec",
"step": 1,
"value": 20
}, {
"id": 3,
"name": "Impulse Pause",
"min": 0,
"max": 10,
"unit": "sec",
"step": 1,
"value": 10
}, {
"id": 4,
"name": "Impulse Ampl.",
"min": 0,
"max": 1,
"unit": "sec",
"step": 0.5,
"value": 0.5
}, {
"id": 5,
"name": "Impulse Freq.",
"min": 1,
"max": 100,
"unit": "Hz",
"step": 1,
"value": 7
}, {
"id": 6,
"name": "Impulse Depth",
"min": 50,
"max": 400,
"unit": "µs",
"step": 50,
"value": 350
}
]
}
]