Zipline includes a built-in URL shortener that lets you create short, memorable links to any destination. It supports vanity URLs, password protection, view tracking, and automatic deletion.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/diced/zipline/llms.txt
Use this file to discover all available pages before exploring further.
How URL shortening works
When you shorten a URL:- Request - You provide a destination URL
- Code generation - A random code is generated (configurable length)
- Vanity support - Optionally use a custom vanity slug
- Storage - The mapping is saved to the database
- URL return - You receive a short link like
https://your-zipline.com/go/abc123 - Redirection - Visitors are redirected to the destination
Creating short URLs
Via the dashboard
- Navigate to the URLs section
- Click “Shorten URL”
- Enter the destination URL
- Optionally configure:
- Custom vanity URL
- Password protection
- Maximum views
- Enable/disable state
Via the API
Create a short URL with the API:URL structure
Each shortened URL in the database contains:prisma/schema.prisma:364-381.
Vanity URLs
Create memorable custom URLs instead of random codes:https://your-zipline.com/go/zipline-repo
Vanity validation happens in src/server/routes/api/user/urls/index.ts:78-86.
Configuration
URL route
Configure the base path for shortened URLs:/go→https://zipline.com/go/abc123/→https://zipline.com/abc123/s→https://zipline.com/s/abc123
Domain selection
Return URLs with a specific domain:https://short.domain.com/go/abc123
You can provide multiple domains separated by commas, and Zipline will randomly select one.
Password protection
Protect URLs with a password:Updating passwords
Change or remove a password:src/server/routes/api/user/urls/[id]/password.ts for implementation.
View tracking and limits
View counter
Every access to a shortened URL increments the view counter:Maximum views
Auto-delete URLs after a certain number of views:- If
featuresDeleteOnMaxViewsis enabled, the URL is deleted - Otherwise, the URL returns a 404
src/server/routes/urls.dy.ts:32-48.
Managing URLs
Enable/disable URLs
Temporarily disable a URL without deleting it:Updating URLs
Update URL properties:You cannot change the code or vanity after creation. Create a new URL if you need a different slug.
Deleting URLs
Searching URLs
Search your shortened URLs by destination, vanity, or code:destination- Search destination URLsvanity- Search vanity slugscode- Search generated codes
src/server/routes/api/user/urls/index.ts:145-184.
URL quotas
Users can have a maximum URL limit:src/server/routes/api/user/urls/index.ts:53-61.
Redirection behavior
When a visitor accesses a shortened URL:- Lookup - System finds URL by code or vanity
- Validation - Checks if enabled and under max views
- Password check - Redirects to password view if protected
- View increment - Increments the view counter
- Redirect - 302 redirect to destination
src/server/routes/urls.dy.ts.
Webhooks
Zipline can trigger webhooks when URLs are shortened:src/lib/webhooks/onShorten for webhook implementation.
Text-only responses
Get just the URL without JSON formatting:FAQs
What happens if two users try to use the same vanity?
What happens if two users try to use the same vanity?
The first user to create the vanity URL gets it. The second request will fail with a 400 error indicating the vanity is already taken.
Can I change a URL's destination after creation?
Can I change a URL's destination after creation?
Yes, you can update the destination using a PATCH request to
/api/user/urls/:id. The code/vanity remains the same.How are random codes generated?
How are random codes generated?
Codes are generated using
randomCharacters() with the configured length (default 6). The system checks for collisions and regenerates if needed.Do disabled URLs count toward quotas?
Do disabled URLs count toward quotas?
Yes, disabled URLs still count toward your quota. Delete the URL if you want to free up quota space.
Can I see who accessed my shortened URLs?
Can I see who accessed my shortened URLs?
Currently, Zipline only tracks the view count, not individual viewer information. View tracking happens in the
urls.dy.ts route.