form_versions
Creates, updates, deletes, gets or lists a form_versions resource.
Overview
| Name | form_versions |
| Type | Resource |
| Id | datadog.service_management.form_versions |
Fields
The following fields are returned by SELECT queries:
SELECT not supported for this resource, use SHOW METHODS to view available operations for the resource.
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
upsert_form_version | insert | form_id, data | Create or update the latest draft version of a form. The upsert_params field controls<br />optimistic concurrency behavior. | |
upsert_and_publish_form_version | exec | form_id, data | Upsert the latest form version and publish it in a single atomic transaction. |
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 |
|---|---|---|
form_id | string (uuid) | The ID of the form. (example: 22f6006a-2302-4926-9396-d2dfcf7b0b34) |
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. |
INSERT examples
- upsert_form_version
- Manifest
Create or update the latest draft version of a form. The upsert_params field controls<br />optimistic concurrency behavior.
INSERT INTO datadog.service_management.form_versions (
data,
form_id
)
SELECT
'{{ data }}' /* required */,
'{{ form_id }}'
RETURNING
data
;
# Description fields are for documentation purposes
- name: form_versions
props:
- name: form_id
value: "{{ form_id }}"
description: Required parameter for the form_versions resource.
- name: data
description: |
The data for creating or updating a form version.
value:
attributes:
data_definition:
description: "{{ description }}"
properties: "{{ properties }}"
required:
- "{{ required }}"
title: "{{ title }}"
type: "{{ type }}"
state: "{{ state }}"
ui_definition:
ui:order:
- "{{ ui:order }}"
ui:theme:
primaryColor: "{{ primaryColor }}"
upsert_params:
etag: "{{ etag }}"
insert_only: {{ insert_only }}
match_policy: "{{ match_policy }}"
type: "{{ type }}"
Lifecycle Methods
EXEC variables use wire (API) names.
- upsert_and_publish_form_version
Upsert the latest form version and publish it in a single atomic transaction.
EXEC datadog.service_management.form_versions.upsert_and_publish_form_version
@form_id='{{ form_id }}' --required,
@@json=
'{
"data": "{{ data }}"
}'
;