Questions tagged [restful-url]

Representational state transfer (REST) is a style of software architecture for distributed hypermedia systems such as the World Wide Web.

https://en.wikipedia.org/wiki/Representational_state_transfer

1351 questions
5
votes
3 answers

How do I create a Spring 3 + Tiles 2 webapp using REST-ful URLs?

I'm having a heck of a time resolving URLs with Spring 3.0 MVC. I'm just building a HelloWorld to try out how to build a RESTful webapp in Spring, nothing theoretically complicated. All of the examples I've been able to find are based on…
Ichiro Furusato
  • 620
  • 6
  • 12
5
votes
5 answers

is restful meant for web services only OR for both web services AND web pages?

I read a lot of Restful tutorials for PHP. (I don't want to go in depth into why I am not using RoR. It is due to the team being more familiar with PHP) Because we are planning for future expansion into having APIs i read that it is important to…
Kim Stacks
  • 10,202
  • 35
  • 151
  • 282
5
votes
2 answers

League of Legends Read Chunks/Keyframes through its RESTful API

I am planning to do game data mining in LOL but stuck at parsing replay files. I find that the most popular replay recorder is LOL Replay which records games in .lrf files. They are saved as binary files. I try to print a lrf file to find some…
czxttkl
  • 486
  • 4
  • 14
5
votes
3 answers

the request sent by the client was syntactically incorrect when sending post requests

The method in myController looks like this @RequestMapping(value="/{processId}/dependents", method=RequestMethod.POST,consumes="application/json") @ResponseBody public Dependents postdependent(@ModelAttribute ProcessContext process,@RequestBody…
Vishwa
  • 117
  • 1
  • 2
  • 12
5
votes
1 answer

Express routing GET with search params

I have two GET routes for get stores but, one route is for get all stores and the other route is for get just nearby stores. 1) The url request for get all stores is as follows: http://mydomain/stores 2) The url for get all nearby…
vitorvigano
  • 697
  • 2
  • 8
  • 18
5
votes
3 answers

RESTFul approach for updating a field

I wonder, what would the more RESTFul, flexible and better approach of updating(!) a field (state) of an item /api/v1/items/:id?action=start /api/v1/items/:id/start /api/v1/items/:id/ + action in the…
user266003
5
votes
2 answers

Laravel resource controllers for both API and non-API use

After creating a resource controller PhotosController for a website that also does AJAX calls to the API, it appears that the resource controller can be used on both the normal website and as the API. This displays a HTML page for Photo with id =…
Nyxynyx
  • 61,411
  • 155
  • 482
  • 830
5
votes
3 answers

Url navigation in a WebApp built with ExtJS

when you develop a web application using ExtJS (with its MVC and a Viewport), generally there's no possibility to navigate: every item into the page (buttons, textfields, textareas, ...) is bound to a specific method of the view's controller. So,…
Wilk
  • 7,873
  • 9
  • 46
  • 70
4
votes
1 answer

how to specify a range of data or multiple entities in a restful web-service

To access an instance of a User in a restful web-service the url is structured as shown in the curl request below: curl -v -X GET -s "$BASE_URL/User/${customer_id}.json" If I wanted to specify all User entities or page through a range of User…
murungu
  • 2,090
  • 4
  • 21
  • 45
4
votes
2 answers

Invalid token character '/' in org.springframework.http.MediaType

I have a basic SpringBoot 2.1.5.RELEASE app. Using Spring Initializer, JPA, embedded Tomcat; I want to create this MediaType MediaType mediaType = new MediaType("application/vnd.bonanza+xml"); that in PostMan works fine, but not in…
Nuñito Calzada
  • 4,394
  • 47
  • 174
  • 301
4
votes
2 answers

ReSTful design: return an empty object as a template for create new form

My question is straighforward - I think. Currently the following Uris exist: http://someserver/service/item GET returns all items http://someserver/service/item POST creates a new item http://someserver/service/item/{id} …
jimjim
  • 225
  • 1
  • 4
  • 10
4
votes
3 answers

What is the proper RESTful API method to replace an entire collection?

Imagine, We have an Entity School and this entity has a one to many relationship with Student entity. In other words, there is a collection of Students attached to a given School If we are to replace the entire Student collection via a single API…
rclakmal
  • 1,872
  • 3
  • 17
  • 19
4
votes
1 answer

Pagination in REST architecture

Suppose we have an endpoint that return a list of users, list can be paginated /users?offset=20&limit=10 What to return when total count of users is less than offset? An empty list, an error or ...? Should we also return total count of users in…
Romper
  • 2,009
  • 3
  • 24
  • 43
4
votes
1 answer

Spring RestTemplate 415 Unsupported Media Type

I try to use Spring Restful webservice. I have created two projects in two eclipse. In one project I have written RestClient program and in another project I have written webservice and stared the webservice over tomcat. I am trying to pass java…
4
votes
2 answers

What's the pattern to request for all records using RESTful app?

I would like to know what's the best approach for my RESTful app when requesting all records. For example, I limit my responses to 10 if no $top value is provided to avoid overload. However, how can I format my request? Which is better, $top=allrows…
Alirio
  • 63
  • 2
  • 5