THIS WEEK Top 9 Free Instagram Apps to Enhance Your Influence Read this week's article →

Quickstart: your first API request in five minutes

Everything the site does, the REST API does. If you can send JSON over HTTPS, you can automate links.

Request an API key
API Quickstart & Documentation illustration

Your first request

curl -X POST "https://goto.now/rest/v3/short-urls" \ -H "X-Api-Key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{"longUrl": "https://example.com/very/long/path", "findIfExists": true}'

Planning serious volume? Enterprise plans add dedicated keys, raised limits and support - And the API product page covers what's possible end to end.

What this means in practice

Create links

POST /rest/v3/short-urls with a longUrl (plus optional customSlug, title, tags) returns the short URL as JSON.

QR codes

GET /{shortCode}/qr-code?size=600&format=svg returns a ready-to-embed image - Parameters control size, format and colors.

Visits & analytics

GET /rest/v3/short-urls/{shortCode}/visits streams paginated click records with referrer, user agent and location.

Tags & organization

Tag links by campaign or system and filter listings by tag for clean programmatic housekeeping.

Full reference

This page plus the API help guides cover every endpoint, parameter and error format you'll meet in practice.

Get a key

API keys are provisioned per account. Contact us with your use case and volume to get started.

The endpoints you'll actually use

Endpoint Method What it does
/rest/v3/short-urls POST Create a link (longUrl, optional customSlug, title, tags, findIfExists)
/rest/v3/short-urls/{code} GET Fetch a link's details incl. visit summary
/rest/v3/short-urls/{code} PATCH Re-point the destination - The feature everything else is built on
/rest/v3/short-urls/{code}/visits GET Paginated click records: time, referrer, UA, coarse geo
/{code}/qr-code?size=600&format=svg GET The link's QR image (no auth needed)

Auth is one header - X-Api-Key: YOUR_KEY - And errors come back as RFC-7807 problem JSON with honest status codes.

Idempotency, the free lunch

Pass findIfExists: true on creation and identical long URLs return the same short link instead of duplicates. That single flag makes retries safe, batch imports boring, and "did my job run twice?" a question you never ask. For per-entity links (orders, tickets), use customSlug with your own ID instead.

From zero to production

  1. Request a key with a sentence about volume.
  2. Copy the cURL above into your stack; the response's shortUrl is ready to send.
  3. Pull /visits nightly into your warehouse and join clicks to outcomes.

The API help guides document every parameter we didn't repeat here, and the help center has task-level guides for creating links, QR codes and exports.

Creation parameters, in full

Parameter Type What it does
longUrl string, required The destination to shorten
customSlug string Your branded back-half (3–60 chars)
title string Human label shown in listings
tags array Organize by campaign, system or client
findIfExists bool Return the existing link for a repeated longUrl
crawlable bool Whether robots may follow the redirect
forwardQuery bool Pass query strings through to the destination (default on)

forwardQuery deserves a highlight: append ?utm_source=x to a short link at share time and it arrives at the destination intact - One link can serve many tagged channels.

Error handling that won't surprise you

Errors are RFC-7807 problem documents: a JSON body with type, title, detail and status. The ones you'll meet: 400 invalid payload or taken slug (the detail says which), 401 missing/invalid API key, 404 unknown short code, 429 over your key's rate limit - Back off and retry with jitter. Log the detail string; it's written for humans.

Working with visits at scale

/visits is paginated (page, itemsPerPage up to a few thousand) and supports date windows via startDate/endDate (ISO-8601). The pattern that works: nightly job pulls yesterday's window per tag, appends to your warehouse, and your BI joins clicks to orders by the slug you embedded with customSlug. Totals without the detail? The short-url GET returns a visitsSummary - Total, human and bot counts - In one call.

Rate limits and being a good citizen

Keys ship with limits matched to your stated volume - Ask for what you actually need and raising it later is one email. Batch creations instead of hot loops, cache QR images (they're immutable per style), and use findIfExists so retries don't mint duplicates. Redirect serving is never limited - Your audience is untouched by any of this.

FAQs

Which API version does GoTo.now run?
REST API v3 - Stable, versioned in the path, and backwards-compatible within the major version.
Is there a sandbox?
Create a free account and request a low-volume key - It behaves identically to production keys.