8 posts tagged with “json”

Safe JSON Parse

JSON.parse throws on garbage — and webhooks, Script Properties, and CacheService strings go garbage more often than we’d like. safeJsonParse…

JSON OK / ERR helpers for Web Apps

doGet / doPost handlers stay readable when every success and failure returns the same JSON shape. jsonOk / jsonErr wrap ContentService so…

Cache JSON with a TTL

Hitting the same API or expensive sheet scan every trigger run burns quota. CacheService gives you a short-lived store (max ~6 hours…

Converting JSON into a flat Array

This code snippet helps you convert an object into a flat array that you can use to import into a Google Sheet. Important Note: This snippet…

Basic REST API GET Call Using JSON

This is a basic REST API call that parses out JSON data and returns it back to you. To do a POST request using JSON data, check out the…