Method: paycache.getTransactions

Asks the partner bank for a subset of known transactions for a given customer account, using a filter to reduce the number of transactions returned. This will be used by Google to discover any transactions that the bank has recorded that Google does not have in its records.

This API will return Transactions that occurred on or after the specified filter-date. It should return all Holds, reguardless of date.

An example request looks like:


{
  "requestHeader": {
    "protocolVersion": {
      "major": 1
    },
    "requestId": "G1MQ0YERJ0Q7LPM",
    "requestTimestamp": {
      "epochMillis":1481899949606
    },
    "paymentIntegratorAccountId": "abcdef123456"
  },
  "googleAccountToken": "fake_account_token",
  "dateBasedFilter": {
    "transactionRecordStartDate": {
      "epochMillis":1481846400000
    }
  }
}

An example success response looks like:


{
  "responseHeader": {
    "responseTimestamp": {
      "epochMillis":1481899950236
    }
  },
  "accountBalanceSummary": {
    "startOfDayLedgerBalance": {
      "amountMicros":"120000000",
      "currencyCode":"USD"
    },
    "currentLedgerBalance": {
      "amountMicros":"120000000",
      "currencyCode":"USD"
    },
    "availableBalance": {
      "amountMicros":"100000000",
      "currencyCode":"USD"
    }
  },
  "transactions": [
    {
      "transactionId": "G1MQ0YERJ0Q7LPM",
      "transactionTimestamp": {
        "epochMillis":1481846400000
      },
      "amount": {
        "amountMicros": "5000000",
        "currencyCode": "USD"
      },
      "description": "Coffee purchase at The Coffee Company",
      "transactionDetails": {
        "credit": {
          "wire": {}
        }
      }
    },
    {
      "transactionId": "G1MQ0YERJ0Q7LPN",
      "transactionTimestamp": {
        "epochMillis":1481846412345
      },
      "amount": {
        "amountMicros": "4000000",
        "currencyCode": "USD"
      },
      "description": "Coffee purchase at The Coffee Company",
      "transactionDetails": {
        "debit": {
          "ach": {}
        }
      }
    }
  ],
  "holds": [
    {
      "transactionId": "G1MQ0YERJ0Q7LPO",
      "holdTimestamp": {
        "epochMillis":1481846400000
      },
      "amount": {
        "amountMicros": "5000000",
        "currencyCode": "USD"
      },
      "description": "Coffee purchase at The Coffee Company",
      "holdDetails": {
        "debit": {
          "reserveFunds": {
            "reservationExpiry": {
              "epochMillis":1482710400000
            }
          }
        }
      }
    }
  ]
}

HTTP request

POST https://www.integratordomain.com/v1/paycache/getTransactions

Request body

The request body contains data with the following structure:

JSON representation
{
  "requestHeader": {
    object (RequestHeader)
  },
  "googleAccountToken": string,
  "dateBasedFilter": {
    object (DateFilter)
  }
}
Fields
requestHeader

object (RequestHeader)

REQUIRED: Common header for all requests.

googleAccountToken

string

REQUIRED: The unique googleAccountToken that represents the Cache account.

dateBasedFilter

object (DateFilter)

Date based filter to ask for the list of transactions the banks know about from a given date through today. While Transactions are date bound, the bank should return all known Holds.

Response body

If successful, the response body contains data with the following structure:

JSON representation
{
  "responseHeader": {
    object (ResponseHeader)
  },
  "accountBalanceSummary": {
    object (AccountBalanceSummary)
  },
  "transactions": [
    {
      object (TransactionRecord)
    }
  ],
  "holds": [
    {
      object (HoldRecord)
    }
  ],
  "accountBalances": {
    object (AccountBalances)
  }
}
Fields
responseHeader

object (ResponseHeader)

REQUIRED: Common header for all responses.

accountBalanceSummary
(deprecated)

object (AccountBalanceSummary)

DEPRECATED: Up-to-date summary of the customer's account balance.

Deprecated due to the balance amounts not containing timestamps.

This will be removed before the final version of this spec. Please use accountBalances instead.

transactions[]

object (TransactionRecord)

REQUIRED: List of transactions for the customer's account in the filter range.. Sort order does not matter.

holds[]

object (HoldRecord)

REQUIRED: List of all holds on the customer's account (events that are considered temporary holds on the account, which affect available balance, not current balance). Sort order does not matter.

accountBalances

object (AccountBalances)

REQUIRED: An up-to-date summary of the customer's account balance.

DateFilter

JSON representation
{
  "transactionRecordStartDate": {
    object (Timestamp)
  }
}
Fields
transactionRecordStartDate

object (Timestamp)

REQUIRED: The starting date (inclusive) the cache bank should return transaction records for.

TransactionRecord

JSON representation
{
  "transactionId": string,
  "transactionTimestamp": {
    object (Timestamp)
  },
  "amount": {
    object (Amount)
  },
  "description": string,
  "transactionDetails": {
    object (TransactionDetails)
  }
}
Fields
transactionId

string

REQUIRED: The unique identifier for this transaction. This should be the transactionId of the Google or Bank event that created this transaction.

transactionTimestamp

object (Timestamp)

REQUIRED: Timestamp of when this transaction occurred.

amount

object (Amount)

REQUIRED: Amount of the transaction (always positive).

description

string

REQUIRED: A description of the transaction.

transactionDetails

object (TransactionDetails)

REQUIRED: Specifies the type of transaction this is, and will contain any details unique to that transaction type.

TransactionDetails

JSON representation
{

  // Union field details can be only one of the following:
  "debit": {
    object (DebitTransactionDetails)
  },
  "credit": {
    object (CreditTransactionDetails)
  }
  // End of list of possible types for union field details.
}
Fields

Union field details.

details can be only one of the following:

debit

object (DebitTransactionDetails)

Details about the credit transaction

credit

object (CreditTransactionDetails)

Details about the debit transaction

DebitTransactionDetails

JSON representation
{

  // Union field type can be only one of the following:
  "ach": {
    object (AchTransaction)
  },
  "payment": {
    object (Payment)
  },
  "p2pTransfer": {
    object (Empty)
  },
  "accountTransfer": {
    object (AccountTransfer)
  },
  "creditReversal": {
    object (CreditReversal)
  },
  "check": {
    object (CheckTransaction)
  }
  // End of list of possible types for union field type.
}
Fields

Union field type.

type can be only one of the following:

ach

object (AchTransaction)

Details about a booked ACH transaction.

payment

object (Payment)

Details about a booked payment transaction.

p2pTransfer

object (Empty)

Details about a booked P2P transfer transaction.

accountTransfer

object (AccountTransfer)

Details about a booked transfer to another account.

creditReversal

object (CreditReversal)

Details about a booked paycache.credit Reversal.

check

object (CheckTransaction)

Details about a booked check transaction.

AchTransaction

JSON representation
{
  "dispute": {
    object (AchDispute)
  }
}
Fields
dispute

object (AchDispute)

OPTIONAL: If this credit or debit is the result of an ACH return, dishonor, or contested dishonor then this is required.

AchDispute

JSON representation
{
  "originalTransactionId": string,
  "returnReasonCode": string,
  "caseId": string
}
Fields
originalTransactionId

string

REQUIRED: This is the transactionId of the original ACH transaction. E.g. If a return is dishonored then both the return and dishonor will use the same originalTransactionId.

returnReasonCode

string

REQUIRED: This is the RXX return reason code used in the return, dishonor, or contested dishonor as defined by NACHA.

caseId

string

OPTIONAL: If this return, dishonor, or contested dishonor is a result of Google calling paycache.initiateDispute then this is required. This is the caseId passed to paycache.initiateDispute of the case that caused this return, dishonor, or contested dishonor.

Payment

JSON representation
{
  "reservationTransactionId": string
}
Fields
reservationTransactionId

string

REQUIRED: The transaction ID from the call to reserveFunds.

AccountTransfer

CreditReversal

CheckTransaction

CreditTransactionDetails

JSON representation
{

  // Union field type can be only one of the following:
  "wire": {
    object (WireTransaction)
  },
  "ach": {
    object (AchTransaction)
  },
  "p2pTransfer": {
    object (Empty)
  },
  "accountTransfer": {
    object (AccountTransfer)
  },
  "debitReversal": {
    object (DebitReversal)
  },
  "gift": {
    object (Empty)
  },
  "interest": {
    object (Empty)
  }
  // End of list of possible types for union field type.
}
Fields

Union field type.

type can be only one of the following:

wire

object (WireTransaction)

Details about a booked wire transaction.

ach

object (AchTransaction)

Details about a booked ACH transaction.

p2pTransfer

object (Empty)

Details about a booked P2P transfer transaction.

accountTransfer

object (AccountTransfer)

Details about a booked transfer to another account.

debitReversal

object (DebitReversal)

Details about a booked paycache.credit Reversal.

gift

object (Empty)

A credit from Google to the customer.

interest

object (Empty)

paycache.credit applied to account from bank-generated interest.

WireTransaction

CreditNotification API.

DebitReversal

HoldRecord

JSON representation
{
  "transactionId": string,
  "holdTimestamp": {
    object (Timestamp)
  },
  "amount": {
    object (Amount)
  },
  "description": string,
  "holdDetails": {
    object (HoldDetails)
  }
}
Fields
transactionId

string

REQUIRED: The unique identifier for this hold. This should be the transactionId of the Google or Bank event that created this transaction.

holdTimestamp

object (Timestamp)

REQUIRED: Timestamp of when this hold occurred.

amount

object (Amount)

REQUIRED: Currently held Amount (always positive).

description

string

REQUIRED: A description of the hold.

holdDetails

object (HoldDetails)

REQUIRED: Specifies the type of hold this is, and will contain any details unique to that hold type.

HoldDetails

JSON representation
{

  // Union field details can be only one of the following:
  "debit": {
    object (DebitHoldDetails)
  },
  "credit": {
    object (CreditHoldDetails)
  }
  // End of list of possible types for union field details.
}
Fields

Union field details.

details can be only one of the following:

debit

object (DebitHoldDetails)

Details about pending debit transactions

credit

object (CreditHoldDetails)

Details about pending credit transactions

DebitHoldDetails

JSON representation
{
  "reserveFunds": {
    object (ReserveFundsHold)
  }
}
Fields
reserveFunds

object (ReserveFundsHold)

Details about a reserve funds (credit card authorization) pending transactions on a customer account.

ReserveFundsHold

JSON representation
{
  "reservationExpiry": {
    object (Timestamp)
  }
}
Fields
reservationExpiry

object (Timestamp)

REQUIRED: Timestamp of the expiration of this reservation.

CreditHoldDetails

JSON representation
{
  "check": {
    object (CheckHold)
  }
}
Fields
check

object (CheckHold)

Details about a deposited check whose funds are pending availability.

CheckHold

JSON representation
{
  "checkAmount": {
    object (Amount)
  }
}
Fields
checkAmount

object (Amount)

REQUIRED: Total check Amount (always positive).