Questions tagged [idhttp]

This is the Indy component for HTTP requests.

TIdHTTP is a component of the Internet Direct (aka "Indy") open source library for performing HTTP requests. The component can handle redirects, authentication, and data retrieval all by itself.

IO Handlers can be attached for SSL, streaming, or custom designed IO.

268 questions
1
vote
2 answers

Delphi TIdHTTP.Get() API fails with 400 Bad Request when parameter value contains space

I'm sending a number of parameters to an API using the TIdHTTP.Get() method. I pull values for the actual API parameters from string variables or component Text properties (like a ComboBox, for example). Everything is fine until any of those values…
t1f
  • 3,021
  • 3
  • 31
  • 61
1
vote
1 answer

Delphi Indy TIdHttp and multipart/x-mixed-replace with Text and jpeg image

I´m using a Dahua Facial terminal and it has a API like (CGI style) and a SDK. i asked some questions about dll convertions, but now i´m trying to use de API too. The API to monitoring the events handled by Facial…
1
vote
1 answer

Delphi - how to create folder by Indy on my HTTP page

Can anybody help me with folder creation on my HTTP server (It is SanDisk Connect WiFi) SanDisk has a own address : http://172.25.63.1/myconnect/ I am able by Indy from Android to do follow : download files from ->> IdHTTP1.Get upload separated…
1
vote
1 answer

Is TIdHTTP threadsafe?

I'm using TIdHTTP in my class to handle web APIs (TWebAPI). Since it might happen that this class is used in a TIdHTTPServer.OnCommandGet event handler, I need to make sure that TWebAPIis thread safe. Do I need to wrap a PUT/GET/POST inside a…
Wolfgang Bures
  • 509
  • 4
  • 12
1
vote
1 answer

TIdCompressorZLib doesn't work in FireMonkey app compiled for Android

I have a function using TIdCompressorZLib and TIdHTTP, like this: pegar := tidhttp.create(nil); compressor := TIdCompressorZLib.create(pegar); seguro := TIdSSLIOHandlerSocketOpenSSL.create(pegar); pegar.compressor :=…
1
vote
1 answer

Delphi XE8 idHttp Erromessage text coding is wrong

I am using Delphi XE8 and I am sendig a PUT message via idHttp. Http.Request.CustomHeaders.Clear; Http.Request.BasicAuthentication := false; http.Request.Method := 'PUT'; Http.Request.Accept := '*/*'; Http.Request.ContentType :=…
1
vote
1 answer

Why TIdHTTP can't get a result correctly, but Postman can

I have written a function in Delphi XE3 to get some data from the web using TIdHTTP. It can't get a result correctly, but postman can. Using a browser also returns data normally. Can someone help here? procedure CreateHTTP(var vHTTP: TIdHTTP; var…
1
vote
0 answers

TidHTTP XML response doesn't contain body

I am currently sending an XML POST (using TidHTTP) to a web server, and I am successfully getting a response, however the body is missing! I feel like I have tried everything to get this working! The body contains crucial data which I would need to…
1
vote
1 answer

POST with Indy + SSL + Proxy

I'm trying to do a POST request through proxy using https. Code looks like: FHttp := TIdHttp.Create(nil); FHttp.ProxyParams.ProxyServer := Host; FHttp.ProxyParams.ProxyPort := Port; FHttp.ProxyParams.ProxyUsername := User; …
Alex
  • 23
  • 5
1
vote
1 answer

delphi 2010 - tidhttp post

i want to post data to the following url: http://mehratin.heroku.com/personals/new i write the following code but has problem: procedure TForm1.Button3Click(Sender: TObject); var aStream: TMemoryStream; Params: TStringList; begin aStream :=…
Abolfazl Mahmoodi
  • 380
  • 1
  • 3
  • 20
1
vote
1 answer

Delphi /w Indy 10: Get Content after ERROR 400 (idHTTP)

I am trying to get around the Indy idHTTP Component and have some issues retrieving the server response after a GET/PUT/POST if it's not 200 OK. Even if I disable the ProtocolException, Response.ResponseText AND the reutrned StringStream only show…
Wolfgang Bures
  • 509
  • 4
  • 12
1
vote
1 answer

Delphi XE7 Indy idHTTP client post error authorising

I'm attempting to connect to an online API using Indy HTTP client. The error I'm getting is "Authorisation failed (that's our message) EIdOSSLUnderlyingcryptoerror Error connecting with SSL, error:14094410: ssl ROUTINES:SSL3_READ_BYTES:SSLV3 alert…
1
vote
0 answers

Segmentation fault with TidHttp in a Android Service

I created a Android local service in delphi that triggers a thread that creates a Tidhhp, if I stop the service through the command JavaService.stopSelf and start the service again without closing the app, a "Segmentation fault(11)" error occurs…
1
vote
1 answer

No mapping for the Unicode character exists in the target multi-byte code page : how to convert MemoryStream to String

My goal is to be able to convert TMemoryStream to string. I have this code to get the data into the TMemoryStream: var idHttp : TIdHTTPEx; url : string; slTemp : TStringList; memoryStream : TMemoryStream; begin try idHttp :=…
Ago
  • 755
  • 7
  • 28
1
vote
1 answer

Delphi 10 Indy IdHttp how to implement OnWork in Task

I implemented a TTask to perform multiple uploads. I still have to implement IdHttp's OnWorkBegin, OnWork, OnWorkEnd methods in the task I created but I don't know how. var TASK: ITask; begin TASK := TTask.Create( procedure var …
Daniele
  • 177
  • 14