Realtime data

Real time data is available in the GBFS format (General Bikeshare Feed Specification). More details are available on GitHub. The data is updated every 10 seconds.

The data is published under the Norwegian Licence for Open Government Data (NLOD) 2.0

Identification in header

All requests to our real time API should send the Client-Identifier header. This should contain a value that describes the application accessing the API. The value should contain your company/organization name, follwed by a dash and the application's name, like mycompany-travelplanner or myname-citymonitor.

Endpoints

Auto discovery

Auto-discovery file that links to all of the other files published by the system.

Endpoint: gbfs.json (Documentation)

CURL request

curl -H "Client-Identifier: IDENTIFIER" https://gbfs.urbansharing.com/bergenbysykkel.no/gbfs.json

Response

{
  "data":{
    "nb":{
      "feeds":[
        {
          "url":"https://gbfs.urbansharing.com/bergenbysykkel.no/system_information.json",
          "name":"system_information"
        },
        {
          "url":"https://gbfs.urbansharing.com/bergenbysykkel.no/station_information.json",
          "name":"station_information"
        },
        {
          "url":"https://gbfs.urbansharing.com/bergenbysykkel.no/station_status.json",
          "name":"station_status"
        }
      ]
    }
  },
  "ttl":10,
  "last_updated":1542035150
}

System

Machine readable basic information about Bergen City Bike

Endpoint: system_information.json (Documentation)

CURL request

curl -H "Client-Identifier: IDENTIFIER" \
  https://gbfs.urbansharing.com/bergenbysykkel.no/system_information.json

Response

{
  "last_updated": 1540309494,
  "ttl": 10,
  "data": {
    "system_id": "bergen-city-bike",
    "language": "nb",
    "name": "Bergen City Bike",
    "operator": "Urban Infrastructure Partner",
    "timezone": "Europe/Oslo",
    "phone_number": "90259737",
    "email": "post@bergenbysykkel.no"
  }
}

Stations

Information about all stations, including geolocation, addresses and descriptions

Endpoint: station_information.json (Documentation)

CURL request

curl -H "Client-Identifier: IDENTIFIER" \
  https://gbfs.urbansharing.com/bergenbysykkel.no/station_information.json

Response

{
 "last_updated": 1540309984,
 "data": {
    "stations": [
       {
          "address": "Kaigaten",
          "capacity": 19,
          "lon": 5.327895003562276,
          "name": "Rådhuset",
          "station_id": "223",
          "lat": 60.39168071231371
       },
       {
          "address": "Måsekjæret",
          "capacity": 10,
          "lon": 5.320473627367278,
          "name": "Sandviken Brygge",
          "station_id": "222",
          "lat": 60.41292872155995
       },
       {
          "address": "sandvikstorget 11",
          "capacity": 19,
          "lon": 5.322648583141813,
          "name": "Sandvikstorget",
          "station_id": "221",
          "lat": 60.408582102784685
       }
     ]
   }
 }

Availability

Bike and dock availability

Endpoint: station_status.json (Documentation)

CURL request

curl -H "Client-Identifier: IDENTIFIER" \
  https://gbfs.urbansharing.com/bergenbysykkel.no/station_status.json

Response

{
  "last_updated": 1540219230,
  "data": {
    "stations": [
      {
        "is_installed": 1,
        "is_renting": 1,
        "num_bikes_available": 7,
        "num_docks_available": 5,
        "last_reported": 1540219230,
        "is_returning": 1,
        "station_id": "175"
      },
      {
        "is_installed": 1,
        "is_renting": 1,
        "num_bikes_available": 4,
        "num_docks_available": 8,
        "last_reported": 1540219230,
        "is_returning": 1,
        "station_id": "47"
      },
      {
        "is_installed": 1,
        "is_renting": 1,
        "num_bikes_available": 4,
        "num_docks_available": 9,
        "last_reported": 1540219230,
        "is_returning": 1,
        "station_id": "10"
      }
    ]
  }
}

Historical data

You may also download anonymised trip records