Created
April 20, 2019 20:28
-
-
Save yoav-lavi/810d96541aa2bea530749faa197c7467 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Variables used by Scriptable. | |
// These must be at the very top of the file. Do not edit. | |
// icon-color: green; icon-glyph: file-code; | |
module.exports = async ({ url, headers = {} }) => { | |
const request = new Request(url); | |
request.method = methods.get; | |
request.headers = { | |
...headers | |
}; | |
return await request.loadString(); | |
}; | |
const methods = { | |
get: "GET" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment