ves-io-schema-alert_policy-API-Get

Examples of getting alert_policy

Usecase:

Get alert_policy.

Request using vesctl:

vesctl configuration get alert_policy object-1 --namespace documentation

vesctl yaml response:

metadata:
  annotations: {}
  labels: {}
  name: object-1
  namespace: documentation
referringObjects: []
resourceVersion: "26"
spec:
  receivers: []
  routes: []
status: []
systemMetadata:
  creationTimestamp: "2021-08-25T09:02:29.452097751Z"
  creatorClass: examplesvc
  creatorId: examplesvc
  finalizers: []
  tenant: acmecorp
  uid: 38c27772-ab51-4e41-94a0-f1cec3a3ec57

Request using curl:

curl -X 'GET' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build970361017_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/documentation/alert_policys/object-1?response_format=0'

curl response:

HTTP/1.1 200 OK
Content-Length: 819
Content-Type: application/json
Date: Wed, 25 Aug 2021 09:02:29 GMT
Vary: Accept-Encoding

{
  "object": null,
  "create_form": null,
  "replace_form": null,
  "resource_version": "26",
  "metadata": {
    "name": "object-1",
    "namespace": "documentation",
    "labels": {
    },
    "annotations": {
    },
    "description": "",
    "disable": false
  },
  "system_metadata": {
    "uid": "38c27772-ab51-4e41-94a0-f1cec3a3ec57",
    "creation_timestamp": "2021-08-25T09:02:29.452097751Z",
    "deletion_timestamp": null,
    "modification_timestamp": null,
    "initializers": null,
    "finalizers": [
    ],
    "tenant": "acmecorp",
    "creator_class": "examplesvc",
    "creator_id": "examplesvc",
    "object_index": 0,
    "owner_view": null
  },
  "spec": {
    "receivers": [
    ],
    "routes": [
    ],
    "notification_parameters": null
  },
  "status": [
  ],
  "referring_objects": [
  ]
}