API reference
Links
Send USDF by link.
POST/
Creates a claimable USDF link.
Auth: Session, not an API key: Authorization: Bearer <session token>. See Sign in.
| Name | Type | Required | Description |
|---|---|---|---|
units | string or integer | Yes | How much, in USDF base units. |
memo | string | No | A note for the recipient. |
expires_ | integer | No | When an unclaimed link returns to you. |
to_ | string | No | An X handle: only the X account behind it can claim. |
POST /v1/links
curl
curl -X POST https://api.usdf.fi/v1/links \ -H "Authorization: Bearer $SESSION" \ -H "Content-Type: application/json" \ -d '{"units": "<units>", "memo": "Thanks"}'
GET/
A link's amount and status.
Auth: None
| Name | Type | Required | Description |
|---|---|---|---|
token | string | Yes | Path. The link token. |
GET /v1/links/{token}
curl
curl https://api.usdf.fi/v1/links/{token}POST/
Claims the link's USDF.
Auth: Session, not an API key: Authorization: Bearer <session token>. See Sign in.
| Name | Type | Required | Description |
|---|---|---|---|
token | string | Yes | Path. The link token. |
identity_ | string | No | The sign-in's identity token, for a link to an X handle. |
POST /v1/links/{token}/claim
curl
curl -X POST https://api.usdf.fi/v1/links/{token}/claim \
-H "Authorization: Bearer $SESSION"POST/
Cancels an unclaimed link.
Auth: Session, not an API key: Authorization: Bearer <session token>. See Sign in.
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Path. The link id. |
POST /v1/links/{id}/cancel
curl
curl -X POST https://api.usdf.fi/v1/links/{id}/cancel \
-H "Authorization: Bearer $SESSION"Foundry documentation