Generate and wait for a specification
Specification, status, search, list, and browser methods return dictionaries at runtime, despite dataclass return annotations in the package. Use
job["specId"] and spec["status"], not job.specId or spec.status. get_credits_balance() is the exception: it constructs a CreditsBalanceResponse object.Method reference
*_async methods and run_async=True submit server-side work and return its ID; they are ordinary blocking Python calls, not coroutines. Do not await them. Spec generation calls use a 300-second HTTP timeout and status, list, and search calls 60 seconds. Browser submissions use 300 seconds, retrieval and list 60 seconds, and queue status 30 seconds. A polling deadline is separate from an individual HTTP timeout, and there is no client-wide timeout or retry option.
Specification history and credits
get_spec_status for full Markdown, JSON, and graphs. See inputs and outputs.
File uploads
The SDK accepts a file path or binary file object viafile. In 1.1.0, it does not set an explicit file-part MIME type or JSON-encode multipart doc_urls. Use direct HTTP when uploading reference documents, especially when supplying documentation URLs:
Run browser tasks and poll
mode, maxSteps, and maxDurationSeconds.
Stream a new browser submission
error frames raise SDK exceptions. A clean iterator exit without done still requires recovery; the SDK does not make EOF a terminal success. To attach to a saved async ID, use existing-run SSE over direct HTTP.
Browser history and evidence
include_events=True adds available timelines and screenshots. Routine polling should omit it. Status and results explains pending stubs, null slots, uppercase task statuses, and lowercase batch statuses.
Errors
status_code attribute. Browser gate errors have typed subclasses; see errors and retries. An Architect 402 without a machine-readable browser gate code raises PredevAPIError. Use direct REST when a retry needs an idempotency key; the SDK has no idempotency or arbitrary-header option.
See the PyPI package or the SDK source.
