Questions tagged [httpresponse]

An HTTP response is a network message which is made of a body and metadata in the form of headers, according to HTTP specification. May also refer an HttpResponse class in software frameworks and libraries that automates relevant functionality

From W3C specification:

   Response      = Status-Line               ;
                   *(( general-header        ;
                    | response-header        ;
                    | entity-header ) CRLF)  ;
                   CRLF
                   [ message-body ]          ;

See also:

3825 questions
1
vote
1 answer

Retrieving response text from curl in cpp

we need to receive response string from curl in CPP ,I tried following options but nothing worked.js uses xhr.responseText for this.I need to do in cpp. static size_t WriteCallback(void *contents, size_t size, size_t nmemb, void *userp) { …
Ek1234
  • 407
  • 3
  • 7
  • 17
1
vote
1 answer

How Do I Indent a New Page in OneNote?

I can successfully create a page in OneNote using the Rest API. I can also successfully indent a given page using patch. However, the issue is when I create a page and then want to indent it. I keep getting back: { "error":{ …
Elliptica
  • 3,928
  • 3
  • 37
  • 68
1
vote
1 answer

How can I get http response sent by android app?

my app is sending some http request, and I want during test step to get all requests and responses. In browser I was used BrowserMobProxy to get all responses but it's look like it's work just on browser. Is some one know how can I get responses…
SelenUser
  • 638
  • 5
  • 13
1
vote
0 answers

Get cookie from HTTPS response message in C - Terminal Ubuntu 16.04LTS

I have a problem when handling the HTTPS response message. I want to get cookie's content from Set-Cookie fields in response header I received. This is my function: void Get_cookie(char *ck, char *message) { const int COOKIE_SIZE = 102400; int i,…
thanhdx
  • 608
  • 4
  • 16
1
vote
2 answers

Can't catch the exception when I send a REST request to an offline HTTP server

In my REST application I use this class to send requests: public final class Utility { private static Client client = ClientBuilder.newClient(); private Utility(){ } public static Response sendRequest(String URI, String method, T payload){ …
logi0517
  • 813
  • 1
  • 13
  • 32
1
vote
2 answers

Django, handle Response from external server

The question is how can I handle HttpResponce from an external server? The idea is that I send json data to an external server (e.g search data {'keyword': keyword, 'limit':limit, 'db':db}) response = requests.post(url, json = userupload,…
sys__admin
  • 124
  • 1
  • 12
1
vote
1 answer

Get HttpResponse object as response from Volley api in android not jsonobject or string

Hi i am using android studio and for network call using volley api. Since it's all good to get JsonObject and String as response from network call . Is it possible to get HttpResponse from volley api ? or any method by which we can retrieve…
user2021938
  • 145
  • 1
  • 1
  • 9
1
vote
1 answer

Deserialize to a CRM Entity from ReadAsStreamAsync or ReadAsStringAsync

I'm making a call to a Web API by HttpResponseMessage response = Helper.SendRequest(...) and I need to deserialize the response to a list of CRM entity Annotation. One of the things we've tried is using ReasAsStreamAsync: List
1
vote
1 answer

Can a RESTful Web Service return a POST Response from Child Thread?

Currently this is the implementation I have for the incoming POST Request. The processing is handled by a Child Thread, but the response must be returned back to the top level to send a response. @Post("json") public String POSTMessage(String…
DrStrange
  • 11
  • 1
1
vote
0 answers

REST service returning wrong content-type if file created has its header set to some value in iOS objective C

In iOS I am using AFNetworking for calling the web-services. Here I am getting the error: "unacceptable content type: application/excel". After a lot of struggle I came to know that it is the server team problem. I have a question regarding…
Medha
  • 39
  • 1
  • 6
1
vote
0 answers

Log response body apache with the client IP

I need to log the server response body along with the client which requested it. Tried mod_dumpio which logs the response body but it doesn't reveal the client IP so I am not able to map the request and response. The other option was audit log…
Varun Hegde
  • 349
  • 2
  • 12
1
vote
3 answers

Continue Processing requests after failure in python

I have a script that runs and submits urls in a text file via GET to an API and saves the response to a text file. However, the for loop quits if I get a failure in the first section and does not continue passing the others. How can I still grab the…
1
vote
1 answer

Custom header is not visible on client side

I have following code in my C# web api HttpResponseMessage result = null; var stream = new MemoryStream(File.ReadAllBytes(tempFileName)); result = Request.CreateResponse(HttpStatusCode.OK); result.Content = new…
1
vote
1 answer

SSL in HttpContext.Current.Response

Might be a dumb question but I need a confirmation regardless. In ASP.NET, if a file was downloaded on a page that was protected by SSL, through a server-side postback that writes to HttpContext.Current.Response.OutputStream, is the transmission…
shyneman
  • 83
  • 4
1
vote
1 answer

How to Parse Google Speech API response in text box

I am working on google speech API in c#. Google is returning results with no problem and its response is shown on my text box. Now I want limited text to be displayed on text box. As given response below, I want only recognized text to be…