-
Notifications
You must be signed in to change notification settings - Fork 4
Making HTTP Requests
Alexander edited this page Apr 16, 2019
·
1 revision
Examples only Request types supported:
- GET
- POST
GET
var contentResponse = http.get("https://example.org/"); //Returns the content/body as a string
POST
//Post a JSON Object
var contentResponse1 = http.post("https://example.org/", {"ID": 1}); //Returns the content/body as a string
var contentResponse2 = http.post("https://example.org/", "hello"); //Returns the content/body as a string
It will automaticly change the content-type to plain or Json