Z.getJSON(...)

Z.getJSON(url: string, success: (data?: any) => void, error?: (xhr?: any) => void);

Retrieves a JSON document from a URL.

For more information please see our Fetching JSON page.

We highly recommend using HTTPS for all calls using this function. In addition to the security benefits for your users, Apple are deprecating HTTP-only network connections from apps.

Parameters

Parameter Type Description
url string The address of the JSON to get.
success function A function that will be called if the JSON is successfully retrieved. The function can be passed the JavaScript object that results from parsing the response.
error function A function that will be called if an error occurred in retrieving the document, or in parsing it.

Returns

XMLHttpRequest object.

zapcode branded_zapcode i