API - Add User to moderator group

I’m not certain is this is method if you are referring to.
However, I tried assigning moderator using this method.

https://discourse.example.com/admin/users/{id}/groups

{
“group_id”: 2 //moderator
}

and I got the following error.

“You cannot modify an automatic group”