mirror of
https://github.com/datarhei/core.git
synced 2025-09-26 20:11:29 +08:00
Add /v3/metrics (get) endpoint to list all known metrics
This commit is contained in:
41
docs/docs.go
41
docs/docs.go
@@ -839,6 +839,30 @@ const docTemplate = `{
|
||||
}
|
||||
},
|
||||
"/api/v3/metrics": {
|
||||
"get": {
|
||||
"security": [
|
||||
{
|
||||
"ApiKeyAuth": []
|
||||
}
|
||||
],
|
||||
"description": "List all known metrics with their description and labels",
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"summary": "List all known metrics with their description and labels",
|
||||
"operationId": "metrics-3-describe",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/api.MetricsDescription"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"post": {
|
||||
"security": [
|
||||
{
|
||||
@@ -2926,6 +2950,23 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"api.MetricsDescription": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "string"
|
||||
},
|
||||
"labels": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"api.MetricsQuery": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
@@ -831,6 +831,30 @@
|
||||
}
|
||||
},
|
||||
"/api/v3/metrics": {
|
||||
"get": {
|
||||
"security": [
|
||||
{
|
||||
"ApiKeyAuth": []
|
||||
}
|
||||
],
|
||||
"description": "List all known metrics with their description and labels",
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"summary": "List all known metrics with their description and labels",
|
||||
"operationId": "metrics-3-describe",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/api.MetricsDescription"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"post": {
|
||||
"security": [
|
||||
{
|
||||
@@ -2918,6 +2942,23 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"api.MetricsDescription": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"description": {
|
||||
"type": "string"
|
||||
},
|
||||
"labels": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"api.MetricsQuery": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
@@ -462,6 +462,17 @@ definitions:
|
||||
- password
|
||||
- username
|
||||
type: object
|
||||
api.MetricsDescription:
|
||||
properties:
|
||||
description:
|
||||
type: string
|
||||
labels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
api.MetricsQuery:
|
||||
properties:
|
||||
interval_sec:
|
||||
@@ -2264,6 +2275,21 @@ paths:
|
||||
- ApiKeyAuth: []
|
||||
summary: Add JSON metadata under the given key
|
||||
/api/v3/metrics:
|
||||
get:
|
||||
description: List all known metrics with their description and labels
|
||||
operationId: metrics-3-describe
|
||||
produces:
|
||||
- application/json
|
||||
responses:
|
||||
"200":
|
||||
description: OK
|
||||
schema:
|
||||
items:
|
||||
$ref: '#/definitions/api.MetricsDescription'
|
||||
type: array
|
||||
security:
|
||||
- ApiKeyAuth: []
|
||||
summary: List all known metrics with their description and labels
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
|
Reference in New Issue
Block a user