Create Read Update Delete Originally was applied to SQL Operations.
Operation | SQL | HTTP/REST | LDAP | Linux Files and File Permissions |
---|---|---|---|---|
Create | INSERT | PUT / POST | Add Request | write |
Read | SELECT | GET | Search Request/SearchResultEntry | read |
Update | UPDATE | PUT / POST / PATCH | Modify Request | write |
Delete | DELETE | DELETE | Delete Request | write |
Though HTTP GET and HTTP DELETE coordinate well, HTTP POST, HTTP PUT, and HTTP PATCH aren’t directly synonymous with a single CRUD operation.
For example, HTTP POST doesn’t necessarily only mean “Create”. It’s actually a very versatile method — so versatile that the entire SOAP protocol is tunneled through the HTTP POST method when used with HTTP.
Since HTTP Methods don’t map cleanly to CRUD, Ulsberg argues that API providers should consider how they might describe their APIs in a different way: "Don’t limit yourself to CRUD when you design a REST API. You should read the specification and understand the semantics of each method, and use it properly."
What it comes down to is that REST is an architectural style, not a protocol.
Description | String | Integer |
---|---|---|
Full Permissions | CRUDX | 31 |
Null Permissions | ----- | 0 |
Read Only | -R--- | 2 |
Read & Execute | -R--X | 18 |