case_types
Creates, updates, deletes, gets or lists a case_types resource.
Overview
| Name | case_types |
| Type | Resource |
| Id | datadog.service_management.case_types |
Fields
The following fields are returned by SELECT queries:
- get_all_case_types
| Name | Datatype | Description |
|---|---|---|
id | string | Case type's identifier (example: aeadc05e-98a8-11ec-ac2c-da7ad0900001) |
attributes | object | Attributes of a case type, which define a classification category for cases. Organizations use case types to model different workflows (for example, Security Incident, Bug Report, Change Request). |
type | string | JSON:API resource type for case types. (case_type) (default: case_type, example: case_type) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_all_case_types | select | Get all case types | ||
create_case_type | insert | data | Create a Case Type | |
update_case_type | replace | case_type_id, data | Updates the name, emoji, or description of an existing case type. | |
delete_case_type | delete | case_type_id | Delete a case type |
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 |
|---|---|---|
case_type_id | string | The UUID of the case type. (example: f98a5a5b-e0ff-45d4-b2f5-afe6e74de505) |
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_all_case_types
Get all case types
SELECT
id,
attributes,
type
FROM datadog.service_management.case_types
;
INSERT examples
- create_case_type
- Manifest
Create a Case Type
INSERT INTO datadog.service_management.case_types (
data
)
SELECT
'{{ data }}' /* required */
RETURNING
data
;
# Description fields are for documentation purposes
- name: case_types
props:
- name: data
description: |
Data object for creating a case type.
value:
attributes:
deleted_at: "{{ deleted_at }}"
description: "{{ description }}"
emoji: "{{ emoji }}"
name: "{{ name }}"
type: "{{ type }}"
REPLACE examples
- update_case_type
Updates the name, emoji, or description of an existing case type.
REPLACE datadog.service_management.case_types
SET
data = '{{ data }}'
WHERE
case_type_id = '{{ case_type_id }}' --required
AND data = '{{ data }}' --required
RETURNING
data;
DELETE examples
- delete_case_type
Delete a case type
DELETE FROM datadog.service_management.case_types
WHERE case_type_id = '{{ case_type_id }}' --required
;