Skip to content

Commit 43f9355

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 65561ac of spec repo
1 parent 94cca5a commit 43f9355

17 files changed

Lines changed: 919 additions & 1 deletion

.generator/schemas/v2/openapi.yaml

Lines changed: 195 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55232,6 +55232,35 @@ components:
5523255232
required:
5523355233
- data
5523455234
type: object
55235+
ListWorkflowsResponse:
55236+
description: The response object for a listing workflows request.
55237+
properties:
55238+
data:
55239+
description: A list of workflows.
55240+
items:
55241+
$ref: "#/components/schemas/WorkflowListItem"
55242+
type: array
55243+
meta:
55244+
$ref: "#/components/schemas/ListWorkflowsResponseMeta"
55245+
type: object
55246+
ListWorkflowsResponseMeta:
55247+
description: Metadata for a List Workflows response.
55248+
properties:
55249+
page:
55250+
$ref: "#/components/schemas/ListWorkflowsResponseMetaPage"
55251+
type: object
55252+
ListWorkflowsResponseMetaPage:
55253+
description: Pagination metadata for a List Workflows response.
55254+
properties:
55255+
totalCount:
55256+
description: The total number of workflows in the organization.
55257+
format: int64
55258+
type: integer
55259+
totalFilteredCount:
55260+
description: The total number of workflows matching the applied filters.
55261+
format: int64
55262+
type: integer
55263+
type: object
5523555264
Log:
5523655265
description: Object description of a log after being processed and stored by Datadog.
5523755266
properties:
@@ -106572,6 +106601,58 @@ components:
106572106601
format: int64
106573106602
type: integer
106574106603
type: object
106604+
WorkflowListItem:
106605+
description: A workflow returned by the list workflows endpoint.
106606+
properties:
106607+
attributes:
106608+
$ref: "#/components/schemas/WorkflowListItemAttributes"
106609+
id:
106610+
description: The workflow identifier.
106611+
readOnly: true
106612+
type: string
106613+
relationships:
106614+
$ref: "#/components/schemas/WorkflowDataRelationships"
106615+
type:
106616+
$ref: "#/components/schemas/WorkflowDataType"
106617+
required:
106618+
- type
106619+
- attributes
106620+
type: object
106621+
WorkflowListItemAttributes:
106622+
description: Attributes of a workflow returned in a list response.
106623+
properties:
106624+
createdAt:
106625+
description: When the workflow was created.
106626+
format: date-time
106627+
readOnly: true
106628+
type: string
106629+
description:
106630+
description: Description of the workflow.
106631+
type: string
106632+
name:
106633+
description: Name of the workflow.
106634+
example: "My Workflow"
106635+
type: string
106636+
published:
106637+
description: Whether the workflow is published. Unpublished workflows can only be run manually. Automatic triggers such as Schedule do not fire until the workflow is published.
106638+
type: boolean
106639+
spec:
106640+
$ref: "#/components/schemas/Spec"
106641+
nullable: true
106642+
tags:
106643+
description: Tags of the workflow.
106644+
items:
106645+
description: A tag string in `key:value` format.
106646+
type: string
106647+
type: array
106648+
updatedAt:
106649+
description: When the workflow was last updated.
106650+
format: date-time
106651+
readOnly: true
106652+
type: string
106653+
required:
106654+
- name
106655+
type: object
106575106656
WorkflowTriggerWrapper:
106576106657
description: "Schema for a Workflow-based trigger."
106577106658
properties:
@@ -188773,6 +188854,120 @@ paths:
188773188854
- manage_log_reports
188774188855
- product_analytics_saved_widgets_write
188775188856
/api/v2/workflows:
188857+
get:
188858+
description: List all workflows in your organization. This API requires a [registered application key](https://docs.datadoghq.com/api/latest/action-connection/#register-a-new-app-key). Alternatively, you can configure these permissions [in the UI](https://docs.datadoghq.com/account_management/api-app-keys/#actions-api-access).
188859+
operationId: ListWorkflows
188860+
parameters:
188861+
- description: The maximum number of workflows to return per page.
188862+
example: 50
188863+
in: query
188864+
name: limit
188865+
required: false
188866+
schema:
188867+
default: 50
188868+
format: int64
188869+
type: integer
188870+
- description: The page number to return, starting from 0.
188871+
example: 0
188872+
in: query
188873+
name: page
188874+
required: false
188875+
schema:
188876+
default: 0
188877+
format: int64
188878+
type: integer
188879+
- description: "The sort order for the returned workflows. Provide a comma-separated list of fields, each optionally prefixed with `-` for descending order. Supported fields are `name`, `createdAt`, `updatedAt`, `creatorName`, `ownerName`, and `lastExecutedAt`."
188880+
example: "-updatedAt"
188881+
in: query
188882+
name: sort
188883+
required: false
188884+
schema:
188885+
type: string
188886+
- description: "A search query used to filter the returned workflows. The query performs a case-insensitive substring match against each workflow's name, creator name, and handle. If the query contains a colon (for example, `team:infra`), the query is treated as a `key:value` tag filter."
188887+
example: deploy
188888+
in: query
188889+
name: filter[query]
188890+
required: false
188891+
schema:
188892+
type: string
188893+
- description: Filters the returned workflows by one or more trigger types, such as `monitor`, `schedule`, or `githubWebhook`. To specify the multiple types, repeat this parameter.
188894+
example:
188895+
- monitor
188896+
explode: true
188897+
in: query
188898+
name: filter[triggerIds]
188899+
required: false
188900+
schema:
188901+
items:
188902+
type: string
188903+
type: array
188904+
- description: Whether to include unpublished workflows in the response.
188905+
in: query
188906+
name: filter[includeUnpublished]
188907+
required: false
188908+
schema:
188909+
default: false
188910+
type: boolean
188911+
- description: Whether to include the full spec of each workflow in the response. When `false` (the default), each workflow's `spec` is returned as `null`.
188912+
in: query
188913+
name: filter[includeSpecs]
188914+
required: false
188915+
schema:
188916+
default: false
188917+
type: boolean
188918+
responses:
188919+
"200":
188920+
content:
188921+
application/json:
188922+
examples:
188923+
default:
188924+
value:
188925+
data:
188926+
- attributes:
188927+
createdAt: "2024-01-01T00:00:00+00:00"
188928+
description: A sample workflow.
188929+
name: Example Workflow
188930+
published: true
188931+
spec: {}
188932+
tags:
188933+
- team:infra
188934+
updatedAt: "2024-01-01T00:00:00+00:00"
188935+
id: 00000000-0000-0000-0000-000000000002
188936+
relationships:
188937+
creator:
188938+
data:
188939+
id: 00000000-0000-0000-0000-000000000009
188940+
type: users
188941+
owner:
188942+
data:
188943+
id: 00000000-0000-0000-0000-000000000009
188944+
type: users
188945+
type: workflows
188946+
meta:
188947+
page:
188948+
totalCount: 1
188949+
totalFilteredCount: 1
188950+
schema:
188951+
$ref: "#/components/schemas/ListWorkflowsResponse"
188952+
description: OK
188953+
"400":
188954+
$ref: "#/components/responses/BadRequestResponse"
188955+
"403":
188956+
$ref: "#/components/responses/ForbiddenResponse"
188957+
"429":
188958+
$ref: "#/components/responses/TooManyRequestsResponse"
188959+
summary: List workflows
188960+
tags:
188961+
- Workflow Automation
188962+
x-pagination:
188963+
limitParam: limit
188964+
pageParam: page
188965+
pageStart: 0
188966+
resultsPath: data
188967+
"x-permission":
188968+
operator: OR
188969+
permissions:
188970+
- workflows_read
188776188971
post:
188777188972
description: Create a new workflow, returning the workflow ID. This API requires a [registered application key](https://docs.datadoghq.com/api/latest/action-connection/#register-a-new-app-key). Alternatively, you can configure these permissions [in the UI](https://docs.datadoghq.com/account_management/api-app-keys/#actions-api-access).
188778188973
operationId: CreateWorkflow

docs/datadog_api_client.v2.model.rst

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20304,6 +20304,27 @@ datadog\_api\_client.v2.model.list\_vulnerable\_assets\_response module
2030420304
:members:
2030520305
:show-inheritance:
2030620306

20307+
datadog\_api\_client.v2.model.list\_workflows\_response module
20308+
--------------------------------------------------------------
20309+
20310+
.. automodule:: datadog_api_client.v2.model.list_workflows_response
20311+
:members:
20312+
:show-inheritance:
20313+
20314+
datadog\_api\_client.v2.model.list\_workflows\_response\_meta module
20315+
--------------------------------------------------------------------
20316+
20317+
.. automodule:: datadog_api_client.v2.model.list_workflows_response_meta
20318+
:members:
20319+
:show-inheritance:
20320+
20321+
datadog\_api\_client.v2.model.list\_workflows\_response\_meta\_page module
20322+
--------------------------------------------------------------------------
20323+
20324+
.. automodule:: datadog_api_client.v2.model.list_workflows_response_meta_page
20325+
:members:
20326+
:show-inheritance:
20327+
2030720328
datadog\_api\_client.v2.model.llm\_obs\_annotated\_interaction\_by\_trace\_item module
2030820329
--------------------------------------------------------------------------------------
2030920330

@@ -45917,6 +45938,20 @@ datadog\_api\_client.v2.model.workflow\_list\_instances\_response\_meta\_page mo
4591745938
:members:
4591845939
:show-inheritance:
4591945940

45941+
datadog\_api\_client.v2.model.workflow\_list\_item module
45942+
---------------------------------------------------------
45943+
45944+
.. automodule:: datadog_api_client.v2.model.workflow_list_item
45945+
:members:
45946+
:show-inheritance:
45947+
45948+
datadog\_api\_client.v2.model.workflow\_list\_item\_attributes module
45949+
---------------------------------------------------------------------
45950+
45951+
.. automodule:: datadog_api_client.v2.model.workflow_list_item_attributes
45952+
:members:
45953+
:show-inheritance:
45954+
4592045955
datadog\_api\_client.v2.model.workflow\_trigger\_wrapper module
4592145956
---------------------------------------------------------------
4592245957

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
"""
2+
List workflows returns "OK" response
3+
"""
4+
5+
from datadog_api_client import ApiClient, Configuration
6+
from datadog_api_client.v2.api.workflow_automation_api import WorkflowAutomationApi
7+
8+
configuration = Configuration()
9+
with ApiClient(configuration) as api_client:
10+
api_instance = WorkflowAutomationApi(api_client)
11+
response = api_instance.list_workflows()
12+
13+
print(response)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
"""
2+
List workflows returns "OK" response with pagination
3+
"""
4+
5+
from datadog_api_client import ApiClient, Configuration
6+
from datadog_api_client.v2.api.workflow_automation_api import WorkflowAutomationApi
7+
8+
configuration = Configuration()
9+
with ApiClient(configuration) as api_client:
10+
api_instance = WorkflowAutomationApi(api_client)
11+
items = api_instance.list_workflows_with_pagination(
12+
limit=2,
13+
filter_query="Example-Workflow-Automation",
14+
)
15+
for item in items:
16+
print(item)

0 commit comments

Comments
 (0)