update metrics endpoint settings.md

Update metrics endpoint settings

PATCH https://app.mk.io/api/v1/projects/{project_name}/metricsEndpoint

See our Grafana dashboard documentation for details.

Enable the metrics endpoint for this project by setting spec.enabled to true.

RBAC Capability Required: mkio.metrics.update

Authentication

Path parameters

Name Type Required Description
project_name string Yes

Request body

Content type: application/json

Example request

curl -X PATCH "https://app.mk.io/api/v1/projects/{project_name}/metricsEndpoint" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
  "kind": "string",
  "spec": {
    "enabled": true
  }
}'

Responses

200 — OK

Example:

{
  "kind": "string",
  "spec": {
    "enabled": true
  },
  "status": {
    "password": "string",
    "url": "string",
    "username": "string"
  }
}

400 — Bad Request

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

401 — Unauthorized

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

403 — Forbidden

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

404 — Not Found

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

429 — Too Many Requests

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

500 — Internal Server Error

Example:

{
  "error": {
    "code": "string",
    "detail": "string",
    "extraDetail": {
      "key": null
    }
  },
  "ref": "string",
  "status": 0
}

Source spec: management-api · operationId: [patch]_/api/v1/projects/{project_name}/metricsEndpoint