EDB Postgres Enterprise Manager REST APIs v7.0: Copy Alert v10.2
post__alert_copy_agent_{agent_id}
Code samples
# You can also use wget curl -X POST https://PEM-SERVER-IP/api/v7/alert/copy/agent/{agent_id} \ -H 'Content-Type: application/json' \ -H 'X-Auth-Token: string'
import requests headers = { 'Content-Type': 'application/json', 'X-Auth-Token': 'string' } r = requests.post('https://PEM-SERVER-IP/api/v7/alert/copy/agent/{agent_id}', headers = headers) print(r.json())
const inputBody = '[ { "type": "string", "agent_id": 0, "ignore_duplicate_alerts": true } ]'; const headers = { 'Content-Type':'application/json', 'X-Auth-Token':'string' }; fetch('https://PEM-SERVER-IP/api/v7/alert/copy/agent/{agent_id}', { method: 'POST', body: inputBody, headers: headers }) .then(function(res) { return res.json(); }).then(function(body) { console.log(body); });
POST /alert/copy/agent/{agent_id}
Copies agent level alert to another agent.
Body parameter
[ { "type": "string", "agent_id": 0, "ignore_duplicate_alerts": true } ]
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| agent_id | path | integer | true | Agent ID |
| X-Auth-Token | header | string | true | Token of authorization |
| body | body | CopyAlertAgentData | true | none |
Detailed descriptions
body: NOTE:
- type value must be 'agent'
Example responses
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Status 200 | None |
Response Schema
Info
This operation does not require authentication
post__alert_copy_server_{server_id}
Code samples