http.get(), http.post() and http.patch(). They are on for every brand. Requests to private or internal addresses are blocked.
To send an API key, save it as a secret and put env.secret.NAME in a header. Never paste keys into the script itself.
http.get(url, headers?)
Make an HTTP GET request.
http.post(url, body, headers?)
Make an HTTP POST request.
http.patch(url, body, headers?)
Same as http.post, with the PATCH method.
Response object
Everyhttp.* call returns an object:
Limits
Security
- Private and internal addresses are blocked: localhost, 10.x.x.x, 172.16-31.x.x, 192.168.x.x, 169.254.x.x and cloud metadata endpoints, including hostnames that resolve to them.
- Only
http://andhttps://URLs are allowed. Redirects are not followed. - Secrets are sent only over https, in headers, to their allowed hosts.