Trying to parse a JSON array returned from a custom REST endpoint in a CXone Studio SNIPPET. Using GetRESTProxy with a basic auth header works fine, but the response body comes back as a string.
ASSIGN result = JSON.parse(response.body) throws a syntax error on the first element. The endpoint returns ["val1", "val2"].
Is there a built-in method to handle arrays in the SNIPPET engine, or do I need to strip brackets manually?