Skip to content

Commit bcdfb9e

Browse files
dd-octo-sts[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit e841bfd of spec repo (#4117)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 0510f73 commit bcdfb9e

7 files changed

Lines changed: 121 additions & 0 deletions

File tree

‎.generator/schemas/v2/openapi.yaml‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103598,6 +103598,7 @@ components:
103598103598
- $ref: "#/components/schemas/SendTeamsMessageAction"
103599103599
- $ref: "#/components/schemas/TriggerWorkflowAutomationAction"
103600103600
- $ref: "#/components/schemas/RoutingRuleEscalationPolicyAction"
103601+
- $ref: "#/components/schemas/RoutingRuleRerouteToTeamAction"
103601103602
RoutingRuleAttributes:
103602103603
description: Defines the configurable attributes of a routing rule, such as actions, query, time restriction, and urgency.
103603103604
properties:
@@ -103696,6 +103697,29 @@ components:
103696103697
type: string
103697103698
x-enum-varnames:
103698103699
- POLICIES
103700+
RoutingRuleRerouteToTeamAction:
103701+
description: "Reroutes the page to another team, which then evaluates it against its own routing rules. Each routing rule can include this action only once. It can be combined only with `send_slack_message` and `send_teams_message` actions. It can't be used with `escalation_policy` or `workflow` actions, or when the routing rule sets `policy_id`."
103702+
properties:
103703+
destination_team_id:
103704+
description: "The ID of the team to reroute the page to."
103705+
example: "00000000-0000-0000-0000-000000000000"
103706+
format: uuid
103707+
type: string
103708+
type:
103709+
$ref: "#/components/schemas/RoutingRuleRerouteToTeamActionType"
103710+
required:
103711+
- type
103712+
- destination_team_id
103713+
type: object
103714+
RoutingRuleRerouteToTeamActionType:
103715+
default: reroute_to_team
103716+
description: "Indicates that the action reroutes the page to another team's routing rules."
103717+
enum:
103718+
- reroute_to_team
103719+
example: reroute_to_team
103720+
type: string
103721+
x-enum-varnames:
103722+
- REROUTE_TO_TEAM
103699103723
RoutingRuleType:
103700103724
default: team_routing_rules
103701103725
description: Team routing rules resource type.

‎src/datadog_api_client/v2/model/routing_rule_action.py‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ def __init__(self, **kwargs):
4444
4545
:param urgency: Specifies the level of urgency for a routing rule (low, high, or dynamic).
4646
:type urgency: Urgency, optional
47+
48+
:param destination_team_id: The ID of the team to reroute the page to.
49+
:type destination_team_id: UUID
4750
"""
4851
super().__init__(kwargs)
4952

@@ -60,12 +63,14 @@ def _composed_schemas(_):
6063
from datadog_api_client.v2.model.send_teams_message_action import SendTeamsMessageAction
6164
from datadog_api_client.v2.model.trigger_workflow_automation_action import TriggerWorkflowAutomationAction
6265
from datadog_api_client.v2.model.routing_rule_escalation_policy_action import RoutingRuleEscalationPolicyAction
66+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action import RoutingRuleRerouteToTeamAction
6367

6468
return {
6569
"oneOf": [
6670
SendSlackMessageAction,
6771
SendTeamsMessageAction,
6872
TriggerWorkflowAutomationAction,
6973
RoutingRuleEscalationPolicyAction,
74+
RoutingRuleRerouteToTeamAction,
7075
],
7176
}

‎src/datadog_api_client/v2/model/routing_rule_attributes.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
from datadog_api_client.v2.model.send_teams_message_action import SendTeamsMessageAction
2222
from datadog_api_client.v2.model.trigger_workflow_automation_action import TriggerWorkflowAutomationAction
2323
from datadog_api_client.v2.model.routing_rule_escalation_policy_action import RoutingRuleEscalationPolicyAction
24+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action import RoutingRuleRerouteToTeamAction
2425

2526

2627
class RoutingRuleAttributes(ModelNormal):
@@ -54,6 +55,7 @@ def __init__(
5455
SendTeamsMessageAction,
5556
TriggerWorkflowAutomationAction,
5657
RoutingRuleEscalationPolicyAction,
58+
RoutingRuleRerouteToTeamAction,
5759
]
5860
],
5961
UnsetType,
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
from typing import TYPE_CHECKING
7+
8+
from datadog_api_client.model_utils import (
9+
ModelNormal,
10+
cached_property,
11+
UUID,
12+
)
13+
14+
15+
if TYPE_CHECKING:
16+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action_type import RoutingRuleRerouteToTeamActionType
17+
18+
19+
class RoutingRuleRerouteToTeamAction(ModelNormal):
20+
@cached_property
21+
def openapi_types(_):
22+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action_type import (
23+
RoutingRuleRerouteToTeamActionType,
24+
)
25+
26+
return {
27+
"destination_team_id": (UUID,),
28+
"type": (RoutingRuleRerouteToTeamActionType,),
29+
}
30+
31+
attribute_map = {
32+
"destination_team_id": "destination_team_id",
33+
"type": "type",
34+
}
35+
36+
def __init__(self_, destination_team_id: UUID, type: RoutingRuleRerouteToTeamActionType, **kwargs):
37+
"""
38+
Reroutes the page to another team, which then evaluates it against its own routing rules. Each routing rule can include this action only once. It can be combined only with ``send_slack_message`` and ``send_teams_message`` actions. It can't be used with ``escalation_policy`` or ``workflow`` actions, or when the routing rule sets ``policy_id``.
39+
40+
:param destination_team_id: The ID of the team to reroute the page to.
41+
:type destination_team_id: UUID
42+
43+
:param type: Indicates that the action reroutes the page to another team's routing rules.
44+
:type type: RoutingRuleRerouteToTeamActionType
45+
"""
46+
super().__init__(kwargs)
47+
48+
self_.destination_team_id = destination_team_id
49+
self_.type = type
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
2+
# This product includes software developed at Datadog (https://www.datadoghq.com/).
3+
# Copyright 2019-Present Datadog, Inc.
4+
from __future__ import annotations
5+
6+
7+
from datadog_api_client.model_utils import (
8+
ModelSimple,
9+
cached_property,
10+
)
11+
12+
from typing import ClassVar
13+
14+
15+
class RoutingRuleRerouteToTeamActionType(ModelSimple):
16+
"""
17+
Indicates that the action reroutes the page to another team's routing rules.
18+
19+
:param value: If omitted defaults to "reroute_to_team". Must be one of ["reroute_to_team"].
20+
:type value: str
21+
"""
22+
23+
allowed_values = {
24+
"reroute_to_team",
25+
}
26+
REROUTE_TO_TEAM: ClassVar["RoutingRuleRerouteToTeamActionType"]
27+
28+
@cached_property
29+
def openapi_types(_):
30+
return {
31+
"value": (str,),
32+
}
33+
34+
35+
RoutingRuleRerouteToTeamActionType.REROUTE_TO_TEAM = RoutingRuleRerouteToTeamActionType("reroute_to_team")

‎src/datadog_api_client/v2/model/team_routing_rules_request_rule.py‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
from datadog_api_client.v2.model.send_teams_message_action import SendTeamsMessageAction
2222
from datadog_api_client.v2.model.trigger_workflow_automation_action import TriggerWorkflowAutomationAction
2323
from datadog_api_client.v2.model.routing_rule_escalation_policy_action import RoutingRuleEscalationPolicyAction
24+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action import RoutingRuleRerouteToTeamAction
2425

2526

2627
class TeamRoutingRulesRequestRule(ModelNormal):
@@ -58,6 +59,7 @@ def __init__(
5859
SendTeamsMessageAction,
5960
TriggerWorkflowAutomationAction,
6061
RoutingRuleEscalationPolicyAction,
62+
RoutingRuleRerouteToTeamAction,
6163
]
6264
],
6365
UnsetType,

‎src/datadog_api_client/v2/models/__init__.py‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9125,6 +9125,8 @@
91259125
from datadog_api_client.v2.model.routing_rule_relationships_policy_data_type import (
91269126
RoutingRuleRelationshipsPolicyDataType,
91279127
)
9128+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action import RoutingRuleRerouteToTeamAction
9129+
from datadog_api_client.v2.model.routing_rule_reroute_to_team_action_type import RoutingRuleRerouteToTeamActionType
91289130
from datadog_api_client.v2.model.routing_rule_type import RoutingRuleType
91299131
from datadog_api_client.v2.model.rule_attributes import RuleAttributes
91309132
from datadog_api_client.v2.model.rule_attributes_request import RuleAttributesRequest
@@ -18719,6 +18721,8 @@
1871918721
"RoutingRuleRelationshipsPolicy",
1872018722
"RoutingRuleRelationshipsPolicyData",
1872118723
"RoutingRuleRelationshipsPolicyDataType",
18724+
"RoutingRuleRerouteToTeamAction",
18725+
"RoutingRuleRerouteToTeamActionType",
1872218726
"RoutingRuleType",
1872318727
"RuleAttributes",
1872418728
"RuleAttributesRequest",

0 commit comments

Comments
 (0)