The metadata API provides basic meta data for the eToro system. The metadata is comprised of reference tables for all the other end-points in this API
<br>
The API returns a vector of all countries recognized in the system. Each member contains an internal country id, it's name and its abbreviation
<br>
<br>The result is a vector of counties. Each country will have the following members
<br><br>
<table style="width=100%;">
<tr><td style="width:25%;"><b>Country ID</b></td><td style="width:8.3%">integer</td><td>Internal country ID</td></tr>
<tr><td><b>Name</b></td><td>string</td><td>Name of the country</td></tr>
<tr><td><b>Abbreviation</b></td><td>string</td><td>Country two letter abbreviation according to the <a href="https://en.wikipedia.org/wiki/ISO_3166-1">ISO 3166-1 </a>standard</td></tr>
</table>
<br>
[
{
"countryId": 1,
"name": "Afghanistan",
"abbreviation": "AF"
},
{
"countryId": 2,
"name": "Albania",
"abbreviation": "AL"
},
{
"countryId": 3,
"name": "Algeria",
"abbreviation": "DZ"
}
]
The API returns a vector of all the exchanges defined in the system.
<br><br>
<b>Note</b> for the sake of compatibility while retrieving instruments, we will return asset classes (FX/CFD, etc.) as an exchange item.
<br>
<br>
The result is a vector of exchanges. Each exchange will have the following members:
<br><br>
<table style="width: 100%;">
<tr>
<td style="width: 25%;"><b>Exchange ID</b></td>
<td style="width: 8.3%;">integer</td>
<td>The internal exchange ID</td>
</tr>
<tr>
<td><b>Name</b></td>
<td>string</td>
<td>Name of the exchange</td>
</tr>
</table>
<br>
[
{
exchangeId: 1,
name: "FX"
},
{
exchangeId: 5,
name: "NYSE"
},
]
<br>
The API returns a vector of all the stock sectors in the system
<br><br>
<br>The result is a vector of industry sectors. Each item contains the following members:
<br>
<table style="width: 100%;">
<tr><td style="width: 25%;"><b>Sector ID</b></td><td style="width: 8.3%">integer</td><td>Internal Sector ID</td></tr>
<tr><td><b>Name</b></td><td>string</td><td>Name of the sector</td></tr>
</table>
<br>
[
{
sectorId: 1,
name: "Basic Materials"
},
{
sectorId: 2,
name: "Conglomerates"
},
]
<br>
The API returns the asset classes of the system
<br>
<style>
.my-param {
padding-left: 15px;
}
.my-row {
margin-bottom: 15px;
}
</style>
<br>The result is a vector of asset classes. Each item contains the following members<br>
<table style="width: 100%;">
<tr class="my-row"><td class="my-param" style="width: 25%;"><b>Asset Class ID</b></td><td style="width: 8.3%;">integer</td><td>The internal Asset Class ID</td></tr>
<tr class="my-row"><td class="my-param"><b>Name</b></td><td>string</td><td>Name of the asset class</td></tr>
</table>
<br>
[
{
assetClassId: 1,
name: "Forex"
},
{
assetClassId: 2,
name: "Commodity"
}
]
<br>The API returns the instruments which are defined in the system. <br>
Comma separated list of instrument IDs which will be retrieved. If this is omitted all the instruments which are defined in the system will be returned
<style>
.my-row {
height: 2.5em;
}
</style>
<br><br>The API returns an array of instrument details. Each instrument contains the following<br>
<table style="width: 100%;">
<tr class="my-row"><td style="width:25%;"><b>Instrument ID</b></td><td style="width: 8.3%">integer</td><td>Internal Instrument ID</td></tr>
<tr class="my-row"><td><b>Name</b></td><td>string</td><td>The displayed name of the instrument</td></tr>
<tr class="my-row"><td><b>Asset Class ID</b></td><td>integer</td><td>The internal asset class ID. For the full list of the asset classes, see the <a href="/docs/services/5784e8446361c811ccfdf536/operations/5784f5076361c811ccfdf53a">Asset Classes</a> API</td></tr>
<tr class="my-row"><td><b>Exchange ID</b></td><td>integer</td><td>The internal exchange ID. For the full list of exchanges, see the <a href="/docs/services/5784e8446361c811ccfdf536/operations/5784ec636361c811ccfdf538">Exchanges</a> API</td></tr>
<tr class="my-row"><td><b>Sector ID</b></td><td>integer</td><td>The internal sector ID. For the full list of sectors, see the
<a href="/docs/services/5784e8446361c811ccfdf536/operations/5784f0c26361c811ccfdf539">Sectors</a> API</td></tr>
<tr class="my-row"><td><b>Ticker</b></td><td>string</td><td>The stock ticker in the exchange</td></tr>
<tr class="my-row"><td><b>Precision</b></td><td>integer</td><td>The number of decimal digits when presenting the price</td></tr>
<tr class="my-row"><td><b>Media</b></td><td>array</td><td><ul><li>Width - width of the image</li><li>Height - height of the image</li><li>URI - of the image</li></ul></td></tr>
</table>
<br>
[
{
instrumentId: 1001,
name: "Apple",
assetClassId: 5,
exchangeId: 4,
sectorId: 3,
ticker: "AAPL",
percision: 2,
media: [
{
width: 35,
height: 35,
uri: "https://etoro-cdn.etorostatic.com/market-avatars/aapl/35x35.png"
},
{
width: 50,
height: 50,
uri: "https://etoro-cdn.etorostatic.com/market-avatars/aapl/50x50.png"
}
]]
The API returns the predefined periods used for aggregate data
<style>
.my-row {
height: 2.5em;
}
</style>
<br>The API returns an array of periods. Each period contains the following<br>
<table style="width: 100%;">
<tr class="my-row"><td style="width: 25%;"><b>Period</b></td><td style="width: 8.3%;">string</td><td>The name of the period</td></tr>
<tr class="my-row"><td><b>Minimum Date</b></td><td>datetime</td><td>The starting date of this period</td></tr>
</table>
<br>
[
{
period: "CurrMonth",
minDate: "2016-07-01T00:00:00Z"
},
{
period: "CurrQuarter",
minDate: "2016-07-01T00:00:00Z"
}
]
The API returns the intervals in which you may retrieve historical price candles<br>
<style>
.my-row {
height: 2.5em;
}
</style>
<br>The API returns an array of candle periods. Each period contains the following elements<br>
<table style="width: 100%;">
<tr class="my-row"><td style="width: 25%;"><b>Candle Period ID</b></td><td style="width: 8.3%">integer</td><td>The internal ID of the period</td></tr>
<tr class="my-row"><td><b>Name</b></td><td>string</td><td>The name of this period</td></tr>
</table>
<br>
[
{
candlePeriodId: 1,
name: "OneMinute"
},
{
candlePeriodId: 2,
name: "FiveMinutes"
}
]