Create a link
Creates a short link or QR code. By default the domain is chosen automatically: destinations recognized as trusted land on u2l.ai, everything else on u.gy - this never errors. Pass a specific domain to use one of your subdomains or verified custom domains instead.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your U2L API key (u2l_live_...). Create one in the dashboard under Settings > API.
Body
Destination URL. https:// is assumed if no scheme is given.
auto (default) picks the best domain for the destination. Or pass one of your domains from List domains. Defaults to "auto".
Custom slug (5-50 chars, letters/numbers/hyphens/underscores). Random when omitted.
Password-protect the link (Advanced plan or above).
Expiration time (Advanced plan or above).
true = 301 redirect, false = 302. Defaults to true.
One of: SL, QR. Defaults to "SL".
Custom social preview (Advanced plan or above).
Image URL.
A/B testing config (Advanced plan or above).
Variant B destination URL.
Traffic percentage to destination A. Defaults to 50.
QR styling (QR links only; pattern/logo customization requires Pro plan or above).
Defaults to "rounded".
Defaults to "extra-rounded".
Defaults to "dot".
Logo image URL.
Response 201
The full short URL.
One of: SL, QR.
Present when the domain differs from the one requested (trust-based placement).
Human-readable explanation of the domain choice.
Errors
See Rate Limits & Errors for the error envelope and per-plan limits.