Questions tagged [http-status-code-204]

The HTTP response status code 204 No Content

The server has successfully fulfilled the request and that there is no additional content to send in the response payload body.

68 questions
2
votes
1 answer

What is the difference between returning void and ResponseEntity in Spring Boot RestController?

I wonder what the difference is between the return value of a Spring Boot RestController if void shall be returned? I can see do difference in a test in either way. It seems that even if I return void the HttpStatus.NO_CONTENT (204) is returned to…
2
votes
0 answers

Axios doesn't resolve/reject promise on status code 204

I'm calling a private REST API with axios as http-client. If I'm calling an endpoint which should respond some information about an object I get an response (status code 200, payload containing the info, and so on). If I'm requesting an object which…
db3000
  • 400
  • 5
  • 16
2
votes
0 answers

Google docs viewer returning blank screen (204 response) sometimes

We use Google doc viewer to view pdf files which sometimes responds back with 204 - an untitled document. After a page refresh the content gets loaded. We have tried to add embed tags which doesn’t solve the issue. We have also noticed that the…
2
votes
1 answer

Return http-status-code 200 or 204 if no content found to process

In web-API client made a get request with a parameter, to process something and get data from the file system. The parameter requested through the API a folder path. If API found that path, it is processing something on the resources inside and…
2
votes
1 answer

Why does Firefox have a problem with this 204 (No Content) response?

I'm calling a WebAPI controller from jQuery AJAX to request an item be deleted via a REST API. The WebAPI controller returns a 204 (No Content) response, which then invokes a second request (GET). For this example I expect both requests to receive a…
awj
  • 7,482
  • 10
  • 66
  • 120
2
votes
0 answers

Warning: Couldn't read data from file

When i try to do an HTTP PUT request to upload a data file .img on image OpenStack like this: curl -i -X PUT -H "X-Auth-Token: $Token" -H "Content-Type: application/octet-stream" -d "@/home/nic/cirros-0.3.5-x86_64-disk.img"…
Tatta
  • 21
  • 4
2
votes
2 answers

How do i create a url that returns a 204

I am trying to use the i frame buster buster code but i need to use a 204 url. How do i create page that gives of a 204 no content error so that this iframe bustter buster code works