
vxnyv (vxnyv) asked a question.
Hello,
When users are requesting access to JIRA through our ticketing system (salesforce) we get a 400 Bad Request error through OKTA workflows
Does OKTA support mail-enabled security groups
{
"_error": true,
"retry_count": 0,
"flo": "3ffea87f-5944-41e5-a672-f63c1b572561",
"method": "q44qRh4r7",
"execution": "9adc83b2-d474-43df-b784-2acb5ccb2751",
"module": "office365admin.addUserToGroup",
"kind": "HTTP Request Error",
"statusCode": 400,
"headers": {
"request-id": "6b1e2913-acf0-4523-ae44-fecdf7dfd3b4",
"client-request-id": "6b1e2913-acf0-4523-ae44-fecdf7dfd3b4",
"transfer-encoding": "chunked",
"date": "Mon, 27 Mar 2023 20:42:48 GMT",
"x-ms-resource-unit": "1",
"cache-control": "no-cache",
"x-ms-ags-diagnostic": "{\"ServerInfo\":{\"DataCenter\":\"West US 2\",\"Slice\":\"E\",\"Ring\":\"1\",\"ScaleUnit\":\"002\",\"RoleInstance\":\"MWH0EPF00032D50\"}}",
"strict-transport-security": "max-age=31536000",
"content-type": "application/json"
},
"body": {
"error": {
"code": "Request_BadRequest",
"message": "Cannot Update a mail-enabled security groups and or distribution list.",
"innerError": {
"date": "2023-03-27T20:42:48",
"request-id": "6b1e2913-acf0-4523-ae44-fecdf7dfd3b4",
"client-request-id": "6b1e2913-acf0-4523-ae44-fecdf7dfd3b4"
}
}
},
"message": "400 Bad Request",
"code": 400,
"description": "HTTP Request Error",
"steps": 32,
"source": {
"flo": "office365admin:1.0.152:addUserToGroup",
"method": "IbqvmNUfg6O",
"execution": "1c560cb1-ed21-41fb-8965-1ce684780d48",
"module": "control.spawn"
},
"_fatal": null

@vxnyv (vxnyv)
From looking at the error we can see you are leveraging the 0365 Admin card with the Action: Add User to Group
--"module": "office365admin.addUserToGroup",
The O365 endpoint then returns the following response:
- "code": "Request_BadRequest",
"message": "Cannot Update a mail-enabled security groups and or distribution list.",
As this is an Error on the Microsoft side a quick search returns this (and several other) document:
https://learn.microsoft.com/en-us/answers/questions/608720/i-am-trying-to-add-member-in-mail-enabled-security
What appears to be pertinent is the type of groups that can be managed through Graph API:
>As per mentioned in this documentation, managing mail-enabled security groups through Microsoft Graph are currently not possible