Skip to content

Commit 1692ff9

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 66ae6dd of spec repo
1 parent da5b867 commit 1692ff9

20 files changed

Lines changed: 1794 additions & 0 deletions

.generator/schemas/v2/openapi.yaml

Lines changed: 274 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42283,6 +42283,74 @@ components:
4228342283
- type
4228442284
- id
4228542285
type: object
42286+
ManagedOrgsData:
42287+
description: The managed organizations resource.
42288+
properties:
42289+
id:
42290+
description: The UUID of the current organization.
42291+
example: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
42292+
format: uuid
42293+
type: string
42294+
relationships:
42295+
$ref: "#/components/schemas/ManagedOrgsRelationships"
42296+
type:
42297+
$ref: "#/components/schemas/ManagedOrgsType"
42298+
required:
42299+
- id
42300+
- type
42301+
- relationships
42302+
type: object
42303+
ManagedOrgsRelationshipToOrg:
42304+
description: Relationship to the current organization.
42305+
properties:
42306+
data:
42307+
$ref: "#/components/schemas/OrgRelationshipData"
42308+
required:
42309+
- data
42310+
type: object
42311+
ManagedOrgsRelationshipToOrgs:
42312+
description: Relationship to the managed organizations.
42313+
properties:
42314+
data:
42315+
description: List of managed organization references.
42316+
items:
42317+
$ref: "#/components/schemas/OrgRelationshipData"
42318+
type: array
42319+
required:
42320+
- data
42321+
type: object
42322+
ManagedOrgsRelationships:
42323+
description: Relationships of the managed organizations resource.
42324+
properties:
42325+
current_org:
42326+
$ref: "#/components/schemas/ManagedOrgsRelationshipToOrg"
42327+
managed_orgs:
42328+
$ref: "#/components/schemas/ManagedOrgsRelationshipToOrgs"
42329+
required:
42330+
- current_org
42331+
- managed_orgs
42332+
type: object
42333+
ManagedOrgsResponse:
42334+
description: Response containing the current organization and its managed organizations.
42335+
properties:
42336+
data:
42337+
$ref: "#/components/schemas/ManagedOrgsData"
42338+
included:
42339+
description: Included organization resources.
42340+
items:
42341+
$ref: "#/components/schemas/OrgData"
42342+
type: array
42343+
required:
42344+
- data
42345+
- included
42346+
type: object
42347+
ManagedOrgsType:
42348+
description: The resource type for managed organizations.
42349+
enum: [managed_orgs]
42350+
example: "managed_orgs"
42351+
type: string
42352+
x-enum-varnames:
42353+
- MANAGED_ORGS
4228642354
MemberTeam:
4228742355
description: A member team
4228842356
properties:
@@ -50978,6 +51046,53 @@ components:
5097851046
x-enum-varnames:
5097951047
- ASC
5098051048
- DESC
51049+
OrgAttributes:
51050+
description: Attributes of an organization.
51051+
properties:
51052+
created_at:
51053+
description: The creation timestamp of the organization.
51054+
example: "2019-09-26T17:28:28Z"
51055+
format: date-time
51056+
type: string
51057+
description:
51058+
description: A description of the organization.
51059+
example: "Production organization."
51060+
type: string
51061+
disabled:
51062+
description: Whether the organization is disabled.
51063+
example: false
51064+
type: boolean
51065+
modified_at:
51066+
description: The last modification timestamp of the organization.
51067+
example: "2024-01-15T10:30:00Z"
51068+
format: date-time
51069+
type: string
51070+
name:
51071+
description: The name of the organization.
51072+
example: "My Organization"
51073+
type: string
51074+
public_id:
51075+
description: The public identifier of the organization.
51076+
example: "abcdef12345"
51077+
type: string
51078+
sharing:
51079+
description: The sharing setting of the organization.
51080+
example: "none"
51081+
type: string
51082+
url:
51083+
description: The URL of the organization.
51084+
example: "https://app.datadoghq.com/account/my-org"
51085+
type: string
51086+
required:
51087+
- public_id
51088+
- name
51089+
- description
51090+
- sharing
51091+
- url
51092+
- disabled
51093+
- created_at
51094+
- modified_at
51095+
type: object
5098151096
OrgConfigGetResponse:
5098251097
description: A response with a single Org Config.
5098351098
properties:
@@ -51279,6 +51394,23 @@ components:
5127951394
type: string
5128051395
x-enum-varnames:
5128151396
- USERS
51397+
OrgData:
51398+
description: An organization resource.
51399+
properties:
51400+
attributes:
51401+
$ref: "#/components/schemas/OrgAttributes"
51402+
id:
51403+
description: The UUID of the organization.
51404+
example: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
51405+
format: uuid
51406+
type: string
51407+
type:
51408+
$ref: "#/components/schemas/OrgResourceType"
51409+
required:
51410+
- id
51411+
- type
51412+
- attributes
51413+
type: object
5128251414
OrgGroupAttributes:
5128351415
description: Attributes of an org group.
5128451416
properties:
@@ -52171,6 +52303,27 @@ components:
5217152303
required:
5217252304
- data
5217352305
type: object
52306+
OrgRelationshipData:
52307+
description: Reference to an organization resource.
52308+
properties:
52309+
id:
52310+
description: The UUID of the organization.
52311+
example: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
52312+
format: uuid
52313+
type: string
52314+
type:
52315+
$ref: "#/components/schemas/OrgResourceType"
52316+
required:
52317+
- id
52318+
- type
52319+
type: object
52320+
OrgResourceType:
52321+
description: The resource type for organizations.
52322+
enum: [orgs]
52323+
example: "orgs"
52324+
type: string
52325+
x-enum-varnames:
52326+
- ORGS
5217452327
Organization:
5217552328
description: Organization object.
5217652329
properties:
@@ -107839,6 +107992,83 @@ paths:
107839107992
operator: OR
107840107993
permissions:
107841107994
- on_call_read
107995+
/api/v2/org:
107996+
get:
107997+
description: Returns the current organization and its managed organizations in JSON:API format.
107998+
operationId: ListOrgs
107999+
parameters:
108000+
- description: Filter managed organizations by name.
108001+
example: "My Child Org"
108002+
in: query
108003+
name: "filter[name]"
108004+
required: false
108005+
schema:
108006+
type: string
108007+
responses:
108008+
"200":
108009+
content:
108010+
application/json:
108011+
examples:
108012+
default:
108013+
value:
108014+
data:
108015+
id: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
108016+
relationships:
108017+
current_org:
108018+
data:
108019+
id: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
108020+
type: "orgs"
108021+
managed_orgs:
108022+
data:
108023+
- id: "a1b2c3d4-00cc-11ea-a77b-570c9d03c6c5"
108024+
type: "orgs"
108025+
type: "managed_orgs"
108026+
included:
108027+
- attributes:
108028+
created_at: "2019-09-26T17:28:28Z"
108029+
description: "Production organization."
108030+
disabled: false
108031+
modified_at: "2024-01-15T10:30:00Z"
108032+
name: "My Organization"
108033+
public_id: "abcdef12345"
108034+
sharing: "none"
108035+
url: "https://app.datadoghq.com/account/my-org"
108036+
id: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
108037+
type: "orgs"
108038+
- attributes:
108039+
created_at: "2020-05-10T12:00:00Z"
108040+
description: "Child organization."
108041+
disabled: false
108042+
modified_at: "2024-06-20T08:15:00Z"
108043+
name: "My Child Org"
108044+
public_id: "ghijkl67890"
108045+
sharing: "none"
108046+
url: "https://app.datadoghq.com/account/my-child-org"
108047+
id: "a1b2c3d4-00cc-11ea-a77b-570c9d03c6c5"
108048+
type: "orgs"
108049+
schema:
108050+
$ref: "#/components/schemas/ManagedOrgsResponse"
108051+
description: OK
108052+
"401":
108053+
$ref: "#/components/responses/UnauthorizedResponse"
108054+
"403":
108055+
$ref: "#/components/responses/ForbiddenResponse"
108056+
"429":
108057+
$ref: "#/components/responses/TooManyRequestsResponse"
108058+
security:
108059+
- apiKeyAuth: []
108060+
appKeyAuth: []
108061+
- AuthZ:
108062+
- org_management
108063+
- org_connections_write
108064+
summary: List your managed organizations
108065+
tags:
108066+
- Organizations
108067+
"x-permission":
108068+
operator: OR
108069+
permissions:
108070+
- org_management
108071+
- org_connections_write
107842108072
/api/v2/org_configs:
107843108073
get:
107844108074
description: Returns all Org Configs (name, description, and value).
@@ -128722,6 +128952,50 @@ paths:
128722128952
permissions:
128723128953
- user_access_manage
128724128954
- service_account_write
128955+
/api/v2/users/{user_id}/invitations:
128956+
delete:
128957+
description: |-
128958+
Cancel all pending invitations for a specified user.
128959+
Requires the `user_access_invite` permission.
128960+
operationId: DeleteUserInvitations
128961+
parameters:
128962+
- description: The UUID of the user whose pending invitations should be canceled.
128963+
in: path
128964+
name: user_id
128965+
required: true
128966+
schema:
128967+
example: "4dee724d-00cc-11ea-a77b-570c9d03c6c5"
128968+
format: uuid
128969+
type: string
128970+
responses:
128971+
"200":
128972+
description: OK
128973+
"403":
128974+
content:
128975+
application/json:
128976+
schema:
128977+
$ref: "#/components/schemas/APIErrorResponse"
128978+
description: Authentication error
128979+
"404":
128980+
content:
128981+
application/json:
128982+
schema:
128983+
$ref: "#/components/schemas/APIErrorResponse"
128984+
description: Not found
128985+
"429":
128986+
$ref: "#/components/responses/TooManyRequestsResponse"
128987+
security:
128988+
- apiKeyAuth: []
128989+
appKeyAuth: []
128990+
- AuthZ:
128991+
- user_access_invite
128992+
summary: Delete a pending user's invitations
128993+
tags:
128994+
- Users
128995+
"x-permission":
128996+
operator: OR
128997+
permissions:
128998+
- user_access_invite
128725128999
/api/v2/users/{user_id}/orgs:
128726129000
get:
128727129001
description: |-
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# List your managed organizations returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::OrganizationsAPI.new
5+
p api_instance.list_orgs()
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Delete a pending user's invitations returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::UsersAPI.new
5+
p api_instance.delete_user_invitations("4dee724d-00cc-11ea-a77b-570c9d03c6c5")

features/scenarios_model_mapping.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3371,6 +3371,9 @@
33713371
"v2.ResolveOnCallPage" => {
33723372
"page_id" => "UUID",
33733373
},
3374+
"v2.ListOrgs" => {
3375+
"filter_name" => "String",
3376+
},
33743377
"v2.GetOrgConfig" => {
33753378
"org_config_name" => "String",
33763379
},
@@ -4523,6 +4526,9 @@
45234526
"user_id" => "String",
45244527
"body" => "UserUpdateRequest",
45254528
},
4529+
"v2.DeleteUserInvitations" => {
4530+
"user_id" => "UUID",
4531+
},
45264532
"v2.ListUserOrganizations" => {
45274533
"user_id" => "String",
45284534
},

features/v2/organizations.feature

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,12 @@ Feature: Organizations
4141
When the request is sent
4242
Then the response status is 200 OK
4343

44+
@generated @skip @team:DataDog/org-management
45+
Scenario: List your managed organizations returns "OK" response
46+
Given new "ListOrgs" request
47+
When the request is sent
48+
Then the response status is 200 OK
49+
4450
@team:DataDog/org-management
4551
Scenario: Update a specific Org Config returns "Bad Request" response
4652
Given new "UpdateOrgConfig" request

features/v2/undo.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4125,6 +4125,12 @@
41254125
"type": "safe"
41264126
}
41274127
},
4128+
"ListOrgs": {
4129+
"tag": "Organizations",
4130+
"undo": {
4131+
"type": "safe"
4132+
}
4133+
},
41284134
"ListOrgConfigs": {
41294135
"tag": "Organizations",
41304136
"undo": {
@@ -6951,6 +6957,12 @@
69516957
"type": "idempotent"
69526958
}
69536959
},
6960+
"DeleteUserInvitations": {
6961+
"tag": "Users",
6962+
"undo": {
6963+
"type": "safe"
6964+
}
6965+
},
69546966
"ListUserOrganizations": {
69556967
"tag": "Users",
69566968
"undo": {

0 commit comments

Comments
 (0)