Developers

Developer API

Shorten links from your own apps, scripts and bots. The API is AdLinkFly-compatible, so tools built for those shorteners work with Vylo.

Your API token

Get my token

Log in and open Dashboard → Tools & API (or Settings) to copy your token. Keep it private: anyone with your token can create links on your account. You can generate a new one at any time, and the old one stops working straight away.

Shorten a link

Send a GET request:

https://vylo.cc/api?api=YOUR_TOKEN&url=URL[&alias=ALIAS][&format=text][&steps=1|2|3|4]

steps sets the link’s ad level — how many pages visitors go through (1–4; 4 is Max). More pages earn more per view. Leave it out to use your account’s default.

ParameterRequiredDescription
apiYesYour API token.
urlYesThe long URL to shorten, URL-encoded. Must be an http:// or https:// address.
aliasNoA custom alias: 3–30 letters, numbers, - or _. If you leave it out, a random alias is created.
formatNoSet to text to get only the short URL as plain text. Without it, the response is JSON.

Responses

On success (HTTP 200):

{"status":"success","shortenedUrl":"https://vylo.cc/Ab3x9K"}

On error, the HTTP status is 401 (invalid token), 403 (account suspended) or 400 (invalid URL, blocked destination, alias taken, and so on):

{"status":"error","message":"That alias is already taken.","shortenedUrl":""}

With format=text, a successful response body is just the short URL. On error the body is empty and the HTTP status shows what went wrong.

Quick link

Opening this address creates the short link and immediately redirects to it. It’s handy for “shorten on click” buttons and browser bookmarks:

https://vylo.cc/st?api=YOUR_TOKEN&url=URL

Limits

Up to 120 requests per minute per IP address. Above that you’ll get HTTP 429; wait a minute and try again. Links created through the API follow the same rules as links created in the dashboard.

Examples

curl

curl "https://vylo.cc/api?api=YOUR_TOKEN&url=https%3A%2F%2Fexample.com%2Fpage"

PHP

<?php $token = 'YOUR_TOKEN'; $long = urlencode('https://example.com/page'); $json = file_get_contents("https://vylo.cc/api?api={$token}&url={$long}"); $data = json_decode($json, true); if ($data && $data['status'] === 'success') { echo $data['shortenedUrl']; } else { echo 'Error: ' . ($data['message'] ?? 'request failed'); }

Python

import requests r = requests.get("https://vylo.cc/api", params={ "api": "YOUR_TOKEN", "url": "https://example.com/page", }) data = r.json() if data["status"] == "success": print(data["shortenedUrl"]) else: print("Error:", data["message"])

JavaScript

const params = new URLSearchParams({ api: 'YOUR_TOKEN', url: 'https://example.com/page' }); const res = await fetch(`https://vylo.cc/api?${params}`); const data = await res.json(); if (data.status === 'success') console.log(data.shortenedUrl); else console.error(data.message);

Telegram bots and shrinker tools

Many Telegram bots and mass-shrinker tools support “AdLinkFly-type” shorteners. To use Vylo with them, set the shortener domain to vylo.cc and paste your API token. No other setup is needed.

Prefer a form? The mass shrinker in your dashboard shortens up to 20 links at once.