Available cash represents the funds you have available to open new positions. It is calculated by taking your total credit and subtracting the sum of all pending order amounts.Documentation Index
Fetch the complete documentation index at: https://api-portal.etoro.com/llms.txt
Use this file to discover all available pages before exploring further.
Available cash only refers to your USD balance.
The Calculation Process
Calculating available cash involves fetching your account data and performing a simple subtraction of all pending order amounts from your total credit.1. Endpoints
Use the P&L endpoint to retrieve your account information. Demo Account:GET https://public-api.etoro.com/api/v1/trading/info/demo/pnl
Real Account: GET https://public-api.etoro.com/api/v1/trading/info/real/pnl
2. Header Requirements
Remember to include your authentication headers with every request.x-api-keyx-user-keyx-request-id
3. Calculation Formula
creditis the total credit balance in your accountordersForOpenis an array of pending market orders (filtered to only include manual positions wheremirrorID = 0)ordersis an array of pending Market-if-touched orders (similar to Limit orders)mirrorID = 0indicates a manual position;mirrorID ≠ 0indicates a mirrored (copy) positionamountis the allocated amount for each order
Examples
Example Calculation
If your account has:credit: 1000ordersForOpen: Two manual pending orders withamountvalues of 200 each (wheremirrorID = 0), and one mirrored order withamountof 100 (wheremirrorID ≠ 0)orders: One existing order withamountvalue of 150
mirrorID ≠ 0.
Best Practices
- Check Before Trading: Always verify your available cash before attempting to open new positions to avoid insufficient funds errors.
- Account for Manual Orders Only: Only manual positions (where
mirrorID = 0) fromordersForOpenare included in the calculation. Mirrored (copy) positions are excluded. All items in theordersarray are included regardless ofmirrorID. - Use the Correct Environment: Make sure to use the demo endpoint when testing and the real endpoint for live trading.