alpacahq / alpacahq/Alpaca-API
Portfolio History equity value sometimes incorrect temporarily
- Langage dominant
- Aucune donnée de langage
- Étoiles
- 173
- Forks
- 17
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
**Describe the bug**
At 8 PM ET every trading day, the current equity value is supposed to be added to the day-level Portfolio History. A new timestamp and value is indeed added but the value is a duplicate of the previous value, not the current equity value. At some later point, the value gets updated to the correct one but it is incorrect for some amount of time.
**To Reproduce**
Steps to reproduce the behavior:
1. `https://paper-api.alpaca.markets/v2/account/portfolio/history?period=3D&timeframe=1D&intraday_reporting=extended_hours&pnl_reset=per_day`
2. Wait until after 8 PM ET.
3. Make the same request as in step 1.
**Expected behavior**
Comparing the before and after responses, there should be a new timestamp and value. The value should be different than the previous value, not the same.
**Screenshots**
At the time of this bug report, it is 2:22 AM ET. The API returns the following:
```json
{
"timestamp": [
1738717200,
1738803600,
1738890000
],
"equity": [
505508.7,
504599.02,
504599.02
],
"profit_loss": [
-1140.52,
-909.68,
0
],
"profit_loss_pct": [
-0.0023,
-0.0018,
0
],
"base_value": 506649.22,
"base_value_asof": "2025-02-03",
"timeframe": "1D"
}
```
Notice how the last two equity values are the same.
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Évaluation
Cette issue n'a pas encore été évaluée.