Compare commits

...

5 Commits

2 changed files with 338 additions and 89 deletions

View File

@ -11,7 +11,7 @@ paths:
get: get:
tags: tags:
- Trips - Trips
summary: Get trips for a token summary: Get trips for a token in profile
description: >- description: >-
Get the most recent trips for a given token ID, as long as this token is Get the most recent trips for a given token ID, as long as this token is
bound to the profile (as derived from sub in given JWT) bound to the profile (as derived from sub in given JWT)
@ -246,6 +246,298 @@ paths:
- default: [] - default: []
x-auth-type: Application & Application User x-auth-type: Application & Application User
x-throttling-tier: Unlimited x-throttling-tier: Unlimited
/customers/tokens/trips:
get:
tags:
- Trips
summary: Get trips for an anonymous token
description: >-
Get the most recent trips for a given token type and value (i.e. SRID and amount or OVpasnumber).
parameters:
- name: X-HTM-JWT-AUTH-HEADER
in: header
required: true
style: simple
explode: false
schema:
type: string
- name: tokenType
in: query
required: true
description: >-
A tokenType IS AN enumerated identifier THAT describes the type of
Token that will be used as an input for the translation.
schema:
type: string
enum:
- srfid
- passnumber
- name: tokenValue
in: query
required: true
description: >-
A tokenValue IS A string THAT defines the value of the specified
tokenType.
examples:
srfid:
value: P485Q6M797J9LW
summary: srfid
passnumber:
value: 424HJGF
summary: passNumber
schema:
type: string
- name: validatorType
in: query
required: true
description: >-
A validatorType IS A string THAT defines the type of the attribute
that is needed to verify the authenticity of the request.
Options:
- **verificationCode**: A validator containing, 4 characters long,
which can be found on a CLT-card
- **amount**: Amount on the bank statement (in cents)
example: verificationcode
schema:
type: string
enum:
- verificationcode
- amount
- name: validatorInput
in: query
required: true
description: >-
A validatorInput IS A string THAT defines the value of the specified
validatorType.
examples:
verificationcode:
value: 6RS9
summary: verificationcode
amount:
value: '1021'
summary: amount
schema:
type: string
- name: dateTimeFrom
in: query
required: false
style: form
explode: false
schema:
type: string
- name: dateTimeUntil
in: query
required: false
style: form
explode: false
schema:
type: string
- name: organisationId
in: query
required: false
style: form
explode: false
schema:
type: string
- name: transportType
in: query
required: false
style: form
explode: false
schema:
type: string
- name: lineId
in: query
required: false
style: form
explode: false
schema:
type: string
- name: paymentMethod
in: query
required: false
style: form
explode: false
schema:
type: string
- name: productTemplateId
in: query
required: false
style: form
explode: false
schema:
type: string
- name: category
in: query
required: false
style: form
explode: false
schema:
type: string
- name: tripStatus
in: query
required: false
style: form
explode: false
schema:
type: string
- name: tripId
in: query
required: false
style: form
explode: false
schema:
type: string
- name: showSuperseedingTrips
in: query
required: false
style: form
explode: false
schema:
type: string
- name: organisationName
in: query
required: false
style: form
explode: false
schema:
type: string
- name: limit
in: query
required: false
style: form
explode: false
schema:
type: integer
- name: offset
in: query
required: false
style: form
explode: false
schema:
type: integer
responses:
'200':
description: ok
content:
application/json:
schema:
$ref: '#/components/schemas/getTokenTrips'
examples:
emptyResponse:
summary: No trips found for a token
value: []
multipleTripsResponse:
summary: Multiple trips found for a token
value:
- tripId: 66538
tripVersion: 2
transportType: RAIL
lineId: "10"
tripStatus: COMPLETE
fare: 2470
currency: EUR
lastUpdatedTripDateTime: 2021-06-01T06:22:00Z
checkinTransactionTimestamp: 2021-06-01T06:00:00Z
checkoutTransactionTimestamp: 2021-06-01T06:22:00Z
checkinLocation:
stopId: 621
stopName:
items:
- key: nl-NL
value: Utrecht Centraal
- key: en-US
value: Utrecht Centraal
stopDesc: Station Utrecht Centraal
stopUrl: /icons/stops/stop.svg
locationType: 0
checkoutLocation:
stopId: 253
stopName:
items:
- key: nl-NL
value: Goes
- key: en-US
value: Goes
stopDesc: Station Goes
stopUrl: /icons/stops/stop.svg
locationType: 0
loyaltyOrDiscount: false
_links:
tripDetails:
href: https://services.acc.api.htm.nl/abt/abtcustomers/1.0/customers/tokens/123/trips/66538
method: GET
templated: false
- tripId: 66539
tripVersion: 1
transportType: BUS
lineId: "20"
tripStatus: MISSING_CKO
fare: 1230
currency: EUR
lastUpdatedTripDateTime: 2021-06-01T07:00:00Z
checkinTransactionTimestamp: 2021-06-01T06:30:00Z
checkoutTransactionTimestamp: null
checkinLocation:
stopId: 622
stopName:
items:
- key: nl-NL
value: Amsterdam Centraal
- key: en-US
value: Amsterdam Centraal
stopDesc: Station Amsterdam Centraal
stopUrl: /icons/stops/stop.svg
locationType: 0
checkoutLocation: null
loyaltyOrDiscount: true
_links:
getTripDetails:
href: https://services.acc.api.htm.nl/abt/abtcustomers/1.0/customers/tokens/123/trips/66539
method: GET
templated: false
getStopsForCorrection:
href: https://services.acc.api.htm.nl/abt/abtcustomers/1.0/customers/trips/stops?xbot=36637b86-7a31-4b77-99dd-2d39b9c1a9b6&tripId=66539&transactionId=001e8481-1151-gemaltoPure-1622527200000
method: GET
templated: false
'400':
description: '400'
content:
application/json:
schema:
$ref: '#/components/schemas/400Response'
'401':
description: '401'
content:
application/json:
schema:
$ref: '#/components/schemas/401Response'
'403':
description: '403'
content:
application/json:
schema:
$ref: '#/components/schemas/403Response'
'404':
description: '404'
content:
application/json:
schema:
$ref: '#/components/schemas/404Response'
'500':
description: '500'
content:
application/json:
schema:
$ref: '#/components/schemas/500Response'
security:
- default: []
x-auth-type: Application & Application User
x-throttling-tier: Unlimited
/customers/trips/{tripId}: /customers/trips/{tripId}:
get: get:
tags: tags:
@ -709,92 +1001,65 @@ paths:
summary: Possible stops for a trip with missing check-out summary: Possible stops for a trip with missing check-out
value: value:
xbot: 36637b86-7a31-4b77-99dd-2d39b9c1a9b6 xbot: 36637b86-7a31-4b77-99dd-2d39b9c1a9b6
counterpartTransactionId: 001e8481-1151-gemaltoPure-1622527200000 counterpartTransactionId: 003D08FF-75032799-emv-1773668001000
counterpartEntryExitType: ENTRY counterpartEntryExitType: ENTRY
counterpartTimeStamp: "2021-06-01T06:00:00Z" counterpartTimeStamp: 2026-03-16T14:33:21+01:00
counterpartStop: counterpartStop:
alternativeTexts: alternativeTexts:
- text: - text:
lang: nl-NL lang: nl-NL
textIdType: Utrecht Centraal textIdType: publicName
text: Utrecht Centraal text: Delftsewallen
name: Utrecht Centraal - text:
shortName: Utrecht Centraal lang: en-US
description: Station Utrecht Centraal textIdType: publicName
location: text: Delftsewallen
longitude: 5.1099 name: Stop point8124
latitude: 52.0894 description: Stop point8124
altitude: 0 stopId: 8124
stopId: 621 transportModes: []
transportModes: deviceId: 3999999
- BUS deviceClassId: 0
- RAIL
deviceId: 3212967
deviceClassId: 9
scheduledStopPoints: scheduledStopPoints:
- alternativeTexts: - alternativeTexts:
- text: - text:
lang: nl-NL lang: nl-NL
textIdType: publicName textIdType: publicName
text: Brouwersgracht text: Centrum-West
name: Brouwersgracht - text:
shortName: Brouwersgracht lang: en-US
description: Brouwersgracht textIdType: publicName
location: text: Centrum-West
longitude: 4.3050492 name: Stop point8127
latitude: 52.0737538 description: Stop point8127
altitude: 0 stopId: 8127
stopId: 42 transportModes: []
transportModes: - alternativeTexts:
- RAIL - text:
lang: nl-NL
textIdType: publicName
text: Halte Onbekend
- text:
lang: en-US
textIdType: publicName
text: Halte Onbekend
name: Stop point65533
description: Stop point65533
stopId: 65533
transportModes: []
- alternativeTexts: - alternativeTexts:
- text: - text:
lang: nl-NL lang: nl-NL
textIdType: publicName textIdType: publicName
text: Grote Markt text: Dorp
name: Grote Markt
shortName: Grote Markt
description: Grote Markt
location:
longitude: 4.3092398
latitude: 52.075929
altitude: 0
stopId: 42
transportModes:
- RAIL
- BUS
- alternativeTexts:
- text: - text:
lang: nl-NL lang: en-US
textIdType: publicName textIdType: publicName
text: Spui text: Dorp
name: Spui name: Stop point8126
shortName: Spui description: Stop point8126
description: Spui stopId: 8126
location: transportModes: []
longitude: 4.3172
latitude: 52.0764
altitude: 0
stopId: 42
transportModes:
- RAIL
- BUS
- alternativeTexts:
- text:
lang: nl-NL
textIdType: publicName
text: Den Haag Centraal
name: Den Haag Centraal
shortName: Den Haag Centraal
description: Den Haag Centraal
location:
longitude: 4.32553
latitude: 52.08176
altitude: 0
stopId: 42
transportModes:
- RAIL
- BUS
'400': '400':
description: '400' description: '400'
content: content:

View File

@ -10,25 +10,9 @@ paths:
get: get:
summary: Get a list of issued vouchers that were issued for a specific touch point summary: Get a list of issued vouchers that were issued for a specific touch point
description: description:
Retrieve all issued vouchers for a specific touch point. This means that only products that have active sellingPeriods for touch points within the same Retrieve all issued vouchers for a specific touch point. This means that only products that the calling touch point is allowed to see or sell
retailer as the calling touch point are returned. (i.e. has active sellingPeriods for touchPointId of the calling touch point) are returned.
parameters: parameters:
- name: touchpointId
in: query
required: false
description: |
This endpoint is meant for salesTouchpoints to check the existance and validity of the voucher a customer has supplied
schema:
type: integer
example: 1001
- name: issuedVoucherId
in: query
required: false
description: The unique identifier of the issued voucher instance to retrieve.
schema:
type: string
format: uuid
example: d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90
- name: voucherCode - name: voucherCode
in: query in: query
required: false required: false