POST
/
v1
/
portfolio
/
:portfolioId
/
deposit
# Deposit ETH
curl --request POST \
  --url 'https://api.glider.fi/v1/portfolio/port_abc123/deposit' \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: your_api_key_here' \
  --data '{
    "tokenContractAddress": "native",
    "tokenChainId": 8453,
    "tokenAmount": "100000000000000000",
    "userWalletAddress": "0xCustomSenderAddress",
    "simulate": false
  }'

# Deposit USDC
curl --request POST \
  --url 'https://api.glider.fi/v1/portfolio/port_abc123/deposit' \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: your_api_key_here' \
  --data '{
    "tokenContractAddress": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "tokenChainId": 8453,
    "tokenAmount": "1000000",
    "userWalletAddress": "0xCustomSenderAddress",
    "simulate": false
  }'
{
  "success": true,
  "data": {
    "portfolioId": "port_abc123",
    "depositRequest": {
      "vaultAddress": "0xPortfolioVaultAddress",
      "token": "native",
      "amount": "100000000000000000"
    },
    "tx": {
      "to": "0xPortfolioVaultAddress",
      "data": "0x",
      "value": "100000000000000000"
    },
    "chainId": "8453",
    "message": "Deposit transaction data generated successfully"
  },
  "correlationId": "corr_abc123",
  "requestId": "req_xyz789",
  "timestamp": "2023-05-21T13:45:12.345Z"
}

Generates transaction data for depositing assets into a portfolio.

portfolioId
string
required

The unique identifier of the portfolio

tokenContractAddress
string
required

The contract address of the token to deposit, or “native” for ETH

tokenChainId
number
required

The chain ID where the token exists (e.g., 8453 for Base)

tokenAmount
string
required

The amount to deposit in base units (e.g., wei for ETH, without decimals)

userWalletAddress
string

Optional custom sender address (defaults to the portfolio owner address)

simulate
boolean
default:"false"

Whether to perform full transaction simulation and gas estimation

X-API-KEY
string
required

Your API key for authentication

Content-Type
string
default:"application/json"

The format of the request body

# Deposit ETH
curl --request POST \
  --url 'https://api.glider.fi/v1/portfolio/port_abc123/deposit' \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: your_api_key_here' \
  --data '{
    "tokenContractAddress": "native",
    "tokenChainId": 8453,
    "tokenAmount": "100000000000000000",
    "userWalletAddress": "0xCustomSenderAddress",
    "simulate": false
  }'

# Deposit USDC
curl --request POST \
  --url 'https://api.glider.fi/v1/portfolio/port_abc123/deposit' \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: your_api_key_here' \
  --data '{
    "tokenContractAddress": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "tokenChainId": 8453,
    "tokenAmount": "1000000",
    "userWalletAddress": "0xCustomSenderAddress",
    "simulate": false
  }'
{
  "success": true,
  "data": {
    "portfolioId": "port_abc123",
    "depositRequest": {
      "vaultAddress": "0xPortfolioVaultAddress",
      "token": "native",
      "amount": "100000000000000000"
    },
    "tx": {
      "to": "0xPortfolioVaultAddress",
      "data": "0x",
      "value": "100000000000000000"
    },
    "chainId": "8453",
    "message": "Deposit transaction data generated successfully"
  },
  "correlationId": "corr_abc123",
  "requestId": "req_xyz789",
  "timestamp": "2023-05-21T13:45:12.345Z"
}