BizKitHub
DokumentacjaEksplorator APILink Shorten/api/v1/link-shorten/create-link
postLink ShortenPubliczne API v1

/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.

linkShortenpostApiV1Link-shortenCreate-link

Parametry

Treść JSON

Treść żądania

application/json
urlstringWymagane

The original URL to shorten.

Przykładhttps://example.com/very/long/path
customAliasstringOpcjonalne

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

Przykładmy-link
expiresAtstringOpcjonalne

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

Przykład2026-12-31T23:59:59Z

Schemat odpowiedzi

1 udokumentowany kod statusu

200SukcesShortened link result.
originalUrlstringWymagane

The original URL that was shortened.

shortUrlstringWymagane

The generated short URL.

Przykładhttps://xhp.cz/my-link

Przykład odpowiedzi

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

Przykład żądania

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

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

Potrzebujesz klucza API?

Wszystkie publiczne endpointy BizKitHub API uwierzytelniają się kluczem API.

Uzyskaj klucz API