The create AD group member action operation will add a AD group member action to a self service product with the specified body content.
Request
Request URI
Method | Request URI |
---|---|
POST | https://{company-name}.helloid.com/api/v1/selfservice/products/{productGUID}/adgroupmemberaction |
POST | https://{company-name}.helloid.com/api/v1/selfservice/products/{productCode}/adgroupmemberaction |
Request parameters
Parameter | Description |
---|---|
{company-name} | The company name of the target company |
{productGUID} | The GUID for the self service product |
{productCode} | The code for the self service product |
Request headers
Header | Description |
---|---|
Content-Type | Required. Must be set to application/json. |
Sample request body
{ "executeOnState": 1, "variables": [ { "name": "groupName", "value": "ExampleUsers", "typeConstraint": "string", "secure": false }, { "name": "groupSid", "value": null, "typeConstraint": "string", "secure": false }, { "name": "domain", "value": "{{company.defaultAdDomain}}", "typeConstraint": "string", "secure": false }, { "name": "addMembership", "value": "false", "typeConstraint": "bool", "secure": false }, { "name": "userSid", "value": "{{requester.immutableId}}", "typeConstraint": "string", "secure": false } ] }
Request body parameters
Parameter | Description | Required/Optional | Default value |
---|---|---|---|
executeOnState | Indicates in which state the AD Group Member action will trigger. Possible values: 1. RequestCreated (default) 2. RequestCreateCompleted 3. RequestApproved 4. RequestApproveCompleted 5. RequestDenied 6. RequestDenyCompleted 7. RequestDeleted 8. RequestDeleteCompleted 9. RequestRevoked 10. RequestRevokeCompleted 11. RequestReturned 12. RequestReturnCompleted |
Optional | - |
variables/domain | Target domain | Optional | - |
variables/groupName | Name of the AD group. | Required | - |
variables/addMembership | Indicates if the AD Group Member action will add to the group or remove from the group. | Optional | true |
variables/groupSid | SID of the group | Optional | - |
variables/userSid | SID of the user | Optional | - |
Response
Response status
Code | Description |
---|---|
200(OK) | Indicates that the operation was successful and the resource is created. |
400(BAD REQUEST) | Indicates that the operation was not successful. The content type was incorrect or the request body was malformed. |
401(UNAUTHORIZED) | Indicates that no authentication header was given or the api key and secret were invalid. If the api key and secret were valid check the configuration in your portal, it is possibilty these were IP restricted or are disabled. |
409(CONFLICT) | Indicates that the operation was not successful. If there were validation errors, the response will include an error result. |
Please also see error result.
Please also see common HTTP status codes.
Sample response body
{ "actionGUID": "1da6c8a4-0fee-4178-91d6-d3824f1a05b5", "name": "Change AD group membership", "options": 1, "objectGUID": "87ed7ecc-0ee7-4d9c-a718-341d2f6861fe", "executeOnState": 1, "automationStoreTaskId": "db9279ad-0f56-45b1-949e-fcf3dc7c930a", "automationStoreTaskVersion": "1.0.0", "executionType": "native", "executionEntry": "ad-change-groupmembership", "executionEnvironment": "helloid-agent", "executionMinimumVersion": "1.1.0", "variables": [ { "id": "702cc2f6-a3f0-4118-8ef4-eca2686dab31", "name": "addMembership", "value": "false", "typeConstraint": "bool", "secure": false, "isScriptVariable": false }, { "id": "97ed9c40-7728-4cb0-9b2b-3c54d28021b9", "name": "domain", "value": "{{company.defaultAdDomain}}", "typeConstraint": "string", "secure": false, "isScriptVariable": false }, { "id": "20fa6ba9-f3b5-43bf-a1a5-a6bcfdf893e3", "name": "groupName", "value": "ExampleUsers", "typeConstraint": "string", "secure": false, "isScriptVariable": false }, { "id": "d057bd26-a3d3-45e5-8365-4ed542aac7f7", "name": "groupSid", "value": null, "typeConstraint": "string", "secure": false, "isScriptVariable": false }, { "id": "3f562dff-1fee-49b7-b982-3ee2b65e0f08", "name": "userSid", "value": "{{requester.immutableId}}", "typeConstraint": "string", "secure": false, "isScriptVariable": false } ] }
Example request with cURL
Replace placeholder values surrounded by {
}
with the actual values.
curl -u {api-key}:{api-secret} -X POST https://{company-name}.helloid.com/api/v1/selfservice/products/{productGUID}/adgroupmemberaction -H "Content-Type:application/json" -d
'{
[request body here]
}'