Skip to content

Commit 104e94a

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit b84f8672 of spec repo
1 parent 5c036f5 commit 104e94a

File tree

48 files changed

+2816
-201
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+2816
-201
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-05-27 17:12:16.501759",
8-
"spec_repo_commit": "ed439f7c"
7+
"regenerated": "2025-05-29 07:07:50.392866",
8+
"spec_repo_commit": "b84f8672"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-27 17:12:16.518477",
13-
"spec_repo_commit": "ed439f7c"
12+
"regenerated": "2025-05-29 07:07:50.410408",
13+
"spec_repo_commit": "b84f8672"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 241 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13751,6 +13751,19 @@ components:
1375113751
- retryStrategy
1375213752
- fallbackStepName
1375313753
type: object
13754+
Escalation:
13755+
description: The definition of `Escalation` object.
13756+
properties:
13757+
id:
13758+
description: The `Escalation` `id`.
13759+
type: string
13760+
relationships:
13761+
$ref: '#/components/schemas/EscalationRelationships'
13762+
type:
13763+
$ref: '#/components/schemas/EscalationType'
13764+
required:
13765+
- type
13766+
type: object
1375413767
EscalationPolicy:
1375513768
description: Represents a complete escalation policy response, including policy
1375613769
data and optionally included related resources.
@@ -14260,6 +14273,44 @@ components:
1426014273
type: string
1426114274
x-enum-varnames:
1426214275
- USERS
14276+
EscalationRelationships:
14277+
description: The definition of `EscalationRelationships` object.
14278+
properties:
14279+
responders:
14280+
$ref: '#/components/schemas/EscalationRelationshipsResponders'
14281+
type: object
14282+
EscalationRelationshipsResponders:
14283+
description: The definition of `EscalationRelationshipsResponders` object.
14284+
properties:
14285+
data:
14286+
description: The `responders` `data`.
14287+
items:
14288+
$ref: '#/components/schemas/EscalationRelationshipsRespondersDataItems'
14289+
type: array
14290+
type: object
14291+
EscalationRelationshipsRespondersDataItems:
14292+
description: The definition of `EscalationRelationshipsRespondersDataItems`
14293+
object.
14294+
properties:
14295+
id:
14296+
description: The `items` `id`.
14297+
example: ''
14298+
type: string
14299+
type:
14300+
$ref: '#/components/schemas/EscalationRelationshipsRespondersDataItemsType'
14301+
required:
14302+
- type
14303+
- id
14304+
type: object
14305+
EscalationRelationshipsRespondersDataItemsType:
14306+
default: users
14307+
description: Users resource type.
14308+
enum:
14309+
- users
14310+
example: users
14311+
type: string
14312+
x-enum-varnames:
14313+
- USERS
1426314314
EscalationTarget:
1426414315
description: Represents an escalation target, which can be a team, user, or
1426514316
schedule.
@@ -14276,6 +14327,15 @@ components:
1427614327
$ref: '#/components/schemas/EscalationTarget'
1427714328
type: array
1427814329
type: object
14330+
EscalationType:
14331+
default: escalation_policy_steps
14332+
description: Escalation policy steps resource type.
14333+
enum:
14334+
- escalation_policy_steps
14335+
example: escalation_policy_steps
14336+
type: string
14337+
x-enum-varnames:
14338+
- ESCALATION_POLICY_STEPS
1427914339
Event:
1428014340
description: The metadata associated with a request.
1428114341
properties:
@@ -37887,6 +37947,145 @@ components:
3788737947
$ref: '#/components/schemas/TeamLink'
3788837948
type: array
3788937949
type: object
37950+
TeamOnCallResponders:
37951+
description: The definition of `TeamOnCallResponders` object.
37952+
example:
37953+
data:
37954+
id: '123'
37955+
relationships:
37956+
escalations:
37957+
data:
37958+
- id: '123'
37959+
type: escalation_policy_steps
37960+
responders:
37961+
data:
37962+
- id: '123'
37963+
type: users
37964+
type: team_oncall_responders
37965+
included:
37966+
- attributes:
37967+
37968+
name: Test User
37969+
status: active
37970+
id: '123'
37971+
type: users
37972+
- id: '123'
37973+
relationships:
37974+
responders:
37975+
data:
37976+
- id: '123'
37977+
type: users
37978+
type: escalation_policy_steps
37979+
properties:
37980+
data:
37981+
$ref: '#/components/schemas/TeamOnCallRespondersData'
37982+
included:
37983+
description: The `TeamOnCallResponders` `included`.
37984+
items:
37985+
$ref: '#/components/schemas/TeamOnCallRespondersIncluded'
37986+
type: array
37987+
type: object
37988+
TeamOnCallRespondersData:
37989+
description: The definition of `TeamOnCallRespondersData` object.
37990+
properties:
37991+
id:
37992+
description: The `TeamOnCallRespondersData` `id`.
37993+
type: string
37994+
relationships:
37995+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationships'
37996+
type:
37997+
$ref: '#/components/schemas/TeamOnCallRespondersDataType'
37998+
required:
37999+
- type
38000+
type: object
38001+
TeamOnCallRespondersDataRelationships:
38002+
description: The definition of `TeamOnCallRespondersDataRelationships` object.
38003+
properties:
38004+
escalations:
38005+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsEscalations'
38006+
responders:
38007+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsResponders'
38008+
type: object
38009+
TeamOnCallRespondersDataRelationshipsEscalations:
38010+
description: The definition of `TeamOnCallRespondersDataRelationshipsEscalations`
38011+
object.
38012+
properties:
38013+
data:
38014+
description: The `escalations` `data`.
38015+
items:
38016+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsEscalationsDataItems'
38017+
type: array
38018+
type: object
38019+
TeamOnCallRespondersDataRelationshipsEscalationsDataItems:
38020+
description: The definition of `TeamOnCallRespondersDataRelationshipsEscalationsDataItems`
38021+
object.
38022+
properties:
38023+
id:
38024+
description: The `items` `id`.
38025+
example: ''
38026+
type: string
38027+
type:
38028+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsEscalationsDataItemsType'
38029+
required:
38030+
- type
38031+
- id
38032+
type: object
38033+
TeamOnCallRespondersDataRelationshipsEscalationsDataItemsType:
38034+
default: escalation_policy_steps
38035+
description: Escalation policy steps resource type.
38036+
enum:
38037+
- escalation_policy_steps
38038+
example: escalation_policy_steps
38039+
type: string
38040+
x-enum-varnames:
38041+
- ESCALATION_POLICY_STEPS
38042+
TeamOnCallRespondersDataRelationshipsResponders:
38043+
description: The definition of `TeamOnCallRespondersDataRelationshipsResponders`
38044+
object.
38045+
properties:
38046+
data:
38047+
description: The `responders` `data`.
38048+
items:
38049+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsRespondersDataItems'
38050+
type: array
38051+
type: object
38052+
TeamOnCallRespondersDataRelationshipsRespondersDataItems:
38053+
description: The definition of `TeamOnCallRespondersDataRelationshipsRespondersDataItems`
38054+
object.
38055+
properties:
38056+
id:
38057+
description: The `items` `id`.
38058+
example: ''
38059+
type: string
38060+
type:
38061+
$ref: '#/components/schemas/TeamOnCallRespondersDataRelationshipsRespondersDataItemsType'
38062+
required:
38063+
- type
38064+
- id
38065+
type: object
38066+
TeamOnCallRespondersDataRelationshipsRespondersDataItemsType:
38067+
default: users
38068+
description: Users resource type.
38069+
enum:
38070+
- users
38071+
example: users
38072+
type: string
38073+
x-enum-varnames:
38074+
- USERS
38075+
TeamOnCallRespondersDataType:
38076+
default: team_oncall_responders
38077+
description: Team oncall responders resource type.
38078+
enum:
38079+
- team_oncall_responders
38080+
example: team_oncall_responders
38081+
type: string
38082+
x-enum-varnames:
38083+
- TEAM_ONCALL_RESPONDERS
38084+
TeamOnCallRespondersIncluded:
38085+
description: The definition of `TeamOnCallRespondersIncluded` object.
38086+
oneOf:
38087+
- $ref: '#/components/schemas/User'
38088+
- $ref: '#/components/schemas/Escalation'
3789038089
TeamPermissionSetting:
3789138090
description: Team permission setting
3789238091
properties:
@@ -52469,6 +52668,48 @@ paths:
5246952668
summary: Get the schedule on-call user
5247052669
tags:
5247152670
- On-Call
52671+
/api/v2/on-call/teams/{team_id}/on-call:
52672+
get:
52673+
description: Get a team's on-call users at a given time
52674+
operationId: GetTeamOnCallUsers
52675+
parameters:
52676+
- description: 'Comma-separated list of included relationships to be returned.
52677+
Allowed values: `responders`, `escalations`, `escalations.responders`.'
52678+
in: query
52679+
name: include
52680+
schema:
52681+
type: string
52682+
- description: The team ID
52683+
in: path
52684+
name: team_id
52685+
required: true
52686+
schema:
52687+
example: 27590dae-47be-4a7d-9abf-8f4e45124020
52688+
type: string
52689+
responses:
52690+
'200':
52691+
content:
52692+
application/json:
52693+
schema:
52694+
$ref: '#/components/schemas/TeamOnCallResponders'
52695+
description: OK
52696+
'400':
52697+
$ref: '#/components/responses/BadRequestResponse'
52698+
'401':
52699+
$ref: '#/components/responses/UnauthorizedResponse'
52700+
'403':
52701+
$ref: '#/components/responses/ForbiddenResponse'
52702+
'404':
52703+
$ref: '#/components/responses/NotFoundResponse'
52704+
'429':
52705+
$ref: '#/components/responses/TooManyRequestsResponse'
52706+
security:
52707+
- apiKeyAuth: []
52708+
appKeyAuth: []
52709+
- AuthZ: []
52710+
summary: Get team on-call users
52711+
tags:
52712+
- On-Call
5247252713
/api/v2/on-call/teams/{team_id}/routing-rules:
5247352714
get:
5247452715
description: Get a team's On-Call routing rules
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
// Get team on-call users returns "OK" response
2+
use datadog_api_client::datadog;
3+
use datadog_api_client::datadogV2::api_on_call::GetTeamOnCallUsersOptionalParams;
4+
use datadog_api_client::datadogV2::api_on_call::OnCallAPI;
5+
6+
#[tokio::main]
7+
async fn main() {
8+
// there are valid "routing_rules" in the system
9+
let routing_rules_data_id = std::env::var("ROUTING_RULES_DATA_ID").unwrap();
10+
let configuration = datadog::Configuration::new();
11+
let api = OnCallAPI::with_config(configuration);
12+
let resp = api
13+
.get_team_on_call_users(
14+
routing_rules_data_id.clone(),
15+
GetTeamOnCallUsersOptionalParams::default()
16+
.include("responders,escalations.responders".to_string()),
17+
)
18+
.await;
19+
if let Ok(value) = resp {
20+
println!("{:#?}", value);
21+
} else {
22+
println!("{:#?}", resp.unwrap_err());
23+
}
24+
}

0 commit comments

Comments
 (0)