ouo-promise
v1.0.3
Published
Shorten links using ouo.io and earn money with promises!
Downloads
5
Maintainers
Readme
ouo-promise
Shorten links using ouo.io and earn money with promises!
Install
$ npm install --save ouo-promise
Usage
const Ouoio = require('ouo-promise');
const o = new Ouoio('YOUR_API_KEY'); // Fill in your API KEY here.
// const o = new Ouoio(); // Or leave it blank.
(async () => {
const sUrl = await o.short('https://www.google.com');
console.log(sUrl);
const urls = ['https://www.facebook.com', 'https://github.com'];
const sUrls = await o.shortMany(urls);
console.log(sUrls);
})();
APIs
.short(url)
Shorten a URL with promise.
.shortMany(arr)
Shorten an array of URL with promise.
License
MIT