Wallet

Create a withdrawal intent

Validates and persists a desired withdrawal (WITHDRAW_SOL / WITHDRAW_TOKEN) for the authenticated PID's smart account. Policy: account + registered passkey required, amount > 0, valid destination, destination != the smart account. The intent is single-use and expires (PRD_v4 §22) — reusing or exceeding it is rejected.

POST
/wallet/intents

Validates and persists a desired withdrawal (WITHDRAW_SOL / WITHDRAW_TOKEN) for the authenticated PID's smart account. Policy: account + registered passkey required, amount > 0, valid destination, destination != the smart account. The intent is single-use and expires (PRD_v4 §22) — reusing or exceeding it is rejected.

Authorization

cookieAuth
pid_access<token>

JWT access token set by /auth/google/callback or /auth/refresh

In: cookie

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/wallet/intents" \  -H "Content-Type: application/json" \  -d '{    "type": "WITHDRAW_SOL",    "payload": {      "amount": "5000000"    }  }'
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "type": "WITHDRAW_SOL",  "payload": {},  "status": "pending",  "expiresAt": "2019-08-24T14:15:22Z",  "createdAt": "2019-08-24T14:15:22Z"}