Skip to content

Browse Intermediated Payments ​

This flow shows how to list all payments intermediated by your agency and inspect individual payment details.

Step 1 — Follow intermediated-payments ​

From the root resource, find the link whose rel ends with intermediated-payments and GET its href.

bash
curl 'https://api-platform.demo.flywire.com/agents/v2/' \
  --header 'X-Authentication-Key: YOUR_API_TOKEN'

# Then follow the intermediated-payments href
curl "$INTERMEDIATED_PAYMENTS_HREF" \
  --header 'X-Authentication-Key: YOUR_API_TOKEN'
python
import requests

HEADERS = {"X-Authentication-Key": "YOUR_API_TOKEN"}

root = requests.get(
    "https://api-platform.demo.flywire.com/agents/v2/",
    headers=HEADERS
).json()

payments_link = next(
    l for l in root["links"]
    if l["rel"].endswith("intermediated-payments")
)
payments = requests.get(payments_link["href"], headers=HEADERS).json()
javascript
const HEADERS = { "X-Authentication-Key": "YOUR_API_TOKEN" };

const root = await fetch(
  "https://api-platform.demo.flywire.com/agents/v2/",
  { headers: HEADERS }
).then(r => r.json());

const paymentsLink = root.links.find(
  l => l.rel.endsWith("intermediated-payments")
);
const payments = await fetch(paymentsLink.href, { headers: HEADERS })
  .then(r => r.json());

Step 2 — Read the Payment List ​

The response contains an items array of payment summaries:

json
{
  "items": [
    {
      "reference": "FW-P-20260315-001",
      "recipient": { "name": "Demo University" },
      "status": { "name": "delivered" },
      "amount": { "value": 15000, "currency": "USD" },
      "intermediation": {
        "timestamp": "2026-03-15T08:55:00Z",
        "agent": { "name": "Acme Agency" },
        "client": { "name": "Wei Zhang" }
      }
    }
  ],
  "links": [
    { "rel": "self", "href": "..." },
    { "rel": "next", "href": "..." },
    {
      "rel": "tag:flywire.com,2016:agents:api:relation:intermediated-payment",
      "href": "...",
      "anchor": "#/items/0"
    }
  ]
}

Each item contains:

FieldDescription
referenceUnique payment identifier
recipient.nameName of the payment destination
status.nameCurrent payment status — see payment-status-name for the full enum
amountPayment value and currency
intermediation.timestampWhen the payment was intermediated
intermediation.agent.nameIntermediating agency
intermediation.client.nameClient whose payment this is

Step 3 — View Payment Details ​

Each item has an anchored intermediated-payment link — the anchor field tells you which item the link belongs to. Follow its href to get the full detail.

bash
curl "$PAYMENT_DETAIL_HREF" \
  --header 'X-Authentication-Key: YOUR_API_TOKEN'
python
detail_link = next(
    l for l in payments["links"]
    if l["rel"].endswith("intermediated-payment")
    and l.get("anchor") == "#/items/0"
)
detail = requests.get(detail_link["href"], headers=HEADERS).json()
javascript
const detailLink = payments.links.find(
  l => l.rel.endsWith("intermediated-payment")
    && l.anchor === "#/items/0"
);
const detail = await fetch(detailLink.href, { headers: HEADERS })
  .then(r => r.json());

The detail response includes:

json
{
  "reference": "FW-P-20260315-001",
  "recipient": { "name": "Demo University" },
  "status": {
    "current": { "name": "delivered", "timestamp": "2026-03-16T12:00:00Z" },
    "previous": [
      { "name": "guaranteed", "timestamp": "2026-03-15T10:30:00Z" },
      { "name": "on_hold", "timestamp": "2026-03-15T09:30:00Z" },
      { "name": "verification", "timestamp": "2026-03-15T09:10:00Z" },
      { "name": "initiated", "timestamp": "2026-03-15T09:00:00Z" }
    ]
  },
  "amount": {
    "original": { "value": 15000, "currency": "USD" },
    "converted": { "value": 13200, "currency": "EUR" },
    "rate": 0.88
  },
  "information": { },
  "intermediation": {
    "timestamp": "2026-03-15T08:55:00Z",
    "agent": { "name": "Acme Agency" },
    "client": { "name": "Wei Zhang" }
  },
  "links": [ ]
}
SectionDescription
status.currentThe payment's current status ({ name, timestamp })
status.previousOrdered history of prior status transitions, newest first
amount.originalAmount in the payer's currency
amount.convertedAmount in the recipient's currency
amount.rateExchange rate applied (payer → recipient)
informationDynamic data whose structure is described by a schema
intermediation.agent.nameIntermediating agency
intermediation.client.nameClient whose payment this is

Note the singular keys

The detail uses status and amount (singular), with histories nested under them — status.current / status.previous and amount.original / amount.converted / amount.rate. The list summary uses the same singular keys but exposes only status.name and a flat amount. There is no statuses or amounts key anywhere in the API.

Step 4 — Pagination ​

The payment list is paginated. Navigate pages using standard link relations:

RelationPurpose
nextNext page of results
prevPrevious page of results
firstFirst page
lastLast page

TIP

Not all pagination links are present on every page. next is absent on the last page, prev is absent on the first.

Payment details may include additional links depending on the payment's state:

RelationDescription
monitorTrack the payment's progress in real time
payment-receiptDownload or view the payment receipt
Example: following a monitor link
python
monitor_link = next(
    (l for l in detail["links"] if l["rel"].endswith("monitor")),
    None
)
if monitor_link:
    tracking = requests.get(monitor_link["href"], headers=HEADERS).json()

Flywire Agents API Documentation