Build a deposit transaction
Returns the transactions the LP signs and sends, in order, to deposit into an asset vault: a token approval when one is needed, then the deposit.
Authorization
ApiKeyAuth Your API key. Authorizing a swap or opening a market takes a key issued to your integration, and the shared key the docs fill in reads and quotes only.
In: header
Path Parameters
The chain's numeric id, for example 8453 for Base. GET /api/vaults/chains lists them.
The asset vault's token, as a contract address. A symbol is refused.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/api/vaults/1/string/prepare-deposit" \ -H "Content-Type: application/json" \ -d '{ "amount": "250000000", "owner": "0x1111111111111111111111111111111111111111" }'{ "vault": "0xb367A4306087d3981B38C032464cD7E3A7a03A4E", "calls": [ { "to": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", "data": "0x095ea7b3000000000000000000000000b367a4306087d3981b38c032464cd7e3a7a03a4e000000000000000000000000000000000000000000000000000000000ee6b280", "value": "0", "description": "Approve the vault to pull 250000000 of the asset" }, { "to": "0xb367A4306087d3981B38C032464cD7E3A7a03A4E", "data": "0x6e553f65000000000000000000000000000000000000000000000000000000000ee6b2800000000000000000000000001111111111111111111111111111111111111111", "value": "0", "description": "Deposit 250000000 into the vault for 0x1111111111111111111111111111111111111111" } ], "requiresApproval": true, "sender": "0x1111111111111111111111111111111111111111", "receiver": "0x1111111111111111111111111111111111111111"}{ "error": "string", "code": "string", "message": "string", "details": {}, "requestId": "string"}{ "error": "string", "code": "string", "message": "string", "details": {}, "requestId": "string"}Build a deposit, withdrawal or backing transaction on Solana
Builds a deposit, a withdrawal, a backing (`commit`), its end (`uncommit`) or a token account, for the owner's wallet to sign. The wallet pays the network fee and any rent.
Build a withdrawal transaction
Returns the transaction the LP signs and sends to withdraw free principal from an asset vault.