Assign Process Permission Groups
Assigns a set of child groups to a named process permission on a parent group.
| Description |
Assigns a set of child groups to a named process permission on a parent group. |
|---|---|
| URL |
|
| Method | POST |
| Parameters |
|
Review the parameter definitions and examples of how to use the processPermissionName endpoint in JQuery and C# calls.
Parameters
| Variable Name | Type | Description | Required |
|---|---|---|---|
| groupName | String | The parent group to assign to | True (URL) |
| processPermissionName | String | The process permission to assign to | True (URL) |
| groups | String array | The child groups to assign to the process permission | True |
Examples
JQuery Call
$.ajax({
url: baseUrl + '/groups/Command/processpermission/Approve Resource Requests',
contentType: 'application/json',
data: JSON.stringify({ 'groups': ['Logistics', 'Finance'] }),
type: 'POST'
});
C# Call
public void AssignProcessPermissions(Cookie cookie)
{
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(baseUrl + "/groups/Command/processpermission/Approve Resource Requests");
request.Method = "POST";
request.ContentType = "application/json";
CookieContainer cookieJar = new CookieContainer();
cookieJar.Add(cookie);
request.CookieContainer = cookieJar;
byte[] bytes = Encoding.UTF8.GetBytes(new JavaScriptSerializer().Serialize(new { groups = new[] { "Logistics", "Finance" } }));
request.ContentLength = bytes.Length;
using (Stream s = request.GetRequestStream()) { s.Write(bytes, 0, bytes.Length); }
request.GetResponse();
}
Errors
401, 400 (blank/unknown group or process permission, or insufficient permissions), 500.