Nexus

TEAL compile error: "Cannot assemble empty program text"

Short answer: The request body was empty. The compile endpoint received no program text.

The exact message

1 error: 0: Cannot assemble empty program text

Source: POST /v2/teal/compile, HTTP 400, captured against a public TestNet node on 2026-12-03.

Why it happens

Captured by posting an empty body to /v2/teal/compile. The message says line 0 because no line was read.

How to fix it

Wording can change between node versions. All API errors · errors.json · transaction errors · SDK errors · costs