I'm having trouble adding users to account-level groups using the API. The API user is an account admin and a "moderator" in the group, but I always get a 404 error when trying to add other users to the group:
{"message":"You are not authorized to perform that action.","status":"unauthorized"}
This happens regardless of the join_level of the group. It's the same API account that was used to create the group. I can add users to the group if the join_level is set to parent_context_auto_join and using the "as_user_id" param, like so:
However, this means that anyone can sign themselves up for the group, which I don't want.
I can request an invite as the user, but that doesn't seem to do anything. The invite API will send the user an email, but the link in the email is incorrect:
https://my.canvas.com/accounts/<account id>/groups/<group id>. If the user visits this link, they will see an "Unauthorized" error, and they still can't access the group, even at the correct URL.
Has anyone had any luck with this?
There seem to be some other problems with groups, possibly related to caching. If I create a group through the API, it won't show up in my "Courses & Groups" menu, but it will show up at
my.canvas.com/groups. This seems to work fine if I add users through the UI (which is tough, because there's no search, and you have to page through thousands of names) it will show up in the menu, but if I change the name of the group, the old group name still shows up in the menu.
Account-level groups is a GREAT feature, but it seems to be unfinished.