Get Instrument
curl --request GET \
--url https://api.{your-broker}.slate-labs.com/instruments/{symbol}import requests
url = "https://api.{your-broker}.slate-labs.com/instruments/{symbol}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.{your-broker}.slate-labs.com/instruments/{symbol}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{your-broker}.slate-labs.com/instruments/{symbol}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.{your-broker}.slate-labs.com/instruments/{symbol}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.{your-broker}.slate-labs.com/instruments/{symbol}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.{your-broker}.slate-labs.com/instruments/{symbol}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"symbol": "<string>",
"display_name": "<string>",
"category": "<string>",
"base_currency": "<string>",
"quote_currency": "<string>",
"unit_currency": "USD",
"digits": 5,
"pip_size": 123,
"contract_size": 100000,
"min_lot": 0.01,
"max_lot": 100,
"lot_step": 0.01,
"margin_rate": 123,
"spread": 0,
"swap_type": "pips",
"swap_long": 0,
"swap_short": 0,
"stale_threshold_ms": 123,
"is_active": true,
"is_enabled": true,
"asset_class": "other",
"exchange": "<string>",
"provider": "<string>",
"provider_symbol": "<string>",
"last_bid": 123,
"last_ask": 123,
"last_tick_at": "2023-11-07T05:31:56Z",
"logo_base_url": "<string>",
"logo_quote_url": "<string>",
"localized_description": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Instruments & Groups
Get Instrument
GET
/
instruments
/
{symbol}
Get Instrument
curl --request GET \
--url https://api.{your-broker}.slate-labs.com/instruments/{symbol}import requests
url = "https://api.{your-broker}.slate-labs.com/instruments/{symbol}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.{your-broker}.slate-labs.com/instruments/{symbol}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{your-broker}.slate-labs.com/instruments/{symbol}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.{your-broker}.slate-labs.com/instruments/{symbol}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.{your-broker}.slate-labs.com/instruments/{symbol}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.{your-broker}.slate-labs.com/instruments/{symbol}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"symbol": "<string>",
"display_name": "<string>",
"category": "<string>",
"base_currency": "<string>",
"quote_currency": "<string>",
"unit_currency": "USD",
"digits": 5,
"pip_size": 123,
"contract_size": 100000,
"min_lot": 0.01,
"max_lot": 100,
"lot_step": 0.01,
"margin_rate": 123,
"spread": 0,
"swap_type": "pips",
"swap_long": 0,
"swap_short": 0,
"stale_threshold_ms": 123,
"is_active": true,
"is_enabled": true,
"asset_class": "other",
"exchange": "<string>",
"provider": "<string>",
"provider_symbol": "<string>",
"last_bid": 123,
"last_ask": 123,
"last_tick_at": "2023-11-07T05:31:56Z",
"logo_base_url": "<string>",
"logo_quote_url": "<string>",
"localized_description": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Path Parameters
Response
Successful Response