HTTP methods used to designate the appropriate action to direct a server towards a resource. GET and POST are the most widely known; PATCH and DELETE also fit in that category, among others.
Questions tagged [http-method]
355 questions
0
votes
1 answer
Should mutations always use POST?
Philosophically, I am accustomed to always using GET for HTTP requests that do not alter state, and POST for requests that do. However, lately I have run into some difficulties with this that have caused me to make exceptions. I was curious if…

Nick Retallack
- 18,986
- 17
- 92
- 114
0
votes
1 answer
Why are allowedMethods generated in controllers defined as POST only in Grails?
The code generated in controllers for domain classes allowed POST method only for 'save', 'update' and 'delete'. Does this only because of that the GET method would show the params in the URL or it is out of other considerations? Like the semantic…

Rgnrtn Cifer
- 3
- 5
0
votes
1 answer
Why the put and delete method need methodoverride?
What I mean is, why just let the put and delete as same as get and post,
they are all http method, when I want use put and delete,
I have to do some special trick, like use methodoverride,
Is there some technical problem about letting the same?

hh54188
- 14,887
- 32
- 113
- 184
0
votes
1 answer
setHttpMethod weird behaviour
I am facing a weird problem in downloading xml files from server.
I am trying to get schedulist.xml using the following code,
- (void) downloadXml:(NSString*)url {
_urlRequest = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:url]];
…

Cyril
- 1,216
- 3
- 19
- 40
0
votes
1 answer
equivalent HTTP queries get different responses
GET http://d9.c4.b1.a0.top.list.ru/ HTTP/1.0\r\nHost: d9.c4.b1.a0.top.list.ru\r\n\r\n
response:
HTTP/1.0 400 Bad Request
Server: wz/1.5
Date: Sat, 17 Nov 2012 19:00:20 GMT
Cache-control: no-store, no-cache, must-revalidate
Pragma:…

eXXXXXXXXXXX2
- 1,540
- 1
- 18
- 32
0
votes
1 answer
java.lang.NoSuchMethodException: in struts 1.3.*
i have a action class which has the method i call but still i get the following exception
SEVERE: Action[/common/DepartmentAction] does not contain method named ''
java.lang.NoSuchMethodException:…

Java Questions
- 7,813
- 41
- 118
- 176
0
votes
0 answers
Rails routes work in console but not server
I'm having trouble with a route that seems to be right in the console but gives me a routing error when I use it in the server. The case is similar to the "edit" and "update" pair. Calling GET 'messages/25/followup' should route to…

Mike Blyth
- 4,158
- 4
- 30
- 41
-1
votes
2 answers
Configuring a route in Symfony with the same URL but different HTTP methods and controller actions
I have the following routes configuration in a Symfony application:
label:
url: /label
param: { module: label, action: configure }
requirements: { sf_method: get }
label_create:
url: /label
param: { module:…

elitalon
- 9,191
- 10
- 50
- 86
-1
votes
2 answers
Cannot POST / - URL with parameters
I'm trying to post something, but always get error.
articlesRouter.post('articles/:target', async (req, res) => {
const target = req.params.target.replaceAll("_", " ")
const article = await Article.findOne({where: {title: target}})
if…

Dmitry
- 9
-1
votes
1 answer
Options request throws AssertionError error in Django REST Framework
I have the following Viewset:
class My_ViewSet(viewsets.ModelViewSet):
serializer_class = My_Serializer
queryset = My_Object.objects.all()
def list(self, request):
# The code here is irrelevant
return Response()
def…

SWater
- 384
- 1
- 13
-1
votes
1 answer
PHP HTTP Proxy - How to create a tunnel after a CONNECT request
I've created an HTTP Proxy with PHP. It works well for simple HTTP requests where it receives the request, passes it to the target, passes the target's response to the client and closes the connection.
But in the case of TLS requests, when a client…

Reza Nooralizadeh
- 95
- 1
- 7
-1
votes
1 answer
Cherrypy, REST : how can i pass an optional argument to the GET function that if it isn't given in the URL is set to a specific value?
I am working with CherryPy framework. I am implementing REST and what i want the HTTP Method GET to retrieve some information given a parameter passed in the URL that should be an integer. This parameter is optional and if not given it must be set…

costola
- 1
-1
votes
2 answers
Get Value and pass as parameter to function in Java
ResponseEntity respEntity = null;
try {
respEntity = getConfiguredRestTemplate().exchange(uri.toString()
, HttpMethod.GET
, entity
, new…

Dev
- 21
- 1
- 6
-1
votes
1 answer
REST Response after updating a resource resulting in a location change
Let's say I have a user resource (/users/{username}) and the client uses PUT to update the username. In this case the location of the resource changes (because username is the ID).
That's not idempotent, because you can't perform the same request a…

Melkor
- 243
- 2
- 14
-1
votes
1 answer
GROOVY: how to write only GET request using serverSocket?
I want to create a socket that will reply to me 200 OK only to GET request and reply 500 to other methods.
Input returns me lines and the first one has the name of method. I can't understand how to match GET with such an output.
static void…

Nicolay
- 1
- 1