/v1/profit-loss
Trade profit/loss
Provalo dal vivo
10 chiamate gratuite al giorno — senza registrazione, senza chiave API. Passa dal gateway oanor.
Funziona. Prendi una chiave API e usala nel tuo progetto.
Ottieni una chiave APIFrammenti di codice
curl "https://api.oanor.com/fxcalculator-api/v1/profit-loss" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/fxcalculator-api/v1/profit-loss", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/fxcalculator-api/v1/profit-loss");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/fxcalculator-api/v1/profit-loss",
headers={"x-oanor-key": "oanor_test_..."}
)
Risposta di esempio
Una risposta reale di questo endpoint, acquisita dall'ultimo health check.
{
"data": {
"exit": 1.09,
"pair": "EUR/USD",
"pips": 50,
"entry": 1.085,
"source": "ECB (Frankfurter)",
"lot_size": 1,
"direction": "buy",
"rates_date": "2026-06-10",
"profit_loss": 500,
"account_currency": "USD",
"profit_loss_quote": 500
},
"meta": {
"timestamp": "2026-06-10T22:56:38.571Z",
"request_id": "30744f47-f893-494c-89ad-eb70176b62ed"
},
"status": "ok",
"message": "Profit/loss computed",
"success": true
}