With help from Oana, I was able to develop one script and one json structure that will create a new user and assign the user to a user group.
-------------------------------------------
Original Message:
Sent: Feb 12, 2026 11:33 AM
From: Steven Blumenkrantz
Subject: Add user to user group via the REST API
When I try the following script, I get the same response:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 166 100 158 100 8 487 24 --:--:-- --:--:-- --:--:-- 513
Response: {
"code" : 45106,
"error" : "The request is invalid and cannot be processed by the Automation Engine.",
"details" : "No detail information available."
}
#!/bin/bash
REST_ENDPOINT="<END POINT>"
CLIENT="8251"
read -sp "Enter password: " PASSWORD
AE_USER_PW="sblumenkrantz/CORP:$PASSWORD"
# Construct the URL
URL="$REST_ENDPOINT/ae/api/v1/${CLIENT}/objects/TEST_USER%2FTEST"
echo ${URL}
# JSON payload
PAYLOAD=$(cat <<EOF
{
"data": {
"user": {
"groups": [
{
"usergroup": "OPERATORS"
}
]
}
}
}
EOF
)
response=$(curl -X PATCH "${URL}" \
--header "Content-Type: application/json" \
--user "$AE_USER_PW" \
--data "PAYLOAD}")
# Output the response
echo "Response: ${response}"
Original Message:
Sent: Feb 12, 2026 09:13 AM
From: Oana Botez
Subject: Add user to user group via the REST API
Hi Steven,
You can use the objects endpoint with PATCH to assign a user to a usergroup.
PATCH https://rest-....com/ae/api/v1/0/objects/TEST%2FTEST
{
"data": {
"user": {
"groups": [
{
"usergroup": "USER_ACCESS"
}
]
}
}
}
BR,
Oana
Original Message:
Sent: Feb 11, 2026 03:50 PM
From: Steven Blumenkrantz
Subject: Add user to user group via the REST API
In preparation for programmatically creating a new user via the REST API (need help, see thread), I wrote the following POC script to add an existing user to the existing user group. When I run it I get, the following. Anyone know where I'm going wrong?
Enter password: <end point>/ae/api/v1/8251/objects/OPERATORS
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 282 100 158 100 124 1698 1333 --:--:-- --:--:-- --:--:-- 3032
Response: {
"code" : 45106,
"error" : "The request is invalid and cannot be processed by the Automation Engine.",
"details" : "No detail information available."
}
#!/bin/bash
REST_ENDPOINT="<end point>"
CLIENT="8251"
read -sp "Enter password: " PASSWORD
AE_USER_PW="sblumenkrantz/CORP:$PASSWORD"
# Construct the URL
URL="$REST_ENDPOINT/ae/api/v1/${CLIENT}/objects/OPERATORS"
echo ${URL}
# JSON payload
PAYLOAD=$(cat <<EOF
{
"data": {
"usrg": {
"members" : [ {
"username" : "TEST_USER/TEST"
} ]
}
}
EOF
)
response=$(curl -X PATCH "${URL}" \
--header "Content-Type: application/json" \
--user "$AE_USER_PW" \
--data "PAYLOAD}"
# Output the response
echo "Response: ${response}"
-------------------------------------------