Create a Link
Creates a new shortened link.
Endpoint: POST /api/link/create
Request Body
The request body must be a JSON object with the following properties:
url(string, required): The original URL to shorten.expiredAt(string, optional): An ISO 8601 date string for when the link should expire.
Example Request
1curl -X POST https://viso.li/api/link/create \
2-H "Authorization: Bearer sk_api_your_api_key" \
3-H "Content-Type: application/json" \
4-d '{"url": "https://mycoolwebsite.com/my-very-long-url", "expiredAt": "2025-12-31T23:59:59.000Z"}'
Success Response
A successful request will return a 201 Created status code and a JSON object containing the shortened URL.
response.json
1{
2 "url": "https://viso.li/{slug}"
3}