1.0.3 • Published 2 years ago

btlnk-short-url v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

BTLNK URL Shortener

BTLNK is the shortest link shortener service with free, fast, and reliable URL shortening. It allows you to track, brand, and share your links.

Register and Add Your Domains to the Whitelist

To obtain a custom API key, sign up at btlnk.com and add your domains to the whitelist.

API Usage

Establish Connection with the Service

const key = "test-api-key";
const api = createBtlnkService({ apiKey: key });
ParameterTypeDescription
apiKeystringRequired. Your API key.
isSSLbooleanIf you are experiencing an SSL error, you need to set this to false.

Create a New Link

await api
  .newLink({ url: "https://example.com" })
  .then((res) => res)
  .catch((err) => err);
ParameterTypeDescription
urlstringRequired. URL to shorten

Get Registered Links

await api
  .fetchLinks({ page: 1 })
  .then((res) => res)
  .catch((err) => err);
ParameterTypeDescription
pagenumberRequired. Page number of the links

Get Link Report

await api
  .fetchLinkReport({ id: 1, page: 1 })
  .then((res) => res)
  .catch((err) => err);
ParameterTypeDescription
idnumberRequired. Link ID
pagenumberRequired. Page number of the link

LICENCE

MIT

Authors and Acknowledgments