Documentation
Get defaults for new links
GET
/v1/link_defaultsLinksWhat a link made in the account starts with when the request leaves a field out, through every door: the dashboard, the API, MCP and imports.
Example request
Terminal
curl "https://snip.link/v1/link_defaults" \
-H "Authorization: Bearer $SNIP_KEY"Example response
Response
{
"defaults": {
"domain": "go.example.com",
"domain_ready": true,
"redirect": 302,
"expires_in_days": null,
"forward_query": true,
"track": true,
"snapshots": "public"
}
}Response fields
| Field | Type | Description |
|---|---|---|
defaults | LinkDefaults | |
defaults.domain | string, null | The account's own domain new links go on; null for snip.link. |
defaults.domain_ready | boolean, null | False while that domain cannot take new links (not live, removed, or the plan has none): new links go on snip.link meanwhile. Null when no domain is set. |
defaults.redirect | 301 | 302 | |
defaults.expires_in_days | integer, null | New links expire this many days after they are made; null for never. |
defaults.forward_query | boolean | Pass the short link's query string on to the destination. |
defaults.track | boolean | False: new links only count visits, without recording each one. |
defaults.snapshots | public | private | off | Whether new links save a copy of their page, and who may open it. |
Errors
| Status | Meaning |
|---|---|
| 401 | The API key is missing, malformed or revoked. |
| 429 | Either the key exceeded its requests-per-second limit (honor Retry-After), or a daily or plan quota is used up (details.reason). |