TypeScript SDK for Dub.co
npm install dub
The SDK constructor accepts an options object with the following properties:
The API token for the Dub.co API. You can create your token from the Dub.co dashboard.
import { Dub } from "dub"; const dub = new Dub({ token: "DUB_API_KEY", }); await dub.links.create({ url: "https://google.com", });
Was this page helpful?