opsgenie_services
Creates, updates, deletes, gets or lists an opsgenie_services resource.
Overview
| Name | opsgenie_services |
| Type | Resource |
| Id | datadog.integrations.opsgenie_services |
Fields
The following fields are returned by SELECT queries:
- get_opsgenie_service
- list_opsgenie_services
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the Opsgenie service. (example: 596da4af-0563-4097-90ff-07230c3f9db3) |
attributes | object | The attributes from an Opsgenie service response. |
type | string | Opsgenie service resource type. (opsgenie-service) (default: opsgenie-service, example: opsgenie-service) |
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the Opsgenie service. (example: 596da4af-0563-4097-90ff-07230c3f9db3) |
attributes | object | The attributes from an Opsgenie service response. |
type | string | Opsgenie service resource type. (opsgenie-service) (default: opsgenie-service, example: opsgenie-service) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_opsgenie_service | select | integration_service_id | Get a single service from the Datadog Opsgenie integration. | |
list_opsgenie_services | select | Get a list of all services from the Datadog Opsgenie integration. | ||
create_opsgenie_service | insert | data | Create a new service object in the Opsgenie integration. | |
update_opsgenie_service | update | integration_service_id, data | Update a single service object in the Datadog Opsgenie integration. | |
delete_opsgenie_service | delete | integration_service_id | Delete a single service object in the Datadog Opsgenie integration. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
integration_service_id | string | The UUID of the service. |
site | string | The Datadog site (region) for your organization, for example datadoghq.com, us3.datadoghq.com, us5.datadoghq.com, ap1.datadoghq.com, ap2.datadoghq.com, datadoghq.eu, ddog-gov.com. Resolved from the DD_SITE environment variable when set. Optional: defaults to datadoghq.com, or the value of the DD_SITE environment variable when set; a WHERE value overrides both. |
SELECT examples
- get_opsgenie_service
- list_opsgenie_services
Get a single service from the Datadog Opsgenie integration.
SELECT
id,
attributes,
type
FROM datadog.integrations.opsgenie_services
WHERE integration_service_id = '{{ integration_service_id }}' -- required
;
Get a list of all services from the Datadog Opsgenie integration.
SELECT
id,
attributes,
type
FROM datadog.integrations.opsgenie_services
;
INSERT examples
- create_opsgenie_service
- Manifest
Create a new service object in the Opsgenie integration.
INSERT INTO datadog.integrations.opsgenie_services (
data
)
SELECT
'{{ data }}' /* required */
RETURNING
data
;
# Description fields are for documentation purposes
- name: opsgenie_services
props:
- name: data
description: |
Opsgenie service data for a create request.
value:
attributes:
custom_url: "{{ custom_url }}"
name: "{{ name }}"
opsgenie_api_key: "{{ opsgenie_api_key }}"
region: "{{ region }}"
type: "{{ type }}"
UPDATE examples
- update_opsgenie_service
Update a single service object in the Datadog Opsgenie integration.
UPDATE datadog.integrations.opsgenie_services
SET
data = '{{ data }}'
WHERE
integration_service_id = '{{ integration_service_id }}' --required
AND data = '{{ data }}' --required
RETURNING
data;
DELETE examples
- delete_opsgenie_service
Delete a single service object in the Datadog Opsgenie integration.
DELETE FROM datadog.integrations.opsgenie_services
WHERE integration_service_id = '{{ integration_service_id }}' --required
;