ves-io-schema-alert_receiver-API-Replace
On This Page:
Examples of replacing alert_receiver
Usecase:
Replace alert_receiver "receiver1" with different email id
Request using vesctl:
vesctl configuration replace alert_receiver -i alert_receiver.yaml
where file alert_receiver.yaml has following contents (alert_receiver.ReplaceRequest):
RequestJSON:
{"metadata":{"name":"receiver1","namespace":"documentation"},"spec":{"email":{"email":"xyz.new@abc.com"}}}
`
vesctl yaml response: None
Request using curl:
curl -X 'PUT' -d '{"metadata":{"name":"receiver1","namespace":"documentation"},"spec":{"email":{"email":"xyz.new@abc.com"}}}' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build1372770011_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/documentation/alert_receivers/receiver1'
curl response:
HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Thu, 28 Jul 2022 12:09:24 GMT
Vary: Accept-Encoding
{
}