Transaction

Transaction

Service to interact with a customer's transactions

Constructor

new Transaction(options)

Create a new transaction service

Parameters:
Name Type Description
options Object

configuration parameters

Source:

Methods

getTransaction(accessToken, transactionId, sourceopt) → {Promise}

Gets the full details of a single transaction

Parameters:
Name Type Attributes Description
accessToken string

the oauth bearer token

transactionId string

the unique transaction ID

source string <optional>

the transaction type (e.g. faster payments, mastercard). If not specified, only generic transaction information will be returned.

Source:
Returns:
  • the http request promise
Type
Promise

getTransactions(accessToken, fromDate, toDate, sourceopt) → {Promise}

Gets the customer's transactions over the given period

Parameters:
Name Type Attributes Description
accessToken string

the oauth bearer token.

fromDate string

filter transactions after this date. Format: YYYY-MM-DD

toDate string

filter transactions before this date. Format: YYYY-MM-DD

source string <optional>

the transaction type (e.g. faster payments, mastercard). If not specified, results are not filtered by source.

Source:
Returns:
  • the http request promise
Type
Promise