<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/</id><updated>2026-03-20T02:45:41.665000Z</updated><subtitle>Recent posts to WebClient result empty</subtitle><entry><title>WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/?limit=25#3f35" rel="alternate"/><published>2026-03-20T02:45:41.665000Z</published><updated>2026-03-20T02:45:41.665000Z</updated><author><name>advisoryel</name><uri>https://forge.codesys.com/u/advisoryel/</uri></author><id>https://forge.codesys.com748464c2099acd8295346eee3ba23f7e981a1a83</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi, it looks like your request is actually working, since you’re getting a 200 status code, but the response seems to be incomplete when using WebClient.&lt;/p&gt;
&lt;p&gt;One possible reason is that the response stream isn’t being read fully. Sometimes WebClient returns partial data if the stream isn’t handled properly or if there’s an encoding issue.&lt;/p&gt;
&lt;p&gt;You might want to try reading the response as a full string (for example with DownloadString in WebClient, or using HttpClient instead), and also check the encoding (UTF-8).&lt;/p&gt;
&lt;p&gt;Another thing to check is whether the device requires any specific headers (like Accept: application/json), as browsers usually send more headers than a simple WebClient request.&lt;/p&gt;
&lt;p&gt;Since it works fine in the browser, it’s most likely a client-side handling issue rather than the IPX device itself. &lt;a href="https://fnaffree.io" rel="nofollow"&gt;fnaf&lt;/a&gt;&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/?limit=25#d0a2" rel="alternate"/><published>2026-03-19T15:39:37.457000Z</published><updated>2026-03-19T15:39:37.457000Z</updated><author><name>Reinier Geers</name><uri>https://forge.codesys.com/u/reinier-geers/</uri></author><id>https://forge.codesys.com6f3ac69e09878ec743b99589d96495c1337221a9</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi Did you solve it ?  I also have problems with webclient.  I tried this forum but no responce.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/?limit=25#a377" rel="alternate"/><published>2026-03-10T08:05:03.406000Z</published><updated>2026-03-10T08:05:03.406000Z</updated><author><name>ineffectua</name><uri>https://forge.codesys.com/u/ineffectua/</uri></author><id>https://forge.codesys.combf0b101611027b9dd0ec392a08c3467264d42fbf</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Since the request works correctly in the browser and returns the full JSON, it seems the API itself is fine. The issue might be related to how the WebClient is reading the response. Sometimes the response is received in chunks or requires waiting until the full content is available before parsing it. You might want to check if the WebClient is reading the complete stream or if there is a buffer/timeout &lt;a href="https://run3-online.io" rel="nofollow"&gt;run 3&lt;/a&gt; setting that stops it too early.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/?limit=25#08c5" rel="alternate"/><published>2026-03-04T20:14:19.139000Z</published><updated>2026-03-04T20:14:19.139000Z</updated><author><name>remlab</name><uri>https://forge.codesys.com/u/remlab/</uri></author><id>https://forge.codesys.com81ec24e390c03e74ac58d965f3e745978173003a</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;If I try &lt;a href="http://192.168.0.250:50543/api/xdevices.json?key=XXX&amp;amp;SetC=1" rel="nofollow"&gt;http://192.168.0.250:50543/api/xdevices.json?key=XXX&amp;amp;SetC=1&lt;/a&gt; it write correctly&lt;br/&gt;
Why can I write but I can't read the Json ?&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>WebClient result empty</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/fcebe348cd/?limit=25#1ab7" rel="alternate"/><published>2026-03-04T20:11:33.468000Z</published><updated>2026-03-04T20:11:33.468000Z</updated><author><name>remlab</name><uri>https://forge.codesys.com/u/remlab/</uri></author><id>https://forge.codesys.com6fd6fd1decd363e6a501eab427ed659c98e2af89</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hello,&lt;br/&gt;
I try to read into a IPX800v4 (this is a PLC for domotic application) with a WebClient fonction&lt;br/&gt;
I use as url &lt;a href="http://192.168.0.250:50543/api/xdevices.json?key=XXX&amp;amp;Get=C" rel="nofollow"&gt;http://192.168.0.250:50543/api/xdevices.json?key=XXX&amp;amp;Get=C&lt;/a&gt;&lt;br/&gt;
XXX is replace by the correct key for sure&lt;br/&gt;
The status code is 200, it should works correctly&lt;br/&gt;
But the result is '{' and this my problem&lt;br/&gt;
When I try the same url with a web browser the result is correct like &lt;br/&gt;
{&lt;br/&gt;
    "product": "IPX800_V4",&lt;br/&gt;
    "status": "Success",&lt;br/&gt;
    "C1": 16,&lt;br/&gt;
    "C2": 2,&lt;br/&gt;
    "C3": 0,&lt;br/&gt;
    "C4": 0,&lt;br/&gt;
    "C5": 0,&lt;br/&gt;
    "C6": 0,&lt;br/&gt;
    "C7": 0,&lt;br/&gt;
    "C8": 0,&lt;br/&gt;
    "C9": 0,&lt;br/&gt;
    "C10": 0,&lt;br/&gt;
    "C11": 0,&lt;br/&gt;
    "C12": 0,&lt;br/&gt;
    "C13": 0,&lt;br/&gt;
    "C14": 0,&lt;br/&gt;
    "C15": 0,&lt;br/&gt;
    "C16": 0&lt;br/&gt;
}&lt;/p&gt;
&lt;p&gt;When i replace the url by a web site like google for exemple it works&lt;/p&gt;
&lt;p&gt;Can you help me please ?&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>