Entur Developer
Products

purchase-windows

Server

Retrieves purchase window by fareFrame id or organisation id

GET
https://api.entur.io/products
/purchase-windows

Retrieves purchase window by fareFrame id or organisation id › query Parameters

orgId
​string · style: form · explode: true

The unique organisation id to identify the owner of the data

fareFrameId
​string · style: form · explode: true

The unique fareFrame id to identify the owner of the data

languageCode
​string · style: form · explode: true

The language code from ISO-639-3

Retrieves purchase window by fareFrame id or organisation id › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

If-None-Match
​string · style: simple

Used to make conditional requests. It allows the client to provide an ETag value, and the server will process the request only if the ETag does not match the current version of the resource.

Retrieves purchase window by fareFrame id or organisation id › Responses

Returns the info

A PurchaseWindow
changed
​string · date-time · required

Changed datetime.

created
​string · date-time · required

Created datetime.

​VersionOfObjectRef · required

Fare frame ref.

id
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:Child
modification
​string · enum · required

Modification status.

Enum values:
NEW
REVISE
DELETE
Example: NEW
nameOfClass
​string · required

Name of class.

Example: PurchaseWindow
status
​string · enum · required

Status

Enum values:
DRAFT
PROPOSED
VERSIONED
DEPRECATED
Example: DRAFT
version
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
compatibleWithVersionRef
​string

Compatible with version.

derivedFromVersionRef
​string

Derived from version.

​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time to purchase.

Example: 23:59:59.999999999
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: 23:59:59.999999999
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: 01:59:59.999999999
​TextInLanguage[]

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Create a purchase window

POST
https://api.entur.io/products
/purchase-windows

Create a purchase window › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

Create a purchase window › Request Body

​VersionOfObjectRef · required

Fare frame ref.

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:90days
​TextInLanguage[] · required

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

version
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time.

Example: 23:59:59
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: PT2160H
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: PT2160H
purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Create a purchase window › Responses

Entity created successfully

No data returned

Retrives a purchase window by id

GET
https://api.entur.io/products
/purchase-windows/{id}

Retrives a purchase window by id › path Parameters

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The unique id to identify a purchase window

Retrives a purchase window by id › query Parameters

version
​string · style: form · explode: true

The id for the version of the purchase window

languageCode
​string · style: form · explode: true

The language code from ISO-639-3

Retrives a purchase window by id › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

If-None-Match
​string · style: simple

Used to make conditional requests. It allows the client to provide an ETag value, and the server will process the request only if the ETag does not match the current version of the resource.

Retrives a purchase window by id › Responses

Returns the info

A PurchaseWindow
changed
​string · date-time · required

Changed datetime.

created
​string · date-time · required

Created datetime.

​VersionOfObjectRef · required

Fare frame ref.

id
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:Child
modification
​string · enum · required

Modification status.

Enum values:
NEW
REVISE
DELETE
Example: NEW
nameOfClass
​string · required

Name of class.

Example: PurchaseWindow
status
​string · enum · required

Status

Enum values:
DRAFT
PROPOSED
VERSIONED
DEPRECATED
Example: DRAFT
version
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
compatibleWithVersionRef
​string

Compatible with version.

derivedFromVersionRef
​string

Derived from version.

​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time to purchase.

Example: 23:59:59.999999999
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: 23:59:59.999999999
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: 01:59:59.999999999
​TextInLanguage[]

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Retrives a purchase window by id and version

GET
https://api.entur.io/products
/purchase-windows/{id}/{version}

Retrives a purchase window by id and version › path Parameters

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The unique id to identify a purchase window

version
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The id for the version of the purchase window

Retrives a purchase window by id and version › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

Accept-Language
​string · style: simple

The language code from ISO-639-3

If-None-Match
​string · style: simple

Used to make conditional requests. It allows the client to provide an ETag value, and the server will process the request only if the ETag does not match the current version of the resource.

Retrives a purchase window by id and version › Responses

Returns the info

A PurchaseWindow
changed
​string · date-time · required

Changed datetime.

created
​string · date-time · required

Created datetime.

​VersionOfObjectRef · required

Fare frame ref.

id
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:Child
modification
​string · enum · required

Modification status.

Enum values:
NEW
REVISE
DELETE
Example: NEW
nameOfClass
​string · required

Name of class.

Example: PurchaseWindow
status
​string · enum · required

Status

Enum values:
DRAFT
PROPOSED
VERSIONED
DEPRECATED
Example: DRAFT
version
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
compatibleWithVersionRef
​string

Compatible with version.

derivedFromVersionRef
​string

Derived from version.

​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time to purchase.

Example: 23:59:59.999999999
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: 23:59:59.999999999
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: 01:59:59.999999999
​TextInLanguage[]

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Update a purchase window

PUT
https://api.entur.io/products
/purchase-windows/{id}/{version}

Update a purchase window › path Parameters

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The unique id to identify a purchase window

version
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The id for the version of the purchase window

Update a purchase window › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

Update a purchase window › Request Body

​VersionOfObjectRef · required

Fare frame ref.

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:90days
​TextInLanguage[] · required

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

version
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time.

Example: 23:59:59
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: PT2160H
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: PT2160H
purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Update a purchase window › Responses

Entity updated successfully

No data returned

Retrieves a purchase window by id

GET
https://api.entur.io/products
/v1/purchase-windows/{id}

Retrieves a purchase window by id › path Parameters

id
​string · pattern: ^([A-Z]{3}):([A-Za-z… · required · style: simple

The unique id to identify a purchase window

Retrieves a purchase window by id › query Parameters

startDate
​string · style: form · explode: true
endDate
​string · style: form · explode: true
status
​string · style: form · explode: true

The version status of the purchase window

fromDate
​string · style: form · explode: true

The from date of the purchase windows version

toDate
​string · style: form · explode: true

The to date of the purchase windows version

Retrieves a purchase window by id › Headers

ET-Client-Name
​string · style: simple

Entur Client Header. It is required that all consumers identify themselves by using this header. Entur will deploy strict rate-limiting policies on API-consumers who do not identify with a header and reserves the right to block unidentified consumers. The structure of ET-Client-Name should be: <company>-<application>.

X-Correlation-Id
​string · style: simple

Correlation id

Accept-Language
​string · style: simple

The language code from ISO-639-3

If-None-Match
​string · style: simple

Used to make conditional requests. It allows the client to provide an ETag value, and the server will process the request only if the ETag does not match the current version of the resource.

Retrieves a purchase window by id › Responses

Returns the info

A PurchaseWindow
changed
​string · date-time · required

Changed datetime.

created
​string · date-time · required

Created datetime.

​VersionOfObjectRef · required

Fare frame ref.

id
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

Id.

Example: NSB:PurchaseWindow:Child
modification
​string · enum · required

Modification status.

Enum values:
NEW
REVISE
DELETE
Example: NEW
nameOfClass
​string · required

Name of class.

Example: PurchaseWindow
status
​string · enum · required

Status

Enum values:
DRAFT
PROPOSED
VERSIONED
DEPRECATED
Example: DRAFT
version
​string · minLength: 1 · pattern: ^([A-Z]{3}):([A-Za-z… · required

PurchaseWindow version.

Example: NSB:Version:V1
compatibleWithVersionRef
​string

Compatible with version.

derivedFromVersionRef
​string

Derived from version.

​TextInLanguage[]

Description represented in different languages. Language codes are ISO-639.

latestTime
​string

Latest time to purchase.

Example: 23:59:59.999999999
​LimitingRule

A LimitingRule

maxmumPeriodBeforeDeparture
​string

Maximum period before departure.

Example: 23:59:59.999999999
minimumPeriodBeforeDeparture
​string

Minimum period before departure.

Example: 01:59:59.999999999
​TextInLanguage[]

PurchaseWindow Name represented in different languages. Language codes are ISO-639.

purchaseWhen
​string · enum

When to purchase.

Enum values:
TIME_OF_TRAVEL_ONLY
DAY_OF_TRAVEL_ONLY
ADVANCE_ONLY
UNTIL_PREVIOUS_DAY
ADVANCE_AND_DAY_OF_TRAVEL
OTHER
Example: ADVANCE_AND_DAY_OF_TRAVEL

Did you find what you were looking for?