> DOCS_

Base: https://vershare.uk All responses JSON unless noted.

Returns a shortlink. JSON body for text/md/code, multipart for file/image.

ParamReqDescription
typeyes"text" | "markdown" | "code" | "file" | "image"
contentyes*Text body (text/md/code only)
titlenoOptional display title
languagenoFor code: "javascript", "python", etc.
fileyes*Binary file (file/image, multipart)

# Text

curl -X POST https://vershare.uk/api/shares \
  -H 'Content-Type: application/json' \
  -d '{"type":"text","content":"Hello!"}'

# Code

curl -X POST https://vershare.uk/api/shares \
  -H 'Content-Type: application/json' \
  -d '{"type":"code","content":"print(42)","language":"python"}'

# File

curl -X POST https://vershare.uk/api/shares \
  -F type=file -F file=@./doc.pdf

# Image

curl -X POST https://vershare.uk/api/shares \
  -F type=image -F file=@./pic.png

Response

{
  "id": "aBcDeFgHiJ",
  "type": "text",
  "createdAt": "2026-03-17T12:00:00Z",
  "url": "https://vershare.uk/s/aBcDeFgHiJ",
  "raw": "https://vershare.uk/api/shares/aBcDeFgHiJ/raw",
  "api": "https://vershare.uk/api/shares/aBcDeFgHiJ"
}

ERRORS

400 Bad request   404 Not found   500 Server error

Format: {"error":"message"}