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

learn more… | top users | synonyms

3
votes
2answers
346 views

How is reactive logic programming different from functional programming?

As Reactive Programming model is perfectly suited to address the change propagation required for transaction processing, that is, when the server receives change (Insert, Update, or Delete) requests. ...
2
votes
1answer
205 views

Restful WebAPI VS Regular Controllers

I'm doing some R&D on what seems like a very confusing topic, I've also read quite a few of the other SO questions, but I feel my question might be unique enough to warrant me asking. We've never ...
1
vote
1answer
198 views

How to handle fine grained field-based ACL permissions in a RESTful service?

I've been trying to design a RESTful API and have had most of my questions answered, but there is one aspect of permissions that I'm struggling with. Different roles may have different permissions ...
0
votes
2answers
117 views

Initiating processing in a RESTful manner

Let's say you have a resource that you can do normal PUT/POST/GET operations on. It represents a BLOB of data and the methods retrieve representations of the data, be they metadata about the BLOB or ...
0
votes
0answers
196 views

Is this a secure solution for RESTful authentication?

I need to quickly implement a RESTful authentication system for my JavaScript application to use. I think I understand how it should work, but I just want to double check. Here's what I'm thinking -- ...
2
votes
1answer
3k views

Session in RESTful web services, how it works?

In a web services, how does the server know which request belongs to which session? I know that for a web application, the web server inspects the cookie (or the sessonId query parameter in case ...
0
votes
1answer
123 views

Is ROA a specific form of doing SOA?

I have read somewhere that ROA (Resource Oriented Architecture) is SOA (Service Oriented Architecture) with specific constraints added. SOA is the abstract concept of combining discrete pieces of ...
2
votes
1answer
243 views

Role based access to resources for a RESTful service

I'm still wrapping my head around REST, but I wonder if someone can help with any suggestions or approaches to role based access control for a RESTful service, particularly from the point of view of ...
0
votes
1answer
198 views

The balance between client and server functionality

I want to bring the discussion that started in our teams and get your opinion about it. Assume we have an user account which could have different credentials for authentication and associated email ...
3
votes
2answers
77 views

REST partial bad request

I'm implementing a REST method that allows you to post a list of items. If all data is correct I obviously return a 201 and if all data is incorrect a 400. What would be an appropriate response code ...
0
votes
0answers
32 views

Which timeout should I set to an external service?

This service is a remote session pool. I need to ask for a session to work with other services. In most cases, this pool will have a session available, so in 15ms I will have a response. But ...
1
vote
2answers
617 views

REST or a message queue in a multi-tier heterogeneous system?

I'm designing a REST API for a three-tier system like: Client application -> Front-end API cloud server -> user's home API server (Home). Home is a home device, and is supposed to maintain connection ...
5
votes
2answers
1k views

Comparing TCP/IP applications vs HTTP applications [closed]

I'm interested in developing a large-scale user-facing website that is written in Java. As for design, I'm thinking of developing independent, modular services that can act as data providers to my ...
4
votes
3answers
396 views

OAuth alternative for a 2 party system

I'm writing a RESTful service (Java EE, Jersey) and a client application that communicates with it, and I wish to secure it and store any usernames & passwords dedicated in my own database. I do ...
3
votes
1answer
127 views

What are the best practices and pitfalls of doing a JS app powered purely by RESTful API? [closed]

We are starting to build a new app and I would like to explore the idea of doing a thick JS client (backbone / angular) with only RESTful API exposed by our application layer. What are some of the ...
0
votes
0answers
49 views

Is it possible to share oAuth Session?

We are working on a project that includes a web server and a mobile application, we need to access the user's private data (facebook, twitter ...) from the web server by requesting from the user to ...
1
vote
2answers
486 views

Can REST, Ajax and jQuery work well together?

I'm trying to use REST (usign spring MVC) as my Ajax backend but got some problems when using it with jQuery. REST best pratices recommend using HTTP status code, e.g. 200, 403, 401, etc, and I have ...
-1
votes
2answers
451 views

SQL API instead of a REST API? [closed]

What are the pros and cons of exposing an SQL API instead of a REST API? Let's assume that this would be a private API – the API developer and user are on the same team. Probably the biggest problem ...
1
vote
2answers
635 views

Django REST + Backbone/Ember/Angular Implementation Method

http://stackoverflow.com/questions/10941249/separate-rest-json-api-server-and-client In light of this post, I wanted to ask questions regarding Django and specifically the implementation methods of ...
1
vote
1answer
276 views

Applying DDD principles in a RESTish web service

I am developing an RESTish web service. I think I got the idea of the difference between aggregation and composition. Aggregation does not enforce lifecycle/scope on the objects it references. ...
2
votes
3answers
101 views

Specifying the format in which I want to get a response through POST

It's a good practice to let a client specify the format in Web REST API: GET /api/items/123.csv However, not only GET can return some answer, but POST also can do Status: 201 Created { mgs: ...
2
votes
3answers
131 views

HasMany RESTfull Implementation

So I've been reading a lot on RESTfull design - specifically dealing with resources. Taking the canonical example of Users, Posts, and Comments, with relationships as: Users ---(hasMany)---> Post ...
1
vote
3answers
130 views

Is POST for an element generally not exposed or invalid in REST APIs?

I was browsing around wikipedia on REST, reading specifically the section on REST APIs Reading the different ways to treat elements from collections I read that POST is not generally used. How does ...
2
votes
1answer
291 views

Design Issue: Service layer/ trying to maintain RESTful architecture

I'm trying to design a web-application - and after doing a lot of reading on REST + design patterns, I'm at a loss on how to handle my requirements. I think I may be getting caught-up in all the ...
2
votes
1answer
144 views

REST Relationships Besides Parent/Child

This would seem to be a pretty basic question, but I can't seem to find appropraite guidelines for it. What is the "restful" way of POSTing a relationship between two entities that are not necessarily ...
2
votes
2answers
202 views

Should a RESTful API provide data for an entire form?

Let's say I have a JavaScript web application which entirely uses a RESTful API for data. Let's say this application has a data form, and let's say I'm editing a record at /product/12345. When ...
1
vote
1answer
129 views

How to Track File Uploads and Return Upload Status with REST?

The users for our software will want to upload potentially large amounts of files in bulk to our servers. It is then desired that we display the upload status any time the user views the upload ...
1
vote
2answers
165 views

Returning view code in an API response

I have an API that returns a JSON formatted array of users within a given pair of lat/ long bounds. I'm using this data to plot a number of markers on a map, based on the location of each user. I ...
2
votes
1answer
183 views

Rest API and caching data

I have developed an application where you should be able to browse products catalog(READ ONLY) even network access is down no wifi or 3g/lte etc. Clients(windows,ios,android etc) consume the rest api. ...
2
votes
2answers
240 views

Should an Http API always return a body?

Is there some sort of standard regarding http api responses? After reading this discourse thread I started to wonder. We are developing our public http json api at my work, and we do not return ...
2
votes
2answers
908 views

Is it safe to transmit access tokens via HTTP headers?

It's the first RESTful web service and I am concerned about security issues. Is it safe to transmit my access token via HTTP headers? For example: POST /v1/i/resource HTTP/1.1 Content-Type: ...
1
vote
2answers
189 views

Architecture for REST consumer [closed]

Are there any good samples of web applications that consume restful web services? I am developing a webapp with spring, and have come to the point of reading lists of elements and element details ...
0
votes
0answers
192 views

Rest API + Java. Scala, Hadoop + JavaScript Client : Deployment & Project Structure

Looking for inputs & best practice for new project : Client side : JavaScript (probably AngularJS supporting tools) Server-side & Rest API's : Java, Scala, Hadoop, Spring MVC 3 and other ...
3
votes
1answer
97 views

Modelling REST endpoints with data that not all users have access to

I am trying to figure out the best way around a small problem i have with a design for a Hypermedia API i am currently building. I have a notion of a site, very simple doesn't have much going on and ...
5
votes
2answers
1k views

How should a REST API handle PUT requests to partially-modifiable resources?

Suppose a REST API, in response to a HTTP GET request, returns some additional data in a sub-object owner: { id: 'xyz', ... some other data ... owner: { name: 'Jo Bloggs', role: ...
4
votes
3answers
2k views

Is it OK to return HTML from a JSON API?

On my current project I am responsible for the implementation of a service which involves the consumption of newly created RESTful APIs, documented as solely supporting JSON. The client consistently ...
1
vote
0answers
303 views

Is OAuth (2.0) is the right choice to make WCF WebService secure?

I have WCF webservice which serves to various mobile application. This was implemented with typical HTTPS/SSL. But there are some cases like Replay Attack needs to be considered in the security ...
1
vote
1answer
367 views

necessary to migrate to Web API from MVC controller

Since the released of Web API, I've been wondering whether it's necessary or helpful to migrate/change MVC controllers to use Web API calls. Since it's hard to describe code I'll show an example of ...
-4
votes
3answers
3k views

When to use REST to handle requests vs using AJAX to handle requests [closed]

On my web page, if I wish to display dynamic dropdowns (e.g city names based on country selected), I can do it using AJAX. But I can also do it using a REST call. So which should I use? My problem is ...
16
votes
4answers
1k views

How should I architect a RESTful webservice to use 3rd party (i.e. Google, Facebook, Twitter) for authentication?

For my job we have a nice RESTful webservice we've built out that we use to drive a couple websites we have. Basically the webservice lets you create and work with support tickets, and the website is ...
5
votes
3answers
1k views

Can a webservice that uses JSON over POST be classified as RESTful?

Recently I have started using a new(to me) paradigm for web services. I use the controller to accept JSON strings sent over POST, process it and return JSON strings. GET, PUT, DELETE and other methods ...
4
votes
2answers
593 views

What can REST API do that a API using HTTP URL query strings cannot do?

I'm learning about REST and had the chance to build a basic REST API. After doing so, most of the material I read was internalized and I now have a better understanding of it. However, I do not ...
2
votes
1answer
716 views

What is the proper way of nesting resources in REST model?

I'm designing a REST API of service and got stuck on proper way to nest resources. Resources: partners, tickets, settings Connections between resources: partner has many tickets, partner has set ...
1
vote
2answers
557 views

Why is aggregation function bad idea for RESTful?

As title: Why is aggregation function bad idea for RESTful? Although I know CRUD is good for RESTful. For example, the resource is 'employee', and client needs to retrive sum of total 'salary' of all ...
0
votes
1answer
206 views

Rest API Architecture from Rest in Practice book

We maintain an API that as part of its purpose makes a call to an external API. This external API takes a few seconds to fulfil the request we make to it. With our current architecture the request is ...
1
vote
4answers
175 views

Provide both RESTful interfaces and Java ones?

I am writing a RESTful service in Java, of course it's typical HTTP based interface. I am wondering should the service provide Java interface which has same semantic to the RESTful interface? I think ...
1
vote
1answer
412 views

Combining Single Page Application and DDD with a REST API

I'm creating a web application which on the client side consists of a Single Page Application (with Durandal) and on the server side an ASP.NET MVC site with a Domain Driven Design. The two are ...
4
votes
1answer
291 views

Where to Perform Authentication in REST API Server?

I am working on a set of REST APIs that needs to be secured so that only authenticated calls will be performed. There will be multiple web apps to service these APIs. Is there a best-practice approach ...
6
votes
4answers
2k views

REST API concepts

I have three questions about REST API design that I'm hoping someone can shed some light on. I've searched relentlessly for many hours but haven't found answers to my questions anywhere (maybe I just ...
4
votes
3answers
485 views

Best Practice: Should error messages be handled by the API or by the App?

I am designing an application that interacts with a RESTful API. When returning error messages like Unable to sign up user Should the error message be generated by the app? or by the API? I am ...