Approve a list of users
POST https://{controlplane_path}/api/1/rest/public/apim/approve_users
This API approves the user ID or a list of user IDs that appear in the created status under Subscription Manager.
Prerequisites
- Org admin (Environment admin) permissions
- Developer portal login credentials
- Specify the user ID or list of user IDs for approval
Path parameters
| Key | Description |
|---|---|
controlplane_path |
Required. The path to the SnapLogic control plane:
elastic.snaplogic.com
For the UAT or EMEA control plane, substitute the name for elastic. For
example:
|
Query parameters
None.
Request header
In the request header, specify Basic for authorization, add your credentials (Login and password of your SnapLogic user or service account), and specify application/json for content type.
For more details on accounts refer to Manage accounts.
Authorization: Basic {base64_encoded <email>:<password>}
Content-Type: application/json
Example of Basic authentication using Postman
When using JWT authentication, the API requests includes specific headers. In the
request header, specify Bearer Token for authorization, add the token,
and specify application/json for content type. These headers are
automatically added when you configure bearer token authentication in your API client.
The authorization header contains the word Bearer followed by a
space and your JWT token.
Authorization: Bearer Token {token}
Content-Type: application/json
Example of JWT authenthication using Postman
Request body
{
"org_name": "Automation2",
"user_ids": [
"test3@gmail.com",
"test4@gmail.com",
"test1@gmail.com",
"test2@gmail.com"
]
}
| Key | Type | Description |
|---|---|---|
org_name |
string | The name of the SnapLogic Environment/Org |
user_ids |
array/string | An array that contains the user ID or a list of user IDs |
Response
{
"response_map": {
"successful approvals": [
{
"User IDs": [
"test3@gmail.com",
"test4@gmail.com"
]
}
],
"failed approvals": [
{
"User test1@gmail.com": "User has not requested access to this org"
},
{
"User test2@gmail.com": "User has not requested access to this org"
}
]
}
}
| Key | Type | Description |
|---|---|---|
{ "Successful Approvals"
: <list of usernames> }
|
array | The JSON object array contains the list of user IDs that are successfully approved. |
{ "Failed Approvals" :
<list of username: error when approving> }
|
array | The JSON object array contains the list of user IDs that failed the approval process. |