Browse documentation

RESOURCES

Payment Links

One-off checkout links a debtor can pay. amountCents is the base debt amount; the platform processing fee is added on top by policy.

POST/payment-linkspayments:writeIdempotency-Key required

Create a payment link. Same-key retries converge on ONE provider session; uncertain provider outcomes hold the key (409) rather than minting a second payable link.

Request body

{
  "caseId": "c3d4…",
  "amountCents": 5000
}

Response

{
  "object": "payment_link",
  "id": "cs_…",
  "url": "https://checkout…",
  "amount_cents": "5200",
  "status": "open"
}

Example

curl https://debt.hlhunt.org/api/v1/payment-links \
  -H "Authorization: Bearer hlh_live_..." \
  -X POST \
  -H "Idempotency-Key: my-unique-key" \
  -H "Content-Type: application/json" \
  -d '{ "caseId": "c3d4…", "amountCents": 5000 }'
GET/payment-links/{id}payments:read

Retrieve a payment link by its checkout session id (cs_…).

Response

{
  "object": "payment_link",
  "id": "cs_…",
  "status": "complete",
  "url": "https://…"
}

Example

curl https://debt.hlhunt.org/api/v1/payment-links/ID \
  -H "Authorization: Bearer hlh_live_..."