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

learn more… | top users | synonyms

0
votes
1answer
20 views

Good way to handle the notification counter like Facebook does

I want to build a similar notification mechanism that Facebook handles. I actually store the user's notification in an SQL table (actually it's a graph database but everybody master RDBMS terms). ...
7
votes
3answers
2k views

Are there any problems with implementing custom HTTP methods?

We have a URL in the following format /instance/{instanceType}/{instanceId} You can call it with the standard HTTP methods: POST, GET, DELETE, PUT. However, there are a few more actions that we ...
-2
votes
0answers
41 views

AS2 - is it necessary? [on hold]

Is AS2 still relevant? A company I'm trying to retrieve data from only provides their data through AS2. I'm not sure exactly how I'll get that data, but from what I've been told, I just need to tell ...
0
votes
1answer
62 views

Single page app permissions represented through RESTful APIs

I'm trying to figure out the right way to handle permissions in a single page app that talks directly to several RESTful APIs, that implement HATEOAS. As an example: "As a user of my application I ...
0
votes
0answers
15 views

Upload Data Using Pipeline Web Service

I need to develop applications to accomplish the following: Client (Android/Blackberry/iPhone/Windows phone) will automate (no users' interaction) the process of submitting data to server Server ...
1
vote
3answers
111 views

Commenting strategies in C# & asp.net web api

I've been working on a ASP.NET Web Api 2 project as a learning exercise, and I was wondering what the norm regarding commenting is. I use the Repository / Service Pattern, and everything is very much ...
-1
votes
1answer
48 views

WebApp + REST - Architecture Approach [closed]

I've been working on a big Java project that requires the following: One Web Application. One REST API that exposes the same data the web app consumes which will be required for those that don't get ...
0
votes
0answers
45 views

Multitier architecture using API

I have been reading a number of posts and I am leaning towards building an SOA. My main dependencies are: Need to support multiple clients Need individual client environments to not effect other ...
0
votes
1answer
72 views

DTO - service layer - statelessness best practices interfering with each other

I am designing a REST API coupled with a service layer that takes DTOs as input and produces them as output. This works fine for most service calls where the DTO is used to access an underlying ...
2
votes
2answers
321 views

How can I refactor client side functionality to create a product line-like generic design?

Assume the following situation similar to that of Stack Overflow: I have a system with a front-end that can perform various manipulations on the data (by sending messages to REST back-end): Posting ...
1
vote
1answer
56 views

Is OAuth suitable for this scenario?

I need to create a simple web application for track expenses, with some basic actions (user must be able to create an account and log in, list expenses, edit them, etc) with a REST API for each one, ...
0
votes
0answers
6 views

how to use '&' in URL Params for Rest Service Method [migrated]

I am using postman extension in chrome as RestClient. My service url is as follows http://localhost:22/myserv.svc/InsertData?Id=1223&OffcName=my office&pid=2234 this is saving correct in ...
1
vote
1answer
78 views

Nested objects in REST

I have simple set of resources, not more than 10 types, with some one-to-many relationships. For example An order has many entries An entry has many comments A machine can have multiple entries ...
0
votes
2answers
129 views

How to structure REST api service that accepts POST parameters in the body

Everything I've read says to pass parameters to a REST service in the URI, whether by template, or query string: https://www.myapp/my/login/api/authenticate/ganders/mypassword or ...
1
vote
1answer
56 views

REST API Structure

I have a REST API that looks something like the below where a person can belong to an organisation (but doesn't have to) and a person has many items. The items may also belong to the organisation ...
0
votes
1answer
49 views

how should I change the representation (not mimetype) of a resource?

I'm looking at how I can change the representation of a payload at runtime for varied potential advantages, but I'm not sure how to do it. Specifically collections. Array of Pairs [{ ...
1
vote
1answer
49 views

What is the argument for singular nouns in RESTful API resource naming?

I understand that when naming RESTful URI's it is commonly accepted to use plurals to represent collections of resources. I am curious as to the argument for using singular nouns instead.
2
votes
2answers
104 views

Is is OK to use a non-primary key as the id in a rails resource?

I am getting ready to set up a resource for some new api calls to my rails application. I am planning on calling the resource devices ie resources :devices This is going to represent android ...
0
votes
0answers
11 views

Making a Wordpress site into a Web App using a Third-Party BaaS [migrated]

I would like to use a BaaS service for my mobile apps. Parse.com seems like it will fit my needs, and it offers login (to Parse) through Facebook and other Social sites. The difficulty I am facing is ...
0
votes
0answers
28 views

Link relation values and REL attribute - edited

In REST, do we always use link relation values to convey semantics/role of a linked resource? I assume link relation value is always specified using rel attribute? Should rel attribute only be ...
4
votes
2answers
404 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 ...
1
vote
2answers
221 views

Doubts about several best practices for rest api + service layer

I'm going to be starting a project soon that exposes a restful api for business intelligence. It may not be limited to a restful api, so I plan to delegate requests to a service layer that then ...
0
votes
0answers
36 views

Access Token Verification

I have spent quite a few days reading up on Oauth and token based security measures for REST API's and I am currently looking at implementing an Oauth based authentication approach almost exactly like ...
1
vote
0answers
94 views

ASP.NET MVC WebService - Security for Industrial Android Clients [closed]

I'm trying to design a system that will allow a bunch of Android devices to securely log into an ASP.NET MVC REST Web service. At present neither side are implemented. However there is an ASP.NET ...
0
votes
0answers
19 views

What exactly are Link Relation Values?

From REST in Practice: Hypermedia and Systems Architecture: For computer-to-computer interactions, we advertise protocol information by embedding links in representations, much as we do with ...
1
vote
2answers
98 views

Quite confused about what constitutes Current state of a resource

From REST in Practice: Hypermedia and Systems Architecture: The current state of a resource is a combination of: The values of information items belonging to that resource Links to ...
0
votes
3answers
156 views

POST and PUT requests – is it just the convention?

I've read quite a few articles on the difference between POST and PUT and in when the two should be used. But there are still few things confusing me ( hopefully questions will make some sense ): 1) ...
1
vote
2answers
99 views

REST Service and CQRS

I am struggling with architecture on a new project. I am using the following patterns/technology. CQRS - anything going in goes through a command REST - using WebAPI MVC - asp.net mvc Angular - ...
0
votes
1answer
33 views

URIs and Resource vs Resource representation

URL is an URI which identifies a resource by location. Resource representation is a view of resource's state. This view is encoded in one or more transferable formats, such as XHTML, Atom, XML, MP3 ...
1
vote
1answer
40 views

Is it RESTful to resume terminated POST operation on a GET request?

I have a RESTful API, one of the resource has a state that is determined collectively by multiple servers, not all of them belong to us. One of the operation on this resource will have to modify the ...
4
votes
3answers
185 views

What is the preferred Internet media type of a RESTful POST request?

Is there a preferred/recommended Internet Media Type for RESTful POST requests? For example, if I want to add a new user, should I send the data as a URL encoded string like: ...
30
votes
4answers
33k views

Reasons NOT to use JSF [closed]

I am new to StackExchange, but I figured you would be able to help me. We're crating a new Java Enterprise application, replacing an legacy JSP solution. Due to many many changes, the UI and parts of ...
3
votes
1answer
111 views

Should REST APIs be context independent or dependent?

Let's say I have several users and each one has a user_id and also friends To access their friends, they should be logged in, so a session will be established with the server. Should the REST API ...
2
votes
2answers
133 views

How to indicate to a web server the language of a resource

I'm writing an HTTP API to a publishing server, and I want resources with representations in multiple languages. A user whose client GETs a resource which has Korean, Japanese and Trad. Chinese ...
1
vote
1answer
52 views

URI Representing a Single Resource with Two Possible Identifiers

I have a resource that can be represented in one of two ways: Big Serial Number, or Small Serial Number Is it closer adherence to REST principles to: A: have a query string specify the type ...
16
votes
6answers
1k views

Do RESTful APIs tend to encourage anemic domain models?

I'm working on a project in which we are trying to apply both domain-driven design and REST to a service-oriented architecture. We aren't worrying about 100% REST compliance; it would probably be ...
0
votes
1answer
58 views

Why was REST web srevice named REST?

What does the word Representational State Transfer (REST) mean actually ? Now I don seem to find any relation between its naming and its working, I have understood that it is a architectural style for ...
28
votes
4answers
16k views

Difference between REST and CRUD

I learned REST and it feels a lot like CRUD (from what I have read about CRUD). I know they are different, and I wonder if thinking they are similar means I don't understand them. Is it that REST is ...
1
vote
1answer
307 views

C++ Web Development for REST API [closed]

I've been a C# developer for long time, focused on ASP MVC the most. Two years ago, basiclly due to the lower costs and ease of deployment/management I began to migrate my projects to linux using ...
0
votes
0answers
55 views

RESTful composition/inclusion of other resources

I have a few HTTP resources, and i'm wondering if including the models of one in the other is acceptable or if there is a cleaner method. In this example, we have a ton of "news" resources, and users ...
-1
votes
3answers
145 views

A RESTful way to verify server state [closed]

I'm interested in building verifications into a REST service to help with service monitoring. For example, one could run assertions like ...
2
votes
2answers
293 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 ...
1
vote
2answers
82 views

Should a REST interface include the query ID as part of the response?

I am currently working an Android app that receives most of the displayed data from a REST interface. First, I request the information for a company the request includes a list of store IDs. With ...
1
vote
1answer
223 views

How to handle exception in REST API

Given a REST API, which throws an exception when handling a request from a client. Whenever the REST API throws an exception, it's logged and the application (in this case a console application) ...
2
votes
2answers
192 views

How to provide a service with RESTful API?

Generally speaking, RESTful API's are very good for representing resources and collections of resources. http://example.com/resources http://example.com/resources/item17 And we are good, if we ...
0
votes
0answers
34 views

Charts, SQL and REST?

We have created a REST API for a voting game. Now we are jumping into creating analytics/graphs/charts for moderators and users to watch how are they doing in the game. The game has a certain group ...
0
votes
3answers
70 views

How to design routes for generalized/specialized resources

I hope I can explain what is troubling me. Example: I have an object basket with a list of fruit objects. So normally I would build my routes like this baskets/{basketId}/fruits/{fruitId). But fruit ...
2
votes
1answer
88 views

REST object with resources

I am designing a HTTP-based REST API. Let's say I have an entity called Entity that has a bunch of properties. Some of its properties are files. Let's say Entity has following properties: name: ...
0
votes
1answer
71 views

RESTful API resource path for resource with complex relationship?

In my RESTful API, I have Users, Applications, and Tokens. An application has an owner, which is a user. A token is linked to both an application, and a user. A user has both public and private ...
27
votes
3answers
1k views

What does HATEOAS offer for discoverability and decoupling besides ability to change your URL structure more or less freely?

Lately I've been reading about Hypermedia as the Engine of Application State (HATEOAS), the constraint that is claimed to make a web API "truly RESTful". It boils down to basically including links ...