Get target compliance
curl --request GET \
--url https://api.glassmarkets.io/v2/organizations/targets/compliance/ \
--header 'Authorization: <api-key>'import requests
url = "https://api.glassmarkets.io/v2/organizations/targets/compliance/"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.glassmarkets.io/v2/organizations/targets/compliance/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"time_start": "2023-11-07T05:31:56Z",
"time_end": "2023-11-07T05:31:56Z",
"interval": "1m",
"targets": [
{
"id": 123,
"type": "gb",
"organization": {
"slug": "<string>",
"name": "<string>"
},
"asset": "<string>",
"exchange": "<string>",
"pair": "<string>",
"metric": "<string>",
"threshold": 123,
"effective_threshold": 123,
"direction": "<string>",
"active": true,
"scaling": {
"mode": "legacy",
"enabled": true,
"source": "asset_twap_24h",
"reference_price": 123,
"current_price": 123,
"factor": 123
},
"compliance": {
"observed": 1,
"passing": 1,
"percentage": 123
},
"latest": {
"value": 123,
"timestamp": "2023-11-07T05:31:56Z",
"source": "trusted",
"passed": true
},
"buckets": [
{
"timestamp": "2023-11-07T05:31:56Z",
"value": 123,
"source": "trusted",
"passed": true
}
],
"market_hours": "market-hours"
}
]
}Targets
Get target compliance
Evaluates the mm targets you can see per bucket. passed says whether the bucket value met the target’s effective threshold; trusted values are used where they exist, reported values otherwise. Intervals below a day need a range of one day or less. passed is null for volume targets below a daily interval, and uptime targets only have daily values.
Get target compliance
curl --request GET \
--url https://api.glassmarkets.io/v2/organizations/targets/compliance/ \
--header 'Authorization: <api-key>'import requests
url = "https://api.glassmarkets.io/v2/organizations/targets/compliance/"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.glassmarkets.io/v2/organizations/targets/compliance/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"time_start": "2023-11-07T05:31:56Z",
"time_end": "2023-11-07T05:31:56Z",
"interval": "1m",
"targets": [
{
"id": 123,
"type": "gb",
"organization": {
"slug": "<string>",
"name": "<string>"
},
"asset": "<string>",
"exchange": "<string>",
"pair": "<string>",
"metric": "<string>",
"threshold": 123,
"effective_threshold": 123,
"direction": "<string>",
"active": true,
"scaling": {
"mode": "legacy",
"enabled": true,
"source": "asset_twap_24h",
"reference_price": 123,
"current_price": 123,
"factor": 123
},
"compliance": {
"observed": 1,
"passing": 1,
"percentage": 123
},
"latest": {
"value": 123,
"timestamp": "2023-11-07T05:31:56Z",
"source": "trusted",
"passed": true
},
"buckets": [
{
"timestamp": "2023-11-07T05:31:56Z",
"value": 123,
"source": "trusted",
"passed": true
}
],
"market_hours": "market-hours"
}
]
}Authorizations
Token-based authentication with required prefix "Token ". Example: "Token 9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b"
Query Parameters
Comma separated list of assets <asset>,<asset>. Defaults to all assets visible to the user.
Maximum array length:
1001m- Aggregated in 1 minute periods. Window must be <= 1 day5m- Aggregated in 5 minute periods. Window must be <= 1 day1h- Aggregated in 1 hour periods.1d- Aggregated in 1 day periods.
Available options:
1m, 5m, 1h, 1d Minimum string length:
1Comma separated list of target ids to narrow the response.
Maximum array length:
100Required range:
x >= 1Response
200 - application/json
1m- Aggregated in 1 minute periods. Window must be <= 1 day5m- Aggregated in 5 minute periods. Window must be <= 1 day1h- Aggregated in 1 hour periods.1d- Aggregated in 1 day periods.
Available options:
1m, 5m, 1h, 1d Show child attributes
Show child attributes

