Using the isin
, mic
and type
query parameter, you have the option to request multiple instruments, trading venues and/or types.
Depending on the client you are using, you could do so by definining multiple ISINs/MICs/Types in the query parameters
like isin=US88160R1014&isin=US19260Q1076
or by simply using commas, like isin=US88160R1014,US19260Q1076
.
Instruments & Trading Venues
This page gives you a detailed description of all endpoints related to Instruments and Trading Venues. These endpoints are part of the Market Data API, therefore use the following base URL for your request:
Finding an Instrument
The instrument endpoint allows to search through all offered instruments. Instruments are equities that are tradable on lemon.markets. The instruments endpoint lets you identify relevant instruments that you can then integrate into your brokerage product.
GET /instruments
This endpoint returns a list of instruments, based on the search criteria or filter you provided in your query parameters. To use the endpoint, use the following request URL:
Request
To retrieve a list of instruments, specify your request as follows:
Request Headers
Set your Authorization header in the format "Authorization: Bearer YOUR-API-KEY"
(see the example in the code snippet on the right)
Perform a conditional request. Pass the most recent value of the Last-Modified
response header.
If the data has changed since your most recent request, you'll receive a response with HTTP status 200 (OK
),
if the data has not changed, you'll receive a response with HTTP status 304 (Not Modified
) and no response body.
Query Parameters
Specify Multiple ISINs, MICs and Types in a Single Request
Use this query parameter to specify the Instrument you are interested in through its International Securities Identification Number. You can also specify multiple ISINs.
To specify multiple ISINs, either define multiple Query Parameters like ?isin=US88160R1014&isin=US19260Q1076 or simply use commas, like isin=US88160R1014,US19260Q1076.
Use this query parameter to search for Name/Title, ISIN, WKN or symbol. You can also perform a partial search by only specifiying the first 4 symbols.
Use this query parameter to specify the type of instrument you want to filter for. You can use any of these (or a comma-separated list of the following):
bond
: A company or government issued bond. Not tradable using lemon.markets!fund
: A share in a mututal fund. Not tradable using lemon.markets!etc
, Exchange Traded Commodity: These represent underlying natual resources, e.g. Gold.etf
, Exchange Traded Funds: Funds that can be bought directly using an exchange, without fees charged by the emitting party.etn
, Exchange Traded Note: Financial products that often track underlying assets not covered by ETFs or ETCs. Some ETNs track crypto currencies.stock
: A share of ownership in a public company.
Other Query Parameters
Enter a Market Identifier Code (MIC) in there. We currently offer data from the Munich Stock Exchange (XMUN).
Define a three letter ISO currency code to see instruments traded in a specific currency, like "EUR" or "USD"
Filter for tradable or non-tradable Instruments with true or false
This parameter is required to influence the Pagination. Use it to define the limit of displayed results on one page.
The default value is 100, the maximum number is 250.
This parameter is required to influence the Pagination. Use it to define the specific results page you wish to display.
How do we determine whether an Instrument is tradable?
Twice a day, we check with Gettex whether an Instrument is tradable - once right before the exchange opens and around 3:35pm when NASDAQ opens. Based on that check, we update our Instruments list.
Response
Response Headers
The time stamp of the most recent modification to the list of instruments. You can use this value in combination with
the request header If-Modified-Since
to perform conditional requests and only update your list of instruments when
the list on the server side changed.
Response Parameters
This is the International Securities Identification Number (ISIN) of the instrument
This is the German Securities Identification Number of instrument
This is the Instrument name
This is the Instrument Title
This is the Symbol of the instrument at the trading venue
The type of the instrument. See the query parameter for possible values.
Venue Attributes
This is the name of the trading venue
This is the title of the trading venue
This is the Market Identifier Code of the trading venue
This indicates if the trading venue is currently open
This indicates if the instrument is tradable at the trading venue
This indicates in which currency the instrument is traded
Pagination
Pagination attribute: this is a URL of the previous page
Pagination attribute: this is a URL of the next page
Pagination attribute: this is the total number of results
Pagination attribute: this is the current page number
Pagination attribute: this is the total number of pages
Other Attributes
Timestamp of your API request
Check our Error Handling Page for specific information on error types.
1import requests
2import json
3
4market_data_key = 'YOUR-MARKET-DATA-KEY'
5request = requests.get("https://data.lemon.markets/v1/instruments",
6 headers={"Authorization": f"Bearer {market_data_key}"})
7print(request.json())
1{
2 "time": "2022-02-14T20:44:03.759+00:00",
3 "results":
4 [
5 {
6 "isin": "US19260Q1076",
7 "wkn": "A2QP7J",
8 "name": "COINBASE GLB.CL.A -,00001",
9 "title": "COINBASE GLOBAL INC",
10 "symbol": "1QZ",
11 "type": "stock",
12 "venues":
13 [
14 {
15 "name": "Börse München - Gettex",
16 "title": "Gettex",
17 "mic": "XMUN",
18 "is_open": true,
19 "tradable": true,
20 "currency": "EUR"
21 }
22 ]
23 }
24 ],
25 "previous": "https://data.lemon.markets/v1/instruments?limit=100&page=1",
26 "next": "https://data.lemon.markets/v1/instruments?limit=100&page=3",
27 "total": 26283,
28 "page": 2,
29 "pages": 263
30}
31
Trading Venues
The Market Data API structure allows to specify from which Trading Venue you want to receive your data.
We currently support the connection to Gettex by the Munich Stock Exchange (XMUN
).
GET /venues
You can access everything related to Trading Venues by using the following request URL:
Request
Specify your request as follows:
Header Parameters
Set your Authorization header in the format "Authorization: Bearer YOUR-API-KEY"
(see the example in the code snippet on the right)
Query Parameters
Enter a Market Identifier Code (MIC) in there. We currently offer data from the Munich Stock Exchange (XMUN).
This parameter is required to influence the Pagination. Use it to define the limit of displayed results on one page.
The default value is 100, the maximum number is 250.
This parameter is required to influence the Pagination. Use it to define the specific results page you wish to display.
Response
Response Parameters
This is the Full Name of the Trading Venue
This is the Short Title of the Trading Venue
This is the Market Identifier Code (MIC) of the Trading Venue
This indicates if the Trading Venue is currently open
Opening Hours
This is the time the Trading Venue opens
This is the time the Trading Venue closes
This is the timezone the Opening Hours are returned in
Pagination
Pagination attribute: this is a URL of the previous page
Pagination attribute: this is a URL of the next page
Pagination attribute: this is the total number of results
Pagination attribute: this is the current page number
Pagination attribute: this is the total number of pages
Other Attributes
Timestamp of your API request
This is a list of days when Trading Venue is open
Check our Error Handling Page for specific information on error types.
1import requests
2import json
3
4market_data_key = 'YOUR-MARKET-DATA-KEY'
5request = requests.get("https://data.lemon.markets/v1/venues",
6 headers={"Authorization": f"Bearer {market_data_key}"})
7print(request.json())
1{
2 "time": "2022-02-14T20:44:03.759+00:00",
3 "results":
4 [
5 {
6 "name": "Börse München - Gettex",
7 "title": "Gettex",
8 "mic": "XMUN",
9 "is_open": true,
10 "opening_hours": {
11 "start": "08:00",
12 "end": "22:00",
13 "timezone": "Europe/Berlin"
14 },
15 "opening_days": [
16 "2021-12-06",
17 "2021-12-07",
18 "2021-12-08",
19 ...
20 ]
21 }
22 ],
23 "previous": "https://data.lemon.markets/v1/venues?limit=1&&page=1",
24 "next": "https://data.lemon.markets/v1/venues?limit=1&&page=3",
25 "total": 3,
26 "page": 2,
27 "pages": 3
28}
29