Skip to content

Commit 8cc9a6e

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 4a5311d of spec repo
1 parent 6ba7e3d commit 8cc9a6e

9 files changed

Lines changed: 75 additions & 105 deletions

File tree

.generator/schemas/v2/openapi.yaml

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1120,7 +1120,7 @@ components:
11201120
PersonalAccessTokenID:
11211121
description: The UUID of the personal access token.
11221122
in: path
1123-
name: pat_uuid
1123+
name: pat_id
11241124
required: true
11251125
schema:
11261126
example: "00000000-0000-1234-0000-000000000000"
@@ -28748,11 +28748,6 @@ components:
2874828748
FullPersonalAccessTokenAttributes:
2874928749
description: Attributes of a full personal access token, including the token key.
2875028750
properties:
28751-
alias:
28752-
description: The alias (short identifier) of the personal access token.
28753-
example: "2H9MCNMBM8FQjQ16YucXkX"
28754-
readOnly: true
28755-
type: string
2875628751
created_at:
2875728752
description: Creation date of the personal access token.
2875828753
example: "2024-01-01T00:00:00+00:00"
@@ -52111,11 +52106,6 @@ components:
5211152106
PersonalAccessTokenAttributes:
5211252107
description: Attributes of a personal access token.
5211352108
properties:
52114-
alias:
52115-
description: The alias (short identifier) of the personal access token.
52116-
example: "2H9MCNMBM8FQjQ16YucXkX"
52117-
readOnly: true
52118-
type: string
5211952109
created_at:
5212052110
description: Creation date of the personal access token.
5212152111
example: "2024-01-01T00:00:00+00:00"
@@ -104402,7 +104392,7 @@ paths:
104402104392
operator: OR
104403104393
permissions:
104404104394
- user_app_keys
104405-
/api/v2/personal_access_tokens/{pat_uuid}:
104395+
/api/v2/personal_access_tokens/{pat_id}:
104406104396
delete:
104407104397
description: Revoke a specific personal access token.
104408104398
operationId: RevokePersonalAccessToken
@@ -113853,7 +113843,7 @@ paths:
113853113843
operator: OR
113854113844
permissions:
113855113845
- service_account_write
113856-
/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}:
113846+
/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}:
113857113847
delete:
113858113848
description: Revoke a specific access token for a service account.
113859113849
operationId: RevokeServiceAccountAccessToken

features/scenarios_model_mapping.rb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,13 +1097,13 @@
10971097
"body" => "PersonalAccessTokenCreateRequest",
10981098
},
10991099
"v2.RevokePersonalAccessToken" => {
1100-
"pat_uuid" => "String",
1100+
"pat_id" => "String",
11011101
},
11021102
"v2.GetPersonalAccessToken" => {
1103-
"pat_uuid" => "String",
1103+
"pat_id" => "String",
11041104
},
11051105
"v2.UpdatePersonalAccessToken" => {
1106-
"pat_uuid" => "String",
1106+
"pat_id" => "String",
11071107
"body" => "PersonalAccessTokenUpdateRequest",
11081108
},
11091109
"v2.ListAPIs" => {
@@ -3949,15 +3949,15 @@
39493949
},
39503950
"v2.RevokeServiceAccountAccessToken" => {
39513951
"service_account_id" => "String",
3952-
"pat_uuid" => "String",
3952+
"pat_id" => "String",
39533953
},
39543954
"v2.GetServiceAccountAccessToken" => {
39553955
"service_account_id" => "String",
3956-
"pat_uuid" => "String",
3956+
"pat_id" => "String",
39573957
},
39583958
"v2.UpdateServiceAccountAccessToken" => {
39593959
"service_account_id" => "String",
3960-
"pat_uuid" => "String",
3960+
"pat_id" => "String",
39613961
"body" => "PersonalAccessTokenUpdateRequest",
39623962
},
39633963
"v2.ListServiceAccountApplicationKeys" => {

features/v2/key_management.feature

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -221,15 +221,15 @@ Feature: Key Management
221221
@generated @skip @team:DataDog/credentials-management
222222
Scenario: Get a personal access token returns "Not Found" response
223223
Given new "GetPersonalAccessToken" request
224-
And request contains "pat_uuid" parameter from "REPLACE.ME"
224+
And request contains "pat_id" parameter from "REPLACE.ME"
225225
When the request is sent
226226
Then the response status is 404 Not Found
227227

228228
@team:DataDog/credentials-management
229229
Scenario: Get a personal access token returns "OK" response
230230
Given there is a valid "personal_access_token" in the system
231231
And new "GetPersonalAccessToken" request
232-
And request contains "pat_uuid" parameter from "personal_access_token.data.id"
232+
And request contains "pat_id" parameter from "personal_access_token.data.id"
233233
When the request is sent
234234
Then the response status is 200 OK
235235
And the response "data.type" is equal to "personal_access_tokens"
@@ -355,29 +355,29 @@ Feature: Key Management
355355
Scenario: Revoke a personal access token returns "No Content" response
356356
Given there is a valid "personal_access_token" in the system
357357
And new "RevokePersonalAccessToken" request
358-
And request contains "pat_uuid" parameter from "personal_access_token.data.id"
358+
And request contains "pat_id" parameter from "personal_access_token.data.id"
359359
When the request is sent
360360
Then the response status is 204 No Content
361361

362362
@generated @skip @team:DataDog/credentials-management
363363
Scenario: Revoke a personal access token returns "Not Found" response
364364
Given new "RevokePersonalAccessToken" request
365-
And request contains "pat_uuid" parameter from "REPLACE.ME"
365+
And request contains "pat_id" parameter from "REPLACE.ME"
366366
When the request is sent
367367
Then the response status is 404 Not Found
368368

369369
@generated @skip @team:DataDog/credentials-management
370370
Scenario: Update a personal access token returns "Bad Request" response
371371
Given new "UpdatePersonalAccessToken" request
372-
And request contains "pat_uuid" parameter from "REPLACE.ME"
372+
And request contains "pat_id" parameter from "REPLACE.ME"
373373
And body with value {"data": {"attributes": {"name": "Updated Personal Access Token", "scopes": ["dashboards_read", "dashboards_write"]}, "id": "00112233-4455-6677-8899-aabbccddeeff", "type": "personal_access_tokens"}}
374374
When the request is sent
375375
Then the response status is 400 Bad Request
376376

377377
@generated @skip @team:DataDog/credentials-management
378378
Scenario: Update a personal access token returns "Not Found" response
379379
Given new "UpdatePersonalAccessToken" request
380-
And request contains "pat_uuid" parameter from "REPLACE.ME"
380+
And request contains "pat_id" parameter from "REPLACE.ME"
381381
And body with value {"data": {"attributes": {"name": "Updated Personal Access Token", "scopes": ["dashboards_read", "dashboards_write"]}, "id": "00112233-4455-6677-8899-aabbccddeeff", "type": "personal_access_tokens"}}
382382
When the request is sent
383383
Then the response status is 404 Not Found
@@ -386,7 +386,7 @@ Feature: Key Management
386386
Scenario: Update a personal access token returns "OK" response
387387
Given there is a valid "personal_access_token" in the system
388388
And new "UpdatePersonalAccessToken" request
389-
And request contains "pat_uuid" parameter from "personal_access_token.data.id"
389+
And request contains "pat_id" parameter from "personal_access_token.data.id"
390390
And body with value {"data": {"type": "personal_access_tokens", "id": "{{ personal_access_token.data.id }}", "attributes": {"name": "{{ unique }}-updated"}}}
391391
When the request is sent
392392
Then the response status is 200 OK

features/v2/service_accounts.feature

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ Feature: Service Accounts
142142
Scenario: Get an access token for a service account returns "Not Found" response
143143
Given new "GetServiceAccountAccessToken" request
144144
And request contains "service_account_id" parameter from "REPLACE.ME"
145-
And request contains "pat_uuid" parameter from "REPLACE.ME"
145+
And request contains "pat_id" parameter from "REPLACE.ME"
146146
When the request is sent
147147
Then the response status is 404 Not Found
148148

@@ -152,7 +152,7 @@ Feature: Service Accounts
152152
And there is a valid "service_account_access_token" for "service_account_user"
153153
And new "GetServiceAccountAccessToken" request
154154
And request contains "service_account_id" parameter from "service_account_user.data.id"
155-
And request contains "pat_uuid" parameter from "service_account_access_token.data.id"
155+
And request contains "pat_id" parameter from "service_account_access_token.data.id"
156156
When the request is sent
157157
Then the response status is 200 OK
158158
And the response "data.attributes.name" has the same value as "service_account_access_token.data.attributes.name"
@@ -232,23 +232,23 @@ Feature: Service Accounts
232232
And there is a valid "service_account_access_token" for "service_account_user"
233233
And new "RevokeServiceAccountAccessToken" request
234234
And request contains "service_account_id" parameter from "service_account_user.data.id"
235-
And request contains "pat_uuid" parameter from "service_account_access_token.data.id"
235+
And request contains "pat_id" parameter from "service_account_access_token.data.id"
236236
When the request is sent
237237
Then the response status is 204 No Content
238238

239239
@generated @skip @team:DataDog/credentials-management
240240
Scenario: Revoke an access token for a service account returns "Not Found" response
241241
Given new "RevokeServiceAccountAccessToken" request
242242
And request contains "service_account_id" parameter from "REPLACE.ME"
243-
And request contains "pat_uuid" parameter from "REPLACE.ME"
243+
And request contains "pat_id" parameter from "REPLACE.ME"
244244
When the request is sent
245245
Then the response status is 404 Not Found
246246

247247
@generated @skip @team:DataDog/credentials-management
248248
Scenario: Update an access token for a service account returns "Bad Request" response
249249
Given new "UpdateServiceAccountAccessToken" request
250250
And request contains "service_account_id" parameter from "REPLACE.ME"
251-
And request contains "pat_uuid" parameter from "REPLACE.ME"
251+
And request contains "pat_id" parameter from "REPLACE.ME"
252252
And body with value {"data": {"attributes": {"name": "Updated Personal Access Token", "scopes": ["dashboards_read", "dashboards_write"]}, "id": "00112233-4455-6677-8899-aabbccddeeff", "type": "personal_access_tokens"}}
253253
When the request is sent
254254
Then the response status is 400 Bad Request
@@ -257,7 +257,7 @@ Feature: Service Accounts
257257
Scenario: Update an access token for a service account returns "Not Found" response
258258
Given new "UpdateServiceAccountAccessToken" request
259259
And request contains "service_account_id" parameter from "REPLACE.ME"
260-
And request contains "pat_uuid" parameter from "REPLACE.ME"
260+
And request contains "pat_id" parameter from "REPLACE.ME"
261261
And body with value {"data": {"attributes": {"name": "Updated Personal Access Token", "scopes": ["dashboards_read", "dashboards_write"]}, "id": "00112233-4455-6677-8899-aabbccddeeff", "type": "personal_access_tokens"}}
262262
When the request is sent
263263
Then the response status is 404 Not Found
@@ -268,7 +268,7 @@ Feature: Service Accounts
268268
And there is a valid "service_account_access_token" for "service_account_user"
269269
And new "UpdateServiceAccountAccessToken" request
270270
And request contains "service_account_id" parameter from "service_account_user.data.id"
271-
And request contains "pat_uuid" parameter from "service_account_access_token.data.id"
271+
And request contains "pat_id" parameter from "service_account_access_token.data.id"
272272
And body with value {"data": {"id": "{{ service_account_access_token.data.id }}", "type": "personal_access_tokens", "attributes": {"name": "{{ service_account_access_token.data.attributes.name }}-updated"}}}
273273
When the request is sent
274274
Then the response status is 200 OK

features/v2/undo.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4293,7 +4293,7 @@
42934293
"operationId": "RevokePersonalAccessToken",
42944294
"parameters": [
42954295
{
4296-
"name": "pat_uuid",
4296+
"name": "pat_id",
42974297
"source": "data.id"
42984298
}
42994299
],
@@ -5816,7 +5816,7 @@
58165816
"source": "data.relationships.owned_by.data.id"
58175817
},
58185818
{
5819-
"name": "pat_uuid",
5819+
"name": "pat_id",
58205820
"source": "data.id"
58215821
}
58225822
],

lib/datadog_api_client/v2/api/key_management_api.rb

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -622,29 +622,29 @@ def get_current_user_application_key_with_http_info(app_key_id, opts = {})
622622
# Get a personal access token.
623623
#
624624
# @see #get_personal_access_token_with_http_info
625-
def get_personal_access_token(pat_uuid, opts = {})
626-
data, _status_code, _headers = get_personal_access_token_with_http_info(pat_uuid, opts)
625+
def get_personal_access_token(pat_id, opts = {})
626+
data, _status_code, _headers = get_personal_access_token_with_http_info(pat_id, opts)
627627
data
628628
end
629629

630630
# Get a personal access token.
631631
#
632632
# Get a specific personal access token by its UUID.
633633
#
634-
# @param pat_uuid [String] The UUID of the personal access token.
634+
# @param pat_id [String] The UUID of the personal access token.
635635
# @param opts [Hash] the optional parameters
636636
# @return [Array<(PersonalAccessTokenResponse, Integer, Hash)>] PersonalAccessTokenResponse data, response status code and response headers
637-
def get_personal_access_token_with_http_info(pat_uuid, opts = {})
637+
def get_personal_access_token_with_http_info(pat_id, opts = {})
638638

639639
if @api_client.config.debugging
640640
@api_client.config.logger.debug 'Calling API: KeyManagementAPI.get_personal_access_token ...'
641641
end
642-
# verify the required parameter 'pat_uuid' is set
643-
if @api_client.config.client_side_validation && pat_uuid.nil?
644-
fail ArgumentError, "Missing the required parameter 'pat_uuid' when calling KeyManagementAPI.get_personal_access_token"
642+
# verify the required parameter 'pat_id' is set
643+
if @api_client.config.client_side_validation && pat_id.nil?
644+
fail ArgumentError, "Missing the required parameter 'pat_id' when calling KeyManagementAPI.get_personal_access_token"
645645
end
646646
# resource path
647-
local_var_path = '/api/v2/personal_access_tokens/{pat_uuid}'.sub('{pat_uuid}', CGI.escape(pat_uuid.to_s).gsub('%2F', '/'))
647+
local_var_path = '/api/v2/personal_access_tokens/{pat_id}'.sub('{pat_id}', CGI.escape(pat_id.to_s).gsub('%2F', '/'))
648648

649649
# query parameters
650650
query_params = opts[:query_params] || {}
@@ -1004,29 +1004,29 @@ def list_personal_access_tokens_with_http_info(opts = {})
10041004
# Revoke a personal access token.
10051005
#
10061006
# @see #revoke_personal_access_token_with_http_info
1007-
def revoke_personal_access_token(pat_uuid, opts = {})
1008-
revoke_personal_access_token_with_http_info(pat_uuid, opts)
1007+
def revoke_personal_access_token(pat_id, opts = {})
1008+
revoke_personal_access_token_with_http_info(pat_id, opts)
10091009
nil
10101010
end
10111011

10121012
# Revoke a personal access token.
10131013
#
10141014
# Revoke a specific personal access token.
10151015
#
1016-
# @param pat_uuid [String] The UUID of the personal access token.
1016+
# @param pat_id [String] The UUID of the personal access token.
10171017
# @param opts [Hash] the optional parameters
10181018
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1019-
def revoke_personal_access_token_with_http_info(pat_uuid, opts = {})
1019+
def revoke_personal_access_token_with_http_info(pat_id, opts = {})
10201020

10211021
if @api_client.config.debugging
10221022
@api_client.config.logger.debug 'Calling API: KeyManagementAPI.revoke_personal_access_token ...'
10231023
end
1024-
# verify the required parameter 'pat_uuid' is set
1025-
if @api_client.config.client_side_validation && pat_uuid.nil?
1026-
fail ArgumentError, "Missing the required parameter 'pat_uuid' when calling KeyManagementAPI.revoke_personal_access_token"
1024+
# verify the required parameter 'pat_id' is set
1025+
if @api_client.config.client_side_validation && pat_id.nil?
1026+
fail ArgumentError, "Missing the required parameter 'pat_id' when calling KeyManagementAPI.revoke_personal_access_token"
10271027
end
10281028
# resource path
1029-
local_var_path = '/api/v2/personal_access_tokens/{pat_uuid}'.sub('{pat_uuid}', CGI.escape(pat_uuid.to_s).gsub('%2F', '/'))
1029+
local_var_path = '/api/v2/personal_access_tokens/{pat_id}'.sub('{pat_id}', CGI.escape(pat_id.to_s).gsub('%2F', '/'))
10301030

10311031
# query parameters
10321032
query_params = opts[:query_params] || {}
@@ -1286,34 +1286,34 @@ def update_current_user_application_key_with_http_info(app_key_id, body, opts =
12861286
# Update a personal access token.
12871287
#
12881288
# @see #update_personal_access_token_with_http_info
1289-
def update_personal_access_token(pat_uuid, body, opts = {})
1290-
data, _status_code, _headers = update_personal_access_token_with_http_info(pat_uuid, body, opts)
1289+
def update_personal_access_token(pat_id, body, opts = {})
1290+
data, _status_code, _headers = update_personal_access_token_with_http_info(pat_id, body, opts)
12911291
data
12921292
end
12931293

12941294
# Update a personal access token.
12951295
#
12961296
# Update a specific personal access token.
12971297
#
1298-
# @param pat_uuid [String] The UUID of the personal access token.
1298+
# @param pat_id [String] The UUID of the personal access token.
12991299
# @param body [PersonalAccessTokenUpdateRequest]
13001300
# @param opts [Hash] the optional parameters
13011301
# @return [Array<(PersonalAccessTokenResponse, Integer, Hash)>] PersonalAccessTokenResponse data, response status code and response headers
1302-
def update_personal_access_token_with_http_info(pat_uuid, body, opts = {})
1302+
def update_personal_access_token_with_http_info(pat_id, body, opts = {})
13031303

13041304
if @api_client.config.debugging
13051305
@api_client.config.logger.debug 'Calling API: KeyManagementAPI.update_personal_access_token ...'
13061306
end
1307-
# verify the required parameter 'pat_uuid' is set
1308-
if @api_client.config.client_side_validation && pat_uuid.nil?
1309-
fail ArgumentError, "Missing the required parameter 'pat_uuid' when calling KeyManagementAPI.update_personal_access_token"
1307+
# verify the required parameter 'pat_id' is set
1308+
if @api_client.config.client_side_validation && pat_id.nil?
1309+
fail ArgumentError, "Missing the required parameter 'pat_id' when calling KeyManagementAPI.update_personal_access_token"
13101310
end
13111311
# verify the required parameter 'body' is set
13121312
if @api_client.config.client_side_validation && body.nil?
13131313
fail ArgumentError, "Missing the required parameter 'body' when calling KeyManagementAPI.update_personal_access_token"
13141314
end
13151315
# resource path
1316-
local_var_path = '/api/v2/personal_access_tokens/{pat_uuid}'.sub('{pat_uuid}', CGI.escape(pat_uuid.to_s).gsub('%2F', '/'))
1316+
local_var_path = '/api/v2/personal_access_tokens/{pat_id}'.sub('{pat_id}', CGI.escape(pat_id.to_s).gsub('%2F', '/'))
13171317

13181318
# query parameters
13191319
query_params = opts[:query_params] || {}

0 commit comments

Comments
 (0)