Update a link
Updates a link. Only the fields you send are changed. Send password: null to remove a password; send expiresAt: null to remove expiration. Destination changes on u2l.ai links re-run the trust check - untrusted destinations are rejected (move the link to another domain 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.
Path Parameters
The link's domain (e.g. u.gy or u2l.ai).
The link's slug (the part after the domain).
Body
New destination URL.
New password; send null to remove (Advanced plan or above).
New expiration; send null to remove.
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.
URL cloaking (Advanced+): serve the destination inside a frame so visitors keep seeing the short URL.
Open the destination in its native mobile app (YouTube, Instagram, etc.) when the visitor has it installed.
Traffic routing rules (Advanced+). Matched visitors are redirected to the rule URL instead of the base destination; rules override the A/B pick.
Uppercase ISO 3166-1 alpha-2 country code (or default) mapped to a destination URL. Max 20 rules.
Continent code (AF, AN, AS, EU, NA, OC, SA) mapped to a URL. A country rule beats a continent rule.
Device type mapped to a destination URL. Keys: ios, android, mobile, desktop. Specific OS beats the generic mobile bucket.
Lowercase "region|cc" key using the region name (e.g. "karnataka|in") or the ISO 3166-2 code (e.g. "ka|in") mapped to a URL. Beats country rules. Max 20 rules.
Lowercase "city|cc" key (e.g. "bengaluru|in") mapped to a URL. Most specific; IP city detection is best-effort. Max 20 rules.
Expire the link after this many human clicks (Growth+). Enforcement is eventual: the link stops within a few minutes of the limit; bot traffic never counts.
Where visitors are redirected (302) once the link has expired by date or click limit. Unset shows the standard expired page.
Before this time the link serves a not-active-yet page. Must be before expiresAt when both are set.
N-way weighted rotation (Advanced+). Visitors are split randomly across 2-10 target URLs by integer weights summing to 100. Supersedes the legacy abTest fields when set; analytics reports variants as A, B, C... by target order.
Retargeting pixels (Advanced+). Fired from a brief redirect page for human visitors only.
One of: meta, tiktok, gtm, google_ads, linkedin.
Vendor pixel/container/tag ID, e.g. a Meta Pixel ID or GTM-XXXX.
App deep links (Advanced+): 'store' sends mobile visitors without the domain's app installed to the App Store / Play Store (with the link carried in the Play install referrer). Requires a mobile app configured on the link's domain in the dashboard; visitors with the app installed open it directly via the domain's universal/app links. One of: store.
Response 200
Link ID (UUID).
The part after the domain.
The link's domain.
Where the link redirects to.
Optional title.
Expiration time, if set.
true = 301 redirect, false = 302.
SL = short link, QR = QR code, PG = link-in-bio page. One of: SL, QR, PG.
Total clicks.
Custom social preview title.
A/B variant destination.
Traffic percentage to destination A.
QR styling options (QR links only).
Open in the phone's default browser when tapped inside in-app browsers (Android).
URL cloaking (Advanced+): serve the destination inside a frame so visitors keep seeing the short URL.
Open the destination in its native mobile app (YouTube, Instagram, etc.) when the visitor has it installed.
Traffic routing rules (Advanced+). Matched visitors are redirected to the rule URL instead of the base destination; rules override the A/B pick.
Uppercase ISO 3166-1 alpha-2 country code (or default) mapped to a destination URL. Max 20 rules.
Continent code (AF, AN, AS, EU, NA, OC, SA) mapped to a URL. A country rule beats a continent rule.
Device type mapped to a destination URL. Keys: ios, android, mobile, desktop. Specific OS beats the generic mobile bucket.
Lowercase "region|cc" key using the region name (e.g. "karnataka|in") or the ISO 3166-2 code (e.g. "ka|in") mapped to a URL. Beats country rules. Max 20 rules.
Lowercase "city|cc" key (e.g. "bengaluru|in") mapped to a URL. Most specific; IP city detection is best-effort. Max 20 rules.
Expire the link after this many human clicks (Growth+). Enforcement is eventual: the link stops within a few minutes of the limit; bot traffic never counts.
Where visitors are redirected (302) once the link has expired by date or click limit. Unset shows the standard expired page.
Before this time the link serves a not-active-yet page. Must be before expiresAt when both are set.
Human clicks counted toward maxClicks. Present only when maxClicks is set.
N-way weighted rotation (Advanced+). Visitors are split randomly across 2-10 target URLs by integer weights summing to 100. Supersedes the legacy abTest fields when set; analytics reports variants as A, B, C... by target order.
Retargeting pixels (Advanced+). Fired from a brief redirect page for human visitors only.
One of: meta, tiktok, gtm, google_ads, linkedin.
Vendor pixel/container/tag ID, e.g. a Meta Pixel ID or GTM-XXXX.
App deep links (Advanced+): 'store' sends mobile visitors without the domain's app installed to the App Store / Play Store (with the link carried in the Play install referrer). Requires a mobile app configured on the link's domain in the dashboard; visitors with the app installed open it directly via the domain's universal/app links. One of: store.
Errors
See Rate Limits & Errors for the error envelope and per-plan limits.