Sample code for 30+ languages & platforms
C#

Example: Http.GetLastJsonData method

Demonstrates the GetLastJsonData method.

Chilkat C# Downloads

C#
bool success = false;

Chilkat.Http http = new Chilkat.Http();
Chilkat.HttpResponse resp = new Chilkat.HttpResponse();

//  Only allow TLS 1.2 or better.
http.SslProtocol = "TLS 1.2 or higher";

success = http.HttpNoBody("GET","https://google.com/",resp);
if (success == false) {
    Debug.WriteLine(http.LastErrorText);
    return;
}

Chilkat.JsonObject json = new Chilkat.JsonObject();
json.EmitCompact = false;

http.GetLastJsonData(json);
Debug.WriteLine(json.Emit());

//  Output as of Chilkat v11.1.0
//  Additional information may be added as requested or needed in future versions of Chilkat.

//  {
//    "tls": {
//      "params": {
//        "sniHostname": "www.google.com",
//        "allowConnectionOnlyIfServerChooses": "TLS 1.2 or higher"
//      },
//      "negotiatedTlsVersion": "TLS 1.3"
//    }
//  }