public void AllowTaskReservationUpdates() { var url = GetWorkspaceUrl() + "/Tasks/**"; var policy = new Policy(url, "POST", true); policy.postFilter.Add("ReservationStatus", Policy.required); policies.Add(policy); }
public void AllowWorkerActivityUpdates() { var url = GetWorkerUrl(); var policy = new Policy(url, "POST", true); policy.postFilter.Add("ActivitySid", Policy.required); policies.Add(policy); }
public void AddPolicy(string url, string method, bool allowed, Dictionary<string, Dictionary<string, bool>> queryFilter = null, Dictionary<string, Dictionary<string, bool>> postFilter = null) { if (queryFilter == null) { queryFilter = new Dictionary<string, Dictionary<string, bool>>(); } if (postFilter == null) { postFilter = new Dictionary<string, Dictionary<string, bool>> (); } var policy = new Policy (url, method, queryFilter, postFilter, allowed); policies.Add(policy); }
public void AllowActivityUpdates() { var policy = new Policy(this.resourceUrl, "POST", true); policy.postFilter.Add("ActivitySid", Policy.required); policies.Add(policy); }
public void AllowTaskReservationUpdates() { if (channelId.Substring (0, 2).Equals ("WK")) { var policy = new Policy(this.baseUrl + "/Tasks/**", "POST", true); policy.postFilter.Add("ReservationStatus", Policy.required); policies.Add(policy); } else { throw new Exception ("Deprecated function not applicable to non Worker"); } }
public void AllowWorkerActivityUpdates() { if (channelId.Substring (0, 2).Equals ("WK")) { var policy = new Policy (this.resourceUrl, "POST", true); policy.postFilter.Add ("ActivitySid", Policy.required); policies.Add (policy); } else { throw new Exception ("Deprecated function not applicable to non Worker"); } }