Get available metrics

Learn how to list available metrics

Description

Sentry supports tens of thousands of metrics on which alerts can be configured. To list available metrics, search for specific metrics and get data on this metrics, the following route can be used.

Endpoint

GET https://sentry.aleno.ai/metrics

Query parameters

Name
required
Type
Description

chainId

required

string

Id of the chain

page

required

number

page number (max 100 metrics returned)

tokenAddresses

optional

string list

Target token addresses (should be in lower case). If provided, metrics related to provided addresses will be selected.

poolAddresses

optional

string list

Target pool addresses (should be in lower case). If provided, metrics related to provided addresses will be selected.

keys

optional

string list

Target metric keys (each metric is defined with a unique key). If provided, metrics corresponding to provided keys will be selected.

To get all available metrics: simply don't add query parameters: GET /metrics

Each query parameter is optional. If multiple query parameters are provided, it will be processed as OR condition. For instance ?tokenAddresses=A,B&poolAddresses=C,D will query: "metrics related to token A or B" OR "metrics related to pool C or D".

Payload

No payload.

CURL example

curl -X GET \
  'https://sentry.aleno.ai/metrics?chainId=eth&poolAddresses=0xb576491f1e6e5e62f1d8f26062ee822b40b0e0d4&tokenAddresses=0xb8b295df2cd735b15be5eb419517aa626fc43cd5&keys=token_total_tvl_0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2&page=1' \
  -H 'accept: application/json'

Result

Returns list of Metric objects supported on Sentry.

{
    "data": [
        {
            "key": "eth_pool_tvl_0xb576491f1e6e5e62f1d8f26062ee822b40b0e0d4_0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
            "chainId": "eth",
            "type": "pool_tvl",
            "name": "WETH tvl on pool Curve CVX / WETH",
            "info": {
                "pool": {
                    "address": "0xb576491f1e6e5e62f1d8f26062ee822b40b0e0d4",
                    "name": "CVX / WETH",
                    "protocolId": "curve",
                    "baseProtocolId": "curve",
                    "tokenAddresses": [
                        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
                        "0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b"
                    ]
                },
                "token": {
                    "address": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
                    "name": "Wrapped Ether",
                    "symbol": "WETH",
                    "decimals": 18,
                    "isTracked": true
                }
            }
        },
        {
            "key": "eth_pool_tvl_0xb576491f1e6e5e62f1d8f26062ee822b40b0e0d4_0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b",
            "chainId": "eth",
            "type": "pool_tvl",
            "name": "CVX tvl on pool Curve CVX / WETH",
            "info": {
                "pool": {
                    "address": "0xb576491f1e6e5e62f1d8f26062ee822b40b0e0d4",
                    "name": "CVX / WETH",
                    "protocolId": "curve",
                    "baseProtocolId": "curve",
                    "tokenAddresses": [
                        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
                        "0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b"
                    ]
                },
                "token": {
                    "address": "0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b",
                    "name": "Convex Token",
                    "symbol": "CVX",
                    "decimals": 18,
                    "isTracked": true
                }
            }
        },
        ...
    ],
    "page": 1,
    "totalPageCount": 86
}

Last updated