diff options
Diffstat (limited to 'src/Hastebin.js')
| -rw-r--r-- | src/Hastebin.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Hastebin.js b/src/Hastebin.js new file mode 100644 index 0000000..1d7bae0 --- /dev/null +++ b/src/Hastebin.js @@ -0,0 +1,6 @@ +const superagent = require('superagent'); + +module.exports = async function hastebin(text) { + let res = await superagent.post('https://hasteb.in/documents').send(text); + return JSON.parse(res.text).key; +};
\ No newline at end of file |
