curl --request POST \
--url https://token-vesting.snek.fun/withdraw \
--header 'Content-Type: application/json' \
--data '{
"id": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef:0",
"address": "addr1..."
}'
{
"cbor": "84a500..."
}
Transaction Builder API
Withdraw vesting lock
Build a transaction that unlocks and withdraws vested tokens
POST
/
withdraw
curl --request POST \
--url https://token-vesting.snek.fun/withdraw \
--header 'Content-Type: application/json' \
--data '{
"id": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef:0",
"address": "addr1..."
}'
{
"cbor": "84a500..."
}
Builds a transaction that unlocks and withdraws tokens from a vesting lock.
Auth: Public
Request body
Response
curl --request POST \
--url https://token-vesting.snek.fun/withdraw \
--header 'Content-Type: application/json' \
--data '{
"id": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef:0",
"address": "addr1..."
}'
{
"cbor": "84a500..."
}
Error response
Possible errors:400 INVALID_PARAMS— one or more required fields are missing or have the wrong type.400 UTxO_SPENT— the vesting UTxO has already been spent.400 INVALID_DATUM— the referenced UTxO has no inline datum.400 LOCK_NOT_EXPIRED— the vesting lock is still active and cannot be withdrawn yet.403 NOT_OWNER—addressdoes not match the lock owner.404 UTxO_NOT_FOUND— the referenced vesting UTxO does not exist.500 SERVER_ERROR— unexpected server-side failure.
{
"cause": "LOCK_NOT_EXPIRED",
"message": "Lock is still active. Unlocks at 2026-12-31T00:00:00.000Z"
}
Was this page helpful?