Indexes
Retrieve market indexes (S&P 500, IBEX 35, etc.) and their constituent assets.
GET
/api/v1/market-data/indexesReturns all available market indexes with their asset counts.
Response
200 OKGET/api/v1/market-data/indexes
curl -X GET "https://api.gilito.ai/api/v1/market-data/indexes" \
-H "Authorization: Bearer YOUR_API_KEY"Try It
Example Response
{
"data": [
{
"id": "i1j2k3l4-...",
"symbol": "SPX",
"name": "S&P 500",
"description": "Standard & Poor's 500 Index",
"assetCount": 503
},
...
]
}GET
/api/v1/market-data/indexes/:idReturns a single index by its ID.
Path Parameters
idstring (UUID)requiredThe index ID.
Response
200 OKGET/api/v1/market-data/indexes/:id
curl -X GET "https://api.gilito.ai/api/v1/market-data/indexes/{id}" \
-H "Authorization: Bearer YOUR_API_KEY"Try It
Example Response
{
"data": {
"id": "i1j2k3l4-...",
"symbol": "SPX",
"name": "S&P 500",
"description": "Standard & Poor's 500 Index",
"assetCount": 503
}
}GET
/api/v1/market-data/indexes/symbol/:symbolLook up an index by its symbol.
Path Parameters
symbolstringrequiredThe index symbol (e.g., SPX, IBEX).
Response
200 OKGET/api/v1/market-data/indexes/symbol/:symbol
curl -X GET "https://api.gilito.ai/api/v1/market-data/indexes/symbol/{symbol}" \
-H "Authorization: Bearer YOUR_API_KEY"Try It
Example Response
{
"data": {
"id": "i1j2k3l4-...",
"symbol": "SPX",
"name": "S&P 500",
"description": "Standard & Poor's 500 Index"
}
}GET
/api/v1/market-data/indexes/:id/assetsReturns all assets that are constituents of a given index.
Path Parameters
idstring (UUID)requiredThe index ID.
Response
200 OKGET/api/v1/market-data/indexes/:id/assets
curl -X GET "https://api.gilito.ai/api/v1/market-data/indexes/{id}/assets" \
-H "Authorization: Bearer YOUR_API_KEY"Try It
Example Response
{
"data": [
{
"id": "a1b2c3d4-...",
"symbol": "AAPL",
"name": "Apple Inc.",
"type": "stock",
"currency": "USD",
"isActive": true
},
...
]
}