DocsInteractive API Docs/api/v1/link-shorten/create-link
post

/api/v1/link-shorten/create-link

Creates a shortened URL. Optionally accepts a custom alias and expiration date. Returns both the original and the shortened URL.

Endpoint Info
Base URLapi.bizkithub.com
AuthBearer Token
Methods1
Authentication Required

This endpoint requires a valid API key passed as a query parameter or Bearer token.

Get your API key

Parameters

3 body parameters

urlstringrequired

The original URL to shorten.

customAliasstring

Custom short URL alias. If omitted, a random alias is generated.

expiresAtstring

Expiration date in ISO 8601 format. Link becomes invalid after this date.

Example Request

JavaScript fetch

const response = await fetch("https://api.bizkithub.com/api/v1/link-shorten/create-link", {
  method: "POST",
  headers: {
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "url": "https://example.com/very/long/path",
    "customAlias": "my-link",
    "expiresAt": "2026-12-31T23:59:59Z"
  })
});

const data = await response.json();
console.log(data);
post

Example Response

200Success
{
  "originalUrl": "example_originalUrl",
  "shortUrl": "https://xhp.cz/my-link"
}

cURL

Command line example

curl -X POST "https://api.bizkithub.com/api/v1/link-shorten/create-link" \
  -H "Content-Type: application/json" \
  -d '{
  "url": "https://example.com/very/long/path",
  "customAlias": "my-link",
  "expiresAt": "2026-12-31T23:59:59Z"
}'

Need an API key?

All BizKitHub API endpoints require authentication via API key.

Get API Key