diff --git a/.apigentools-info b/.apigentools-info index d703be69617..000a4d982d2 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.6.5", - "regenerated": "2023-07-10 17:45:14.758583", - "spec_repo_commit": "9e0b471a" + "regenerated": "2023-07-11 14:36:43.463695", + "spec_repo_commit": "7ca677d6" }, "v2": { "apigentools_version": "1.6.5", - "regenerated": "2023-07-10 17:45:14.774389", - "spec_repo_commit": "9e0b471a" + "regenerated": "2023-07-11 14:36:43.479079", + "spec_repo_commit": "7ca677d6" } } } \ No newline at end of file diff --git a/.generator/schemas/v1/openapi.yaml b/.generator/schemas/v1/openapi.yaml index 41f98f88604..ba7f53a8a08 100644 --- a/.generator/schemas/v1/openapi.yaml +++ b/.generator/schemas/v1/openapi.yaml @@ -352,7 +352,6 @@ components: type: array type: object AccessRole: - default: st description: The access role of the user. Options are **st** (standard user), **adm** (admin user), or **ro** (read-only user). enum: @@ -360,7 +359,8 @@ components: - adm - ro - ERROR - example: st + example: ro + nullable: true type: string x-enum-varnames: - STANDARD diff --git a/.generator/src/generator/formatter.py b/.generator/src/generator/formatter.py index 3c8fd0b38bc..962294f09d2 100644 --- a/.generator/src/generator/formatter.py +++ b/.generator/src/generator/formatter.py @@ -328,8 +328,12 @@ def format_data_with_schema( default_name=None, ): name, imports = get_name_and_imports(schema) - if "enum" in schema and data not in schema["enum"]: - raise ValueError(f"{data} is not valid enum value {schema['enum']}") + nullable = schema.get("nullable", False) + if "enum" in schema: + if nullable and data is None: + pass + elif data not in schema["enum"]: + raise ValueError(f"{data} is not valid enum value {schema['enum']}") if replace_values and data in replace_values: parameters = replace_values[data] @@ -337,7 +341,7 @@ def format_data_with_schema( if isinstance(parameters, str) and schema.get("format") == "double": parameters = f"Long.valueOf({parameters}).doubleValue()" else: - if schema.get("nullable") and data is None: + if nullable and data is None: parameters = "null" else: @@ -385,13 +389,12 @@ def open_file(x): parameters = formatter(data) if "enum" in schema and name: - # find schema index and get name from x-enum-varnames - index = schema["enum"].index(data) - enum_varnames = schema["x-enum-varnames"][index] - parameters = f"{name}.{enum_varnames}" - imports.add(name) - # TODO handle nullable enums if necessary and replaced data - # parameters = f"{name}.fromValue({parameters})" + if data is not None: + # find schema index and get name from x-enum-varnames + index = schema["enum"].index(data) + enum_varnames = schema["x-enum-varnames"][index] + parameters = f"{name}.{enum_varnames}" + imports.add(name) if schema.get("nullable") and schema.get("type") is not None: return name, parameters, imports diff --git a/examples/v1/organizations/UpdateOrg.java b/examples/v1/organizations/UpdateOrg.java index d0de42dfcfd..65bade6dc01 100644 --- a/examples/v1/organizations/UpdateOrg.java +++ b/examples/v1/organizations/UpdateOrg.java @@ -30,7 +30,7 @@ public static void main(String[] args) { new OrganizationSettings() .privateWidgetShare(false) .saml(new OrganizationSettingsSaml().enabled(false)) - .samlAutocreateAccessRole(AccessRole.STANDARD) + .samlAutocreateAccessRole(AccessRole.READ_ONLY) .samlAutocreateUsersDomains( new OrganizationSettingsSamlAutocreateUsersDomains() .domains(Collections.singletonList("example.com")) diff --git a/examples/v1/users/CreateUser.java b/examples/v1/users/CreateUser.java index e56e72ca852..1b72b59ad3a 100644 --- a/examples/v1/users/CreateUser.java +++ b/examples/v1/users/CreateUser.java @@ -14,7 +14,7 @@ public static void main(String[] args) { User body = new User() - .accessRole(AccessRole.STANDARD) + .accessRole(AccessRole.READ_ONLY) .disabled(false) .email("test@datadoghq.com") .handle("test@datadoghq.com") diff --git a/examples/v1/users/CreateUser_266604071.java b/examples/v1/users/CreateUser_266604071.java new file mode 100644 index 00000000000..928063e3e97 --- /dev/null +++ b/examples/v1/users/CreateUser_266604071.java @@ -0,0 +1,33 @@ +// Create a user returns null access role + +import com.datadog.api.client.ApiClient; +import com.datadog.api.client.ApiException; +import com.datadog.api.client.v1.api.UsersApi; +import com.datadog.api.client.v1.model.User; +import com.datadog.api.client.v1.model.UserResponse; + +public class Example { + public static void main(String[] args) { + ApiClient defaultClient = ApiClient.getDefaultApiClient(); + UsersApi apiInstance = new UsersApi(defaultClient); + + User body = + new User() + .accessRole(null) + .disabled(false) + .email("test@datadoghq.com") + .handle("test@datadoghq.com") + .name("test user"); + + try { + UserResponse result = apiInstance.createUser(body); + System.out.println(result); + } catch (ApiException e) { + System.err.println("Exception when calling UsersApi#createUser"); + System.err.println("Status code: " + e.getCode()); + System.err.println("Reason: " + e.getResponseBody()); + System.err.println("Response headers: " + e.getResponseHeaders()); + e.printStackTrace(); + } + } +} diff --git a/examples/v1/users/UpdateUser.java b/examples/v1/users/UpdateUser.java index 4b81d5ddec8..740a5e4be9d 100644 --- a/examples/v1/users/UpdateUser.java +++ b/examples/v1/users/UpdateUser.java @@ -14,7 +14,7 @@ public static void main(String[] args) { User body = new User() - .accessRole(AccessRole.STANDARD) + .accessRole(AccessRole.READ_ONLY) .disabled(false) .email("test@datadoghq.com") .handle("test@datadoghq.com") diff --git a/src/main/java/com/datadog/api/client/v1/model/OrganizationSettings.java b/src/main/java/com/datadog/api/client/v1/model/OrganizationSettings.java index b370818fb40..4a5d3935776 100644 --- a/src/main/java/com/datadog/api/client/v1/model/OrganizationSettings.java +++ b/src/main/java/com/datadog/api/client/v1/model/OrganizationSettings.java @@ -15,6 +15,7 @@ import java.util.HashMap; import java.util.Map; import java.util.Objects; +import org.openapitools.jackson.nullable.JsonNullable; /** A JSON array of settings. */ @JsonPropertyOrder({ @@ -41,7 +42,7 @@ public class OrganizationSettings { public static final String JSON_PROPERTY_SAML_AUTOCREATE_ACCESS_ROLE = "saml_autocreate_access_role"; - private AccessRole samlAutocreateAccessRole = AccessRole.STANDARD; + private JsonNullable samlAutocreateAccessRole = JsonNullable.undefined(); public static final String JSON_PROPERTY_SAML_AUTOCREATE_USERS_DOMAINS = "saml_autocreate_users_domains"; @@ -111,8 +112,7 @@ public void setSaml(OrganizationSettingsSaml saml) { } public OrganizationSettings samlAutocreateAccessRole(AccessRole samlAutocreateAccessRole) { - this.samlAutocreateAccessRole = samlAutocreateAccessRole; - this.unparsed |= !samlAutocreateAccessRole.isValid(); + this.samlAutocreateAccessRole = JsonNullable.of(samlAutocreateAccessRole); return this; } @@ -123,17 +123,28 @@ public OrganizationSettings samlAutocreateAccessRole(AccessRole samlAutocreateAc * @return samlAutocreateAccessRole */ @jakarta.annotation.Nullable + @JsonIgnore + public AccessRole getSamlAutocreateAccessRole() { + return samlAutocreateAccessRole.orElse(null); + } + @JsonProperty(JSON_PROPERTY_SAML_AUTOCREATE_ACCESS_ROLE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public AccessRole getSamlAutocreateAccessRole() { + public JsonNullable getSamlAutocreateAccessRole_JsonNullable() { return samlAutocreateAccessRole; } + @JsonProperty(JSON_PROPERTY_SAML_AUTOCREATE_ACCESS_ROLE) + public void setSamlAutocreateAccessRole_JsonNullable( + JsonNullable samlAutocreateAccessRole) { + this.samlAutocreateAccessRole = samlAutocreateAccessRole; + } + public void setSamlAutocreateAccessRole(AccessRole samlAutocreateAccessRole) { if (!samlAutocreateAccessRole.isValid()) { this.unparsed = true; } - this.samlAutocreateAccessRole = samlAutocreateAccessRole; + this.samlAutocreateAccessRole = JsonNullable.of(samlAutocreateAccessRole); } public OrganizationSettings samlAutocreateUsersDomains( diff --git a/src/main/java/com/datadog/api/client/v1/model/User.java b/src/main/java/com/datadog/api/client/v1/model/User.java index 01ee75b0602..ac30819f4b3 100644 --- a/src/main/java/com/datadog/api/client/v1/model/User.java +++ b/src/main/java/com/datadog/api/client/v1/model/User.java @@ -15,6 +15,7 @@ import java.util.HashMap; import java.util.Map; import java.util.Objects; +import org.openapitools.jackson.nullable.JsonNullable; /** Create, edit, and disable users. */ @JsonPropertyOrder({ @@ -31,7 +32,7 @@ public class User { @JsonIgnore public boolean unparsed = false; public static final String JSON_PROPERTY_ACCESS_ROLE = "access_role"; - private AccessRole accessRole = AccessRole.STANDARD; + private JsonNullable accessRole = JsonNullable.undefined(); public static final String JSON_PROPERTY_DISABLED = "disabled"; private Boolean disabled; @@ -52,8 +53,7 @@ public class User { private Boolean verified; public User accessRole(AccessRole accessRole) { - this.accessRole = accessRole; - this.unparsed |= !accessRole.isValid(); + this.accessRole = JsonNullable.of(accessRole); return this; } @@ -64,17 +64,27 @@ public User accessRole(AccessRole accessRole) { * @return accessRole */ @jakarta.annotation.Nullable + @JsonIgnore + public AccessRole getAccessRole() { + return accessRole.orElse(null); + } + @JsonProperty(JSON_PROPERTY_ACCESS_ROLE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) - public AccessRole getAccessRole() { + public JsonNullable getAccessRole_JsonNullable() { return accessRole; } + @JsonProperty(JSON_PROPERTY_ACCESS_ROLE) + public void setAccessRole_JsonNullable(JsonNullable accessRole) { + this.accessRole = accessRole; + } + public void setAccessRole(AccessRole accessRole) { if (!accessRole.isValid()) { this.unparsed = true; } - this.accessRole = accessRole; + this.accessRole = JsonNullable.of(accessRole); } public User disabled(Boolean disabled) { diff --git a/src/test/java/com/datadog/api/client/v1/api/UsersApiTest.java b/src/test/java/com/datadog/api/client/v1/api/UsersApiTest.java index 0b6b55cb984..505b44bb119 100644 --- a/src/test/java/com/datadog/api/client/v1/api/UsersApiTest.java +++ b/src/test/java/com/datadog/api/client/v1/api/UsersApiTest.java @@ -37,7 +37,6 @@ public class UsersApiTest extends V1ApiTest { private final String apiUri = "/api/v1/user"; private final String fixturePrefix = "client/v1/api/user_fixtures"; - private final AccessRole testingUserAR = AccessRole.STANDARD; private ArrayList disableUsers = null; @Override @@ -77,7 +76,6 @@ public void userCreateModifyDisableTest() throws ApiException { String testingUserName = getUniqueEntityName(47); String testingUserHandle = testingUserName.toLowerCase() + "@datadoghq.com"; User user = new User(); - user.setAccessRole(testingUserAR); user.setHandle(testingUserHandle); user.setName(testingUserName); UserResponse response = api.createUser(user); @@ -87,12 +85,14 @@ public void userCreateModifyDisableTest() throws ApiException { user = response.getUser(); assertEquals(testingUserHandle, user.getHandle()); assertEquals(testingUserName, user.getName()); - assertEquals(testingUserAR.toString(), user.getAccessRole().toString()); // Now test updating user - user.setName(testingUserName + "-updated"); - user.setDisabled(false); - response = api.updateUser(user.getHandle(), user); + User updatedUser = new User(); + updatedUser.setHandle(testingUserHandle); + updatedUser.setName(testingUserName + "-updated"); + updatedUser.setDisabled(false); + + response = api.updateUser(user.getHandle(), updatedUser); assertEquals(testingUserName + "-updated", response.getUser().getName()); @@ -100,7 +100,6 @@ public void userCreateModifyDisableTest() throws ApiException { response = api.getUser(user.getHandle()); assertEquals(testingUserHandle, response.getUser().getHandle()); assertEquals(testingUserName + "-updated", response.getUser().getName()); - assertEquals(testingUserAR.toString(), response.getUser().getAccessRole().toString()); assertEquals(false, response.getUser().getDisabled()); // Now test disabling user @@ -120,7 +119,6 @@ public void listUsersTest() throws ApiException { String testingUserName = getUniqueEntityName(53); for (String suffix : suffixes) { User user = new User(); - user.setAccessRole(testingUserAR); user.setHandle(String.format("%s-%s@datadoghq.com", testingUserName, suffix)); user.setName(String.format("%s-%s", testingUserName, suffix)); UserResponse response = api.createUser(user); @@ -158,7 +156,6 @@ public void listUsersTestAsync() throws ApiException, InterruptedException, Exec String testingUserName = getUniqueEntityName(53); for (String suffix : suffixes) { User user = new User(); - user.setAccessRole(testingUserAR); user.setHandle(String.format("%s-%s@datadoghq.com", testingUserName, suffix)); user.setName(String.format("%s-%s", testingUserName, suffix)); UserResponse response = api.createUserAsync(user).get(); @@ -255,7 +252,6 @@ public void userUpdateErrorsTest() throws ApiException, IOException { String testingUserName = getUniqueEntityName(55); String testingUserHandle = testingUserName + "@datadoghq.com"; User user = new User(); - user.setAccessRole(testingUserAR); user.setHandle(testingUserHandle); user.setName(testingUserName); UserResponse response = api.createUser(user); @@ -299,18 +295,21 @@ public void userDisableErrorsTest() throws ApiException, IOException { String testingUserName = getUniqueEntityName(55); String testingUserHandle = testingUserName + "@datadoghq.com"; User user = new User(); - user.setAccessRole(testingUserAR); user.setHandle(testingUserHandle); user.setName(testingUserName); UserResponse response = api.createUser(user); // If something fails, make sure we disable the user disableUsers.add(testingUserHandle); - user = response.getUser(); - user.setDisabled(true); - api.updateUser(user.getHandle(), user); + + User updatedUser = new User(); + updatedUser.setHandle(response.getUser().getHandle()); + updatedUser.setName(response.getUser().getName()); + updatedUser.setDisabled(true); + + api.updateUser(updatedUser.getHandle(), updatedUser); try { - api.disableUser(user.getHandle()); + api.disableUser(updatedUser.getHandle()); fail("Expected ApiException not thrown"); } catch (ApiException e) { assertEquals(400, e.getCode()); diff --git a/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.freeze b/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.freeze new file mode 100644 index 00000000000..7cfa88b8e17 --- /dev/null +++ b/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.freeze @@ -0,0 +1 @@ +2023-07-10T18:57:28.744Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.json b/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.json new file mode 100644 index 00000000000..42def371a51 --- /dev/null +++ b/src/test/resources/cassettes/features/v1/Create_a_user_returns_User_created_response_test.json @@ -0,0 +1,58 @@ +[ + { + "httpRequest": { + "body": { + "type": "JSON", + "json": "{\"access_role\":\"st\",\"disabled\":false,\"email\":\"test@datadoghq.com\",\"handle\":\"test@datadoghq.com\",\"name\":\"test user\"}" + }, + "headers": {}, + "method": "POST", + "path": "/api/v1/user", + "keepAlive": false, + "secure": true + }, + "httpResponse": { + "body": "{\"user\":{\"handle\":\"test@datadoghq.com\",\"name\":\"test user\",\"role\":null,\"title\":null,\"email\":\"test@datadoghq.com\",\"disabled\":false,\"access_role\":null,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/f979f58720feb88e09cc3d11ce3d15da?s=48&d=retro\",\"verified\":false}}\n", + "headers": { + "Content-Type": [ + "application/json" + ] + }, + "statusCode": 200, + "reasonPhrase": "OK" + }, + "times": { + "remainingTimes": 1 + }, + "timeToLive": { + "unlimited": true + }, + "id": "c6a38078-91b6-9d00-16b7-a45bf564a768" + }, + { + "httpRequest": { + "headers": {}, + "method": "DELETE", + "path": "/api/v1/user/test%40datadoghq.com", + "keepAlive": false, + "secure": true + }, + "httpResponse": { + "body": "{\"message\":\"User test@datadoghq.com disabled\"}\n", + "headers": { + "Content-Type": [ + "application/json" + ] + }, + "statusCode": 200, + "reasonPhrase": "OK" + }, + "times": { + "remainingTimes": 1 + }, + "timeToLive": { + "unlimited": true + }, + "id": "af617072-2860-ba27-e045-b00c8baf0187" + } +] \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.freeze b/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.freeze new file mode 100644 index 00000000000..fabf2eb6d47 --- /dev/null +++ b/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.freeze @@ -0,0 +1 @@ +2023-07-10T18:58:47.628Z \ No newline at end of file diff --git a/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.json b/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.json new file mode 100644 index 00000000000..5a17eb5f03a --- /dev/null +++ b/src/test/resources/cassettes/features/v1/Create_a_user_returns_null_access_role.json @@ -0,0 +1,58 @@ +[ + { + "httpRequest": { + "body": { + "type": "JSON", + "json": "{\"access_role\":null,\"disabled\":false,\"email\":\"test@datadoghq.com\",\"handle\":\"test@datadoghq.com\",\"name\":\"test user\"}" + }, + "headers": {}, + "method": "POST", + "path": "/api/v1/user", + "keepAlive": false, + "secure": true + }, + "httpResponse": { + "body": "{\"user\":{\"handle\":\"test@datadoghq.com\",\"name\":\"test user\",\"role\":null,\"title\":null,\"email\":\"test@datadoghq.com\",\"disabled\":true,\"access_role\":null,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/f979f58720feb88e09cc3d11ce3d15da?s=48&d=retro\",\"verified\":false}}\n", + "headers": { + "Content-Type": [ + "application/json" + ] + }, + "statusCode": 200, + "reasonPhrase": "OK" + }, + "times": { + "remainingTimes": 1 + }, + "timeToLive": { + "unlimited": true + }, + "id": "caca59e8-b77c-5fba-34ff-14276808609d" + }, + { + "httpRequest": { + "headers": {}, + "method": "DELETE", + "path": "/api/v1/user/test%40datadoghq.com", + "keepAlive": false, + "secure": true + }, + "httpResponse": { + "body": "{\"errors\":[\"User is already disabled\"]}", + "headers": { + "Content-Type": [ + "application/json" + ] + }, + "statusCode": 400, + "reasonPhrase": "Bad Request" + }, + "times": { + "remainingTimes": 1 + }, + "timeToLive": { + "unlimited": true + }, + "id": "af617072-2860-ba27-e045-b00c8baf0188" + } +] \ No newline at end of file diff --git a/src/test/resources/cassettes/v1/UsersApiTest.userCreateErrorsTest.json b/src/test/resources/cassettes/v1/UsersApiTest.userCreateErrorsTest.json index c4ae67fd83e..5970bfd3774 100644 --- a/src/test/resources/cassettes/v1/UsersApiTest.userCreateErrorsTest.json +++ b/src/test/resources/cassettes/v1/UsersApiTest.userCreateErrorsTest.json @@ -14,7 +14,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\"}" + "json" : "{}" } }, "times" : { @@ -58,7 +58,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\"}" + "json" : "{}" } }, "times" : { diff --git a/src/test/resources/cassettes/v1/UsersApiTest.userCreateModifyDisableTest.json b/src/test/resources/cassettes/v1/UsersApiTest.userCreateModifyDisableTest.json index 143310c175c..ad0fe546f89 100644 --- a/src/test/resources/cassettes/v1/UsersApiTest.userCreateModifyDisableTest.json +++ b/src/test/resources/cassettes/v1/UsersApiTest.userCreateModifyDisableTest.json @@ -14,7 +14,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466\"}" + "json" : "{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466\"}" } }, "times" : { @@ -46,7 +46,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466\",\"title\":null,\"is_admin\":false,\"role\":null,\"access_role\":\"st\",\"verified\":false,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\"}}" + "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466\",\"title\":null,\"is_admin\":false,\"role\":null,\"verified\":false,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\"}}" } }, { "id" : "dd5be39b-2b5c-4461-9da4-827d9fce444f", @@ -64,7 +64,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"disabled\":false,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"verified\":false}" + "json" : "{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\"}" } }, "times" : { @@ -96,7 +96,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"title\":null,\"is_admin\":false,\"role\":null,\"access_role\":\"st\",\"verified\":false,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\"}}" + "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"title\":null,\"is_admin\":false,\"role\":null,\"verified\":false,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\"}}" } }, { "id" : "f5c55b55-c333-40b5-8fd8-5a8ede860399", @@ -141,7 +141,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"access_role\":\"st\",\"disabled\":false,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" + "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"disabled\":false,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" } }, { "id" : "4e4fb8a3-51e3-4e65-8fcf-b427092326a4", @@ -232,7 +232,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"access_role\":\"st\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" + "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" } }, { "id" : "9a4d04f0-39d8-4877-9e34-5b0ba15bdf38", @@ -277,6 +277,6 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"access_role\":\"st\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" + "body" : "{\"user\":{\"handle\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/64f997d5be486e87968277969ff665aa?s=48&d=retro\",\"verified\":false,\"name\":\"java-userCreateModifyDisableTest-local-15959466-updated\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-usercreatemodifydisabletest-local-15959466@datadoghq.com\"}}" } }] diff --git a/src/test/resources/cassettes/v1/UsersApiTest.userDisableErrorsTest.json b/src/test/resources/cassettes/v1/UsersApiTest.userDisableErrorsTest.json index d8fe752eac1..bbaca80e576 100644 --- a/src/test/resources/cassettes/v1/UsersApiTest.userDisableErrorsTest.json +++ b/src/test/resources/cassettes/v1/UsersApiTest.userDisableErrorsTest.json @@ -14,7 +14,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"handle\":\"java-userDisableErrorsTest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\"}" + "json" : "{\"handle\":\"java-userDisableErrorsTest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\"}" } }, "times" : { @@ -46,7 +46,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"title\":null,\"is_admin\":false,\"role\":null,\"access_role\":\"st\",\"verified\":false,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\"}}" + "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"title\":null,\"is_admin\":false,\"role\":null,\"verified\":false,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\"}}" } }, { "id" : "1ede868c-1f1c-4629-b9d7-d410df6b7279", @@ -64,7 +64,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"disabled\":true,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\",\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"verified\":false}" + "json" : "{\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\"}" } }, "times" : { @@ -96,7 +96,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"disabled\":true,\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"title\":null,\"is_admin\":false,\"role\":null,\"access_role\":\"st\",\"verified\":false,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\"}}" + "body" : "{\"user\":{\"disabled\":true,\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"title\":null,\"is_admin\":false,\"role\":null,\"verified\":false,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\"}}" } }, { "id" : "df05ab71-9e1d-47bd-98d9-83b9a3c87527", @@ -256,6 +256,6 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"access_role\":\"st\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\",\"verified\":false,\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\"}}" + "body" : "{\"user\":{\"handle\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\",\"disabled\":true,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/7b20ed475a9bc62294bbdf3538295a93?s=48&d=retro\",\"verified\":false,\"name\":\"java-userDisableErrorsTest-local-1595946645\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-userdisableerrorstest-local-1595946645@datadoghq.com\"}}" } }] diff --git a/src/test/resources/cassettes/v1/UsersApiTest.userUpdateErrorsTest.json b/src/test/resources/cassettes/v1/UsersApiTest.userUpdateErrorsTest.json index 04cf7dece3b..181fcb5c549 100644 --- a/src/test/resources/cassettes/v1/UsersApiTest.userUpdateErrorsTest.json +++ b/src/test/resources/cassettes/v1/UsersApiTest.userUpdateErrorsTest.json @@ -14,7 +14,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"handle\":\"java-userUpdateErrorsTest-local-1595946652@datadoghq.com\",\"name\":\"java-userUpdateErrorsTest-local-1595946652\"}" + "json" : "{\"handle\":\"java-userUpdateErrorsTest-local-1595946652@datadoghq.com\",\"name\":\"java-userUpdateErrorsTest-local-1595946652\"}" } }, "times" : { @@ -46,7 +46,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"name\":\"java-userUpdateErrorsTest-local-1595946652\",\"title\":null,\"is_admin\":false,\"role\":null,\"access_role\":\"st\",\"verified\":false,\"email\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7226458b1fb7d8bad4ee18333a63261c?s=48&d=retro\"}}" + "body" : "{\"user\":{\"disabled\":false,\"handle\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"name\":\"java-userUpdateErrorsTest-local-1595946652\",\"title\":null,\"is_admin\":false,\"role\":null,\"verified\":false,\"email\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"icon\":\"https://secure.gravatar.com/avatar/7226458b1fb7d8bad4ee18333a63261c?s=48&d=retro\"}}" } }, { "id" : "a227cf3a-cfe4-485a-ad1d-75cc8ba64865", @@ -64,7 +64,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"email\":\"notanemail\"}" + "json" : "{\"email\":\"notanemail\"}" } }, "times" : { @@ -108,7 +108,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"email\":\"notanemail\"}" + "json" : "{\"email\":\"notanemail\"}" } }, "times" : { @@ -146,7 +146,7 @@ "secure" : true, "body" : { "type" : "JSON", - "json" : "{\"access_role\":\"st\",\"email\":\"notanemail\"}" + "json" : "{\"email\":\"notanemail\"}" } }, "times" : { @@ -218,7 +218,7 @@ "cookies" : { "DD-PSHARD" : "233" }, - "body" : "{\"user\":{\"handle\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"access_role\":\"st\",\"disabled\":false,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/7226458b1fb7d8bad4ee18333a63261c?s=48&d=retro\",\"verified\":false,\"name\":\"java-userUpdateErrorsTest-local-1595946652\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\"}}" + "body" : "{\"user\":{\"handle\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\",\"disabled\":false,\"is_admin\":false,\"icon\":\"https://secure.gravatar.com/avatar/7226458b1fb7d8bad4ee18333a63261c?s=48&d=retro\",\"verified\":false,\"name\":\"java-userUpdateErrorsTest-local-1595946652\",\"roles\":[{\"uuid\":\"94172443-be03-11e9-a77a-373332f69711\",\"created_at\":\"2019-08-13T19:50:19.075284\",\"name\":\"Datadog Standard Role\",\"last_modified\":\"2019-08-13T19:50:19.075284\",\"id\":904116,\"permissions\":[{\"display_name\":\"Security Signals\",\"description\":\"The ability to view Security signals.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:48.410398\",\"name\":\"security_monitoring_signals_read\",\"uuid\":\"80de1ec0-aa58-11ea-95e2-aff381626d5d\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to create and edit Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:39.099413\",\"name\":\"security_monitoring_rules_write\",\"uuid\":\"7b516476-aa58-11ea-95e2-93718cd56369\"},{\"display_name\":\"Detection Rules\",\"description\":\"The ability to read Detection rules.\",\"restricted\":false,\"created_at\":\"2020-06-09T13:52:25.279909\",\"name\":\"security_monitoring_rules_read\",\"uuid\":\"7314eb20-aa58-11ea-95e2-6fb6e4a451d5\"},{\"display_name\":\"Logs Archives\",\"description\":\"The ability to read logs archives location and use it for rehydration.\",\"restricted\":false,\"created_at\":\"2020-04-23T07:40:27.966133\",\"name\":\"logs_read_archives\",\"uuid\":\"b382b982-8535-11ea-93de-2bf1bdf20798\"},{\"display_name\":\"Logs Read Data\",\"description\":\"The ability to read log data. Can be restricted with restriction queries.\",\"restricted\":false,\"created_at\":\"2020-04-06T16:24:35.989108\",\"name\":\"logs_read_data\",\"uuid\":\"1af86ce4-7823-11ea-93dc-d7cad1b1c6cb\"},{\"display_name\":\"Logs Read Index Data\",\"description\":\"The ability to read all or some log indexes. Can be granted in a limited capacity per index from the Logs interface or APIs. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:19.727450\",\"name\":\"logs_read_index_data\",\"uuid\":\"5e605652-dd12-11e8-9e53-375565b8970e\"},{\"display_name\":\"Log Write Processors\",\"description\":\"The ability to add and change some or all log processor configurations. Can be granted in a limited capacity per pipeline to specific roles via the Logs interface or API. If granted via the Roles interface or API the permission has global scope.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:23.969725\",\"name\":\"logs_write_processors\",\"uuid\":\"84aa3ae4-dd12-11e8-9e58-a373a514ccd0\"},{\"display_name\":\"Monitors Manage Downtimes\",\"description\":\"The ability to set downtimes for your organization. A user with this permission can suppress alerts from any monitor using a downtime, even if they do not have permission to edit those monitors explicitly.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:23.306702\",\"name\":\"monitors_downtime\",\"uuid\":\"4d87d5f8-d8b1-11e9-a77a-eb9c8350d04f\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to view dashboards.\",\"restricted\":true,\"created_at\":\"2019-09-10T14:39:51.955175\",\"name\":\"dashboards_read\",\"uuid\":\"d90f6830-d3d8-11e9-a77a-b3404e5e9ee2\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to change, mute, and delete individual monitors.\",\"restricted\":false,\"created_at\":\"2019-09-16T18:39:15.597109\",\"name\":\"monitors_write\",\"uuid\":\"48ef71ea-d8b1-11e9-a77a-93f408470ad0\"},{\"display_name\":\"Monitors\",\"description\":\"The ability to view monitors.\",\"restricted\":true,\"created_at\":\"2019-09-16T18:39:07.744297\",\"name\":\"monitors_read\",\"uuid\":\"4441648c-d8b1-11e9-a77a-1b899a04b304\"},{\"display_name\":\"Dashboards Share\",\"description\":\"The ability to share dashboards externally.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.967094\",\"name\":\"dashboards_public_share\",\"uuid\":\"d90f6832-d3d8-11e9-a77a-bf8a2607f864\"},{\"display_name\":\"Dashboards\",\"description\":\"The ability to create and change dashboards.\",\"restricted\":false,\"created_at\":\"2019-09-10T14:39:51.962944\",\"name\":\"dashboards_write\",\"uuid\":\"d90f6831-d3d8-11e9-a77a-4fd230ddbc6a\"},{\"display_name\":\"Log Generate Metrics\",\"description\":\"The ability to create custom metrics from logs.\",\"restricted\":false,\"created_at\":\"2019-07-25T12:27:39.640758\",\"name\":\"logs_generate_metrics\",\"uuid\":\"979df720-aed7-11e9-99c6-a7eb8373165a\"},{\"display_name\":\"Logs Write Pipelines\",\"description\":\"The ability to add and change log pipeline configurations, including the ability to grant the Logs Write Processors permission to other roles, for some or all pipelines. This permission also grants global Log Processor Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:40:17.996379\",\"name\":\"logs_write_pipelines\",\"uuid\":\"811ac4ca-dd12-11e8-9e57-676a7f0beef9\"},{\"display_name\":\"Logs Live Tail Access\",\"description\":\"The ability to view the live tail feed for all log indexes, even if otherwise specifically restricted.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:48.292879\",\"name\":\"logs_live_tail\",\"uuid\":\"6f66600e-dd12-11e8-9e55-7f30fbb45e73\"},{\"display_name\":\"Logs Modify Indexes\",\"description\":\"The ability to read and modify all indexes in your account. This includes the ability to grant the Logs Read Index Data and Logs Write Exclusion Filter permission to other roles, for some or all indexes. This permission also grants global Log Index Read and Log Exclusion Filter Write implicitly.\",\"restricted\":false,\"created_at\":\"2018-10-31T13:39:27.148615\",\"name\":\"logs_modify_indexes\",\"uuid\":\"62cc036c-dd12-11e8-9e54-db9995643092\"},{\"display_name\":\"Standard Access\",\"description\":\"This permission gives you the ability to view and edit components in your Datadog organization that do not have explicitly defined permissions. This includes APM, Events, and other non-Account Management functionality.\",\"restricted\":false,\"created_at\":\"2018-10-19T15:35:23.756736\",\"name\":\"standard\",\"uuid\":\"984d2f00-d3b4-11e8-a200-bb47109e9987\"}]}],\"title\":null,\"role\":null,\"email\":\"java-userupdateerrorstest-local-1595946652@datadoghq.com\"}}" } }, { "id" : "3c22a77a-334c-4541-b07c-2d86ed531290", diff --git a/src/test/resources/com/datadog/api/client/v1/api/organizations.feature b/src/test/resources/com/datadog/api/client/v1/api/organizations.feature index 3f3b2d0ffca..d9d89aa89d9 100644 --- a/src/test/resources/com/datadog/api/client/v1/api/organizations.feature +++ b/src/test/resources/com/datadog/api/client/v1/api/organizations.feature @@ -60,7 +60,7 @@ Feature: Organizations Scenario: Update your organization returns "Bad Request" response Given new "UpdateOrg" request And request contains "public_id" parameter from "REPLACE.ME" - And body with value {"billing": {"type": "parent_billing"}, "description": "some description", "name": "New child org", "public_id": "abcdef12345", "settings": {"private_widget_share": false, "saml": {"enabled": false}, "saml_autocreate_access_role": "st", "saml_autocreate_users_domains": {"domains": ["example.com"], "enabled": false}, "saml_can_be_enabled": false, "saml_idp_endpoint": "https://my.saml.endpoint", "saml_idp_initiated_login": {"enabled": false}, "saml_idp_metadata_uploaded": false, "saml_login_url": "https://my.saml.login.url", "saml_strict_mode": {"enabled": false}}, "subscription": {"type": "pro"}, "trial": false} + And body with value {"billing": {"type": "parent_billing"}, "description": "some description", "name": "New child org", "public_id": "abcdef12345", "settings": {"private_widget_share": false, "saml": {"enabled": false}, "saml_autocreate_access_role": "ro", "saml_autocreate_users_domains": {"domains": ["example.com"], "enabled": false}, "saml_can_be_enabled": false, "saml_idp_endpoint": "https://my.saml.endpoint", "saml_idp_initiated_login": {"enabled": false}, "saml_idp_metadata_uploaded": false, "saml_login_url": "https://my.saml.login.url", "saml_strict_mode": {"enabled": false}}, "subscription": {"type": "pro"}, "trial": false} When the request is sent Then the response status is 400 Bad Request @@ -68,7 +68,7 @@ Feature: Organizations Scenario: Update your organization returns "OK" response Given new "UpdateOrg" request And request contains "public_id" parameter from "REPLACE.ME" - And body with value {"billing": {"type": "parent_billing"}, "description": "some description", "name": "New child org", "public_id": "abcdef12345", "settings": {"private_widget_share": false, "saml": {"enabled": false}, "saml_autocreate_access_role": "st", "saml_autocreate_users_domains": {"domains": ["example.com"], "enabled": false}, "saml_can_be_enabled": false, "saml_idp_endpoint": "https://my.saml.endpoint", "saml_idp_initiated_login": {"enabled": false}, "saml_idp_metadata_uploaded": false, "saml_login_url": "https://my.saml.login.url", "saml_strict_mode": {"enabled": false}}, "subscription": {"type": "pro"}, "trial": false} + And body with value {"billing": {"type": "parent_billing"}, "description": "some description", "name": "New child org", "public_id": "abcdef12345", "settings": {"private_widget_share": false, "saml": {"enabled": false}, "saml_autocreate_access_role": "ro", "saml_autocreate_users_domains": {"domains": ["example.com"], "enabled": false}, "saml_can_be_enabled": false, "saml_idp_endpoint": "https://my.saml.endpoint", "saml_idp_initiated_login": {"enabled": false}, "saml_idp_metadata_uploaded": false, "saml_login_url": "https://my.saml.login.url", "saml_strict_mode": {"enabled": false}}, "subscription": {"type": "pro"}, "trial": false} When the request is sent Then the response status is 200 OK diff --git a/src/test/resources/com/datadog/api/client/v1/api/users.feature b/src/test/resources/com/datadog/api/client/v1/api/users.feature index 468f34a08d0..57285544672 100644 --- a/src/test/resources/com/datadog/api/client/v1/api/users.feature +++ b/src/test/resources/com/datadog/api/client/v1/api/users.feature @@ -10,24 +10,32 @@ Feature: Users @generated @skip @team:DataDog/team-aaa-identity Scenario: Create a user returns "Bad Request" response Given new "CreateUser" request - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 400 Bad Request @generated @skip @team:DataDog/team-aaa-identity Scenario: Create a user returns "Conflict" response Given new "CreateUser" request - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 409 Conflict @generated @skip @team:DataDog/team-aaa-identity Scenario: Create a user returns "User created" response Given new "CreateUser" request - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 200 User created + @replay-only @team:DataDog/team-aaa-identity + Scenario: Create a user returns null access role + Given new "CreateUser" request + And body with value {"access_role": null, "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + When the request is sent + Then the response status is 200 User created + And the response "user.access_role" is equal to null + @generated @skip @team:DataDog/team-aaa-identity Scenario: Disable a user returns "Bad Request" response Given new "DisableUser" request @@ -73,7 +81,7 @@ Feature: Users Scenario: Update a user returns "Bad Request" response Given new "UpdateUser" request And request contains "user_handle" parameter from "REPLACE.ME" - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 400 Bad Request @@ -81,7 +89,7 @@ Feature: Users Scenario: Update a user returns "Not Found" response Given new "UpdateUser" request And request contains "user_handle" parameter from "REPLACE.ME" - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 404 Not Found @@ -89,6 +97,6 @@ Feature: Users Scenario: Update a user returns "User updated" response Given new "UpdateUser" request And request contains "user_handle" parameter from "REPLACE.ME" - And body with value {"access_role": "st", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} + And body with value {"access_role": "ro", "disabled": false, "email": "test@datadoghq.com", "handle": "test@datadoghq.com", "name": "test user"} When the request is sent Then the response status is 200 User updated