Mid-stream errors (sent as SSE frames before [DONE]) raise the same MeshAPIError from inside the iterator.
The client automatically retries GET and non-streaming POST / PATCH requests on status codes 429, 502, 503, 504 with exponential backoff (default: 3 retries, base delay 500 ms, max 30 s, with jitter). The Retry-After header is respected on 429 responses.
Streams do not retry. If a connection drops mid-stream, a MeshAPIError with error_code="stream_interrupted" is raised. Catch it and restart a new request: