Convert API

Every conversion behind the free /tools/convert pages is also reachable directly over HTTP — one endpoint per format pair, matching the pages one for one. A call here and the equivalent web upload always produce byte-identical output, since both go through the same underlying App\Services\Tools\SubtitleConverter.

Base URL and authentication

https://www.aisubtitlestudio.com/api/v1/convert

The API is public and unauthenticated for now — no API key, no account, no billing. It's throttled to 60 requests per minute per IP address. This is the same posture as the tools API: expect keyed/metered access later, with the endpoint shapes below staying stable when that happens.

A plain GET on the base URL above returns a JSON index of every conversion endpoint.

Making a request

Every endpoint is POST /api/v1/convert/{slug} with a multipart/form-data body, where {slug} is one of the conversions listed below (e.g. ass-to-srt). All of them take:

fileRequired. The subtitle file to convert, in the source format that endpoint expects. Up to 5 MB.

A successful call returns the converted file as the raw response body, with Content-Type and Content-Disposition: attachment set for the target format. Pipe the response straight to a file.

Endpoints

POST /ass-to-srtASS/SSA → SRT. Accepts .ass/.ssa.
POST /vtt-to-srtWebVTT → SRT. Accepts .vtt/.webvtt.
POST /microdvd-to-srtMicroDVD (frame-based) → SRT. Accepts .sub. Takes an optional fps parameter (numeric, 1–120, default 23.976) — ignored if the file has its own frame-rate hint cue.
POST /sami-to-srtSAMI → SRT. Accepts .smi/.sami.
POST /mpl2-to-srtMPL2 → SRT. Accepts .mpl2/.txt.
POST /sbv-to-srtSBV (YouTube captions) → SRT. Accepts .sbv.
POST /srt-to-vttSRT → WebVTT. Accepts .srt.
POST /ass-to-vttASS/SSA → WebVTT. Accepts .ass/.ssa.
POST /srt-to-txtSRT, WebVTT or ASS/SSA → plain text (timestamps stripped). Accepts .srt/.vtt/.webvtt/.ass/.ssa.
curl -X POST https://www.aisubtitlestudio.com/api/v1/convert/ass-to-srt \
    -F "file=@episode.ass" \
    -o episode.srt

MicroDVD with an explicit frame rate:

curl -X POST https://www.aisubtitlestudio.com/api/v1/convert/microdvd-to-srt \
    -F "file=@episode.sub" \
    -F "fps=25" \
    -o episode.srt

Errors

Anything other than success comes back as JSON — never a redirect, never HTML.

An unknown slug:

{ "message": "Unknown conversion \"foo-to-bar\". See /api/v1/convert for the list of endpoints." }

A file with no subtitles a parser can find, or the wrong file for that endpoint:

{ "message": "No subtitles found in that file. Make sure it's in one of the formats this converter accepts." }

A validation failure carries the same shape Laravel uses everywhere:

{
  "message": "The file field is required.",
  "errors": { "file": ["The file field is required."] }
}

Exceeding the rate limit returns 429 with the standard X-RateLimit-* headers.

FAQ

Do I need an API key?
Not yet. The API is open and unauthenticated for now, same as the tools API.
Is the output the same as using the website?
Yes — the API and the /tools/convert web forms call the exact same conversion code, so a given file always produces byte-identical output either way.
Can I convert to ASS/SSA?
Not through this API — converting *to* ASS properly requires building a full styled document (headers, style definitions), which none of these endpoints do. All of them convert *from* ASS, or between the plain formats (SRT, WebVTT, plain text).
What happens to files I upload?
Each request is processed in memory for that one call and never written to disk on our end.
Is there a rate limit?
Yes, 60 requests per minute per IP address. Going over it returns a 429 response.