Partner - Transaction API

Create transaction.

Adds a new transaction to the system and returns its ID and details.


Open Swagger Specification

Endpoint

    POST - https://api.travisroadservices.com/partners/v1/transactions
    Copy
  

Header params

Parameter Type Description
location string Location ID of the requesting location.

Request body

Response body

Response 201

TransactionResource resource created

Fields

Field Type Description
id integer Unique identifier of the transaction.
service string Service for which the transaction is created. Possible values: parking, repair, tankcleaning.
serviceInformation object Service-specific information such as arrival and departure for parking, order number for repair, or reference and cost specification for tankcleaning.
arrival string (date-time) In local time. Required and applicable only to the parking service.
departure string (date-time) In local time. Required and applicable only to the parking service.
orderNumber string Work order number for repair service. Required and applicable only to the repair service.
reference string Optional partner reference. Applicable only to the tankcleaning service.
costSpecification array Optional itemised cost specification. Applicable only to the tankcleaning service. When provided, the sum of the line costs must equal the transaction price amount.
vehicles object Vehicles involved in the transaction. At least one vehicle (truck or trailer) must be provided, unless the payment is a travis booking code, in which case vehicles are taken from the booking and must not be provided.
truck object
licensePlate string
trailer object
licensePlate string
driver string Name or identifier of the driver. Optional. Must not be provided when the payment is a booking travis code.
payment object Payment means used for the transaction.
type string The type of payment used. Available choices: travis_code, fuel_card. If "travis_code", then a travis code must be provided in "information". If "fuel_card", then the track data must be provided in "information.fuelCard".
information object
travisCode string Travis code for payment.
fuelCard object
provider string Fuel card provider.
holder string Fuel card holder name.
cardNumber string Fuel card number.
expiryDate string (date-time) Fuel card expiration date.
licensePlateType string Plate type that paid the transaction. "truck" or "trailer". Only set for drive_in payments.
price object Total price of the transaction.
amount number Price amount in the specified currency.
currency string ISO 4217 currency code.
payout object Payout amount applicable to the transaction.
amount number Price amount in the specified currency.
currency string ISO 4217 currency code.
customerDiscount object Customer discount applied to the transaction.
amount number Price amount in the specified currency.
currency string ISO 4217 currency code.
status object Current status of the transaction.
createdAt string (date-time) Date and time the transaction was created.
cancelledAt string (date-time) Date and time the transaction was cancelled, if applicable.
creditTransactionId integer Identifier of the related credit transaction. Only present when the transaction has been credited.
additionalCosts array List of additional cost transactions related to this transaction.
priceParts object Price of parts. Required and applicable to the repair service only.
amount number Price amount in the specified currency.
currency string ISO 4217 currency code.
priceLabour object Price of labour. Required and applicable to the repair service only.
amount number Price amount in the specified currency.
currency string ISO 4217 currency code.

Example