curl --request GET \
--url https://statsigapi.net/console/v1/metrics/metric_source/{name} \
--header 'STATSIG-API-KEY: <api-key>'
{
"message": "Metric source read successfully.",
"data": {
"name": "test_metric_source4",
"description": "Test description for metric source",
"tags": [
"non_production"
],
"sql": "SELECT * FROM `shoppy-sales.logging.events`",
"timestampColumn": "ts",
"timestampAsDay": true,
"idTypeMapping": [
{
"statsigUnitID": "userID",
"column": "user_id"
}
],
"sourceType": "table",
"tableName": "shoppy-sales.logging.events"
}
}
Optional header to respect review settings for mutation endpoints.
name
Read metric source response
The response is of type object
.
curl --request GET \
--url https://statsigapi.net/console/v1/metrics/metric_source/{name} \
--header 'STATSIG-API-KEY: <api-key>'
{
"message": "Metric source read successfully.",
"data": {
"name": "test_metric_source4",
"description": "Test description for metric source",
"tags": [
"non_production"
],
"sql": "SELECT * FROM `shoppy-sales.logging.events`",
"timestampColumn": "ts",
"timestampAsDay": true,
"idTypeMapping": [
{
"statsigUnitID": "userID",
"column": "user_id"
}
],
"sourceType": "table",
"tableName": "shoppy-sales.logging.events"
}
}