Transactions

Get transaction lineage

See how a transaction's spend was allocated across providers with the Java SDK.

GET/transactions/{transaction_id}/lineage

Use blnk.transactions().getLineage for this operation.

Call the method

ApiResponse<JsonNode> response = blnk.transactions().getLineage(
    "txn_f482a1b3-6c2d-4e89-a17b-3d5e8f2a1c94"
);
FieldTypeDescription
transactionIdStringTransaction ID with fund lineage enabled.

Use the provider breakdown

Read fund_allocation for how much came from each provider. Read shadow_transactions for the internal records Blnk created to track each provider’s share.

Response

{
  "transaction_id": "txn_8d2ce2f0-0d75-4a91-9d43-2ad2c2e6b9ad",
  "fund_allocation": [
    {
      "provider": "stripe",
      "amount": "2500"
    }
  ],
  "shadow_transactions": [
    {
      "transaction_id": "txn_shadow_123",
      "reference": "ref_002_release_stripe_0",
      "precise_amount": "2500",
      "currency": "USD",
      "status": "APPLIED"
    }
  ]
}
FieldTypeDescription
transaction_idStringTransaction you queried.
fund_allocationJsonNodeJSON array describing how much of the spend came from each provider. Amounts are strings in minor units.
shadow_transactionsJsonNodeJSON array of internal records Blnk creates to track each provider’s share of the spend.