All of the endpoints in the Role REST API are inherited from the generic PersistedModel REST API.  The reference is provided here for convenience.

Quick reference

URI Pattern

HTTP VerbDefault PermissionDescriptionArguments

/roles

 

POSTAllow

Add role instance and persist to data source. Inherited from generic model API.

JSON object (in request body)
/rolesGETDenyFind all instances of role that match specified filter. Inherited from generic model API .

One or more filters in query parameters:

  • where
  • include
  • order
  • limit
  • skip / offset
  • fields
/rolesPUTDenyUpdate / insert role instance and persist to data source. Inherited from generic model API .JSON object (in request body)
/roles/idGETDenyFind role by ID: Return data for the specified role instance ID. Inherited from generic model API .id, the role instance ID (in URI path)
/roles/idPUTDenyUpdate attributes for specified role ID and persist. Inherited from generic model API .

Query parameters:

  • data - An object containing property name/value pairs
  • id - The model id
/roles/idDELETEDenyDelete role with specified instance ID. Inherited from generic model API .id, role ID (in URI path)
/roles/id/existsGETDeny

Check instance existence: Return true if specified role ID exists. Inherited from generic model API .

URI path:

  • id - Model instance ID
/roles/countGETDeny

Return the number of role instances that matches specified where clause. Inherited from generic model API.

Where filter specified in query parameter
/roles/findOneGETDeny

Find first role instance that matches specified filter. Inherited from generic model API .

Same as Find matching instances.