instrumentId to identify the asset you wish to access, rather than the text-based ticker symbol (e.g., ‘AAPL’).
To bridge this gap, you must use the Search endpoint to resolve a symbol into its corresponding ID.
The Resolution Process
Resolving a symbol involves sending a specific query to the market data search endpoint and parsing the result to find the matching instrument record.1. Endpoint
Use the Search endpoint to query for the instrument.GET https://public-api.etoro.com/api/v1/market-data/search
2. Query Parameters
While the search endpoint accepts general search text, the most precise way to find a specific ID is to filter by theinternalSymbolFull field.
| Parameter | Value | Description |
|---|---|---|
internalSymbolFull | AAPL | The specific ticker symbol you want to resolve. |
3. Header Requirements
Remember to include your authentication headers with every request.x-api-keyx-user-keyx-request-id
Examples
Best Practices
-
Verify the Match: The search might return partial matches or related assets. Always verify that the
internalSymbolFullproperty of the returned item exactly matches your requested symbol. - Cache your IDs: Instrument IDs are immutable: They never change, even if a company rebrands or changes its ticker symbol. While symbols rarely change, relying on the permanent instrumentId ensures your application remains robust against such events. We strongly recommend fetching these IDs once and caching the mapping (e.g., AAPL -> 1001) locally.