input
field to process the request data.
To learn more about endpoint requests, see Send requests.
runpod.serverless.start()
function launches your serverless application with the specified handler.
test_input.json
file:/stream
endpoint. Set return_aggregate_stream
to True
to make outputs available from the /run
and /runsync
endpoints as well.
async
and await
keywords throughout your code to maintain truly non-blocking operations and prevent performance bottlenecks, and consider leveraging the yield
statement to generate outputs progressively over time.Always test your async code thoroughly to properly handle asynchronous exceptions and edge cases, as async error patterns can be more complex than in synchronous code.FAILED
and returns the exception details in the job results.
For custom error responses:
try/except
blocks to avoid unintentionally suppressing errors. Either return the error for a graceful failure or raise it to flag the job as FAILED
.
refresh_worker
flag. This flag will be removed before the remaining job output is returned.
/run
endpoint: 10 MB/runsync
endpoint: 20 MB