Vercel 413 FUNCTION_PAYLOAD_TOO_LARGE with Sume video

Vercel Functions cap request and response bodies at 4.5 MB. Do not proxy a generated video through one; hand the client the media.sume.com URL instead.

4 min readSume
All posts

Vercel returns 413: FUNCTION_PAYLOAD_TOO_LARGE when a Function's request or response body exceeds 4.5 MB. A generated video is usually bigger, so do not stream it back through a Function; return the Sume media URL from the job result and let the browser fetch it directly.

The limit is from Vercel's Functions limitations page (updated 2026-08-24), read 2026-09-30. Sume behavior is from Jobs and results and Media inputs.

What exactly does Vercel limit?

The page says the maximum payload size for the request body or the response body of a Vercel Function is 4.5 MB, and a larger payload returns 413 FUNCTION_PAYLOAD_TOO_LARGE. It applies in both directions, so it hits an upload through your route and a download through your route.

What does a Sume result give me instead of bytes?

Results carry a hosted URL. A webhook payload's artifact looks like { "id": "artf_...", "url": "https://media.sume.com/artifacts/...", "type": "image", ... }. The docs say to use Sume media URLs from the result, that Sume mirrors generated outputs into Sume-owned media URLs, and that integrations should store the Sume URL. So your route can return a few hundred bytes of JSON.

What passes through your Function, from the Vercel page and Sume docs, read 2026-09-30
ApproachBody size through the FunctionRisk
Proxy the video bytesThe whole file413 above 4.5 MB
Return the Sume artifact URLA short JSON fieldNone from this limit
Browser fetches the URLNothingStore your own copy if you need long-term retention

What about sending big inputs to Sume?

Inputs go in as public HTTPS URLs in fields such as input.image_url or video_url, and the docs say no separate upload step is needed for normal integrations. So you do not need to push a large file through a Function either. See downloading a generated video from the API for saving the file.

Does Sume also have a request size limit?

Yes, separately: the error table lists 413 payload_too_large when the request body exceeds the configured API limit. That is about your JSON request to Sume, which should be small when you pass URLs.

Sources

Related posts

More in Developers

All Developers posts

Written by Sume