Note:
You can use the StrongLoop API Explorer to quickly construct and make requests to a LoopBack app running on the server.
If a LoopBack app is running on localhost
at port 3000
, then by default API Explorer is available at
http://localhost:3000/explorer/.
All of the endpoints in the ACL REST API are inherited from the PersistedModel REST API. The reference is provided here for convenience.
By default, the ACL REST API is not exposed. To expose it, add the following to models.json:
"acl": {
"public": true,
"options": {
"base": "ACL"
},
"dataSource": "db"
}
Quick reference
URI Pattern |
HTTP Verb | Default Permission | Description | Arguments |
---|---|---|---|---|
|
POST | Allow |
Add ACL instance and persist to data source. |
JSON object (in request body) |
/acls |
GET | Deny | Find instances of ACLs that match specified filter. |
One or more filters in query parameters:
|
/acls |
PUT | Deny | Update / insert ACL instance and persist to data source. | JSON object (in request body) |
/acls/id |
GET | Deny | Find ACL by ID: Return data for the specified ACL instance ID. | id, the ACL instance ID (in URI path) |
/acls/id |
PUT | Deny | Update attributes for specified ACL ID and persist. |
Query parameters:
|
/acls/id |
DELETE | Deny | Delete ACL with specified instance ID. | id, acls ID (in URI path) |
/acls/id/exists |
GET | Deny |
Check instance existence: Return true if specified ACL ID exists. |
URI path:
|
/acls/count |
GET | Deny |
Return the number of ACL instances that matches specified where clause. |
Where filter specified in query parameter |
/acls/findOne |
GET | Deny |
Find first ACL instance that matches specified filter. |
Same as Find matching instances. |