Wallet Infrastructure
Wallet Infrastructure
Treasury

Prepare allowance setup

POST
/v1/limits/setup

Requires scope wallets:write.

Authorization

ApiKey
headerAuthorizationBearer <sk_test_ or sk_live_ key>

Your sk_live_ / sk_test_ API key

Request Body

application/json
  1. body
chain*string
Value in"ethereum""base""arbitrum""polygon""celo""optimism""plasma"
safeAddress?string
Match^0x[0-9a-fA-F]{40}$
passkeyPublicKey*
includeModuleEnable?boolean
Defaultfalse
feeToken?string
Value in"usdt""xaut"
allowances*array<>
Items1 <= items

Response Body

200application/json

A prepared userOp and its hash

TypeScript Definitions

Use the response body type in TypeScript.

data*
status*number
success*boolean
401application/json

The Authorization header is missing, malformed, or the API key is unknown or revoked

TypeScript Definitions

Use the response body type in TypeScript.

data*
status*number
success*boolean
403

forbidden: on-chain limits are a treasury feature — safeAddress is not this tenant's treasury Safe, or the tenant has no treasury

429application/json

The API key exceeded its request budget for the window

TypeScript Definitions

Use the response body type in TypeScript.

data*
status*number
success*boolean

Language

curl -X POST 'https://api.pilot.shiga.io/v1/limits/setup' \  -H 'Authorization: Bearer sk_test_...' \  -H 'Content-Type: application/json' \  -d '{  "chain": "ethereum",  "passkeyPublicKey": {    "x": "string",    "y": "string"  },  "allowances": [    {      "delegate": "string",      "token": "string",      "capBaseUnits": "string",      "windowMinutes": "string"    }  ]}'
Example Response
{  "data": {    "chain": "base",    "safeAddress": "string",    "userOp": {},    "userOpHash": "string"  },  "status": 200,  "success": true}