Skip to content

Commit 8f2e3c7

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Add team and assignee filters for Search Error Tracking Issues API (#3408)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 0f95355 commit 8f2e3c7

2 files changed

Lines changed: 45 additions & 1 deletion

File tree

.generator/schemas/v2/openapi.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35984,6 +35984,15 @@ components:
3598435984
IssuesSearchRequestDataAttributes:
3598535985
description: Object describing a search issue request.
3598635986
properties:
35987+
assignee_ids:
35988+
description: Filter issues by assignee IDs. Multiple values are combined with OR logic.
35989+
example:
35990+
- "00000000-0000-0000-0000-000000000001"
35991+
items:
35992+
format: uuid
35993+
type: string
35994+
maxItems: 50
35995+
type: array
3598735996
from:
3598835997
description: Start date (inclusive) of the query in milliseconds since the Unix epoch.
3598935998
example: 1671612804000
@@ -35997,6 +36006,15 @@ components:
3599736006
description: Search query following the event search syntax.
3599836007
example: "service:orders-* AND @language:go"
3599936008
type: string
36009+
team_ids:
36010+
description: Filter issues by team IDs. Multiple values are combined with OR logic.
36011+
example:
36012+
- "00000000-0000-0000-0000-000000000002"
36013+
items:
36014+
format: uuid
36015+
type: string
36016+
maxItems: 50
36017+
type: array
3600036018
to:
3600136019
description: End date (exclusive) of the query in milliseconds since the Unix epoch.
3600236020
example: 1671620004000

src/datadog_api_client/v2/model/issues_search_request_data_attributes.py

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,14 @@
33
# Copyright 2019-Present Datadog, Inc.
44
from __future__ import annotations
55

6-
from typing import Union, TYPE_CHECKING
6+
from typing import List, Union, TYPE_CHECKING
77

88
from datadog_api_client.model_utils import (
99
ModelNormal,
1010
cached_property,
1111
unset,
1212
UnsetType,
13+
UUID,
1314
)
1415

1516

@@ -26,6 +27,15 @@
2627

2728

2829
class IssuesSearchRequestDataAttributes(ModelNormal):
30+
validations = {
31+
"assignee_ids": {
32+
"max_items": 50,
33+
},
34+
"team_ids": {
35+
"max_items": 50,
36+
},
37+
}
38+
2939
@cached_property
3040
def openapi_types(_):
3141
from datadog_api_client.v2.model.issues_search_request_data_attributes_order_by import (
@@ -39,19 +49,23 @@ def openapi_types(_):
3949
)
4050

4151
return {
52+
"assignee_ids": ([UUID],),
4253
"_from": (int,),
4354
"order_by": (IssuesSearchRequestDataAttributesOrderBy,),
4455
"persona": (IssuesSearchRequestDataAttributesPersona,),
4556
"query": (str,),
57+
"team_ids": ([UUID],),
4658
"to": (int,),
4759
"track": (IssuesSearchRequestDataAttributesTrack,),
4860
}
4961

5062
attribute_map = {
63+
"assignee_ids": "assignee_ids",
5164
"_from": "from",
5265
"order_by": "order_by",
5366
"persona": "persona",
5467
"query": "query",
68+
"team_ids": "team_ids",
5569
"to": "to",
5670
"track": "track",
5771
}
@@ -61,14 +75,19 @@ def __init__(
6175
_from: int,
6276
query: str,
6377
to: int,
78+
assignee_ids: Union[List[UUID], UnsetType] = unset,
6479
order_by: Union[IssuesSearchRequestDataAttributesOrderBy, UnsetType] = unset,
6580
persona: Union[IssuesSearchRequestDataAttributesPersona, UnsetType] = unset,
81+
team_ids: Union[List[UUID], UnsetType] = unset,
6682
track: Union[IssuesSearchRequestDataAttributesTrack, UnsetType] = unset,
6783
**kwargs,
6884
):
6985
"""
7086
Object describing a search issue request.
7187
88+
:param assignee_ids: Filter issues by assignee IDs. Multiple values are combined with OR logic.
89+
:type assignee_ids: [UUID], optional
90+
7291
:param _from: Start date (inclusive) of the query in milliseconds since the Unix epoch.
7392
:type _from: int
7493
@@ -81,16 +100,23 @@ def __init__(
81100
:param query: Search query following the event search syntax.
82101
:type query: str
83102
103+
:param team_ids: Filter issues by team IDs. Multiple values are combined with OR logic.
104+
:type team_ids: [UUID], optional
105+
84106
:param to: End date (exclusive) of the query in milliseconds since the Unix epoch.
85107
:type to: int
86108
87109
:param track: Track of the events to query. Either track(s) or persona(s) must be specified.
88110
:type track: IssuesSearchRequestDataAttributesTrack, optional
89111
"""
112+
if assignee_ids is not unset:
113+
kwargs["assignee_ids"] = assignee_ids
90114
if order_by is not unset:
91115
kwargs["order_by"] = order_by
92116
if persona is not unset:
93117
kwargs["persona"] = persona
118+
if team_ids is not unset:
119+
kwargs["team_ids"] = team_ids
94120
if track is not unset:
95121
kwargs["track"] = track
96122
super().__init__(kwargs)

0 commit comments

Comments
 (0)