/accounts/{accountId}/risk-statusСнимок риска, который торговый движок хранит для счёта: текущий баланс и эквити, эквити на начало дня и максимальное эквити, счётчик торговых дней, состояние правила согласованности и базовая линия выплат.
- Считывается в реальном времени из шарда, в котором хранится счёт, поэтому открытые позиции уже отражены в эквити.
- Интерактивные сессии получают отдельный бюджет для этого эндпоинта, отличный от других; API-ключ вместо этого ограничен своими собственными лимитами на чтение.
https://api.upscale.tradeПараметры
accountIdstring · uuidобязательноИдентификатор торгового аккаунта. Должен принадлежать вызывающей стороне.
00000000-0000-4000-8000-000000000000Примеры
curl --request GET 'https://api.upscale.trade/accounts/{accountId}/risk-status' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY'const response = await fetch("https://api.upscale.trade/accounts/{accountId}/risk-status", {
method: "GET",
headers: {
"Accept": "application/json",
"Authorization": "Bearer YOUR_API_KEY"
},
});
console.log(response.status, await response.text());import requests
response = requests.request(
"GET",
"https://api.upscale.trade/accounts/{accountId}/risk-status",
headers={"Accept":"application/json","Authorization":"Bearer YOUR_API_KEY"},
timeout=30,
)
print(response.status_code, response.text)Ответы
200Ответapplication/json
accountIdstring · uuidобязательноTrader account the snapshot belongs to.
- pattern
- ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$
00000000-0000-4000-8000-000000000000tradingDaysnumberобязательноNumber of days the account has traded on — counted against the minimum trading days of the challenge.
0currentBalancestring · int32обязательноAccount balance without the unrealised pnl of open positions, fp9 raw.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000currentEquitystring · int32обязательноBalance plus the unrealised pnl of open positions, fp9 raw. This is what drawdown rules are measured against.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000dayStartEquitystring · int32обязательноEquity the current trading day opened at, fp9 raw — the base of the daily drawdown limit.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000maxEquitystring · int32 · nullableобязательноHighest equity the account has ever reached, fp9 raw — the base of the trailing drawdown. Null before the first trade.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000periodStartEquitystring · int32 · nullableобязательноEquity the current withdrawal period opened at, fp9 raw. Null while no period is running.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000maxPeriodDailyEquityDeltastring · int32 · nullableобязательноLargest single-day equity gain inside the current period, fp9 raw — the numerator of the consistency rule. Null while no day has closed in profit.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000maxPeriodDailyEquityDeltaAtstring · date-time · nullableобязательноDay that produced maxPeriodDailyEquityDelta. Null together with it.
2026-05-01T12:30:00.000ZconsistencyRuleAppliesbooleanобязательноWhether the consistency rule is part of the rules of this account in its current phase.
trueconsistencyRuleMetboolean[]обязательноWhether the rule is currently satisfied. Null while the period is not in profit and the ratio cannot be computed.
Элементы массива · boolean
boolean
Посмотреть пример
[
true
]consistencyRuleRatiostring · int32 · nullableобязательноShare of the period profit made on its best day, fp9 raw fraction. Null together with consistencyRuleMet.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000consistencyRuleLimitstring · int32обязательноLargest share of period profit one day may account for, fp9 raw fraction (300000000 = 30%). A ratio above it fails the rule.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000payoutBaselineBalancestring · int32обязательноBalance the next payout is measured from, fp9 raw. Equal to the initial account size until the first payout moves it.
- pattern
- ^(?:-?[1-9][0-9]*|0)$
1000000000isPayoutBaselineRequirementMetbooleanобязательноWhether equity is above payoutBaselineBalance — the condition for being eligible to request a payout.
true{
"accountId": "00000000-0000-4000-8000-000000000000",
"tradingDays": 0,
"currentBalance": "1000000000",
"currentEquity": "1000000000",
"dayStartEquity": "1000000000",
"maxEquity": "1000000000",
"periodStartEquity": "1000000000",
"maxPeriodDailyEquityDelta": "1000000000",
"maxPeriodDailyEquityDeltaAt": "2026-05-01T12:30:00.000Z",
"consistencyRuleApplies": true,
"consistencyRuleMet": [
true
],
"consistencyRuleRatio": "1000000000",
"consistencyRuleLimit": "1000000000",
"payoutBaselineBalance": "1000000000",
"isPayoutBaselineRequirementMet": true
}Неавторизовано
Аккаунт принадлежит другому пользователю (account_access_denied), или запрос аутентифицирован с помощью API-ключа, тогда как api_trading отключён на аккаунте (api_trading_not_enabled).
Нет аккаунта с этим идентификатором.
Превышен лимит частоты запросов API-ключа (api_key_rate_limit_exceeded). Retry-After указывает, когда вернуться; тело содержит бакет (read / write), окно, которое сработало, его лимит и retryAt.