Get a paper trading portfolio
curl --request GET \
--url https://api.agg.market/apps/{appId}/paper-trading/accounts/{accountId}/portfolio \
--header 'x-app-api-key: <api-key>'{
"account": {
"id": "<string>",
"appId": "<string>",
"name": "<string>",
"externalId": "<string>",
"currency": "<string>",
"startingBalanceRaw": "<string>",
"startingBalance": 123,
"cashBalanceRaw": "<string>",
"cashBalance": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"kycStatus": "verified",
"kycVerified": true,
"createdAt": "<string>",
"updatedAt": "<string>"
},
"cashBalanceRaw": "<string>",
"cashBalance": 123,
"marketValueRaw": "<string>",
"marketValue": 123,
"equityRaw": "<string>",
"equity": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"unrealizedPnlRaw": "<string>",
"unrealizedPnl": 123,
"liquidationValueRaw": "<string>",
"liquidationValue": 123,
"liquidationEquityRaw": "<string>",
"liquidationEquity": 123,
"liquidationPnlRaw": "<string>",
"liquidationPnl": 123,
"positions": [
{
"id": "<string>",
"accountId": "<string>",
"venue": "<string>",
"venueMarketId": "<string>",
"venueMarketOutcomeId": "<string>",
"marketQuestion": "<string>",
"outcomeLabel": "<string>",
"size": 123,
"avgEntryPrice": 123,
"markPrice": 123,
"markTimestamp": 123,
"bestBidPrice": 123,
"bestAskPrice": 123,
"midpoint": 123,
"spread": 123,
"marketValueRaw": "<string>",
"marketValue": 123,
"unrealizedPnlRaw": "<string>",
"unrealizedPnl": 123,
"liquidationPrice": 123,
"liquidationValueRaw": "<string>",
"liquidationValue": 123,
"liquidationPnlRaw": "<string>",
"liquidationPnl": 123,
"liquidityShares": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"createdAt": "<string>",
"updatedAt": "<string>"
}
]
}Execution
Get a paper trading portfolio
GET
/
apps
/
{appId}
/
paper-trading
/
accounts
/
{accountId}
/
portfolio
Get a paper trading portfolio
curl --request GET \
--url https://api.agg.market/apps/{appId}/paper-trading/accounts/{accountId}/portfolio \
--header 'x-app-api-key: <api-key>'{
"account": {
"id": "<string>",
"appId": "<string>",
"name": "<string>",
"externalId": "<string>",
"currency": "<string>",
"startingBalanceRaw": "<string>",
"startingBalance": 123,
"cashBalanceRaw": "<string>",
"cashBalance": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"kycStatus": "verified",
"kycVerified": true,
"createdAt": "<string>",
"updatedAt": "<string>"
},
"cashBalanceRaw": "<string>",
"cashBalance": 123,
"marketValueRaw": "<string>",
"marketValue": 123,
"equityRaw": "<string>",
"equity": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"unrealizedPnlRaw": "<string>",
"unrealizedPnl": 123,
"liquidationValueRaw": "<string>",
"liquidationValue": 123,
"liquidationEquityRaw": "<string>",
"liquidationEquity": 123,
"liquidationPnlRaw": "<string>",
"liquidationPnl": 123,
"positions": [
{
"id": "<string>",
"accountId": "<string>",
"venue": "<string>",
"venueMarketId": "<string>",
"venueMarketOutcomeId": "<string>",
"marketQuestion": "<string>",
"outcomeLabel": "<string>",
"size": 123,
"avgEntryPrice": 123,
"markPrice": 123,
"markTimestamp": 123,
"bestBidPrice": 123,
"bestAskPrice": 123,
"midpoint": 123,
"spread": 123,
"marketValueRaw": "<string>",
"marketValue": 123,
"unrealizedPnlRaw": "<string>",
"unrealizedPnl": 123,
"liquidationPrice": 123,
"liquidationValueRaw": "<string>",
"liquidationValue": 123,
"liquidationPnlRaw": "<string>",
"liquidationPnl": 123,
"liquidityShares": 123,
"realizedPnlRaw": "<string>",
"realizedPnl": 123,
"createdAt": "<string>",
"updatedAt": "<string>"
}
]
}Authorizations
App-scoped API key for programmatic app management.
Response
200
Show child attributes
Show child attributes
Show child attributes
Show child attributes
⌘I