Provides a web service for managing and checking entitlements.
| Method |
Description |
| addGroupEntitlement |
Adds the entitlements specified by the supplied mask to the user for the given container and content type. |
| addUserEntitlement |
Adds the entitlements specified by the supplied mask to the user for the given container and content type. |
| getEntitlementMasks |
Returns all the entitlement masks available in the system. |
| isUserEntitled |
Returns true if the supplied user has any of the entitlements specified by the given mask for the supplied container
and content type
|
| removeGroupEntitlement |
Removes the entitlements specified by the supplied mask from the user for the given container and content type. |
| removeUserEntitlement |
Removes the entitlements specified by the supplied mask from the user for the given container and content type. |
addGroupEntitlement
Adds the entitlements specified by the supplied mask to the user for the given container and content type.
POST http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Arguments
| Name |
Type |
Description |
| groupID |
xs:long |
the id of the group to set entitlements for |
| containerID |
xs:long |
the id of the container to set entitlements for |
| containerType |
xs:int |
the type of the container to set entitlements for |
| contentTypeID |
xs:int |
the content type to set entitlements for |
| mask |
xs:int |
the entitlement mask to add |
Arguments Template
<addGroupEntitlement>
<groupID>xs:long</groupID>
<containerID>xs:long</containerID>
<containerType>xs:int</containerType>
<contentTypeID>xs:int</contentTypeID>
<mask>xs:int</mask>
</addGroupEntitlement>Errors
| Error |
When Returned |
| NotFound |
if the specified group or container do not exist. |
addUserEntitlement
Adds the entitlements specified by the supplied mask to the user for the given container and content type.
POST http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Arguments
| Name |
Type |
Description |
| userID |
xs:long |
the id of the user to set entitlements for |
| containerID |
xs:long |
the id of the container to set entitlements for |
| containerType |
xs:int |
the type of the container to set entitlements for |
| contentTypeID |
xs:int |
the content type to set entitlements for |
| mask |
xs:int |
the entitlement mask to add |
Arguments Template
<addUserEntitlement>
<userID>xs:long</userID>
<containerID>xs:long</containerID>
<containerType>xs:int</containerType>
<contentTypeID>xs:int</contentTypeID>
<mask>xs:int</mask>
</addUserEntitlement>Errors
| Error |
When Returned |
| NotFound |
if the specified user or container do not exist. |
getEntitlementMasks
Returns all the entitlement masks available in the system. Once a client acquires the set of available masks, the values they
container can be OR'ed together (or merely passed individually) as the 'mask' argument to the other methods of this service.
GET http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Response
| Type |
Description |
| List of
EntitlementMask |
all the entitlement masks available in the system |
Response Template
<getEntitlementMasksResponse>
<!-- List of ... -->
<return>
<!-- Contents of EntitlementMask -->
<return>
</getEntitlementMasksResponse>isUserEntitled
Returns true if the supplied user has any of the entitlements specified by the given mask for the supplied container
and content type
GET http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Arguments
| Name |
Type |
Description |
| userID |
xs:long |
the id of the user to test |
| containerID |
xs:long |
the id of the container to test |
| containerType |
xs:int |
the type of the container to test |
| contentTypeID |
xs:int |
the content type to test |
| mask |
xs:int |
the entitlement mask to test |
Arguments Template
<isUserEntitled>
<userID>xs:long</userID>
<containerID>xs:long</containerID>
<containerType>xs:int</containerType>
<contentTypeID>xs:int</contentTypeID>
<mask>xs:int</mask>
</isUserEntitled>Response
| Type |
Description |
| xs:boolean |
true if the supplied user has any of the entitlements specified by the given mask for the supplied container
and content type
|
Response Template
<isUserEntitledResponse>
<return>xs:boolean</return>
</isUserEntitledResponse>Errors
| Error |
When Returned |
| NotFound |
if the specified user or container do not exist. |
removeGroupEntitlement
Removes the entitlements specified by the supplied mask from the user for the given container and content type.
POST http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Arguments
| Name |
Type |
Description |
| groupID |
xs:long |
the id of the group to remove entitlements for |
| containerID |
xs:long |
the id of the container to remove entitlements for |
| containerType |
xs:int |
the type of the container to remove entitlements for |
| contentTypeID |
xs:int |
the content type to remove entitlements for |
| mask |
xs:int |
the entitlement mask to remove |
Arguments Template
<removeGroupEntitlement>
<groupID>xs:long</groupID>
<containerID>xs:long</containerID>
<containerType>xs:int</containerType>
<contentTypeID>xs:int</contentTypeID>
<mask>xs:int</mask>
</removeGroupEntitlement>Errors
| Error |
When Returned |
| NotFound |
if the specified group or container do not exist. |
removeUserEntitlement
Removes the entitlements specified by the supplied mask from the user for the given container and content type.
POST http://domain:port/application_context/rpc/rest/entitlementService/entitlements
Arguments
| Name |
Type |
Description |
| userID |
xs:long |
the id of the user to remove entitlements for |
| containerID |
xs:long |
the id of the container to remove entitlements for |
| containerType |
xs:int |
the type of the container to remove entitlements for |
| contentTypeID |
xs:int |
the content type to remove entitlements for |
| mask |
xs:int |
the entitlement mask to remove |
Arguments Template
<removeUserEntitlement>
<userID>xs:long</userID>
<containerID>xs:long</containerID>
<containerType>xs:int</containerType>
<contentTypeID>xs:int</contentTypeID>
<mask>xs:int</mask>
</removeUserEntitlement>Errors
| Error |
When Returned |
| NotFound |
if the specified user or container do not exist. |