Questions tagged [http-request]

HTTP Request is a message within a request/response sequence, according to HTTP specification. May also refer an HttpRequest class in software frameworks and libraries that automates relevant functionality

From W3C specification:

A request message from a client to a server includes, within the first line of that message, the method to be applied to the resource, the identifier of the resource, and the protocol version in use.

    Request       = Request-Line              ;
                    *(( general-header        ;
                     | request-header         ;
                     | entity-header ) CRLF)  ;
                    CRLF
                    [ message-body ]          ;

See also:

355 questions
1
vote
1 answer

Sending image as binary via require("http") request to a remote server

I'm trying to send an image to remote server from nodejs server. Here's the request format so far. Note: Just like binary request in postman and choosing a file and sending) function upload(options, body) { body = body || ''; return new…
user2727195
  • 7,122
  • 17
  • 70
  • 118
1
vote
1 answer

wp_remote_get function response not showing intended result

I have not made WordPress http request before this. I did it first time and I am not getting the return response. It seems the response is not the intended as the API I am using, there the documentation depicts some parameters we can get in return,…
1
vote
1 answer

Provisional headers are shown only for my ip address

Whenever I send HTTP Post Request to upload files through an HTML form, it hangs on my ip address. I've done a lot of troubleshooting. very simple HTML form, only the form is in the PHP file, submit the form to itself, i tested across multiple…
user2898051
  • 99
  • 10
1
vote
1 answer

idHttp post ListBox or StringList content in json

How can I post the content of a TStringList or TListBox in JSON format using TIdHTTP? Note : I need to post them in one request ! The content of the list box looks like this : window door box pin book lamp tree house roof .. .. .
K.MuS
  • 141
  • 1
  • 10
1
vote
1 answer

HttpWebRequest Fails Compact Framework

Trying to make a Http POST request on a windows mobile 6.5 device I can view the web page in a browser on the device but the Http request fails private string SendData(string directory, string data) { string page =…
likdaboo
  • 180
  • 1
  • 1
  • 11
1
vote
0 answers

406: not acceptable response received using LWP::UserAgent/File::Download

Edit: it seems the issue was caused by a dropped cookie. There should have been a session id cookie as well. For posterity, here's the original question When sending a request formed as this GET https://? Cache-Control:…
mpag
  • 531
  • 7
  • 19
1
vote
2 answers

Sending request from node.js to apache2.2.21

I am calling function dorequest many times per request to node server. I have problem with request to webpage running on apache2.2.21. Almost of these request are done without any problems, but several request ending with error ECONNRESET and I…
Tomas Ji
  • 55
  • 4
1
vote
1 answer

ios swift 2.1 - unable to send Patch request with body

I'm trying to write a http rest client for my webservice and i need to send some PATCH requestes with data in the body. I'm using the JUST library for sending requests ( https://github.com/JustHTTP/Just ) My express application just doesn't see the…
Mirco Lcl
  • 373
  • 7
  • 19
1
vote
2 answers

AngularJS $http request to Web Service requires CORS

I am writing a service which needs to access a WebService (which I have no control over) - an API which I would like to consume in my application. I have visited the url in question within my browser and the login is successful, and I can see my…
Josh Brass
  • 147
  • 2
  • 15
1
vote
0 answers

Robolectric: testing with HTTP Response

I create a test call API with Robolectric with this code FakeHttp fakeHttpLayer = FakeHttp.getFakeHttpLayer(); // Allow all Fake Http Request fakeHttpLayer.interceptHttpRequests(false); FakeHttp.setDefaultHttpResponse(200, "OK"); …
Khang Tran
  • 467
  • 5
  • 16
1
vote
1 answer

What is the difference between node.js request and restify client?

Both seem to serve similar purpose. I am using restify server as REST API server. Does it mean it is better that I use restify client as well? http://restify.com/#client-api https://www.npmjs.com/package/request
guagay_wk
  • 26,337
  • 54
  • 186
  • 295
1
vote
0 answers

Is it a good practice to cancel a HTTP request with another request?

Consider we have an HTTP server and there are many concurrent clients making HTTP requests to this server. The responses are adequately big to be considered. User may send requests on the trot, with different request bodies. Once a new request has…
Buğra Ekuklu
  • 3,049
  • 2
  • 17
  • 28
1
vote
0 answers

HTTP request and response flow for get

I am having difficulties understanding the HTTP request and response flow. I am working with a system where I can "hijack" incoming HTTP request and give my own response. The problem I am having is that some type of GET request seem to assume that…
1
vote
1 answer

http requests : from urllib2 to requests python 2.7

I've been trying to switch all my http requests in a script from using urllib1/2 to using Requests to do more advanced requests. Clearly, I fail to do so. Can anyone explain me the difference between : import…
Julien BERNARD
  • 653
  • 6
  • 17
1
vote
1 answer

403 error in Unity3D C#

I have the following code: HttpWebRequest tokenRequest = (HttpWebRequest)WebRequest.Create("http://carkit.kg"); tokenRequest.CookieContainer = new CookieContainer(); string token = ""; using (var response =…
Vassily
  • 5,263
  • 4
  • 33
  • 63