diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index d16435a94fc..c502febe15b 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -1132,9 +1132,9 @@ components: schema: type: string PersonalAccessTokenID: - description: The UUID of the personal access token. + description: The ID of the personal access token. in: path - name: pat_uuid + name: pat_id required: true schema: example: "00000000-0000-1234-0000-000000000000" @@ -29172,11 +29172,6 @@ components: FullPersonalAccessTokenAttributes: description: Attributes of a full personal access token, including the token key. properties: - alias: - description: The alias (short identifier) of the personal access token. - example: "2H9MCNMBM8FQjQ16YucXkX" - readOnly: true - type: string created_at: description: Creation date of the personal access token. example: "2024-01-01T00:00:00+00:00" @@ -52995,11 +52990,6 @@ components: PersonalAccessTokenAttributes: description: Attributes of a personal access token. properties: - alias: - description: The alias (short identifier) of the personal access token. - example: "2H9MCNMBM8FQjQ16YucXkX" - readOnly: true - type: string created_at: description: Creation date of the personal access token. example: "2024-01-01T00:00:00+00:00" @@ -77461,6 +77451,10 @@ components: description: Title of the user. nullable: true type: string + uuid: + description: UUID of the user. + readOnly: true + type: string verified: description: Whether the user is verified. type: boolean @@ -105498,7 +105492,7 @@ paths: operator: OR permissions: - user_app_keys - /api/v2/personal_access_tokens/{pat_uuid}: + /api/v2/personal_access_tokens/{pat_id}: delete: description: Revoke a specific personal access token. operationId: RevokePersonalAccessToken @@ -115188,7 +115182,7 @@ paths: operator: OR permissions: - service_account_write - /api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}: + /api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}: delete: description: Revoke a specific access token for a service account. operationId: RevokeServiceAccountAccessToken diff --git a/src/main/java/com/datadog/api/client/v2/api/KeyManagementApi.java b/src/main/java/com/datadog/api/client/v2/api/KeyManagementApi.java index 1db4055410e..56de4559fd1 100644 --- a/src/main/java/com/datadog/api/client/v2/api/KeyManagementApi.java +++ b/src/main/java/com/datadog/api/client/v2/api/KeyManagementApi.java @@ -1402,12 +1402,12 @@ public ApiResponse getCurrentUserApplicationKeyWithHttpI * *

See {@link #getPersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return PersonalAccessTokenResponse * @throws ApiException if fails to make API call */ - public PersonalAccessTokenResponse getPersonalAccessToken(String patUuid) throws ApiException { - return getPersonalAccessTokenWithHttpInfo(patUuid).getData(); + public PersonalAccessTokenResponse getPersonalAccessToken(String patId) throws ApiException { + return getPersonalAccessTokenWithHttpInfo(patId).getData(); } /** @@ -1415,12 +1415,11 @@ public PersonalAccessTokenResponse getPersonalAccessToken(String patUuid) throws * *

See {@link #getPersonalAccessTokenWithHttpInfoAsync}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<PersonalAccessTokenResponse> */ - public CompletableFuture getPersonalAccessTokenAsync( - String patUuid) { - return getPersonalAccessTokenWithHttpInfoAsync(patUuid) + public CompletableFuture getPersonalAccessTokenAsync(String patId) { + return getPersonalAccessTokenWithHttpInfoAsync(patId) .thenApply( response -> { return response.getData(); @@ -1430,7 +1429,7 @@ public CompletableFuture getPersonalAccessTokenAsyn /** * Get a specific personal access token by its UUID. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return ApiResponse<PersonalAccessTokenResponse> * @throws ApiException if fails to make API call * @http.response.details @@ -1443,19 +1442,19 @@ public CompletableFuture getPersonalAccessTokenAsyn * 429 Too many requests - * */ - public ApiResponse getPersonalAccessTokenWithHttpInfo(String patUuid) + public ApiResponse getPersonalAccessTokenWithHttpInfo(String patId) throws ApiException { Object localVarPostBody = null; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( - 400, "Missing the required parameter 'patUuid' when calling getPersonalAccessToken"); + 400, "Missing the required parameter 'patId' when calling getPersonalAccessToken"); } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -1484,26 +1483,26 @@ public ApiResponse getPersonalAccessTokenWithHttpIn * *

See {@link #getPersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<ApiResponse<PersonalAccessTokenResponse>> */ public CompletableFuture> - getPersonalAccessTokenWithHttpInfoAsync(String patUuid) { + getPersonalAccessTokenWithHttpInfoAsync(String patId) { Object localVarPostBody = null; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( - 400, "Missing the required parameter 'patUuid' when calling getPersonalAccessToken")); + 400, "Missing the required parameter 'patId' when calling getPersonalAccessToken")); return result; } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -2695,11 +2694,11 @@ public ApiResponse listPersonalAccessTokensWit * *

See {@link #revokePersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @throws ApiException if fails to make API call */ - public void revokePersonalAccessToken(String patUuid) throws ApiException { - revokePersonalAccessTokenWithHttpInfo(patUuid); + public void revokePersonalAccessToken(String patId) throws ApiException { + revokePersonalAccessTokenWithHttpInfo(patId); } /** @@ -2707,11 +2706,11 @@ public void revokePersonalAccessToken(String patUuid) throws ApiException { * *

See {@link #revokePersonalAccessTokenWithHttpInfoAsync}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture */ - public CompletableFuture revokePersonalAccessTokenAsync(String patUuid) { - return revokePersonalAccessTokenWithHttpInfoAsync(patUuid) + public CompletableFuture revokePersonalAccessTokenAsync(String patId) { + return revokePersonalAccessTokenWithHttpInfoAsync(patId) .thenApply( response -> { return response.getData(); @@ -2721,7 +2720,7 @@ public CompletableFuture revokePersonalAccessTokenAsync(String patUuid) { /** * Revoke a specific personal access token. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return ApiResponse<Void> * @throws ApiException if fails to make API call * @http.response.details @@ -2734,19 +2733,18 @@ public CompletableFuture revokePersonalAccessTokenAsync(String patUuid) { * 429 Too many requests - * */ - public ApiResponse revokePersonalAccessTokenWithHttpInfo(String patUuid) - throws ApiException { + public ApiResponse revokePersonalAccessTokenWithHttpInfo(String patId) throws ApiException { Object localVarPostBody = null; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( - 400, "Missing the required parameter 'patUuid' when calling revokePersonalAccessToken"); + 400, "Missing the required parameter 'patId' when calling revokePersonalAccessToken"); } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -2775,26 +2773,26 @@ public ApiResponse revokePersonalAccessTokenWithHttpInfo(String patUuid) * *

See {@link #revokePersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<ApiResponse<Void>> */ public CompletableFuture> revokePersonalAccessTokenWithHttpInfoAsync( - String patUuid) { + String patId) { Object localVarPostBody = null; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( 400, - "Missing the required parameter 'patUuid' when calling revokePersonalAccessToken")); + "Missing the required parameter 'patId' when calling revokePersonalAccessToken")); return result; } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -3310,14 +3308,14 @@ public ApiResponse updateCurrentUserApplicationKeyWithHt * *

See {@link #updatePersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return PersonalAccessTokenResponse * @throws ApiException if fails to make API call */ public PersonalAccessTokenResponse updatePersonalAccessToken( - String patUuid, PersonalAccessTokenUpdateRequest body) throws ApiException { - return updatePersonalAccessTokenWithHttpInfo(patUuid, body).getData(); + String patId, PersonalAccessTokenUpdateRequest body) throws ApiException { + return updatePersonalAccessTokenWithHttpInfo(patId, body).getData(); } /** @@ -3325,13 +3323,13 @@ public PersonalAccessTokenResponse updatePersonalAccessToken( * *

See {@link #updatePersonalAccessTokenWithHttpInfoAsync}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return CompletableFuture<PersonalAccessTokenResponse> */ public CompletableFuture updatePersonalAccessTokenAsync( - String patUuid, PersonalAccessTokenUpdateRequest body) { - return updatePersonalAccessTokenWithHttpInfoAsync(patUuid, body) + String patId, PersonalAccessTokenUpdateRequest body) { + return updatePersonalAccessTokenWithHttpInfoAsync(patId, body) .thenApply( response -> { return response.getData(); @@ -3341,7 +3339,7 @@ public CompletableFuture updatePersonalAccessTokenA /** * Update a specific personal access token. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return ApiResponse<PersonalAccessTokenResponse> * @throws ApiException if fails to make API call @@ -3357,13 +3355,13 @@ public CompletableFuture updatePersonalAccessTokenA * */ public ApiResponse updatePersonalAccessTokenWithHttpInfo( - String patUuid, PersonalAccessTokenUpdateRequest body) throws ApiException { + String patId, PersonalAccessTokenUpdateRequest body) throws ApiException { Object localVarPostBody = body; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( - 400, "Missing the required parameter 'patUuid' when calling updatePersonalAccessToken"); + 400, "Missing the required parameter 'patId' when calling updatePersonalAccessToken"); } // verify the required parameter 'body' is set @@ -3373,8 +3371,8 @@ public ApiResponse updatePersonalAccessTokenWithHtt } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -3403,23 +3401,23 @@ public ApiResponse updatePersonalAccessTokenWithHtt * *

See {@link #updatePersonalAccessTokenWithHttpInfo}. * - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return CompletableFuture<ApiResponse<PersonalAccessTokenResponse>> */ public CompletableFuture> updatePersonalAccessTokenWithHttpInfoAsync( - String patUuid, PersonalAccessTokenUpdateRequest body) { + String patId, PersonalAccessTokenUpdateRequest body) { Object localVarPostBody = body; - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( 400, - "Missing the required parameter 'patUuid' when calling updatePersonalAccessToken")); + "Missing the required parameter 'patId' when calling updatePersonalAccessToken")); return result; } @@ -3434,8 +3432,8 @@ public ApiResponse updatePersonalAccessTokenWithHtt } // create path and map variables String localVarPath = - "/api/v2/personal_access_tokens/{pat_uuid}" - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + "/api/v2/personal_access_tokens/{pat_id}" + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); diff --git a/src/main/java/com/datadog/api/client/v2/api/ServiceAccountsApi.java b/src/main/java/com/datadog/api/client/v2/api/ServiceAccountsApi.java index bf9dd0283b1..51d74b62f06 100644 --- a/src/main/java/com/datadog/api/client/v2/api/ServiceAccountsApi.java +++ b/src/main/java/com/datadog/api/client/v2/api/ServiceAccountsApi.java @@ -704,13 +704,13 @@ public CompletableFuture> deleteServiceAccountApplicationKeyWi *

See {@link #getServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return PersonalAccessTokenResponse * @throws ApiException if fails to make API call */ public PersonalAccessTokenResponse getServiceAccountAccessToken( - String serviceAccountId, String patUuid) throws ApiException { - return getServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patUuid).getData(); + String serviceAccountId, String patId) throws ApiException { + return getServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patId).getData(); } /** @@ -719,12 +719,12 @@ public PersonalAccessTokenResponse getServiceAccountAccessToken( *

See {@link #getServiceAccountAccessTokenWithHttpInfoAsync}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<PersonalAccessTokenResponse> */ public CompletableFuture getServiceAccountAccessTokenAsync( - String serviceAccountId, String patUuid) { - return getServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patUuid) + String serviceAccountId, String patId) { + return getServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patId) .thenApply( response -> { return response.getData(); @@ -735,7 +735,7 @@ public CompletableFuture getServiceAccountAccessTok * Get a specific access token for a service account by its UUID. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return ApiResponse<PersonalAccessTokenResponse> * @throws ApiException if fails to make API call * @http.response.details @@ -749,7 +749,7 @@ public CompletableFuture getServiceAccountAccessTok * */ public ApiResponse getServiceAccountAccessTokenWithHttpInfo( - String serviceAccountId, String patUuid) throws ApiException { + String serviceAccountId, String patId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'serviceAccountId' is set @@ -760,19 +760,18 @@ public ApiResponse getServiceAccountAccessTokenWith + " getServiceAccountAccessToken"); } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( - 400, - "Missing the required parameter 'patUuid' when calling getServiceAccountAccessToken"); + 400, "Missing the required parameter 'patId' when calling getServiceAccountAccessToken"); } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -802,11 +801,11 @@ public ApiResponse getServiceAccountAccessTokenWith *

See {@link #getServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<ApiResponse<PersonalAccessTokenResponse>> */ public CompletableFuture> - getServiceAccountAccessTokenWithHttpInfoAsync(String serviceAccountId, String patUuid) { + getServiceAccountAccessTokenWithHttpInfoAsync(String serviceAccountId, String patId) { Object localVarPostBody = null; // verify the required parameter 'serviceAccountId' is set @@ -821,24 +820,23 @@ public ApiResponse getServiceAccountAccessTokenWith return result; } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( 400, - "Missing the required parameter 'patUuid' when calling" - + " getServiceAccountAccessToken")); + "Missing the required parameter 'patId' when calling getServiceAccountAccessToken")); return result; } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -1616,12 +1614,12 @@ public ApiResponse listServiceAccountApplicationKey *

See {@link #revokeServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @throws ApiException if fails to make API call */ - public void revokeServiceAccountAccessToken(String serviceAccountId, String patUuid) + public void revokeServiceAccountAccessToken(String serviceAccountId, String patId) throws ApiException { - revokeServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patUuid); + revokeServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patId); } /** @@ -1630,12 +1628,12 @@ public void revokeServiceAccountAccessToken(String serviceAccountId, String patU *

See {@link #revokeServiceAccountAccessTokenWithHttpInfoAsync}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture */ public CompletableFuture revokeServiceAccountAccessTokenAsync( - String serviceAccountId, String patUuid) { - return revokeServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patUuid) + String serviceAccountId, String patId) { + return revokeServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patId) .thenApply( response -> { return response.getData(); @@ -1646,7 +1644,7 @@ public CompletableFuture revokeServiceAccountAccessTokenAsync( * Revoke a specific access token for a service account. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return ApiResponse<Void> * @throws ApiException if fails to make API call * @http.response.details @@ -1660,7 +1658,7 @@ public CompletableFuture revokeServiceAccountAccessTokenAsync( * */ public ApiResponse revokeServiceAccountAccessTokenWithHttpInfo( - String serviceAccountId, String patUuid) throws ApiException { + String serviceAccountId, String patId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'serviceAccountId' is set @@ -1671,19 +1669,19 @@ public ApiResponse revokeServiceAccountAccessTokenWithHttpInfo( + " revokeServiceAccountAccessToken"); } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( 400, - "Missing the required parameter 'patUuid' when calling revokeServiceAccountAccessToken"); + "Missing the required parameter 'patId' when calling revokeServiceAccountAccessToken"); } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -1713,11 +1711,11 @@ public ApiResponse revokeServiceAccountAccessTokenWithHttpInfo( *

See {@link #revokeServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @return CompletableFuture<ApiResponse<Void>> */ public CompletableFuture> revokeServiceAccountAccessTokenWithHttpInfoAsync( - String serviceAccountId, String patUuid) { + String serviceAccountId, String patId) { Object localVarPostBody = null; // verify the required parameter 'serviceAccountId' is set @@ -1731,23 +1729,23 @@ public CompletableFuture> revokeServiceAccountAccessTokenWithH return result; } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( 400, - "Missing the required parameter 'patUuid' when calling" + "Missing the required parameter 'patId' when calling" + " revokeServiceAccountAccessToken")); return result; } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -1784,15 +1782,15 @@ public CompletableFuture> revokeServiceAccountAccessTokenWithH *

See {@link #updateServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return PersonalAccessTokenResponse * @throws ApiException if fails to make API call */ public PersonalAccessTokenResponse updateServiceAccountAccessToken( - String serviceAccountId, String patUuid, PersonalAccessTokenUpdateRequest body) + String serviceAccountId, String patId, PersonalAccessTokenUpdateRequest body) throws ApiException { - return updateServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patUuid, body).getData(); + return updateServiceAccountAccessTokenWithHttpInfo(serviceAccountId, patId, body).getData(); } /** @@ -1801,13 +1799,13 @@ public PersonalAccessTokenResponse updateServiceAccountAccessToken( *

See {@link #updateServiceAccountAccessTokenWithHttpInfoAsync}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return CompletableFuture<PersonalAccessTokenResponse> */ public CompletableFuture updateServiceAccountAccessTokenAsync( - String serviceAccountId, String patUuid, PersonalAccessTokenUpdateRequest body) { - return updateServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patUuid, body) + String serviceAccountId, String patId, PersonalAccessTokenUpdateRequest body) { + return updateServiceAccountAccessTokenWithHttpInfoAsync(serviceAccountId, patId, body) .thenApply( response -> { return response.getData(); @@ -1818,7 +1816,7 @@ public CompletableFuture updateServiceAccountAccess * Update a specific access token for a service account. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return ApiResponse<PersonalAccessTokenResponse> * @throws ApiException if fails to make API call @@ -1834,7 +1832,7 @@ public CompletableFuture updateServiceAccountAccess * */ public ApiResponse updateServiceAccountAccessTokenWithHttpInfo( - String serviceAccountId, String patUuid, PersonalAccessTokenUpdateRequest body) + String serviceAccountId, String patId, PersonalAccessTokenUpdateRequest body) throws ApiException { Object localVarPostBody = body; @@ -1846,11 +1844,11 @@ public ApiResponse updateServiceAccountAccessTokenW + " updateServiceAccountAccessToken"); } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { throw new ApiException( 400, - "Missing the required parameter 'patUuid' when calling updateServiceAccountAccessToken"); + "Missing the required parameter 'patId' when calling updateServiceAccountAccessToken"); } // verify the required parameter 'body' is set @@ -1861,11 +1859,11 @@ public ApiResponse updateServiceAccountAccessTokenW } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); @@ -1895,13 +1893,13 @@ public ApiResponse updateServiceAccountAccessTokenW *

See {@link #updateServiceAccountAccessTokenWithHttpInfo}. * * @param serviceAccountId The ID of the service account. (required) - * @param patUuid The UUID of the personal access token. (required) + * @param patId The ID of the personal access token. (required) * @param body (required) * @return CompletableFuture<ApiResponse<PersonalAccessTokenResponse>> */ public CompletableFuture> updateServiceAccountAccessTokenWithHttpInfoAsync( - String serviceAccountId, String patUuid, PersonalAccessTokenUpdateRequest body) { + String serviceAccountId, String patId, PersonalAccessTokenUpdateRequest body) { Object localVarPostBody = body; // verify the required parameter 'serviceAccountId' is set @@ -1916,14 +1914,14 @@ public ApiResponse updateServiceAccountAccessTokenW return result; } - // verify the required parameter 'patUuid' is set - if (patUuid == null) { + // verify the required parameter 'patId' is set + if (patId == null) { CompletableFuture> result = new CompletableFuture<>(); result.completeExceptionally( new ApiException( 400, - "Missing the required parameter 'patUuid' when calling" + "Missing the required parameter 'patId' when calling" + " updateServiceAccountAccessToken")); return result; } @@ -1941,11 +1939,11 @@ public ApiResponse updateServiceAccountAccessTokenW } // create path and map variables String localVarPath = - "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_uuid}" + "/api/v2/service_accounts/{service_account_id}/access_tokens/{pat_id}" .replaceAll( "\\{" + "service_account_id" + "\\}", apiClient.escapeString(serviceAccountId.toString())) - .replaceAll("\\{" + "pat_uuid" + "\\}", apiClient.escapeString(patUuid.toString())); + .replaceAll("\\{" + "pat_id" + "\\}", apiClient.escapeString(patId.toString())); Map localVarHeaderParams = new HashMap(); diff --git a/src/main/java/com/datadog/api/client/v2/model/FullPersonalAccessTokenAttributes.java b/src/main/java/com/datadog/api/client/v2/model/FullPersonalAccessTokenAttributes.java index 59a9d4e5d07..f715e51361d 100644 --- a/src/main/java/com/datadog/api/client/v2/model/FullPersonalAccessTokenAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/FullPersonalAccessTokenAttributes.java @@ -22,7 +22,6 @@ /** Attributes of a full personal access token, including the token key. */ @JsonPropertyOrder({ - FullPersonalAccessTokenAttributes.JSON_PROPERTY_ALIAS, FullPersonalAccessTokenAttributes.JSON_PROPERTY_CREATED_AT, FullPersonalAccessTokenAttributes.JSON_PROPERTY_EXPIRES_AT, FullPersonalAccessTokenAttributes.JSON_PROPERTY_KEY, @@ -34,9 +33,6 @@ value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator") public class FullPersonalAccessTokenAttributes { @JsonIgnore public boolean unparsed = false; - public static final String JSON_PROPERTY_ALIAS = "alias"; - private String alias; - public static final String JSON_PROPERTY_CREATED_AT = "created_at"; private OffsetDateTime createdAt; @@ -55,18 +51,6 @@ public class FullPersonalAccessTokenAttributes { public static final String JSON_PROPERTY_SCOPES = "scopes"; private List scopes = null; - /** - * The alias (short identifier) of the personal access token. - * - * @return alias - */ - @jakarta.annotation.Nullable - @JsonProperty(JSON_PROPERTY_ALIAS) - @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getAlias() { - return alias; - } - /** * Creation date of the personal access token. * @@ -236,8 +220,7 @@ public boolean equals(Object o) { } FullPersonalAccessTokenAttributes fullPersonalAccessTokenAttributes = (FullPersonalAccessTokenAttributes) o; - return Objects.equals(this.alias, fullPersonalAccessTokenAttributes.alias) - && Objects.equals(this.createdAt, fullPersonalAccessTokenAttributes.createdAt) + return Objects.equals(this.createdAt, fullPersonalAccessTokenAttributes.createdAt) && Objects.equals(this.expiresAt, fullPersonalAccessTokenAttributes.expiresAt) && Objects.equals(this.key, fullPersonalAccessTokenAttributes.key) && Objects.equals(this.name, fullPersonalAccessTokenAttributes.name) @@ -250,14 +233,13 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( - alias, createdAt, expiresAt, key, name, publicPortion, scopes, additionalProperties); + createdAt, expiresAt, key, name, publicPortion, scopes, additionalProperties); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class FullPersonalAccessTokenAttributes {\n"); - sb.append(" alias: ").append(toIndentedString(alias)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" expiresAt: ").append(toIndentedString(expiresAt)).append("\n"); sb.append(" key: ").append(toIndentedString(key)).append("\n"); diff --git a/src/main/java/com/datadog/api/client/v2/model/PersonalAccessTokenAttributes.java b/src/main/java/com/datadog/api/client/v2/model/PersonalAccessTokenAttributes.java index 1a9b5f964af..328e30dc7f9 100644 --- a/src/main/java/com/datadog/api/client/v2/model/PersonalAccessTokenAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/PersonalAccessTokenAttributes.java @@ -22,7 +22,6 @@ /** Attributes of a personal access token. */ @JsonPropertyOrder({ - PersonalAccessTokenAttributes.JSON_PROPERTY_ALIAS, PersonalAccessTokenAttributes.JSON_PROPERTY_CREATED_AT, PersonalAccessTokenAttributes.JSON_PROPERTY_EXPIRES_AT, PersonalAccessTokenAttributes.JSON_PROPERTY_LAST_USED_AT, @@ -35,9 +34,6 @@ value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator") public class PersonalAccessTokenAttributes { @JsonIgnore public boolean unparsed = false; - public static final String JSON_PROPERTY_ALIAS = "alias"; - private String alias; - public static final String JSON_PROPERTY_CREATED_AT = "created_at"; private OffsetDateTime createdAt; @@ -59,18 +55,6 @@ public class PersonalAccessTokenAttributes { public static final String JSON_PROPERTY_SCOPES = "scopes"; private List scopes = null; - /** - * The alias (short identifier) of the personal access token. - * - * @return alias - */ - @jakarta.annotation.Nullable - @JsonProperty(JSON_PROPERTY_ALIAS) - @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public String getAlias() { - return alias; - } - /** * Creation date of the personal access token. * @@ -279,8 +263,7 @@ public boolean equals(Object o) { return false; } PersonalAccessTokenAttributes personalAccessTokenAttributes = (PersonalAccessTokenAttributes) o; - return Objects.equals(this.alias, personalAccessTokenAttributes.alias) - && Objects.equals(this.createdAt, personalAccessTokenAttributes.createdAt) + return Objects.equals(this.createdAt, personalAccessTokenAttributes.createdAt) && Objects.equals(this.expiresAt, personalAccessTokenAttributes.expiresAt) && Objects.equals(this.lastUsedAt, personalAccessTokenAttributes.lastUsedAt) && Objects.equals(this.modifiedAt, personalAccessTokenAttributes.modifiedAt) @@ -294,7 +277,6 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( - alias, createdAt, expiresAt, lastUsedAt, @@ -309,7 +291,6 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class PersonalAccessTokenAttributes {\n"); - sb.append(" alias: ").append(toIndentedString(alias)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" expiresAt: ").append(toIndentedString(expiresAt)).append("\n"); sb.append(" lastUsedAt: ").append(toIndentedString(lastUsedAt)).append("\n"); diff --git a/src/main/java/com/datadog/api/client/v2/model/UserAttributes.java b/src/main/java/com/datadog/api/client/v2/model/UserAttributes.java index e3d84466c8b..e1264d262ca 100644 --- a/src/main/java/com/datadog/api/client/v2/model/UserAttributes.java +++ b/src/main/java/com/datadog/api/client/v2/model/UserAttributes.java @@ -32,6 +32,7 @@ UserAttributes.JSON_PROPERTY_SERVICE_ACCOUNT, UserAttributes.JSON_PROPERTY_STATUS, UserAttributes.JSON_PROPERTY_TITLE, + UserAttributes.JSON_PROPERTY_UUID, UserAttributes.JSON_PROPERTY_VERIFIED }) @jakarta.annotation.Generated( @@ -74,6 +75,9 @@ public class UserAttributes { public static final String JSON_PROPERTY_TITLE = "title"; private JsonNullable title = JsonNullable.undefined(); + public static final String JSON_PROPERTY_UUID = "uuid"; + private String uuid; + public static final String JSON_PROPERTY_VERIFIED = "verified"; private Boolean verified; @@ -345,6 +349,18 @@ public void setTitle(String title) { this.title = JsonNullable.of(title); } + /** + * UUID of the user. + * + * @return uuid + */ + @jakarta.annotation.Nullable + @JsonProperty(JSON_PROPERTY_UUID) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getUuid() { + return uuid; + } + public UserAttributes verified(Boolean verified) { this.verified = verified; return this; @@ -434,6 +450,7 @@ public boolean equals(Object o) { && Objects.equals(this.serviceAccount, userAttributes.serviceAccount) && Objects.equals(this.status, userAttributes.status) && Objects.equals(this.title, userAttributes.title) + && Objects.equals(this.uuid, userAttributes.uuid) && Objects.equals(this.verified, userAttributes.verified) && Objects.equals(this.additionalProperties, userAttributes.additionalProperties); } @@ -453,6 +470,7 @@ public int hashCode() { serviceAccount, status, title, + uuid, verified, additionalProperties); } @@ -473,6 +491,7 @@ public String toString() { sb.append(" serviceAccount: ").append(toIndentedString(serviceAccount)).append("\n"); sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" title: ").append(toIndentedString(title)).append("\n"); + sb.append(" uuid: ").append(toIndentedString(uuid)).append("\n"); sb.append(" verified: ").append(toIndentedString(verified)).append("\n"); sb.append(" additionalProperties: ") .append(toIndentedString(additionalProperties)) diff --git a/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.freeze b/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.freeze index b457d0ec92c..7ccf87f4bd5 100644 --- a/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.freeze +++ b/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.freeze @@ -1 +1 @@ -2026-04-03T21:02:56.793Z \ No newline at end of file +2026-04-16T20:03:06.304Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.json b/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.json index ebd30ca2de3..d7cbb9016a0 100644 --- a/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.json +++ b/src/test/resources/cassettes/features/v2/Create_an_access_token_for_a_service_account_returns_Created_response.json @@ -3,7 +3,7 @@ "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1775250176@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" + "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1776369786@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" }, "headers": {}, "method": "POST", @@ -12,7 +12,7 @@ "secure": true }, "httpResponse": { - "body": "{\"data\":{\"type\":\"users\",\"id\":\"7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0\",\"attributes\":{\"name\":null,\"handle\":\"7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0\",\"created_at\":\"2026-04-03T21:02:56.980609+00:00\",\"modified_at\":\"2026-04-03T21:02:56.980609+00:00\",\"email\":\"test-create_an_access_token_for_a_service_account_returns_created_response-1775250176@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/1a703b50769c96d7b84a5470f474ef74?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", + "body": "{\"data\":{\"type\":\"users\",\"id\":\"498cce13-39cf-11f1-9928-be1871753dee\",\"attributes\":{\"uuid\":\"498cce13-39cf-11f1-9928-be1871753dee\",\"name\":null,\"handle\":\"498cce13-39cf-11f1-9928-be1871753dee\",\"created_at\":\"2026-04-16T20:03:08.017467+00:00\",\"modified_at\":\"2026-04-16T20:03:08.017467+00:00\",\"email\":\"test-create_an_access_token_for_a_service_account_returns_created_response-1776369786@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/ed167ebfacd06c99ea70d4c121f5a7f1?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", "headers": { "Content-Type": [ "application/json" @@ -27,22 +27,22 @@ "timeToLive": { "unlimited": true }, - "id": "567c34c3-ae3c-8785-a73a-27fcc9a742ba" + "id": "f47bb188-a2e6-ba96-a9a6-a881be2e659e" }, { "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1775250176\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" + "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1776369786\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" }, "headers": {}, "method": "POST", - "path": "/api/v2/service_accounts/7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0/access_tokens", + "path": "/api/v2/service_accounts/498cce13-39cf-11f1-9928-be1871753dee/access_tokens", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"6f2491f5-8c3f-45a3-962a-5f769b95e806\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"3NirNJ5Y2qB4Fmac8B4wnm\",\"created_at\":\"2026-04-03T21:02:57.288351972Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxXxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1775250176\",\"public_portion\":\"3NirNJ5Y2qB4Fmac8B4wnm\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"88337232-8552-4495-987c-1cfed567d461\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:08.381725456Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Create_an_access_token_for_a_service_account_returns_Created_response-1776369786\",\"public_portion\":\"ddpat_490SyfYQqhqnr008BTjQWn\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"498cce13-39cf-11f1-9928-be1871753dee\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -57,13 +57,13 @@ "timeToLive": { "unlimited": true }, - "id": "c6adfa6b-1027-61d3-a8c2-030c2ba28080" + "id": "6d806020-4556-1183-3ebc-a80b6034dce9" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/service_accounts/7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0/access_tokens/6f2491f5-8c3f-45a3-962a-5f769b95e806", + "path": "/api/v2/service_accounts/498cce13-39cf-11f1-9928-be1871753dee/access_tokens/88337232-8552-4495-987c-1cfed567d461", "keepAlive": false, "secure": true }, @@ -78,13 +78,13 @@ "timeToLive": { "unlimited": true }, - "id": "09473a0a-cca9-78f1-677a-1a4f8ac133da" + "id": "9f6795a3-3733-f1de-83fa-480c56c66320" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/users/7d5e5ea9-2fa0-11f1-991f-62f4bfc595d0", + "path": "/api/v2/users/498cce13-39cf-11f1-9928-be1871753dee", "keepAlive": false, "secure": true }, @@ -99,6 +99,6 @@ "timeToLive": { "unlimited": true }, - "id": "393e616c-bf05-7584-1cd3-0dad62ab2cff" + "id": "8fda343e-c920-8ee6-219a-f8b36492a756" } ] \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.freeze b/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.freeze index 55c4828532c..767a9f9c250 100644 --- a/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.freeze +++ b/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.freeze @@ -1 +1 @@ -2026-04-03T21:03:03.500Z \ No newline at end of file +2026-04-16T20:03:09.123Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.json b/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.json index 8ce61fc245e..3347aebddcb 100644 --- a/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.json +++ b/src/test/resources/cassettes/features/v2/Get_an_access_token_for_a_service_account_returns_OK_response.json @@ -3,7 +3,7 @@ "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1775250183@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" + "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1776369789@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" }, "headers": {}, "method": "POST", @@ -12,7 +12,7 @@ "secure": true }, "httpResponse": { - "body": "{\"data\":{\"type\":\"users\",\"id\":\"8161ef90-2fa0-11f1-991f-62f4bfc595d0\",\"attributes\":{\"name\":null,\"handle\":\"8161ef90-2fa0-11f1-991f-62f4bfc595d0\",\"created_at\":\"2026-04-03T21:03:03.714879+00:00\",\"modified_at\":\"2026-04-03T21:03:03.714879+00:00\",\"email\":\"test-get_an_access_token_for_a_service_account_returns_ok_response-1775250183@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/bb3c6df0d99066bbe05cf7dff99b5561?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", + "body": "{\"data\":{\"type\":\"users\",\"id\":\"4a56376d-39cf-11f1-9a29-2eb65349fc01\",\"attributes\":{\"uuid\":\"4a56376d-39cf-11f1-9a29-2eb65349fc01\",\"name\":null,\"handle\":\"4a56376d-39cf-11f1-9a29-2eb65349fc01\",\"created_at\":\"2026-04-16T20:03:09.337439+00:00\",\"modified_at\":\"2026-04-16T20:03:09.337439+00:00\",\"email\":\"test-get_an_access_token_for_a_service_account_returns_ok_response-1776369789@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7473377b9dced0689feddb50f5d82d29?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", "headers": { "Content-Type": [ "application/json" @@ -27,22 +27,22 @@ "timeToLive": { "unlimited": true }, - "id": "145227f5-47e3-35aa-327f-58dc2e4b258b" + "id": "d077c285-8166-09b6-bafd-ac466b66d2ea" }, { "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1775250183\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" + "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1776369789\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" }, "headers": {}, "method": "POST", - "path": "/api/v2/service_accounts/8161ef90-2fa0-11f1-991f-62f4bfc595d0/access_tokens", + "path": "/api/v2/service_accounts/4a56376d-39cf-11f1-9a29-2eb65349fc01/access_tokens", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"f2362958-1e67-414b-985d-d3196afd9315\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"7N2tUOwxIjSF8QziOBIpVd\",\"created_at\":\"2026-04-03T21:03:04.002376467Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1775250183\",\"public_portion\":\"7N2tUOwxIjSF8QziOBIpVd\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"8161ef90-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"b84d8c2c-b88c-4f72-82ef-fc09dddd1153\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:09.695802251Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1776369789\",\"public_portion\":\"ddpat_5bm1hhcTKQzH22hPiJgkEN\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"4a56376d-39cf-11f1-9a29-2eb65349fc01\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -57,18 +57,18 @@ "timeToLive": { "unlimited": true }, - "id": "fdccf204-9c1e-92e9-0008-e334c10c3ed8" + "id": "43c62610-8b63-b6e6-6162-25e0c9c01f18" }, { "httpRequest": { "headers": {}, "method": "GET", - "path": "/api/v2/service_accounts/8161ef90-2fa0-11f1-991f-62f4bfc595d0/access_tokens/f2362958-1e67-414b-985d-d3196afd9315", + "path": "/api/v2/service_accounts/4a56376d-39cf-11f1-9a29-2eb65349fc01/access_tokens/b84d8c2c-b88c-4f72-82ef-fc09dddd1153", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"f2362958-1e67-414b-985d-d3196afd9315\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"7N2tUOwxIjSF8QziOBIpVd\",\"created_at\":\"2026-04-03T21:03:04.002376Z\",\"expires_at\":null,\"last_used_at\":null,\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1775250183\",\"public_portion\":\"7N2tUOwxIjSF8QziOBIpVd\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"8161ef90-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"b84d8c2c-b88c-4f72-82ef-fc09dddd1153\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:09.695802Z\",\"expires_at\":null,\"last_used_at\":null,\"name\":\"Test-Get_an_access_token_for_a_service_account_returns_OK_response-1776369789\",\"public_portion\":\"ddpat_5bm1hhcTKQzH22hPiJgkEN\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"4a56376d-39cf-11f1-9a29-2eb65349fc01\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -83,13 +83,13 @@ "timeToLive": { "unlimited": true }, - "id": "8e65c5a6-4047-d080-cfc9-d5fed107089c" + "id": "42134347-5af4-f8df-7193-56b4cfa2f4f0" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/service_accounts/8161ef90-2fa0-11f1-991f-62f4bfc595d0/access_tokens/f2362958-1e67-414b-985d-d3196afd9315", + "path": "/api/v2/service_accounts/4a56376d-39cf-11f1-9a29-2eb65349fc01/access_tokens/b84d8c2c-b88c-4f72-82ef-fc09dddd1153", "keepAlive": false, "secure": true }, @@ -104,13 +104,13 @@ "timeToLive": { "unlimited": true }, - "id": "c26607f1-bdf6-dc7e-1abe-ba1d99b0d986" + "id": "207dc4ce-726f-bb5d-f2ec-232ddf8d8fb9" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/users/8161ef90-2fa0-11f1-991f-62f4bfc595d0", + "path": "/api/v2/users/4a56376d-39cf-11f1-9a29-2eb65349fc01", "keepAlive": false, "secure": true }, @@ -125,6 +125,6 @@ "timeToLive": { "unlimited": true }, - "id": "18d29cd2-ed05-67c0-ce3f-cd340445e82f" + "id": "98343038-3a18-ef13-9153-732118bbfdc9" } ] \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.freeze b/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.freeze index 6234af8a3e4..db15643c3b7 100644 --- a/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.freeze +++ b/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.freeze @@ -1 +1 @@ -2026-04-03T21:03:09.026Z \ No newline at end of file +2026-04-16T20:03:10.610Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.json b/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.json index 63738b91632..11c655fcc28 100644 --- a/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.json +++ b/src/test/resources/cassettes/features/v2/List_access_tokens_for_a_service_account_returns_OK_response.json @@ -3,7 +3,7 @@ "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"email\":\"Test-List_access_tokens_for_a_service_account_returns_OK_response-1775250189@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" + "json": "{\"data\":{\"attributes\":{\"email\":\"Test-List_access_tokens_for_a_service_account_returns_OK_response-1776369790@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" }, "headers": {}, "method": "POST", @@ -12,7 +12,7 @@ "secure": true }, "httpResponse": { - "body": "{\"data\":{\"type\":\"users\",\"id\":\"84a7b33b-2fa0-11f1-96b6-7a9b8860a1d7\",\"attributes\":{\"name\":null,\"handle\":\"84a7b33b-2fa0-11f1-96b6-7a9b8860a1d7\",\"created_at\":\"2026-04-03T21:03:09.205232+00:00\",\"modified_at\":\"2026-04-03T21:03:09.205232+00:00\",\"email\":\"test-list_access_tokens_for_a_service_account_returns_ok_response-1775250189@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/816e106f74328dd4c20e98c116a9edeb?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}", + "body": "{\"data\":{\"type\":\"users\",\"id\":\"4b3b0a2c-39cf-11f1-bf73-ce6d1c25b9b4\",\"attributes\":{\"uuid\":\"4b3b0a2c-39cf-11f1-bf73-ce6d1c25b9b4\",\"name\":null,\"handle\":\"4b3b0a2c-39cf-11f1-bf73-ce6d1c25b9b4\",\"created_at\":\"2026-04-16T20:03:10.837056+00:00\",\"modified_at\":\"2026-04-16T20:03:10.837056+00:00\",\"email\":\"test-list_access_tokens_for_a_service_account_returns_ok_response-1776369790@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/0a5772e4c2381e3c1061e55142e2281a?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", "headers": { "Content-Type": [ "application/json" @@ -27,13 +27,13 @@ "timeToLive": { "unlimited": true }, - "id": "15159beb-c452-f76c-c58b-3dd52e769af5" + "id": "315fbb2a-1c68-4067-2ddf-70846fbd17d2" }, { "httpRequest": { "headers": {}, "method": "GET", - "path": "/api/v2/service_accounts/84a7b33b-2fa0-11f1-96b6-7a9b8860a1d7/access_tokens", + "path": "/api/v2/service_accounts/4b3b0a2c-39cf-11f1-bf73-ce6d1c25b9b4/access_tokens", "keepAlive": false, "secure": true }, @@ -53,13 +53,13 @@ "timeToLive": { "unlimited": true }, - "id": "fcd67808-c945-bd4d-6169-075b41c61c92" + "id": "e8917630-83f6-7504-ebf6-c0d63c473dbc" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/users/84a7b33b-2fa0-11f1-96b6-7a9b8860a1d7", + "path": "/api/v2/users/4b3b0a2c-39cf-11f1-bf73-ce6d1c25b9b4", "keepAlive": false, "secure": true }, @@ -74,6 +74,6 @@ "timeToLive": { "unlimited": true }, - "id": "29e3fcdb-4d74-bd98-edbd-15ce7445207c" + "id": "03782f84-f04f-b210-02b4-e3f5ca9577df" } ] \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.freeze b/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.freeze index fa38ba91a95..4a8602fd913 100644 --- a/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.freeze +++ b/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.freeze @@ -1 +1 @@ -2026-04-03T21:03:10.520Z \ No newline at end of file +2026-04-16T20:03:12.932Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.json b/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.json index d9de91753fa..297f1a4fea9 100644 --- a/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.json +++ b/src/test/resources/cassettes/features/v2/Revoke_an_access_token_for_a_service_account_returns_No_Content_response.json @@ -3,7 +3,7 @@ "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1775250190@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" + "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1776369792@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" }, "headers": {}, "method": "POST", @@ -12,7 +12,7 @@ "secure": true }, "httpResponse": { - "body": "{\"data\":{\"type\":\"users\",\"id\":\"860878b5-2fa0-11f1-991f-62f4bfc595d0\",\"attributes\":{\"name\":null,\"handle\":\"860878b5-2fa0-11f1-991f-62f4bfc595d0\",\"created_at\":\"2026-04-03T21:03:11.517157+00:00\",\"modified_at\":\"2026-04-03T21:03:11.517157+00:00\",\"email\":\"test-revoke_an_access_token_for_a_service_account_returns_no_content_response-1775250190@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7d18813f3cbc71a5e46b1184fc3ad8fb?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", + "body": "{\"data\":{\"type\":\"users\",\"id\":\"4c99fbee-39cf-11f1-beb2-cad70c641dfa\",\"attributes\":{\"uuid\":\"4c99fbee-39cf-11f1-beb2-cad70c641dfa\",\"name\":null,\"handle\":\"4c99fbee-39cf-11f1-beb2-cad70c641dfa\",\"created_at\":\"2026-04-16T20:03:13.136998+00:00\",\"modified_at\":\"2026-04-16T20:03:13.136998+00:00\",\"email\":\"test-revoke_an_access_token_for_a_service_account_returns_no_content_response-1776369792@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7586d09a6a08e32a963f425a34463a4d?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", "headers": { "Content-Type": [ "application/json" @@ -27,22 +27,22 @@ "timeToLive": { "unlimited": true }, - "id": "8e80ce1e-baea-0855-a516-5204026b7cb0" + "id": "feae69d6-cf82-4560-fc06-fba6fe8c4884" }, { "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1775250190\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" + "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1776369792\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" }, "headers": {}, "method": "POST", - "path": "/api/v2/service_accounts/860878b5-2fa0-11f1-991f-62f4bfc595d0/access_tokens", + "path": "/api/v2/service_accounts/4c99fbee-39cf-11f1-beb2-cad70c641dfa/access_tokens", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"7346d75b-83f3-48ba-9186-899fc80bce16\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"3VWUVmuRsjFIKue2Uq9ii6\",\"created_at\":\"2026-04-03T21:03:11.782016283Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1775250190\",\"public_portion\":\"3VWUVmuRsjFIKue2Uq9ii6\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"860878b5-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"a5b5e3c3-2b58-448b-a1b1-5c97f16837a6\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:13.505344652Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxXxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Revoke_an_access_token_for_a_service_account_returns_No_Content_response-1776369792\",\"public_portion\":\"ddpat_52grBIAi4zKGY0uxhjLVVW\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"4c99fbee-39cf-11f1-beb2-cad70c641dfa\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -57,13 +57,13 @@ "timeToLive": { "unlimited": true }, - "id": "0f38e844-7171-92c4-d557-1f9a6b65056c" + "id": "8a5a8bec-f645-edef-33c1-e3ea927b06ff" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/service_accounts/860878b5-2fa0-11f1-991f-62f4bfc595d0/access_tokens/7346d75b-83f3-48ba-9186-899fc80bce16", + "path": "/api/v2/service_accounts/4c99fbee-39cf-11f1-beb2-cad70c641dfa/access_tokens/a5b5e3c3-2b58-448b-a1b1-5c97f16837a6", "keepAlive": false, "secure": true }, @@ -78,13 +78,13 @@ "timeToLive": { "unlimited": true }, - "id": "69600d26-98fc-c50d-de4a-9a91c7a31bbe" + "id": "9f2fc74e-4b0e-839a-3ec0-9da4a2a8ae4b" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/service_accounts/860878b5-2fa0-11f1-991f-62f4bfc595d0/access_tokens/7346d75b-83f3-48ba-9186-899fc80bce16", + "path": "/api/v2/service_accounts/4c99fbee-39cf-11f1-beb2-cad70c641dfa/access_tokens/a5b5e3c3-2b58-448b-a1b1-5c97f16837a6", "keepAlive": false, "secure": true }, @@ -99,13 +99,13 @@ "timeToLive": { "unlimited": true }, - "id": "69600d26-98fc-c50d-de4a-9a91c7a31bbf" + "id": "9f2fc74e-4b0e-839a-3ec0-9da4a2a8ae4c" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/users/860878b5-2fa0-11f1-991f-62f4bfc595d0", + "path": "/api/v2/users/4c99fbee-39cf-11f1-beb2-cad70c641dfa", "keepAlive": false, "secure": true }, @@ -120,6 +120,6 @@ "timeToLive": { "unlimited": true }, - "id": "6877b2e2-ef94-29e4-86b5-baf7800f86bd" + "id": "994e08b8-d361-e7d6-a7a2-8323e62d9c95" } ] \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.freeze b/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.freeze index 6a894d59da1..58278ff6c0f 100644 --- a/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.freeze +++ b/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.freeze @@ -1 +1 @@ -2026-04-03T21:03:12.499Z \ No newline at end of file +2026-04-16T20:03:14.527Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.json b/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.json index 084402251cc..790a7566ae7 100644 --- a/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.json +++ b/src/test/resources/cassettes/features/v2/Update_an_access_token_for_a_service_account_returns_OK_response.json @@ -3,7 +3,7 @@ "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1775250192@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" + "json": "{\"data\":{\"attributes\":{\"email\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1776369794@datadoghq.com\",\"service_account\":true,\"title\":\"user title\"},\"type\":\"users\"}}" }, "headers": {}, "method": "POST", @@ -12,7 +12,7 @@ "secure": true }, "httpResponse": { - "body": "{\"data\":{\"type\":\"users\",\"id\":\"86bdf0d7-2fa0-11f1-991f-62f4bfc595d0\",\"attributes\":{\"name\":null,\"handle\":\"86bdf0d7-2fa0-11f1-991f-62f4bfc595d0\",\"created_at\":\"2026-04-03T21:03:12.706435+00:00\",\"modified_at\":\"2026-04-03T21:03:12.706435+00:00\",\"email\":\"test-update_an_access_token_for_a_service_account_returns_ok_response-1775250192@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/8ef25c203ebdbe5e11acb74bd99ba7da?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", + "body": "{\"data\":{\"type\":\"users\",\"id\":\"4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4\",\"attributes\":{\"uuid\":\"4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4\",\"name\":null,\"handle\":\"4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4\",\"created_at\":\"2026-04-16T20:03:14.742691+00:00\",\"modified_at\":\"2026-04-16T20:03:14.742691+00:00\",\"email\":\"test-update_an_access_token_for_a_service_account_returns_ok_response-1776369794@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/05aacae415f13819561258b03c973881?s=48&d=retro\",\"title\":\"user title\",\"verified\":true,\"service_account\":true,\"disabled\":false,\"allowed_login_methods\":[],\"status\":\"Active\",\"last_login_time\":null},\"relationships\":{\"roles\":{\"data\":[]},\"org\":{\"data\":{\"type\":\"orgs\",\"id\":\"4dee724d-00cc-11ea-a77b-570c9d03c6c5\"}}}}}\n", "headers": { "Content-Type": [ "application/json" @@ -27,22 +27,22 @@ "timeToLive": { "unlimited": true }, - "id": "284472d5-9973-7d0e-2c04-6ac82d23b165" + "id": "fcac50ec-362b-af11-9f23-2eea03a03b40" }, { "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1775250192\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" + "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1776369794\",\"scopes\":[\"dashboards_read\"]},\"type\":\"personal_access_tokens\"}}" }, "headers": {}, "method": "POST", - "path": "/api/v2/service_accounts/86bdf0d7-2fa0-11f1-991f-62f4bfc595d0/access_tokens", + "path": "/api/v2/service_accounts/4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4/access_tokens", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"9a7d27cc-4969-4a57-990c-03c23a9f2adc\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"4hW0tyOpjf5Dj84mZaXqwe\",\"created_at\":\"2026-04-03T21:03:12.978132411Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxXxxx_xxxxxXxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1775250192\",\"public_portion\":\"4hW0tyOpjf5Dj84mZaXqwe\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"86bdf0d7-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"eafa3dd9-430d-4075-a183-63171c7f3de5\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:15.138533237Z\",\"expires_at\":null,\"key\":\"xxxxx_xxxxxxxxxxxxxxxxxxxxxx_xxxxxxxxxxxxxxxXxxxxxxxxxxxxxxxxxxxx\",\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1776369794\",\"public_portion\":\"ddpat_79OZ2nUHcB3McO399ZaVVt\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -57,22 +57,22 @@ "timeToLive": { "unlimited": true }, - "id": "00c32353-a37b-6c00-e267-5c108c52d533" + "id": "f623cff4-6c3a-0e83-71be-452b054aad18" }, { "httpRequest": { "body": { "type": "JSON", - "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1775250192-updated\"},\"id\":\"9a7d27cc-4969-4a57-990c-03c23a9f2adc\",\"type\":\"personal_access_tokens\"}}" + "json": "{\"data\":{\"attributes\":{\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1776369794-updated\"},\"id\":\"eafa3dd9-430d-4075-a183-63171c7f3de5\",\"type\":\"personal_access_tokens\"}}" }, "headers": {}, "method": "PATCH", - "path": "/api/v2/service_accounts/86bdf0d7-2fa0-11f1-991f-62f4bfc595d0/access_tokens/9a7d27cc-4969-4a57-990c-03c23a9f2adc", + "path": "/api/v2/service_accounts/4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4/access_tokens/eafa3dd9-430d-4075-a183-63171c7f3de5", "keepAlive": false, "secure": true }, "httpResponse": { - "body": "{\"data\":{\"id\":\"9a7d27cc-4969-4a57-990c-03c23a9f2adc\",\"type\":\"personal_access_tokens\",\"attributes\":{\"alias\":\"4hW0tyOpjf5Dj84mZaXqwe\",\"created_at\":\"2026-04-03T21:03:12.978132Z\",\"expires_at\":null,\"last_used_at\":null,\"modified_at\":\"2026-04-03T21:03:13.152078Z\",\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1775250192-updated\",\"public_portion\":\"4hW0tyOpjf5Dj84mZaXqwe\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"86bdf0d7-2fa0-11f1-991f-62f4bfc595d0\",\"type\":\"users\"}}}}}", + "body": "{\"data\":{\"id\":\"eafa3dd9-430d-4075-a183-63171c7f3de5\",\"type\":\"personal_access_tokens\",\"attributes\":{\"created_at\":\"2026-04-16T20:03:15.138533Z\",\"expires_at\":null,\"last_used_at\":null,\"modified_at\":\"2026-04-16T20:03:15.375809Z\",\"name\":\"Test-Update_an_access_token_for_a_service_account_returns_OK_response-1776369794-updated\",\"public_portion\":\"ddpat_79OZ2nUHcB3McO399ZaVVt\",\"scopes\":[\"dashboards_read\"]},\"relationships\":{\"owned_by\":{\"data\":{\"id\":\"4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4\",\"type\":\"users\"}}}}}", "headers": { "Content-Type": [ "application/vnd.api+json" @@ -87,13 +87,13 @@ "timeToLive": { "unlimited": true }, - "id": "601591e1-22a4-cbbd-2ab8-729d01a9e7bb" + "id": "10f62515-3f2f-dceb-9e2f-46e87cf0e500" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/service_accounts/86bdf0d7-2fa0-11f1-991f-62f4bfc595d0/access_tokens/9a7d27cc-4969-4a57-990c-03c23a9f2adc", + "path": "/api/v2/service_accounts/4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4/access_tokens/eafa3dd9-430d-4075-a183-63171c7f3de5", "keepAlive": false, "secure": true }, @@ -108,13 +108,13 @@ "timeToLive": { "unlimited": true }, - "id": "d69fc8d6-6af5-6d67-b249-12a17d3fc28f" + "id": "ade5368b-108f-866d-8803-6d4c5735ba3c" }, { "httpRequest": { "headers": {}, "method": "DELETE", - "path": "/api/v2/users/86bdf0d7-2fa0-11f1-991f-62f4bfc595d0", + "path": "/api/v2/users/4d8efdef-39cf-11f1-bf73-ce6d1c25b9b4", "keepAlive": false, "secure": true }, @@ -129,6 +129,6 @@ "timeToLive": { "unlimited": true }, - "id": "96de1c9c-aa07-1667-ed8e-5edd9be98b5e" + "id": "a3dce74c-505e-2fbb-b31a-a8b86157dc12" } ] \ No newline at end of file diff --git a/src/test/resources/com/datadog/api/client/v2/api/key_management.feature b/src/test/resources/com/datadog/api/client/v2/api/key_management.feature index 6c464845562..365c53ed7c2 100644 --- a/src/test/resources/com/datadog/api/client/v2/api/key_management.feature +++ b/src/test/resources/com/datadog/api/client/v2/api/key_management.feature @@ -221,7 +221,7 @@ Feature: Key Management @generated @skip @team:DataDog/credentials-management Scenario: Get a personal access token returns "Not Found" response Given new "GetPersonalAccessToken" request - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 404 Not Found @@ -229,7 +229,7 @@ Feature: Key Management Scenario: Get a personal access token returns "OK" response Given there is a valid "personal_access_token" in the system And new "GetPersonalAccessToken" request - And request contains "pat_uuid" parameter from "personal_access_token.data.id" + And request contains "pat_id" parameter from "personal_access_token.data.id" When the request is sent Then the response status is 200 OK And the response "data.type" is equal to "personal_access_tokens" @@ -355,21 +355,21 @@ Feature: Key Management Scenario: Revoke a personal access token returns "No Content" response Given there is a valid "personal_access_token" in the system And new "RevokePersonalAccessToken" request - And request contains "pat_uuid" parameter from "personal_access_token.data.id" + And request contains "pat_id" parameter from "personal_access_token.data.id" When the request is sent Then the response status is 204 No Content @generated @skip @team:DataDog/credentials-management Scenario: Revoke a personal access token returns "Not Found" response Given new "RevokePersonalAccessToken" request - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 404 Not Found @generated @skip @team:DataDog/credentials-management Scenario: Update a personal access token returns "Bad Request" response Given new "UpdatePersonalAccessToken" request - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" 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"}} When the request is sent Then the response status is 400 Bad Request @@ -377,7 +377,7 @@ Feature: Key Management @generated @skip @team:DataDog/credentials-management Scenario: Update a personal access token returns "Not Found" response Given new "UpdatePersonalAccessToken" request - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" 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"}} When the request is sent Then the response status is 404 Not Found @@ -386,7 +386,7 @@ Feature: Key Management Scenario: Update a personal access token returns "OK" response Given there is a valid "personal_access_token" in the system And new "UpdatePersonalAccessToken" request - And request contains "pat_uuid" parameter from "personal_access_token.data.id" + And request contains "pat_id" parameter from "personal_access_token.data.id" And body with value {"data": {"type": "personal_access_tokens", "id": "{{ personal_access_token.data.id }}", "attributes": {"name": "{{ unique }}-updated"}}} When the request is sent Then the response status is 200 OK diff --git a/src/test/resources/com/datadog/api/client/v2/api/service_accounts.feature b/src/test/resources/com/datadog/api/client/v2/api/service_accounts.feature index 25744abc832..fa8c81440e2 100644 --- a/src/test/resources/com/datadog/api/client/v2/api/service_accounts.feature +++ b/src/test/resources/com/datadog/api/client/v2/api/service_accounts.feature @@ -142,7 +142,7 @@ Feature: Service Accounts Scenario: Get an access token for a service account returns "Not Found" response Given new "GetServiceAccountAccessToken" request And request contains "service_account_id" parameter from "REPLACE.ME" - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 404 Not Found @@ -152,7 +152,7 @@ Feature: Service Accounts And there is a valid "service_account_access_token" for "service_account_user" And new "GetServiceAccountAccessToken" request And request contains "service_account_id" parameter from "service_account_user.data.id" - And request contains "pat_uuid" parameter from "service_account_access_token.data.id" + And request contains "pat_id" parameter from "service_account_access_token.data.id" When the request is sent Then the response status is 200 OK And the response "data.attributes.name" has the same value as "service_account_access_token.data.attributes.name" @@ -232,7 +232,7 @@ Feature: Service Accounts And there is a valid "service_account_access_token" for "service_account_user" And new "RevokeServiceAccountAccessToken" request And request contains "service_account_id" parameter from "service_account_user.data.id" - And request contains "pat_uuid" parameter from "service_account_access_token.data.id" + And request contains "pat_id" parameter from "service_account_access_token.data.id" When the request is sent Then the response status is 204 No Content @@ -240,7 +240,7 @@ Feature: Service Accounts Scenario: Revoke an access token for a service account returns "Not Found" response Given new "RevokeServiceAccountAccessToken" request And request contains "service_account_id" parameter from "REPLACE.ME" - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" When the request is sent Then the response status is 404 Not Found @@ -248,7 +248,7 @@ Feature: Service Accounts Scenario: Update an access token for a service account returns "Bad Request" response Given new "UpdateServiceAccountAccessToken" request And request contains "service_account_id" parameter from "REPLACE.ME" - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" 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"}} When the request is sent Then the response status is 400 Bad Request @@ -257,7 +257,7 @@ Feature: Service Accounts Scenario: Update an access token for a service account returns "Not Found" response Given new "UpdateServiceAccountAccessToken" request And request contains "service_account_id" parameter from "REPLACE.ME" - And request contains "pat_uuid" parameter from "REPLACE.ME" + And request contains "pat_id" parameter from "REPLACE.ME" 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"}} When the request is sent Then the response status is 404 Not Found @@ -268,7 +268,7 @@ Feature: Service Accounts And there is a valid "service_account_access_token" for "service_account_user" And new "UpdateServiceAccountAccessToken" request And request contains "service_account_id" parameter from "service_account_user.data.id" - And request contains "pat_uuid" parameter from "service_account_access_token.data.id" + And request contains "pat_id" parameter from "service_account_access_token.data.id" 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"}}} When the request is sent Then the response status is 200 OK diff --git a/src/test/resources/com/datadog/api/client/v2/api/undo.json b/src/test/resources/com/datadog/api/client/v2/api/undo.json index bbfa27e028c..00b8b2c334b 100644 --- a/src/test/resources/com/datadog/api/client/v2/api/undo.json +++ b/src/test/resources/com/datadog/api/client/v2/api/undo.json @@ -4293,7 +4293,7 @@ "operationId": "RevokePersonalAccessToken", "parameters": [ { - "name": "pat_uuid", + "name": "pat_id", "source": "data.id" } ], @@ -5846,7 +5846,7 @@ "source": "data.relationships.owned_by.data.id" }, { - "name": "pat_uuid", + "name": "pat_id", "source": "data.id" } ],