Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
graphical tool for display the JSON structure
#3
Thanks for your help.
I used the following method to get the value I needed, but it might fail in some cases, such as when the order of arrays in the JSON string changes.
Displaying and processing JSON objects, arrays, and strings is something that almost all programming languages need to handle. It seems necessary to provide a tool to address this issue.
 
Code:
Copy      Help
        var j = internet.http.Post(uri, internet.jsonContent(body), [$"Authorization: Bearer {token}"]).Json();
        var messagesArray = (JsonArray)j["messages"];
        var firstMessageObject = (JsonObject)messagesArray[3];
        string r = (string)firstMessageObject["content"];
        print.it(r);


Messages In This Thread
RE: graphical tool for display the JSON structure - by Davider - 05-28-2024, 06:20 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)