v2026.5.3
All Bundles
Bundle Shared networking types used across all HTTP libraries: Url (parsing and construction), Response (status code, headers, body), Cookie, and WebDownloader for streaming downloads. Compile with -lib net.

Response

HTTP response for methods such as GET, POST and PUT

Operations

GetCode #

Gets the response code

method : public : GetCode() ~ Int

Return

TypeDescription
Intresponse code

GetContent #

Gets response content

method : public : GetContent() ~ Byte[]

Return

TypeDescription
Byteresponse content

Example

response := Web.HTTP.HttpsClient->QuickGet(Web.HTTP.Url->New("https://httpbin.org/get"));
if(response <> Nil) {
  bytes := response->GetContent();
  String->New(bytes)->PrintLine();  # raw response body
};

GetType #

Gets content type

method : public : GetType() ~ String

Return

TypeDescription
Stringcontent type

Example

url := Web.HTTP.Url->New("https://httpbin.org/get");
response := Web.HTTP.HttpsClient->QuickGet(url);
if(response <> Nil) {
  response->GetType()->PrintLine();     # application/json
  response->GetCode()->PrintLine();     # 200
};

ToString #

Get the string representation

method : public : ToString() ~ String

Return

TypeDescription
Stringstring representation

Example

response := Web.HTTP.HttpsClient->QuickGet(Web.HTTP.Url->New("https://httpbin.org/get"));
if(response <> Nil) {
  response->ToString()->PrintLine();  # code=200, type=application/json, content_length=...
};