RESTAPIResponse - setHeaders(Object headers)

Set the headers for the web service response.

Table 1. Parameters
Name Type Description
headers Object A JavaScript object listing each header and the value to assign that header.
Table 2. Returns
Type Description
void

var headers = {};
headers.X-Total-Count=100;
headers.Location=‘https://instance.service-now.com/<endpoint_to_resource>';
response.setHeaders(headers);