--- title: Hep.gg URL Shortener (LLM) description: Create shortlinks under your own serve host. The same /:id redirector that serves uploads dispatches shortlink hits. --- # Hep.gg URL Shortener Create shortlinks under your own subdomain, a custom domain, or the default serve host. The same /:ID redirector that serves uploads dispatches shortlink hits. Base URL: https://hep.gg Two ways to create a shortlink: - Programmatic: POST /upload with a `link` field and no file body, authed with your ShareX bearer token (see the Uploader reference). Returns { ID, url }. - Dashboard: POST /api/v1/shorten (cookie session via /signin). This is the only path that accepts a custom alias. ## Programmatic create (POST /upload) Auth: Authorization: Bearer Body: form-urlencoded or multipart with a single field: link string required. The destination URL. Response: { "ID": "", "url": "https:///" } A non-URL `link` value is stored as a .txt snippet instead (subject to your allowed MIME types). Visiting the returned URL issues a 302 to the target. The public /upload route does NOT accept an `alias` field; programmatic callers get the auto-generated content ID. Use the dashboard endpoint for vanity slugs. ## Dashboard create (POST /api/v1/shorten) Cookie auth. Body (JSON): url string required. Destination URL. alias string optional. Custom slug; alphanumeric + dash/underscore/dot. Rules: - alias is capped at 32 chars; a longer alias returns 403. - reserved slugs return 400. - you cannot shorten to a Hep.gg-managed host (the apex, any *.hep.gg, or a registered serve domain); those targets return 400. - 120 requests/min. Response: { "ID": "", "url": "https:///" } ## Manage your shortlinks (dashboard, cookie auth) GET /api/v1/uploads?type=links (list shortlinks owned by you) PATCH /api/v1/uploads/:contentID { alias?, favourite?, link? } (link = edit the destination URL) DELETE /api/v1/uploads/:contentID