CLI (Homebrew + Chocolatey)

Install the T.LY command-line tool with Homebrew or Chocolatey and create short links from your terminal.

The T.LY CLI gives you a fast way to create short links from your terminal, which is handy for scripts, local automation, and quick one-off link creation. If you want language-specific packages instead, see API basics & SDKs.

Install with Homebrew

The CLI is distributed through the tlyshortener/tly Homebrew tap.

brew tap tlyshortener/tly
brew install tly

Install with Chocolatey

On Windows, install the CLI from the T.LY CLI Chocolatey package.

choco install tly-cli

Create your API token

  1. Log in to your T.LY account.
  2. Create a token in Settings > API.
  3. Add it to your shell before using the CLI.

macOS, Linux, or Git Bash:

export TLY_API_TOKEN="your-api-token"

PowerShell:

$env:TLY_API_TOKEN="your-api-token"
API settings showing the Create API Token form used for T.LY integrations and CLI access.
Create a token in Settings > API, then set it as TLY_API_TOKEN for the CLI.

Create your first short link

tly create https://example.com

A few common examples:

tly create https://example.com --short-id promo
tly create https://example.com --description "Spring campaign"
tly create https://example.com --domain https://go.example.com/
tly create https://example.com --json

Helpful notes

  • Use tly --help or tly --version to confirm the CLI is installed correctly.
  • You can pass --token directly, but using TLY_API_TOKEN is usually better for local scripts.
  • Chocolatey package details are available at community.chocolatey.org/packages/tly-cli.
  • Need more than simple CLI commands? Use the API docs or the official SDKs.

Need more help?

If you still have questions, contact [email protected] or use the contact form. For abuse or suspicious links, use Report Abuse. For feature requests, email [email protected].