Skip to content

OpenJourneyPlanner (OJP) API

Contact Info

Documentation

This sandbox feature implements part of the OpenJourneyPlanner API which is a standard defined by CEN, the European Committee for Standardization.

The following request types are supported:

  • StopEventRequest
  • TripRequest

To enable this turn on OjpApi as a feature in otp-config.json.

Configuration

This feature allows a small number of config options. To change the configuration, add the following to router-config.json.

Example configuration

// router-config.json
{
  "ojpApi" : {
    "hideFeedId" : true,
    "hardcodedInputFeedId" : "ch"
  }
}

Overview

Config Parameter Type Summary Req./Opt. Default Value Since
hardcodedInputFeedId string The hardcoded feedId to add to all input ids. Optional 2.9
hideFeedId boolean Hide the feed id in all API output, and add it to input ids. Optional false 2.9

Details

hardcodedInputFeedId

Since version: 2.9Type: stringCardinality: Optional
Path: /ojpApi

The hardcoded feedId to add to all input ids.

Only turn this feature on if you have unique ids across all feeds, without the feedId prefix and hideFeedId is set to true.`

hideFeedId

Since version: 2.9Type: booleanCardinality: OptionalDefault value: false
Path: /ojpApi

Hide the feed id in all API output, and add it to input ids.

Only turn this feature on if you have unique ids across all feeds, without the feedId prefix.