Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 74584

Representational state transfer, or REST, is an architectural style for networking software to transfer information through the web.

4 votes
Accepted

REST and foreign key constraints

Should REST or the database be responsible for referential integrity? Both: DB should have proper constraints. API should have validation rules which reflect those constraints (e.g. … Is it bad practice to have foreign keys constraints in the database when the entities are updated / deleted via REST? No, it is a requirement if you want to keep your data consistent. …
  • 4,412
3 votes

Is this a secure solution for RESTful authentication?

This can help: OWASP REST Security Cheat Sheet, Authentication Cheat Sheet …
  • 4,412
1 vote
Accepted

Transactions and subresources with JAX-RS

If JAX-RS is not a requirement, then I'd suggest looking at Restlet. It uses conveyor architecture, so nesting resources into other resources is not a problem - see hierarchical URIs. When integrating …
  • 4,412
0 votes

Handling DomainExceptions using REST endpoint

Recently I wrote a detailed post on these and some related questions. Should I return a status code and a message in a response? Yes, but message should not contain exception message unless that …
  • 4,412
1 vote

Wait time created by having separated REST API and web application

If you have a REST API, you don't need an MVC application. Instead, create a frontend JavaScript application which uses your API directly. … Compare your current scheme: [JS/HTML frontend] <---> [MVC app] <---> [REST API] to: [JS/HTML frontend] <---> [REST API] ("JS/HTML frontend" is whatever user sees in their browser, be it a thin HTML …
  • 4,412
2 votes
Accepted

What's the proper name for the type of security where we secure resources by ownerrship?

If an owner can grant access to other users, then it is called Discretionary Access Control (DAC): discretionary access control (DAC) is a type of access control defined <...> "as a means of rest …
  • 4,412
5 votes
Accepted

Introduce Data Transfer Objects or expose complex data model in REST

I currently work on a project where both web interface and JSON API (kind of REST, but not quite) use the same Hibernate entities - it is fragile, since every change in one place affects the other. … ORM is good for web interfaces (and probably RPC-style APIs), but seems to cause a lot of troubles with REST - it is related to the idea of CQRS. …
  • 4,412
4 votes
Accepted

Calling RESTful service from browser and handling 4xx class responses

404 is perfectly fine for this use case. 4xx status codes are client error codes, so browser treats them as such, and that is perfectly fine too. Another kind of APIs (e.g. JSON-RPC) use different ap …
  • 4,412