@@ -39838,6 +39838,10 @@ components:
3983839838 example: b51f08b698d88d8027a935d9db649774949f5fb41a0c559bfee6a9a13225c72d
3983939839 nullable: true
3984039840 type: string
39841+ has_ever_been_published:
39842+ description: Whether this version number has ever appeared in the form's publication history.
39843+ example: true
39844+ type: boolean
3984139845 id:
3984239846 description: The ID of the form version.
3984339847 example: "126"
@@ -39894,6 +39898,15 @@ components:
3989439898 - type
3989539899 - attributes
3989639900 type: object
39901+ FormVersionListType:
39902+ default: form_version_lists
39903+ description: The resource type for a list of form versions.
39904+ enum:
39905+ - form_version_lists
39906+ example: form_version_lists
39907+ type: string
39908+ x-enum-varnames:
39909+ - FORM_VERSION_LISTS
3989739910 FormVersionResponse:
3989839911 description: A response containing a single form version.
3989939912 properties:
@@ -57900,6 +57913,41 @@ components:
5790057913 - data
5790157914 - meta
5790257915 type: object
57916+ ListFormVersionsData:
57917+ description: A list-of-form-versions resource object.
57918+ properties:
57919+ attributes:
57920+ $ref: "#/components/schemas/ListFormVersionsDataAttributes"
57921+ id:
57922+ description: The ID of the form.
57923+ example: 22f6006a-2302-4926-9396-d2dfcf7b0b34
57924+ type: string
57925+ type:
57926+ $ref: "#/components/schemas/FormVersionListType"
57927+ required:
57928+ - id
57929+ - type
57930+ - attributes
57931+ type: object
57932+ ListFormVersionsDataAttributes:
57933+ description: The attributes for a list of form versions.
57934+ properties:
57935+ versions:
57936+ description: The list of versions for the form.
57937+ items:
57938+ $ref: "#/components/schemas/FormVersionAttributes"
57939+ type: array
57940+ required:
57941+ - versions
57942+ type: object
57943+ ListFormVersionsResponse:
57944+ description: A response containing the list of versions for a form.
57945+ properties:
57946+ data:
57947+ $ref: "#/components/schemas/ListFormVersionsData"
57948+ required:
57949+ - data
57950+ type: object
5790357951 ListHistoricalJobsResponse:
5790457952 description: List of historical jobs.
5790557953 properties:
@@ -138604,6 +138652,71 @@ paths:
138604138652 **Note**: This endpoint is in preview and is subject to change.
138605138653 If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
138606138654 /api/v2/forms/{form_id}/versions:
138655+ get:
138656+ description: List all versions of a form.
138657+ operationId: ListFormVersions
138658+ parameters:
138659+ - description: The ID of the form.
138660+ example: 22f6006a-2302-4926-9396-d2dfcf7b0b34
138661+ in: path
138662+ name: form_id
138663+ required: true
138664+ schema:
138665+ format: uuid
138666+ type: string
138667+ responses:
138668+ "200":
138669+ content:
138670+ application/json:
138671+ examples:
138672+ default:
138673+ value:
138674+ data:
138675+ attributes:
138676+ versions:
138677+ - created_at: "2026-05-29T20:06:14.895921Z"
138678+ data_definition: {}
138679+ definition_signature: '{"signature":"b7f312957a80cea2c8c9950532b205a90a3f8a7ebb7e52fc25437a25d903d545","version":1}'
138680+ etag: b51f08b698d88d8027a935d9db649774949f5fb41a0c559bfee6a9a13225c72d
138681+ has_ever_been_published: true
138682+ id: "126"
138683+ modified_at: "2026-05-29T20:06:14.949163Z"
138684+ state: draft
138685+ ui_definition: {}
138686+ user_id: 10001
138687+ user_uuid: 1fc709aa-be19-4539-a47d-52a30d78a978
138688+ version: 2
138689+ id: 22f6006a-2302-4926-9396-d2dfcf7b0b34
138690+ type: form_version_lists
138691+ schema:
138692+ $ref: "#/components/schemas/ListFormVersionsResponse"
138693+ description: OK
138694+ "400":
138695+ content:
138696+ application/json:
138697+ schema:
138698+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138699+ description: Bad Request
138700+ "401":
138701+ content:
138702+ application/json:
138703+ schema:
138704+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138705+ description: Unauthorized
138706+ "404":
138707+ content:
138708+ application/json:
138709+ schema:
138710+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138711+ description: Not Found
138712+ "429":
138713+ $ref: "#/components/responses/TooManyRequestsResponse"
138714+ summary: List form versions
138715+ tags:
138716+ - Forms
138717+ x-unstable: |-
138718+ **Note**: This endpoint is in preview and is subject to change.
138719+ If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
138607138720 post:
138608138721 description: |-
138609138722 Create or update the latest draft version of a form. The `upsert_params` field controls
@@ -138686,6 +138799,84 @@ paths:
138686138799 x-unstable: |-
138687138800 **Note**: This endpoint is in preview and is subject to change.
138688138801 If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
138802+ /api/v2/forms/{form_id}/versions/revert:
138803+ post:
138804+ description: Revert a form to a prior version by creating a new draft version copied from it.
138805+ operationId: RevertFormVersion
138806+ parameters:
138807+ - description: The ID of the form.
138808+ example: 22f6006a-2302-4926-9396-d2dfcf7b0b34
138809+ in: path
138810+ name: form_id
138811+ required: true
138812+ schema:
138813+ format: uuid
138814+ type: string
138815+ - description: The version number to revert to.
138816+ example: 1
138817+ in: query
138818+ name: version
138819+ required: true
138820+ schema:
138821+ format: int64
138822+ type: integer
138823+ responses:
138824+ "200":
138825+ content:
138826+ application/json:
138827+ examples:
138828+ default:
138829+ value:
138830+ data:
138831+ attributes:
138832+ created_at: "2026-05-29T20:10:14.895921Z"
138833+ data_definition:
138834+ $ref: "#/components/schemas/FormDataDefinition"
138835+ definition_signature: '{"signature":"c8f312957a80cea2c8c9950532b205a90a3f8a7ebb7e52fc25437a25d903d545","version":1}'
138836+ etag: c61f08b698d88d8027a935d9db649774949f5fb41a0c559bfee6a9a13225c72d
138837+ modified_at: "2026-05-29T20:10:14.949163Z"
138838+ state: draft
138839+ ui_definition: {}
138840+ user_id: 10001
138841+ user_uuid: 1fc709aa-be19-4539-a47d-52a30d78a978
138842+ version: 3
138843+ id: "127"
138844+ type: form_versions
138845+ schema:
138846+ $ref: "#/components/schemas/FormVersionResponse"
138847+ description: OK
138848+ "400":
138849+ content:
138850+ application/json:
138851+ schema:
138852+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138853+ description: Bad Request
138854+ "401":
138855+ content:
138856+ application/json:
138857+ schema:
138858+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138859+ description: Unauthorized
138860+ "404":
138861+ content:
138862+ application/json:
138863+ schema:
138864+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138865+ description: Not Found
138866+ "409":
138867+ content:
138868+ application/json:
138869+ schema:
138870+ $ref: "#/components/schemas/JSONAPIErrorResponse"
138871+ description: Conflict
138872+ "429":
138873+ $ref: "#/components/responses/TooManyRequestsResponse"
138874+ summary: Revert a form to a prior version
138875+ tags:
138876+ - Forms
138877+ x-unstable: |-
138878+ **Note**: This endpoint is in preview and is subject to change.
138879+ If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/).
138689138880 /api/v2/forms/{form_id}/versions/upsert_and_publish:
138690138881 post:
138691138882 description: Upsert the latest form version and publish it in a single atomic transaction.
0 commit comments