sharee.bike-Wiki/5.2.-tool-request=bikes_all.md
2022-12-29 10:10:02 +00:00

4.1 KiB

request=bikes_all

request GET all rental bikes with the optional limitations of station and/or bike number

key Required Format Comment
authcookie + text unique encrypted key
station o text station prefix+number
bike o text bike prefix+number

response "bikes" by JSON-Objects

key Required Format Comment
state + text bike available state
lock_state + text smartlock locking state
service_state o text service state for maintanance
description o text short bike description
bike + text bike prefix_number
gps + array GPS: latitude, longitude
station + text station prefix_number
bike_group + array bike group, describes bike dependent fleets
todo_info o text key if Aufgaben defined
system + text bike lock system (BC or Ilockit)
uri_operator + text URI of Operator-Server
lockit_ID + text bluetooth ID
lockit_GUID + text bluetooth GUID
service_code o array color keys, only available for servicetool users
bike_type + object describes the bike with some attributes
smartlock_type + object (under development) describes the smartlock with some attributes

bike_type JSON Object

key Required Format Comment
category o text "city" or "cargo"
wheels o text "2" or "3"
engine o object contains engine attributes like "manufacturer"
battery o object contains bike battery attributes. "hidden=0" means not in App visible. "backend_accessible=0" means no bike charge API available

smartlock_type JSON Object

key Required Format Comment
system o text ex. "Ilockit"
battery o object contains smartlock battery attributes.

Example request to get all bikes with states

https://shareeapp-primary.copri-bike.de/APIjsonserver?request=bikes_all&authcookie=6103_f782a208d9399291ba8d086b5dcc2509_23456789

response sharee JSON defaults + response multiple bike objects

{
   "shareejson" : {
  ***sharee JSON defaults***
 },
"bikes" : {
         "WUE5526" : {
            "state" : "available",
            "service_code" : [
               "blue",
               "red",
               "green",
               "green",
               "red",
               "red"
            ],
            "gps" : {
               "longitude" : "7.8167567567",
               "latitude" : "47.98797891085045"
            },
            "service_state" : "0",
            "lock_state" : "locked",
            "description" : "Lasten-Dreirad Bert",
            "bike" : "WUE5526",
            "todo_info" : "0",
            "bike_group" : [
               "WUE300029"
            ],
            "station" : "WUE303",
            "Ilockit_GUID" : "",
            "uri_operator" : "https://shareeapp-wue.copri-bike.de",
            "system" : "Ilockit",
            "Ilockit_ID" : "00000000-0000-0000-0000-fc3c045a2ade"
         },
         "WUE5525" {
            ...
         }
    }
}