Migrating Links
Use the ClickSpot CLI to import links from other URL shorteners. The CLI fetches your links using your provider's API key and creates them in ClickSpot.
Supported Providers
| Provider | Where to Get API Key |
|---|---|
| Bitly | Settings → Developer settings → API |
| Rebrandly | Account → API → API Keys |
| Short.io | Integrations & API → API Key |
Before You Start
- Install the ClickSpot CLI
- Authenticate with your ClickSpot account
- Get your API key from your current URL shortener (see table above)
Import from Bitly
Import All Links
clickspot migrate bitly --api-key="YOUR_BITLY_API_KEY"Import from a Specific Group
If you have multiple Bitly groups, you can import from just one:
clickspot migrate bitly --api-key="YOUR_BITLY_API_KEY" --group="BITLY_GROUP_GUID"Preview Before Importing
Use the --dry-run flag to see what would be imported without making any changes:
clickspot migrate bitly --api-key="YOUR_BITLY_API_KEY" --dry-runImport from Rebrandly
Import All Links
clickspot migrate rebrandly --api-key="YOUR_REBRANDLY_API_KEY"Import from a Specific Workspace
clickspot migrate rebrandly --api-key="YOUR_REBRANDLY_API_KEY" --rebrandly-workspace="WORKSPACE_ID"Preview Before Importing
clickspot migrate rebrandly --api-key="YOUR_REBRANDLY_API_KEY" --dry-runImport from Short.io
Import All Links
clickspot migrate shortio --api-key="YOUR_SHORTIO_API_KEY"Import from a Specific Domain
clickspot migrate shortio --api-key="YOUR_SHORTIO_API_KEY" --domain="DOMAIN_ID"Preview Before Importing
clickspot migrate shortio --api-key="YOUR_SHORTIO_API_KEY" --dry-runUsing Environment Variables
Instead of passing API keys as command arguments, you can set them as environment variables:
export BITLY_API_KEY="your-bitly-key"
export REBRANDLY_API_KEY="your-rebrandly-key"
export SHORTIO_API_KEY="your-shortio-key"
clickspot migrate bitly --dry-runThis is useful for scripting or when you don't want the API key to appear in your shell history.
What Gets Imported
The CLI imports the following data for each link:
- Short code (the unique part of your short URL)
- Destination URL
- Title (if available)
- Tags (if available)
- Creation date
Troubleshooting
Rate Limit Errors
The CLI automatically handles rate limits by backing off and retrying. If you continue to see errors, wait a few minutes and try again.
Authentication Errors
Double-check that your provider API key is correct and has the necessary permissions to read links.
Missing Links
Some providers have different workspaces or groups. Try running without the workspace/group filter to import all links, or check that you're using the correct workspace/group ID.