Detect Form (Async)
Start detecting fields in a PDF form and return immediately with a form_detection_run resource, typically in the PROCESSING state.
Subscribe to the form_detection_run.processed and form_detection_run.failed webhook events, or poll the Get Form Detection Run endpoint until the status is PROCESSED or FAILED. When processing succeeds, output.schema contains an edit schema you can pass directly to POST /edit or POST /edit_runs.
See Async Processing for polling guidance and Editing Error Handling for HTTP errors and failed runs.
Authentication
Bearer authentication of the form Bearer <token>, where token is your auth token.
Headers
API version to use for the request. If you’re using an SDK, you can ignore this parameter. If you are not using an SDK and do not specify a version, you will either receive a 400 Bad Request or be set to a previous legacy version. See API Versioning for more details.
Request
Response
The type of object. Will always be "form_detection_run".
A unique identifier for the form detection run.
Example: "sgr_xK9mLPqRtN3vS8wF5hB2cQ"
The status of the form detection run:
"PROCESSING"- The form is still being analyzed"PROCESSED"- Form detection completed successfully"FAILED"- Form detection failed (seefailureReasonfor details)
The reason for failure.
Availability: Present when status is "FAILED".
Possible values include:
UNABLE_TO_DOWNLOAD_FILEFILE_TYPE_NOT_SUPPORTEDFILE_SIZE_TOO_LARGECORRUPT_FILEFIELD_DETECTION_ERRORPASSWORD_PROTECTED_FILEFAILED_TO_CONVERT_TO_PDFEMPTY_SCHEMAINTERNAL_ERRORINVALID_OPTIONSOUT_OF_CREDITS
Note: Additional failure reasons may be added in the future. Your integration should handle unknown values gracefully.
A human-readable description of the failure.
Availability: Present when status is "FAILED".
The detected schema and optional mapping metadata.
Availability: Present when status is "PROCESSED".
Metrics about the form detection process.
Availability: Present when status is "PROCESSED".

