Search…
Resources
Related Links
parseJSON
To convert a JSON string to a JSON object
This function converts a string to a JSON object.
The string needs to be written as a valid JSON object. Otherwise, the function will return unuseful stuff. Not good.
🤓
This can be quite handy if you need to modify a JSON object and pass it on in the http() function.

Syntax

parseJSON(string)

Return

JSON

Examples

parseJSON(jsonString) To convert a JSON string to a JSON object.
Please remember to use double quotation marks to escape the string.
parseJSON("{
""test"": 123
}")
Result: {"test":123}

See also

formatJSON, which creates a JSON string of a valid JSON object.
Last modified 2mo ago
Export as PDF
Copy link