Links

Update a link

Partial update. Only recognised fields are written. Returns the updated Link and sends a link.update webhook to the calling user's webhooks.

Auth: API key (Bearer flyn_sk_live_...), an MCP OAuth access token (Bearer flyn_mcp_at_...), or the signed-in dashboard session cookie when neither is sent.

Plan: on Free, a custom domain or a Pro field set to a real value returns 403 UPGRADE_REQUIRED; there is no monthly cap on edits. Pro, Lifetime or Team (a member of a paying owner's workspace has the effective plan team) have no gate. Team roles: viewer gets 403; a member may edit only links they created; owner and admin may edit any link in the workspace.

Rate limit: 10 requests per 60 s per client IP, fixed window, in memory per server instance, checked before authentication.

An invalid JSON body returns 500.

patch/api/links/{id}

Request

  • Base URL: https://www.flyn.to
  • URL: https://www.flyn.to/api/links/{id}
  • Auth: HTTP bearer

Request body

urlstring

New destination. Same rules as create, except the host does not need a dot. On a rotating link the first rotation destination is re-pointed too. null or an empty string returns 400.

slugstring

New back-half; not reserved; 409 on clash. null or an empty string returns 400.

domainstring

Moves the link to another short domain. The current Flyn short domain, or the legacy value www.flyn.to, moves it back to the default. Any other value must exactly match (case-sensitive) a custom domain owned by the workspace (the team in a team workspace, otherwise your own), else 403 "Domain not found or not owned by you"; that includes flyn.to and other customers' domains. A pending or paused domain is accepted, but the link does not serve until the domain is active. Sending the link's current domain changes nothing. Pro for a custom domain. null or an empty string returns 400.

titlestring
status'active' | 'expired' | 'archived'

Any other value returns 400, including an empty string or null.

tagsstring[]

Pro when non-empty. Replaces the array.

passwordstring nullable

Pro when non-empty. A non-empty string is hashed and set; null or "" removes the password.

expiresAtstring date-time nullable

Must parse as a date; null clears it.

folderIdstring uuid nullable

Folder in the workspace (404 otherwise); null clears it.

ogTitlestring
ogDescriptionstring
ogImagestring

http or https, public IP.

cloakingboolean

Pro when true.

noIndexboolean

Pro when true. Accepted and stored for compatibility. It has no effect on how the link is served: every short link is already served with a noindex robots header on every plan, whether or not this is set.

notesstring
abUrlBstring nullable

Pro when non-empty. Returns 409 ROTATION_ACTIVE when the link has a stored rotation other than the legacy two-destination A/B pair (ids A and B) and rotation is not sent in the same request; update rotation instead. Otherwise the create rules apply, including 400 "Cannot shorten Flyn URLs" for a Flyn host.

abSplitnumber nullable

Pro when non-zero. Clamped to 0..100; same 409 rule as abUrlB.

deepLinkboolean

Pro when true. Send a JSON boolean; null returns 400.

pixelIdsstring[]

Pro when non-empty. Ids outside the workspace are dropped; [] clears; null returns 400. If any id is not a valid UUID the list is set to [].

forwardParamsboolean

null returns 400.

clickLimitinteger nullable

Pro when set. null or "" clears it.

fallbackUrlstring nullable

Pro when set. null or "" clears it; otherwise the same rules as create.

conversionTrackingboolean

Pro when true. Stored as value === true, so any other value (including the string "true") turns tracking off.

Response

The updated link.

idstring uuid required

Link id.

slugstring required

Back-half of the short URL.

urlstring required

Destination URL.

shortUrlstring uri required

Full short URL, https://<domain>/<slug>.

domainstring required

Short domain the link lives on. New links default to the current Flyn short domain.

titlestring nullable required

Display title.

clicksinteger required

Human clicks (bots and scanners excluded). This is the headline number.

botClicksinteger required

Clicks filtered out as bots or scanners.

qrScansinteger required

Clicks that arrived from a Flyn QR code; a subset of clicks.

totalClicksinteger required

clicks + botClicks.

status'active' | 'expired' | 'archived' required

Stored status. A link past expiresAt keeps active here; the redirect checks the expiry itself.

tagsstring[] required
createdAtstring date-time required
expiresAtstring nullable required

Expiry as stored (ISO 8601), or null.

folderIdstring uuid nullable required
passwordboolean required

True when the link is password protected. The password itself is never returned.

ogTitlestring nullable required
ogDescriptionstring nullable required
ogImagestring nullable required
cloakingboolean required
noIndexboolean required

Stored value of the legacy per-link no-index flag. It has no effect on how the link is served: every short link is already served with a noindex robots header on every plan, whether or not this is set.

notesstring nullable required

Private notes.

abUrlBstring nullable required

Legacy two-way A/B view of rotation, kept for older integrations.

abSplitnumber nullable required

Legacy A/B split: percent kept on the primary url.

deepLinkboolean required

Native-app handoff mode on mobile.

pixelIdsstring[] required

Retargeting pixels fired on click.

forwardParamsboolean required

Query-string passthrough to the destination.

clickLimitinteger nullable required

Maximum human clicks. Once reached, visitors go to fallbackUrl, or to the expired-link page when no http(s) fallbackUrl is set.

fallbackUrlstring nullable required

Destination after the click limit is reached.

conversionTrackingboolean required

When true, each human click gets a flyn_id click id for conversion pings.

conversionsinteger required

Recorded conversions, net of refunds (never below 0).

conversionValueCentsinteger required

Summed conversion value in minor units.

conversionCurrencystring nullable required

Currency of the summed value.

Changes

No recorded changes to this operation across all 1 revision of this API.