From f06518f662b782fcacfe9a2ffeb360efdec79141 Mon Sep 17 00:00:00 2001 From: Hari K Arla Date: Mon, 12 Jan 2026 21:10:32 +0530 Subject: [PATCH] feat(IAM Identity): add apikey expiration Signed-off-by: Hari K Arla --- .../iam_identity/v1/IamIdentity.java | 8 ++- .../iam_identity/v1/model/ApiKey.java | 15 ++++- .../ApiKeyInsideCreateServiceIdRequest.java | 56 ++++++++++++++++++- .../v1/model/CreateApiKeyOptions.java | 28 +++++++++- .../v1/model/UpdateApiKeyOptions.java | 28 +++++++++- .../model/UserReportMfaEnrollmentStatus.java | 37 ++++++++++-- .../iam_identity/v1/IamIdentityIT.java | 9 +++ .../iam_identity/v1/IamIdentityTest.java | 27 +++++---- ...piKeyInsideCreateServiceIdRequestTest.java | 8 ++- .../iam_identity/v1/model/ApiKeyTest.java | 3 +- .../v1/model/CreateApiKeyOptionsTest.java | 4 +- .../v1/model/CreateServiceIdOptionsTest.java | 6 +- .../model/ReportMfaEnrollmentStatusTest.java | 3 +- .../v1/model/UpdateApiKeyOptionsTest.java | 4 +- .../UserReportMfaEnrollmentStatusTest.java | 7 ++- 15 files changed, 210 insertions(+), 33 deletions(-) diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentity.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentity.java index a3009619ad..19c90e5489 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentity.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentity.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -715,6 +715,9 @@ public ServiceCall createApiKey(CreateApiKeyOptions createApiKeyOptions) if (createApiKeyOptions.actionWhenLeaked() != null) { contentJson.addProperty("action_when_leaked", createApiKeyOptions.actionWhenLeaked()); } + if (createApiKeyOptions.expiresAt() != null) { + contentJson.addProperty("expires_at", createApiKeyOptions.expiresAt()); + } builder.bodyJson(contentJson); ResponseConverter responseConverter = ResponseConverterUtils.getValue(new com.google.gson.reflect.TypeToken() { }.getType()); @@ -830,6 +833,9 @@ public ServiceCall updateApiKey(UpdateApiKeyOptions updateApiKeyOptions) if (updateApiKeyOptions.actionWhenLeaked() != null) { contentJson.addProperty("action_when_leaked", updateApiKeyOptions.actionWhenLeaked()); } + if (updateApiKeyOptions.expiresAt() != null) { + contentJson.addProperty("expires_at", updateApiKeyOptions.expiresAt()); + } builder.bodyJson(contentJson); ResponseConverter responseConverter = ResponseConverterUtils.getValue(new com.google.gson.reflect.TypeToken() { }.getType()); diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKey.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKey.java index 3b46a13f1b..b0e1ceffd7 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKey.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKey.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -42,6 +42,8 @@ public class ApiKey extends GenericModel { protected Boolean supportSessions; @SerializedName("action_when_leaked") protected String actionWhenLeaked; + @SerializedName("expires_at") + protected String expiresAt; protected String description; @SerializedName("iam_id") protected String iamId; @@ -190,6 +192,17 @@ public String getActionWhenLeaked() { return actionWhenLeaked; } + /** + * Gets the expiresAt. + * + * Date and time when the API key becomes invalid, ISO 8601 datetime in the format 'yyyy-MM-ddTHH:mm+0000'. + * + * @return the expiresAt + */ + public String getExpiresAt() { + return expiresAt; + } + /** * Gets the description. * diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequest.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequest.java index 786809e7d9..b619fe68f4 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequest.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -26,6 +26,10 @@ public class ApiKeyInsideCreateServiceIdRequest extends GenericModel { protected String apikey; @SerializedName("store_value") protected Boolean storeValue; + @SerializedName("action_when_leaked") + protected String actionWhenLeaked; + @SerializedName("expires_at") + protected String expiresAt; /** * Builder. @@ -35,6 +39,8 @@ public static class Builder { private String description; private String apikey; private Boolean storeValue; + private String actionWhenLeaked; + private String expiresAt; /** * Instantiates a new Builder from an existing ApiKeyInsideCreateServiceIdRequest instance. @@ -46,6 +52,8 @@ private Builder(ApiKeyInsideCreateServiceIdRequest apiKeyInsideCreateServiceIdRe this.description = apiKeyInsideCreateServiceIdRequest.description; this.apikey = apiKeyInsideCreateServiceIdRequest.apikey; this.storeValue = apiKeyInsideCreateServiceIdRequest.storeValue; + this.actionWhenLeaked = apiKeyInsideCreateServiceIdRequest.actionWhenLeaked; + this.expiresAt = apiKeyInsideCreateServiceIdRequest.expiresAt; } /** @@ -115,6 +123,28 @@ public Builder storeValue(Boolean storeValue) { this.storeValue = storeValue; return this; } + + /** + * Set the actionWhenLeaked. + * + * @param actionWhenLeaked the actionWhenLeaked + * @return the ApiKeyInsideCreateServiceIdRequest builder + */ + public Builder actionWhenLeaked(String actionWhenLeaked) { + this.actionWhenLeaked = actionWhenLeaked; + return this; + } + + /** + * Set the expiresAt. + * + * @param expiresAt the expiresAt + * @return the ApiKeyInsideCreateServiceIdRequest builder + */ + public Builder expiresAt(String expiresAt) { + this.expiresAt = expiresAt; + return this; + } } protected ApiKeyInsideCreateServiceIdRequest() { } @@ -126,6 +156,8 @@ protected ApiKeyInsideCreateServiceIdRequest(Builder builder) { description = builder.description; apikey = builder.apikey; storeValue = builder.storeValue; + actionWhenLeaked = builder.actionWhenLeaked; + expiresAt = builder.expiresAt; } /** @@ -188,5 +220,27 @@ public String apikey() { public Boolean storeValue() { return storeValue; } + + /** + * Gets the actionWhenLeaked. + * + * Defines the action to take when API key is leaked, valid values are 'none', 'disable' and 'delete'. + * + * @return the actionWhenLeaked + */ + public String actionWhenLeaked() { + return actionWhenLeaked; + } + + /** + * Gets the expiresAt. + * + * Date and time when the API key becomes invalid, ISO 8601 datetime in the format 'yyyy-MM-ddTHH:mm+0000'. + * + * @return the expiresAt + */ + public String expiresAt() { + return expiresAt; + } } diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptions.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptions.java index 1f09d22860..65570aeede 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptions.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptions.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -28,6 +28,7 @@ public class CreateApiKeyOptions extends GenericModel { protected Boolean storeValue; protected Boolean supportSessions; protected String actionWhenLeaked; + protected String expiresAt; protected String entityLock; protected String entityDisable; @@ -43,6 +44,7 @@ public static class Builder { private Boolean storeValue; private Boolean supportSessions; private String actionWhenLeaked; + private String expiresAt; private String entityLock; private String entityDisable; @@ -60,6 +62,7 @@ private Builder(CreateApiKeyOptions createApiKeyOptions) { this.storeValue = createApiKeyOptions.storeValue; this.supportSessions = createApiKeyOptions.supportSessions; this.actionWhenLeaked = createApiKeyOptions.actionWhenLeaked; + this.expiresAt = createApiKeyOptions.expiresAt; this.entityLock = createApiKeyOptions.entityLock; this.entityDisable = createApiKeyOptions.entityDisable; } @@ -178,6 +181,17 @@ public Builder actionWhenLeaked(String actionWhenLeaked) { return this; } + /** + * Set the expiresAt. + * + * @param expiresAt the expiresAt + * @return the CreateApiKeyOptions builder + */ + public Builder expiresAt(String expiresAt) { + this.expiresAt = expiresAt; + return this; + } + /** * Set the entityLock. * @@ -216,6 +230,7 @@ protected CreateApiKeyOptions(Builder builder) { storeValue = builder.storeValue; supportSessions = builder.supportSessions; actionWhenLeaked = builder.actionWhenLeaked; + expiresAt = builder.expiresAt; entityLock = builder.entityLock; entityDisable = builder.entityDisable; } @@ -327,6 +342,17 @@ public String actionWhenLeaked() { return actionWhenLeaked; } + /** + * Gets the expiresAt. + * + * Date and time when the API key becomes invalid, ISO 8601 datetime in the format 'yyyy-MM-ddTHH:mm+0000'. + * + * @return the expiresAt + */ + public String expiresAt() { + return expiresAt; + } + /** * Gets the entityLock. * diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptions.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptions.java index e3b1d83a51..4c82e1d35a 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptions.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptions.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -26,6 +26,7 @@ public class UpdateApiKeyOptions extends GenericModel { protected String description; protected Boolean supportSessions; protected String actionWhenLeaked; + protected String expiresAt; /** * Builder. @@ -37,6 +38,7 @@ public static class Builder { private String description; private Boolean supportSessions; private String actionWhenLeaked; + private String expiresAt; /** * Instantiates a new Builder from an existing UpdateApiKeyOptions instance. @@ -50,6 +52,7 @@ private Builder(UpdateApiKeyOptions updateApiKeyOptions) { this.description = updateApiKeyOptions.description; this.supportSessions = updateApiKeyOptions.supportSessions; this.actionWhenLeaked = updateApiKeyOptions.actionWhenLeaked; + this.expiresAt = updateApiKeyOptions.expiresAt; } /** @@ -143,6 +146,17 @@ public Builder actionWhenLeaked(String actionWhenLeaked) { this.actionWhenLeaked = actionWhenLeaked; return this; } + + /** + * Set the expiresAt. + * + * @param expiresAt the expiresAt + * @return the UpdateApiKeyOptions builder + */ + public Builder expiresAt(String expiresAt) { + this.expiresAt = expiresAt; + return this; + } } protected UpdateApiKeyOptions() { } @@ -158,6 +172,7 @@ protected UpdateApiKeyOptions(Builder builder) { description = builder.description; supportSessions = builder.supportSessions; actionWhenLeaked = builder.actionWhenLeaked; + expiresAt = builder.expiresAt; } /** @@ -240,5 +255,16 @@ public Boolean supportSessions() { public String actionWhenLeaked() { return actionWhenLeaked; } + + /** + * Gets the expiresAt. + * + * Date and time when the API key becomes invalid, ISO 8601 datetime in the format 'yyyy-MM-ddTHH:mm+0000'. + * + * @return the expiresAt + */ + public String expiresAt() { + return expiresAt; + } } diff --git a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatus.java b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatus.java index 011b89321f..a7928c5a5e 100644 --- a/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatus.java +++ b/modules/iam-identity/src/main/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatus.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -26,7 +26,12 @@ public class UserReportMfaEnrollmentStatus extends GenericModel { protected String name; protected String username; protected String email; - protected MfaEnrollments enrollments; + @SerializedName("effective_mfa_type") + protected String effectiveMfaType; + @SerializedName("id_based_mfa") + protected IdBasedMfaEnrollment idBasedMfa; + @SerializedName("account_based_mfa") + protected AccountBasedMfaEnrollment accountBasedMfa; protected UserReportMfaEnrollmentStatus() { } @@ -75,12 +80,32 @@ public String getEmail() { } /** - * Gets the enrollments. + * Gets the effectiveMfaType. * - * @return the enrollments + * currently effective mfa type i.e. id_based_mfa or account_based_mfa. + * + * @return the effectiveMfaType + */ + public String getEffectiveMfaType() { + return effectiveMfaType; + } + + /** + * Gets the idBasedMfa. + * + * @return the idBasedMfa + */ + public IdBasedMfaEnrollment getIdBasedMfa() { + return idBasedMfa; + } + + /** + * Gets the accountBasedMfa. + * + * @return the accountBasedMfa */ - public MfaEnrollments getEnrollments() { - return enrollments; + public AccountBasedMfaEnrollment getAccountBasedMfa() { + return accountBasedMfa; } } diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityIT.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityIT.java index 570b98f88f..8159aa17cf 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityIT.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityIT.java @@ -155,6 +155,7 @@ public void testCreateApiKey1() throws Exception { .name(APIKEY_NAME) .iamId(IAM_ID) .description("JavaSDK test apikey #1") + .expiresAt("2049-01-02T18:30:00+0000") .build(); Response response = service.createApiKey(createApiKeyOptions).execute(); @@ -369,6 +370,7 @@ public void testUpdateApiKey() throws Exception { .id(apikeyId1) .ifMatch(apikeyEtag1) .description(newDescription) + .expiresAt("2049-01-02T18:30:00+0000") .build(); Response response = service.updateApiKey(updateApiKeyOptions).execute(); @@ -494,10 +496,17 @@ public void testDeleteApiKey1() throws Exception { @Test public void testCreateServiceId() throws Exception { try { + ApiKeyInsideCreateServiceIdRequest apiKeyInsideCreateServiceIdRequestModel = new ApiKeyInsideCreateServiceIdRequest.Builder() + .name("APIKey name") + .storeValue(true) + .expiresAt("2049-01-02T18:30:00+0000") + .build(); + CreateServiceIdOptions createServiceIdOptions = new CreateServiceIdOptions.Builder() .accountId(ACCOUNT_ID) .name(SERVICEID_NAME) .description("JavaSDK test serviceId") + .apikey(apiKeyInsideCreateServiceIdRequestModel) .build(); Response response = service.createServiceId(createServiceIdOptions).execute(); assertNotNull(response); diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityTest.java index e510c42e85..da1ccb75c4 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/IamIdentityTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -113,7 +113,6 @@ import com.ibm.cloud.platform_services.iam_identity.v1.model.LockApiKeyOptions; import com.ibm.cloud.platform_services.iam_identity.v1.model.LockServiceIdOptions; import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollmentTypeStatus; -import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollments; import com.ibm.cloud.platform_services.iam_identity.v1.model.PolicyTemplateReference; import com.ibm.cloud.platform_services.iam_identity.v1.model.ProfileClaimRule; import com.ibm.cloud.platform_services.iam_identity.v1.model.ProfileClaimRuleConditions; @@ -207,7 +206,7 @@ public void testConstructorWithNullAuthenticator() throws Throwable { @Test public void testListServiceIdsWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"offset\": 6, \"limit\": 5, \"first\": \"first\", \"previous\": \"previous\", \"next\": \"next\", \"serviceids\": [{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}]}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"offset\": 6, \"limit\": 5, \"first\": \"first\", \"previous\": \"previous\", \"next\": \"next\", \"serviceids\": [{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}]}"; String listServiceIdsPath = "/v1/serviceids/"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -270,7 +269,7 @@ public void testListServiceIdsWRetries() throws Throwable { @Test public void testCreateServiceIdWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String createServiceIdPath = "/v1/serviceids/"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -283,6 +282,8 @@ public void testCreateServiceIdWOptions() throws Throwable { .description("testString") .apikey("testString") .storeValue(true) + .actionWhenLeaked("testString") + .expiresAt("testString") .build(); // Construct an instance of the CreateServiceIdOptions model @@ -337,7 +338,7 @@ public void testCreateServiceIdNoOptions() throws Throwable { @Test public void testGetServiceIdWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String getServiceIdPath = "/v1/serviceids/testString"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -394,7 +395,7 @@ public void testGetServiceIdNoOptions() throws Throwable { @Test public void testUpdateServiceIdWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"iam_id\": \"iamId\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"account_id\": \"accountId\", \"group_id\": \"groupId\", \"name\": \"name\", \"description\": \"description\", \"unique_instance_crns\": [\"uniqueInstanceCrns\"], \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"apikey\": {\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}, \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String updateServiceIdPath = "/v1/serviceids/testString"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -858,7 +859,7 @@ public void testDeleteServiceIdGroupNoOptions() throws Throwable { @Test public void testListApiKeysWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"offset\": 6, \"limit\": 5, \"first\": \"first\", \"previous\": \"previous\", \"next\": \"next\", \"apikeys\": [{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}]}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"offset\": 6, \"limit\": 5, \"first\": \"first\", \"previous\": \"previous\", \"next\": \"next\", \"apikeys\": [{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}]}"; String listApiKeysPath = "/v1/apikeys"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -923,7 +924,7 @@ public void testListApiKeysWRetries() throws Throwable { @Test public void testCreateApiKeyWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String createApiKeyPath = "/v1/apikeys"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -940,6 +941,7 @@ public void testCreateApiKeyWOptions() throws Throwable { .storeValue(true) .supportSessions(true) .actionWhenLeaked("testString") + .expiresAt("testString") .entityLock("false") .entityDisable("false") .build(); @@ -983,7 +985,7 @@ public void testCreateApiKeyNoOptions() throws Throwable { @Test public void testGetApiKeysDetailsWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String getApiKeysDetailsPath = "/v1/apikeys/details"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -1029,7 +1031,7 @@ public void testGetApiKeysDetailsWRetries() throws Throwable { @Test public void testGetApiKeyWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String getApiKeyPath = "/v1/apikeys/testString"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -1084,7 +1086,7 @@ public void testGetApiKeyNoOptions() throws Throwable { @Test public void testUpdateApiKeyWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; + String mockResponseBody = "{\"context\": {\"transaction_id\": \"transactionId\", \"operation\": \"operation\", \"user_agent\": \"userAgent\", \"url\": \"url\", \"instance_id\": \"instanceId\", \"thread_id\": \"threadId\", \"host\": \"host\", \"start_time\": \"startTime\", \"end_time\": \"endTime\", \"elapsed_time\": \"elapsedTime\", \"cluster_name\": \"clusterName\"}, \"id\": \"id\", \"entity_tag\": \"entityTag\", \"crn\": \"crn\", \"locked\": true, \"disabled\": true, \"created_at\": \"2019-01-01T12:00:00.000Z\", \"created_by\": \"createdBy\", \"modified_at\": \"2019-01-01T12:00:00.000Z\", \"name\": \"name\", \"support_sessions\": false, \"action_when_leaked\": \"actionWhenLeaked\", \"expires_at\": \"expiresAt\", \"description\": \"description\", \"iam_id\": \"iamId\", \"account_id\": \"accountId\", \"apikey\": \"apikey\", \"history\": [{\"timestamp\": \"timestamp\", \"iam_id\": \"iamId\", \"iam_id_account\": \"iamIdAccount\", \"action\": \"action\", \"params\": [\"params\"], \"message\": \"message\"}], \"activity\": {\"last_authn\": \"lastAuthn\", \"authn_count\": 10}}"; String updateApiKeyPath = "/v1/apikeys/testString"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") @@ -1099,6 +1101,7 @@ public void testUpdateApiKeyWOptions() throws Throwable { .description("testString") .supportSessions(true) .actionWhenLeaked("testString") + .expiresAt("testString") .build(); // Invoke updateApiKey() with a valid options model and verify the result @@ -2946,7 +2949,7 @@ public void testCreateMfaReportNoOptions() throws Throwable { @Test public void testGetMfaReportWOptions() throws Throwable { // Register a mock response - String mockResponseBody = "{\"created_by\": \"createdBy\", \"reference\": \"reference\", \"report_time\": \"reportTime\", \"account_id\": \"accountId\", \"ims_account_id\": \"imsAccountId\", \"users\": [{\"iam_id\": \"iamId\", \"name\": \"name\", \"username\": \"username\", \"email\": \"email\", \"enrollments\": {\"effective_mfa_type\": \"effectiveMfaType\", \"id_based_mfa\": {\"trait_account_default\": \"NONE\", \"trait_user_specific\": \"NONE\", \"trait_effective\": \"NONE\", \"complies\": true, \"comply_state\": \"NO\"}, \"account_based_mfa\": {\"security_questions\": {\"required\": true, \"enrolled\": true}, \"totp\": {\"required\": true, \"enrolled\": true}, \"verisign\": {\"required\": true, \"enrolled\": true}, \"complies\": true}}}]}"; + String mockResponseBody = "{\"created_by\": \"createdBy\", \"reference\": \"reference\", \"report_time\": \"reportTime\", \"account_id\": \"accountId\", \"ims_account_id\": \"imsAccountId\", \"users\": [{\"iam_id\": \"iamId\", \"name\": \"name\", \"username\": \"username\", \"email\": \"email\", \"effective_mfa_type\": \"effectiveMfaType\", \"id_based_mfa\": {\"trait_account_default\": \"NONE\", \"trait_user_specific\": \"NONE\", \"trait_effective\": \"NONE\", \"complies\": true, \"comply_state\": \"NO\"}, \"account_based_mfa\": {\"security_questions\": {\"required\": true, \"enrolled\": true}, \"totp\": {\"required\": true, \"enrolled\": true}, \"verisign\": {\"required\": true, \"enrolled\": true}, \"complies\": true}}]}"; String getMfaReportPath = "/v1/mfa/accounts/testString/report/testString"; server.enqueue(new MockResponse() .setHeader("Content-type", "application/json") diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequestTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequestTest.java index 51e2a2ce88..8e9af21ea4 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequestTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyInsideCreateServiceIdRequestTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -36,11 +36,15 @@ public void testApiKeyInsideCreateServiceIdRequest() throws Throwable { .description("testString") .apikey("testString") .storeValue(true) + .actionWhenLeaked("testString") + .expiresAt("testString") .build(); assertEquals(apiKeyInsideCreateServiceIdRequestModel.name(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.description(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.apikey(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.storeValue(), Boolean.valueOf(true)); + assertEquals(apiKeyInsideCreateServiceIdRequestModel.actionWhenLeaked(), "testString"); + assertEquals(apiKeyInsideCreateServiceIdRequestModel.expiresAt(), "testString"); String json = TestUtilities.serialize(apiKeyInsideCreateServiceIdRequestModel); @@ -50,6 +54,8 @@ public void testApiKeyInsideCreateServiceIdRequest() throws Throwable { assertEquals(apiKeyInsideCreateServiceIdRequestModelNew.description(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModelNew.apikey(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModelNew.storeValue(), Boolean.valueOf(true)); + assertEquals(apiKeyInsideCreateServiceIdRequestModelNew.actionWhenLeaked(), "testString"); + assertEquals(apiKeyInsideCreateServiceIdRequestModelNew.expiresAt(), "testString"); } @Test(expectedExceptions = IllegalArgumentException.class) diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyTest.java index 5849aaa5bd..17291d81ba 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ApiKeyTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -47,6 +47,7 @@ public void testApiKey() throws Throwable { assertNull(apiKeyModel.getName()); assertNull(apiKeyModel.isSupportSessions()); assertNull(apiKeyModel.getActionWhenLeaked()); + assertNull(apiKeyModel.getExpiresAt()); assertNull(apiKeyModel.getDescription()); assertNull(apiKeyModel.getIamId()); assertNull(apiKeyModel.getAccountId()); diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptionsTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptionsTest.java index df97fd6600..3bd6c72307 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptionsTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateApiKeyOptionsTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -40,6 +40,7 @@ public void testCreateApiKeyOptions() throws Throwable { .storeValue(true) .supportSessions(true) .actionWhenLeaked("testString") + .expiresAt("testString") .entityLock("false") .entityDisable("false") .build(); @@ -51,6 +52,7 @@ public void testCreateApiKeyOptions() throws Throwable { assertEquals(createApiKeyOptionsModel.storeValue(), Boolean.valueOf(true)); assertEquals(createApiKeyOptionsModel.supportSessions(), Boolean.valueOf(true)); assertEquals(createApiKeyOptionsModel.actionWhenLeaked(), "testString"); + assertEquals(createApiKeyOptionsModel.expiresAt(), "testString"); assertEquals(createApiKeyOptionsModel.entityLock(), "false"); assertEquals(createApiKeyOptionsModel.entityDisable(), "false"); } diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateServiceIdOptionsTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateServiceIdOptionsTest.java index 6986351d63..9402ad8f4b 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateServiceIdOptionsTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/CreateServiceIdOptionsTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -37,11 +37,15 @@ public void testCreateServiceIdOptions() throws Throwable { .description("testString") .apikey("testString") .storeValue(true) + .actionWhenLeaked("testString") + .expiresAt("testString") .build(); assertEquals(apiKeyInsideCreateServiceIdRequestModel.name(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.description(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.apikey(), "testString"); assertEquals(apiKeyInsideCreateServiceIdRequestModel.storeValue(), Boolean.valueOf(true)); + assertEquals(apiKeyInsideCreateServiceIdRequestModel.actionWhenLeaked(), "testString"); + assertEquals(apiKeyInsideCreateServiceIdRequestModel.expiresAt(), "testString"); CreateServiceIdOptions createServiceIdOptionsModel = new CreateServiceIdOptions.Builder() .accountId("testString") diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ReportMfaEnrollmentStatusTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ReportMfaEnrollmentStatusTest.java index 65576d4e60..77e10d08c6 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ReportMfaEnrollmentStatusTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/ReportMfaEnrollmentStatusTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -16,7 +16,6 @@ import com.ibm.cloud.platform_services.iam_identity.v1.model.AccountBasedMfaEnrollment; import com.ibm.cloud.platform_services.iam_identity.v1.model.IdBasedMfaEnrollment; import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollmentTypeStatus; -import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollments; import com.ibm.cloud.platform_services.iam_identity.v1.model.ReportMfaEnrollmentStatus; import com.ibm.cloud.platform_services.iam_identity.v1.model.UserReportMfaEnrollmentStatus; import com.ibm.cloud.platform_services.iam_identity.v1.utils.TestUtilities; diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptionsTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptionsTest.java index a797daf3d4..53a22e51b8 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptionsTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UpdateApiKeyOptionsTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -38,6 +38,7 @@ public void testUpdateApiKeyOptions() throws Throwable { .description("testString") .supportSessions(true) .actionWhenLeaked("testString") + .expiresAt("testString") .build(); assertEquals(updateApiKeyOptionsModel.id(), "testString"); assertEquals(updateApiKeyOptionsModel.ifMatch(), "testString"); @@ -45,6 +46,7 @@ public void testUpdateApiKeyOptions() throws Throwable { assertEquals(updateApiKeyOptionsModel.description(), "testString"); assertEquals(updateApiKeyOptionsModel.supportSessions(), Boolean.valueOf(true)); assertEquals(updateApiKeyOptionsModel.actionWhenLeaked(), "testString"); + assertEquals(updateApiKeyOptionsModel.expiresAt(), "testString"); } @Test(expectedExceptions = IllegalArgumentException.class) diff --git a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatusTest.java b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatusTest.java index a416139f3c..ddf364942e 100644 --- a/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatusTest.java +++ b/modules/iam-identity/src/test/java/com/ibm/cloud/platform_services/iam_identity/v1/model/UserReportMfaEnrollmentStatusTest.java @@ -1,5 +1,5 @@ /* - * (C) Copyright IBM Corp. 2025. + * (C) Copyright IBM Corp. 2026. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at @@ -16,7 +16,6 @@ import com.ibm.cloud.platform_services.iam_identity.v1.model.AccountBasedMfaEnrollment; import com.ibm.cloud.platform_services.iam_identity.v1.model.IdBasedMfaEnrollment; import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollmentTypeStatus; -import com.ibm.cloud.platform_services.iam_identity.v1.model.MfaEnrollments; import com.ibm.cloud.platform_services.iam_identity.v1.model.UserReportMfaEnrollmentStatus; import com.ibm.cloud.platform_services.iam_identity.v1.utils.TestUtilities; import com.ibm.cloud.sdk.core.service.model.FileWithMetadata; @@ -40,6 +39,8 @@ public void testUserReportMfaEnrollmentStatus() throws Throwable { assertNull(userReportMfaEnrollmentStatusModel.getName()); assertNull(userReportMfaEnrollmentStatusModel.getUsername()); assertNull(userReportMfaEnrollmentStatusModel.getEmail()); - assertNull(userReportMfaEnrollmentStatusModel.getEnrollments()); + assertNull(userReportMfaEnrollmentStatusModel.getEffectiveMfaType()); + assertNull(userReportMfaEnrollmentStatusModel.getIdBasedMfa()); + assertNull(userReportMfaEnrollmentStatusModel.getAccountBasedMfa()); } } \ No newline at end of file