Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/pacifica-fi/docs-migrate/llms.txt

Use this file to discover all available pages before exploring further.

Vaults are managed trading pools on Pacifica where a designated manager trades on behalf of limited partners (LPs). Depositors receive vault shares representing their proportional ownership; the manager earns a performance fee defined at vault creation. The REST API path uses the internal namespace /api/v1/lake/*.
All POST endpoints on this page require request signing. See the Authentication guide for details.

POST /api/v1/lake/create — Create Vault

Creates a new vault and returns the generated vault account address. Optionally seeds the vault with an initial deposit and claims a referral code in the same request.
This endpoint requires a signed request. Set the type header field to "create_lake". See Authentication.manager_loss_share is currently disabled; omit it or pass "0".
Request
account
string
required
Creator wallet address.
signature
string
required
Signature over the sorted request payload.
timestamp
integer
required
Current timestamp in milliseconds.
manager
string
Manager wallet address. Omit to create a vault with no initial manager.
nickname
string
Display name for the vault.
deposit_cap
decimal string
Maximum LP balance accepted by the vault, e.g. "1000000".
manager_profit_share
decimal string
Performance fee fraction in [0, 1], e.g. "0.20" for 20%.
manager_loss_share
decimal string
Temporarily disabled; only "0" is accepted.
deposit_min_duration_ms
integer
Minimum deposit lock duration in milliseconds.
manager_min_balance_portion
decimal string
Manager balance ratio required to claim or re-enable the vault.
manager_liquidation_balance_portion
decimal string
Manager balance ratio that triggers a trading halt and liquidation.
initial_deposit
decimal string
Seed deposit from the creator in the same request.
withdraw_window_s
integer
Withdrawal cycle period in seconds.
withdraw_duration_s
integer
Open withdrawal time per cycle in seconds.
referral_code
string
Referral code to claim for the new vault.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "nickname": "BTC Basis Vault",
  "manager_profit_share": "0.20",
  "deposit_cap": "1000000",
  "deposit_min_duration_ms": 86400000,
  "manager_min_balance_portion": "0.10",
  "manager_liquidation_balance_portion": "0.05",
  "initial_deposit": "1000.00",
  "withdraw_window_s": 2592000,
  "withdraw_duration_s": 259200,
  "referral_code": "testcode",
  "expiry_window": 30000
}
Response
{
  "success": true,
  "data": {
    "lake_address": "AbCdEfGh123456789...",
    "referral_claimed": true
  },
  "error": null,
  "code": null
}
lake_address
string
Generated vault account address.
referral_claimed
boolean
Whether the optional referral code was successfully claimed.

POST /api/v1/lake/deposit — Deposit to Vault

Deposits USDC from an account into a vault and mints vault shares to the depositor. Deposits are idempotent when an idempotency_key is supplied.
This endpoint requires a signed request. Set the type header field to "deposit_to_lake". See Authentication.
Request
account
string
required
Depositor wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
amount
decimal string
required
Deposit amount in USDC.
idempotency_key
string
Client-generated UUID to prevent duplicate deposits.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "amount": "1000.00",
  "idempotency_key": "550e8400-e29b-41d4-a716-446655440000"
}
Response
{
  "success": true,
  "data": {
    "shares_minted": "1000.00"
  },
  "error": null,
  "code": null
}
shares_minted
decimal string
Number of vault shares minted to the depositor.

POST /api/v1/lake/withdraw — Withdraw from Vault

Redeems vault shares and returns the proportional USDC to the depositor. Withdrawals are idempotent when an idempotency_key is supplied.
This endpoint requires a signed request. Set the type header field to "withdraw_from_lake". See Authentication.
Request
account
string
required
Depositor wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
shares
decimal string
required
Number of shares to redeem.
idempotency_key
string
Client-generated UUID to prevent duplicate withdrawals.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "shares": "50.00",
  "idempotency_key": "550e8400-e29b-41d4-a716-446655440000"
}
Response
{
  "success": true,
  "data": {
    "amount_withdrawn": "500.00"
  },
  "error": null,
  "code": null
}
amount_withdrawn
decimal string
USDC amount returned to the depositor.

POST /api/v1/lake/claim_manager — Claim Vault Manager

Claims the manager role on a fresh vault that was created without a designated manager.
This endpoint requires a signed request. Set the type header field to "claim_lake_manager". See Authentication.
Request
account
string
required
Claimer wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
deposit_amount
decimal string
required
Manager’s initial deposit amount.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "deposit_amount": "1000.00"
}
Response
{
  "success": true,
  "data": {
    "shares_minted": "1000.00"
  },
  "error": null,
  "code": null
}
shares_minted
decimal string
Number of manager shares minted to the claimer.

POST /api/v1/lake/claim_referral_code — Claim Vault Referral Code

Claims a referral code for an existing vault. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "claim_lake_referral". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
code
string
required
Referral code to claim.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "code": "testcode"
}
Response
{
  "success": true,
  "data": {
    "success": true
  },
  "error": null,
  "code": null
}

POST /api/v1/lake/update_deposit_cap — Update Vault Deposit Cap

Updates or removes the LP deposit cap for a vault. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "update_lake_deposit_cap". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
deposit_cap
decimal string or null
New LP deposit cap. Set to null to remove the cap entirely.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "deposit_cap": "2000000"
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/add_whitelist — Add Vault Whitelist

Adds symbols to the vault’s tradable whitelist. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "add_lake_whitelist". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols to add, e.g. ["BTC", "ETH"].
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"]
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/remove_whitelist — Remove Vault Whitelist

Removes symbols from the vault’s tradable whitelist. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "remove_lake_whitelist". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols to remove from the whitelist.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"]
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/add_blacklist — Add Vault Blacklist

Adds symbols to the vault’s blocked blacklist. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "add_lake_blacklist". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols to block.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"]
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/remove_blacklist — Remove Vault Blacklist

Removes symbols from the vault’s blocked blacklist. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "remove_lake_blacklist". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols to remove from the blacklist.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"]
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/add_max_leverage — Add Vault Max Leverage

Sets per-symbol maximum leverage caps for the vault. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "add_lake_max_leverage". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols that should receive the leverage cap.
max_leverage
decimal string
required
Maximum leverage to apply to every listed symbol.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"],
  "max_leverage": "10"
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

POST /api/v1/lake/remove_max_leverage — Remove Vault Max Leverage

Removes per-symbol maximum leverage caps from the vault. Only the vault creator can call this endpoint.
This endpoint requires a signed request. Set the type header field to "remove_lake_max_leverage". See Authentication.
Request
account
string
required
Creator wallet address.
signature
string
required
Cryptographic signature.
timestamp
integer
required
Current timestamp in milliseconds.
lake
string
required
Vault address.
symbols
string[]
required
Symbols whose custom leverage cap should be removed.
agent_wallet
string
Agent wallet address.
expiry_window
integer
Signature expiry in milliseconds.
{
  "account": "42trU9A5...",
  "signature": "5J3mBbAH...",
  "timestamp": 1716200000000,
  "lake": "AbCdEfGh123456789...",
  "symbols": ["BTC", "ETH"]
}
Response
{
  "success": true,
  "data": { "success": true },
  "error": null,
  "code": null
}

GET /api/v1/lake/list — List Vaults

Returns all vaults ordered by creation time descending. When account is provided, the response includes that account’s share balance in each vault. Request
account
string
Account address whose share balance should be included in the response.
curl "https://api.pacifica.fi/api/v1/lake/list?account=42trU9A5..."
Response
{
  "success": true,
  "data": {
    "lakes": [
      {
        "address": "AbCdEfGh123456789...",
        "creator": "42trU9A5...",
        "manager": "8zFqj1Kp...",
        "nickname": "BTC Basis Vault",
        "lp_shares": "900000.00",
        "manager_shares": "100000.00",
        "lp_balance": "910000.00",
        "manager_balance": "115000.00",
        "last_checked_equity": "1025000.00",
        "high_watermark": "1025000.00",
        "created_at": 1700000000000,
        "referrer": "7xyReferrer...",
        "user_share": "500.00",
        "config": {
          "deposit_cap": "1000000.00",
          "manager_profit_share": "0.20",
          "manager_loss_share": "0",
          "deposit_min_duration_ms": 86400000,
          "manager_min_balance_portion": "0.10",
          "manager_liquidation_balance_portion": "0.05",
          "withdraw_window_s": 2592000,
          "withdraw_duration_s": 259200
        }
      }
    ]
  },
  "error": null,
  "code": null
}
lakes
array
List of vault objects.

Build docs developers (and LLMs) love