Skip to main content
Whether you are using Dub’s API or not, this page is a quick way to understand how Dub works. Within Dub, all data belongs to a Workspace. Within a workspace, you have Links, Domains, Tags, and more.

Workspace

Workspaces is the defacto way of organizing your links and working with your team on Dub. You can think of a Dub workspace like a workspace on Slack or Discord – it’s a shared space where you can invite your team members to collaborate on links. When interacting with Dub’s API, you’ll also need to create a workspace API key to authenticate your requests.
string
required
The unique ID of the workspace.
string
required
The name of the workspace.
string
required
The slug of the workspace.
The logo of the workspace.
number
required
The usage of the workspace.
number
required
The usage limit of the workspace.
The links usage of the workspace.
The links limit of the workspace.
number
required
The domains limit of the workspace.
number
required
The tags limit of the workspace.
number
required
The users limit of the workspace.
string
required
The plan of the workspace.
string | null
required
The Stripe ID of the workspace.
number
required
The date and time when the billing cycle starts for the workspace.
string
required
The date and time when the workspace was created.
object[]
required
The role of the authenticated user in the workspace.
object[]
required
The domains of the workspace.
Links are the bread and butter of Dub. You can shorten any URL to a Dub link, which you can then share with your audience. Links can be created, updated, and deleted via the Dub API or the Dub dashboard.

Domains

On Dub, you can add custom domains to create branded short links for better brand recognition. You can also set a primary domain for it to be used as the default domain for new links (both via the API and the dashboard).
string
required
The unique identifier of the domain.
string
required
The domain name.
boolean
default:false
required
Whether the domain is verified.
boolean
default:false
required
Whether the domain is the primary domain for the workspace.
boolean
default:false
required
Whether the domain is archived.
string
default:"https://dub.co/help/article/what-is-dub"
required
Provide context to your teammates in the link creation modal by showing them an example of a link to be shortened.
string | null
required
The URL to redirect to when a link under this domain has expired.
string | null
required
The URL to redirect to when a link under this domain doesn’t exist.
string
required
The date the domain was created.
string
required
The date the domain was last updated.
object | null
required
The registered domain record.

Tags

Tags are a way to organize your links. You can add tags to your links to categorize them and make them easier to find. You can also filter analytics by tags to get a better understanding of how your campaigns are performing.
string
required
The unique ID of the tag.
string
required
The name of the tag.
string
required
The color of the tag.