โ11-14-2024 11:04 PM
Hello Workato Support Team,
Iโm encountering an issue when using the Invite a Collaborator API. While testing in Postman, I received the following error:
**"Privilege group can't be blank"**
Hereโs the current request Iโm using based on the documentation:
curl -X POST https://www.workato.com/api/member_invitations \
-H 'Authorization: Bearer <api_token>' \
-H 'Content-Type: application/json' \
-d '{
"name": "John",
"email": "john@acme.com",
"env_roles": [
{ "environment_type": "dev", "name": "Admin" }
]
}'
Iโve also ensured the following:
The API token Iโm using was created with client roles configured.
I tried adding a privilege_group field to the request body outside of the env_roles array.
I verified the roles in env_roles (e.g., "Admin", "Analyst", "Operator") against the documentation.
Despite these efforts, the error persists. Could you please clarify:
Whether an additional privilege_group parameter or any other specific field is required for this API request?
The accepted values for privilege_group and other required fields that might not be explicitly documented.
Thank you for your assistance.
Best regards, C.Rohtih.
โ11-16-2024 07:13 PM
The error occurs because the privilege_group field is missing in your request. Add it outside the env_roles array like this:
{
"name": "John",
"email": "john@acme.com",
"privilege_group": "Admin",
"env_roles": [
{ "environment_type": "dev", "name": "Admin" }
]
}
Ensure privilege_group has valid values like "Admin", "Editor", or "Viewer".
โ11-17-2024 11:07 PM
Thank you for your earlier response and for clarifying the need to include the privilege_group field. I updated my API request as follows:
{
"name": "John",
"email": "john@acme.com",
"privilege_group": "Admin",
"env_roles": [
{ "environment_type": "dev", "name": "Admin" }
]
}
Despite this, I am still encountering the same error:
"Privilege group can't be blank"