Representational state transfer, or REST, is an architectural style for networking software to transfer information through the web.
1
vote
1answer
19 views
Mixing REST and websocket in the same API
A bit of background first, I'm working on an application that manages a piece of physical equipment with motors, stuff like that. When I started on the project, there was an existing application, ...
-6
votes
0answers
34 views
RESTful interface [duplicate]
I've applied for a perl programming job. The potential employer asked me, how would I implement a certain function, that would work in RESTful way. I've searched the internet about what is the RESTful ...
1
vote
1answer
43 views
Testing front-end app that hits a REST service
A lot of questions about testing here... And I have another one. Forgive me, but I want to make sure I do this right.
Let's say I have a front-end application, be it a mobile app, or a single-page ...
0
votes
1answer
24 views
What is the idiomatic way in REST to handle field level permissions?
REST APIs conventionally expose resources addressed at the object level. While it's easy to do object level permissions using the appropriate HTTP responses, handling field level permissions is a bit ...
-2
votes
0answers
24 views
Almost identical Spring Rest request return different responses, how to understand Spring trace? [migrated]
I have almost two identical controllers connecting to two different JPA Spring data repository. The JPA request work correctly, been tested.
I have other request on the same server that works ...
0
votes
1answer
70 views
Should I implement Enterprise Web based apps without backend only REST? [on hold]
I keep seeing conversations about frontend driven application and using a frontend with REST API directly.
For me, the "cover all cases" architecture is:
REST API - allow users to use your data ...
3
votes
1answer
80 views
Nested REST urls and parent id, which is better design?
Okay, we have two resources: Album and Song. Here is API:
GET,POST /albums
GET,POST /albums/:albumId
GET,POST /albums/:albumId/songs
GET,POST /albums/:albumId/songs/:songId
We know that we hate ...
3
votes
4answers
283 views
What architecture/design to adopt when consuming a RESTful API? (iOS App)
TL;DR
Part 1)
I want to refactor the biggest part of the app on which I work - and it is pretty much spaghetti. It's a single class that makes the requests to the server, parses the JSON and saves ...
3
votes
1answer
149 views
Grouping and nesting of REST APIs
My question is around best practice of aggregating or grouping REST APIs.
I have a scenario where there are many different vendors, data sources, etc. and I think grouping REST APIs would make a lot ...
0
votes
1answer
42 views
REST and foreign key constraints
I have a rather complex database schema using foreign key constraints. This database schema will be accessed with REST services.
Should REST or the database be responsible for referential integrity? ...
0
votes
1answer
33 views
What is the best way to expose services to mobile devices? [closed]
We are working on providing services to mobile devices(Android, iOS and Windows). These services mostly return data and nothing OS or any programming language specific. We are currently planning on ...
0
votes
1answer
28 views
Design of actions handlers requiring some order
I have a REST application where 'actions' can be executed to perform anything in the system. For example: user.save, user.get, etc...
I also have pre and post execution 'handlers'. For example a ...
0
votes
1answer
41 views
proper way to design REST interface with nginx lua.
I'm a noob at nginx and lua. But I'm trying to design a REST interface.
The plan is to create a location entry that will match URIs like this:
curl -i -X GET ...
2
votes
1answer
112 views
Many small requests vs. few large requests (API Design)
I'm currently working on a project with an organization as follows:
Client - Gets data from the main server via REST api.
Server - Requests data from various other servers via third-party APIs
...
1
vote
1answer
63 views
How do I write a REStful API's functional specifications?
I've been looking for answers about writing functional specifications for a software for a while now but I can't seem to find an answer to my specific case.
I think I understand the difference ...
0
votes
1answer
70 views
Is this pattern RESTful? Or something else?
I'm working on a new project that will create a web-based API to perform CRUD operations on a relational database.
Originally, I was going to create the API as http-based, and make it RESTful so ...
4
votes
2answers
69 views
Is ReST useful in Read/Write Operations that involve over 100 Gig
I work in Healthcare and we use SAS to Extract and Transform medical and pharmacy claims data for use in downstream reporting applications. For a given Report Request(usually 40 are running at a ...
2
votes
1answer
46 views
Transactions and subresources with JAX-RS
I'm porting an existing application RESTful API to a Java web framework -- I don't actually care which -- but it's proving hard to get the basics right.
The core of the problem appears to be getting ...
1
vote
0answers
63 views
How shall I project CQRS command and query services through WCF
I got directed to this site for more conceptual questions. Here is my issue:
Im designing an application that uses CQRS to expose functionality to higher levels in the stack. This looks like below ...
2
votes
4answers
72 views
Persistent RESTful state on client without cookies
I'm reading Roy Fielding's dissertation Architectural Styles and the Design of Network-based Software Architectures, which introduces the REST architectural style.
Roy explains that cookies are a ...
1
vote
1answer
59 views
RESTful basic http atuhentication credentials
I am currently working on web application which has front-end, and back-end.
Back-end has RESTful architecture, or something that looks like RESTful to me (this is my first attempt to make something ...
0
votes
0answers
20 views
How to run a function after returning 201 view [migrated]
I'm using the Django Python framework with the Django REST Framework. When a new instance of a model is saved, I need to generate a PDF that is saved locally on the server. Is there a way that I can ...
1
vote
1answer
34 views
What's the proper name for type of security where we secure resources by ownerrship
I work on REST API that mixes two types of security:
First you have standard role-based security - so we have multiple roles such as admin, read-only user, super user user etc.
Then we have also ...
3
votes
1answer
148 views
Event sourcing and REST
I came across Event Sourcing design and I would like to use in an application where a REST client is needed (RESTful to be precise). However I fail to connect these together as REST is quite CRUD-like ...
0
votes
1answer
49 views
Secure Rest api from authenticated user
Let's say that my Rest api is secured using OAuth 2. Let's say my client is a mobile App. Let's say that i have an Api call:
@Post /increasePoints host:https://www.example.com/increasePoints ...
1
vote
2answers
45 views
Should I specify the userId in the REST URL structure?
Basically, one feature of my app is to retrieve the logged user's friends.
Actually, I hesitate between both kind of endpoints:
GET /api/users/friends
GET /api/users/:userId/friends
Using 1, ...
0
votes
1answer
90 views
advantage of having multiple REST web services
I have a application designed using Spring REST service. the application has two REST projects:
Web
Core
Web has html, JavaScript and Java classes (ajax calls this REST). These Java classes in ...
0
votes
1answer
34 views
Handling DomainExceptions using REST endpoint
Suppose I'm doing some DDD.
Now, I have a microservice reflecting a bounded context/a part of a bounded context.
Now, suppose there is a REST endpoint:
'/somedomainmodel/someaction'
My API user is ...
0
votes
1answer
40 views
Why does this API include a static “kind” parameter in the request and response?
I am looking at the Google QPX Express API and noticed that each group of parameters includes a kind parameter that is set to a specific string. For example, on the request:
{
"request": {
...
2
votes
2answers
72 views
Web API: avoiding name conflicts in URL query parameters
I am implementing a REST-like API and have just faced an interesting problem. There is a need to provide a resource with an open list of query parameters to filter the results.
For example:
GET ...
1
vote
1answer
47 views
Do RESTful API controllers typically only provide resources related to their own type?
Let's say my API has the following routes:
GET /theaters
GET /theaters/:id
GET /theaters/:id/movies
GET /movies
GET /movies/:id
GET /movies/:id/theaters
And then I have the following controllers ...
0
votes
2answers
61 views
What does that mean? SOAP operation represents logic and REST Resources that represent data
I am trying to understand the different between SOAP and REST so one of these differences is. SOAP exposes operation that represents logic and REST exposes Resources that represent data. What does ...
1
vote
1answer
12 views
Resource representation can depend on identity?
If some resource on a RESTful api is to be protected, we can do it by using OAuth for example, and then if the there's no token on the headers of the request (i.e. no identity) we return a 401 status ...
0
votes
2answers
347 views
REST API - Should API Return Nested JSON Objects?
When it comes to JSON APIs is it good practice to flatten out responses and avoid nested JSON objects?
As an example lets say we have an API similar to IMDb but for video games. There are a couple ...
5
votes
3answers
130 views
What's the point with HATEOAS on the client-side?
As I currently understand HATEOAS is basically all about sending together with each response links with information about what to do next. One simple example is easily found on the internet: a banking ...
2
votes
1answer
37 views
Separating Django models for SOA
First of all, the goal of this exercise is to create a SOA with Django.
I am trying to understand what the implications would be if I decided to separate and insulate models into apps, provide a REST ...
1
vote
1answer
96 views
How to design a RESTful API with good performance
When designing RESTful APIs, one of the rules is: "URI designates exactly one resource" , but in the real world we also like good performance and one thing to kill performance is the N+1 problem.
So ...
2
votes
1answer
139 views
Trying to process partial POST of data in REST when some data is successful?
I have a resource that accepts array of numbers. Each number is proceed interdependently, and computation fails are expected. How should I communicate to API client "some of your numbers couldn't be ...
2
votes
2answers
155 views
Understanding RESTful web services
I've been trying to understand how RESTful web services work and I've come up with a series of doubts and questions for which I have been unable to find an answer. First of all and to make sure I am ...
0
votes
0answers
71 views
Web Api design - Using Nouns vs verbs
I have this design situation at work. We have a internal Web-Api application and a Asp.Net Web forms application(UI). The web-application is calling Web-Api to update a Contractor.
public Class ...
1
vote
1answer
118 views
Does ORM at any point become a “requirement” for RESTful API?
I've started building a RESTful API in PHP's Slim framework. The framework appealed to me because of its light-weight design and routing features. I am using PostgreSQL for the database.
However, ...
0
votes
2answers
98 views
RESTful Backend - How coupled should my back end and front end be?
I'm creating a web application with a front end client written in angular as well as a back end that I'm writing in Django (there are reasons I picked the frameworks but they are irrelevant to my ...
1
vote
1answer
45 views
What is really a resource?
I'm starting to study about web api's and REST and I'm having a hard time to understand what is really a resource. Basically the book I'm reading says that a resource is a conceptual mapping to one or ...
1
vote
3answers
288 views
RESTful Api: Send email with links to client URL
A client can call the following REST api URI to send an enquiry
POST /v1/businesses/{business_name}/enquiries
The enquiry can then be viewed through the following call:
GET ...
0
votes
1answer
32 views
RESTful way of referencing other resources in the request body
Let's assume that I have a resource called group with the following representation:
{
"id": 1,
"name": "Superheroes"
"_links": {
"self": {
"href": ...
0
votes
0answers
47 views
How to consume inconsistent REST API with Mongo DB backend?
We are using a third party REST API and we are building one of the pages on our ASP.NET site around the data it delivers. We get results in JSON, and interact with it mostly using .NET MongoDB Driver.
...
1
vote
2answers
38 views
Using many Resource URI to create a Record and handling failure
Hi Guys,
I have a decision to make to solve a problem, I’m describing the problem below.
Application Overview
I have an ASP.NET MVC 4 webApp which uses Rest Api for almost all the tasks, from Login ...
6
votes
3answers
536 views
Designing a REST api by URI vs query string
Let's say I have three resources that are related like so:
Grandparent (collection) -> Parent (collection) -> and Child (collection)
The above depicts the relationship among these resources ...
1
vote
2answers
82 views
Do web applications use HTTP as a transport layer, or do they count as an integral part of the HTTP server?
Given an HTTP server (e.g. Apache, IIS) and a web application (user code running in the server using PHP, ASP.NET and the likes), which of those can decide which HTTP status code to return for any ...
1
vote
1answer
66 views
REST request of different length
When a client requests my .../resources/user URL with a HTTP GET I get the following response:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<collection>
<User ...