Referência da API
Cada endpoint, parâmetro e código de erro da API pública.
Esta referência é gerada diretamente do nosso documento OpenAPI e permanece em inglês.
Toda requisição parte de https://doctransform.xyz/api/v1.
Leia as respostas como um leitor tolerante: ignore qualquer campo que não reconheça, já que adicionamos campos sem aviso prévio.
A API é versionada uma única vez, nesta URL base. Se algum dia retirarmos um campo ou endpoint, ele continuará funcionando por pelo menos 12 meses depois de ser marcado com os cabeçalhos Deprecation e Sunset.
Postman → Import → este arquivo: baixe o JSON OpenAPI acima e entregue-o à importação OpenAPI 3.1 do Postman.
GET/api/v1/runs/{run_id}
get_run
Get Run
Scope: runs:read
Parameters
run_idpath, required
Responses
200Successful Responsecompleted_atstring, nullablecreated_atstring, requirederrorobject, nullablecodestring, requiredmessagestring, required
expires_atstring, nullableidstring, requiredoutputobject, nullabledownload_urlstring, requiredmime_typestring, requirednamestring, requiredsize_bytesinteger, required
rows_writteninteger, nullablestatusstring, requiredThe Run record's closed `status` vocabulary -- every writer (`run_admission.admit_run`, this module's own `reap_record`, `run_service.execute_run`) and every reader (the Public API's `RunResponse`, `router.py`'s own status branches) uses these members, never the bare string literals a typo in one call site could drift from the others.
template_idstring, requiredtruncatedboolean
401API_KEY_MISSING, API_KEY_INVALIDerrorstring, requiredmessagestring, required
API_KEY_MISSINGAPI_KEY_INVALID
403INSUFFICIENT_SCOPE, NO_SUBSCRIPTIONerrorstring, requiredmessagestring, required
INSUFFICIENT_SCOPENO_SUBSCRIPTION
404TEMPLATE_NOT_FOUND, RUN_NOT_FOUNDerrorstring, requiredmessagestring, required
TEMPLATE_NOT_FOUNDRUN_NOT_FOUND
429CONCURRENCY_LIMIT_REACHED, RATE_LIMITEDerrorstring, requiredmessagestring, required
CONCURRENCY_LIMIT_REACHEDRATE_LIMITED
curl
curl -X GET "https://doctransform.xyz/api/v1/runs/{run_id}" \
-H "Authorization: Bearer $DOCTRANSFORM_API_KEY"GET/api/v1/runs/{run_id}/output
get_run_output
Get Run Output
Scope: runs:read
Parameters
run_idpath, required
Responses
200Successful Response401API_KEY_MISSING, API_KEY_INVALIDerrorstring, requiredmessagestring, required
API_KEY_MISSINGAPI_KEY_INVALID
403INSUFFICIENT_SCOPE, NO_SUBSCRIPTIONerrorstring, requiredmessagestring, required
INSUFFICIENT_SCOPENO_SUBSCRIPTION
404TEMPLATE_NOT_FOUND, RUN_NOT_FOUNDerrorstring, requiredmessagestring, required
TEMPLATE_NOT_FOUNDRUN_NOT_FOUND
429CONCURRENCY_LIMIT_REACHED, RATE_LIMITEDerrorstring, requiredmessagestring, required
CONCURRENCY_LIMIT_REACHEDRATE_LIMITED
curl
curl -X GET "https://doctransform.xyz/api/v1/runs/{run_id}/output" \
-H "Authorization: Bearer $DOCTRANSFORM_API_KEY"GET/api/v1/templates
list_templates
List Templates
Scope: templates:read
Responses
200Successful Responsedataarray, requireditems[]objectdescriptionstring, nullableidstring, requirednamestring, nullableoutput_formatstring, nullable
401API_KEY_MISSING, API_KEY_INVALIDerrorstring, requiredmessagestring, required
API_KEY_MISSINGAPI_KEY_INVALID
403INSUFFICIENT_SCOPE, NO_SUBSCRIPTIONerrorstring, requiredmessagestring, required
INSUFFICIENT_SCOPENO_SUBSCRIPTION
429CONCURRENCY_LIMIT_REACHED, RATE_LIMITEDerrorstring, requiredmessagestring, required
CONCURRENCY_LIMIT_REACHEDRATE_LIMITED
curl
curl -X GET "https://doctransform.xyz/api/v1/templates" \
-H "Authorization: Bearer $DOCTRANSFORM_API_KEY"POST/api/v1/templates/{template_id}/runs
create_run
Create Run
Runs `template_id` on one uploaded file. Answers `201` with a finished Run if it completes within about 30 seconds, else `202` with `Location`/`Retry-After` while it keeps running in the background -- poll `GET /runs/{id}` for its outcome. An optional `Idempotency-Key` header makes a retry of the same request replay the Run it already started or finished, rather than starting (and charging) a second one; the same key with a different request answers `409`.
Scope: runs:write
Parameters
template_idpath, requiredIdempotency-Keyheader, optionalReplays the Run already started or finished for this key rather than starting a second one; a different request with the same key answers `409 IDEMPOTENCY_KEY_REUSED`.
Body
multipart/form-data: file, delimiter, header_row
Responses
200OKcompleted_atstring, nullablecreated_atstring, requirederrorobject, nullablecodestring, requiredmessagestring, required
expires_atstring, nullableidstring, requiredoutputobject, nullabledownload_urlstring, requiredmime_typestring, requirednamestring, requiredsize_bytesinteger, required
rows_writteninteger, nullablestatusstring, requiredThe Run record's closed `status` vocabulary -- every writer (`run_admission.admit_run`, this module's own `reap_record`, `run_service.execute_run`) and every reader (the Public API's `RunResponse`, `router.py`'s own status branches) uses these members, never the bare string literals a typo in one call site could drift from the others.
template_idstring, requiredtruncatedboolean
201Successful Responsecompleted_atstring, nullablecreated_atstring, requirederrorobject, nullablecodestring, requiredmessagestring, required
expires_atstring, nullableidstring, requiredoutputobject, nullabledownload_urlstring, requiredmime_typestring, requirednamestring, requiredsize_bytesinteger, required
rows_writteninteger, nullablestatusstring, requiredThe Run record's closed `status` vocabulary -- every writer (`run_admission.admit_run`, this module's own `reap_record`, `run_service.execute_run`) and every reader (the Public API's `RunResponse`, `router.py`'s own status branches) uses these members, never the bare string literals a typo in one call site could drift from the others.
template_idstring, requiredtruncatedboolean
202Acceptedcompleted_atstring, nullablecreated_atstring, requirederrorobject, nullablecodestring, requiredmessagestring, required
expires_atstring, nullableidstring, requiredoutputobject, nullabledownload_urlstring, requiredmime_typestring, requirednamestring, requiredsize_bytesinteger, required
rows_writteninteger, nullablestatusstring, requiredThe Run record's closed `status` vocabulary -- every writer (`run_admission.admit_run`, this module's own `reap_record`, `run_service.execute_run`) and every reader (the Public API's `RunResponse`, `router.py`'s own status branches) uses these members, never the bare string literals a typo in one call site could drift from the others.
template_idstring, requiredtruncatedboolean
400MALFORMED_FILEerrorstring, requiredmessagestring, required
MALFORMED_FILE
401API_KEY_MISSING, API_KEY_INVALIDerrorstring, requiredmessagestring, required
API_KEY_MISSINGAPI_KEY_INVALID
402EXPORT_LIMIT_REACHEDerrorstring, requiredmessagestring, requiredquotaobject, requiredlimitinteger, requiredresets_atstring, requiredusedinteger, required
EXPORT_LIMIT_REACHED
403INSUFFICIENT_SCOPE, NO_SUBSCRIPTIONerrorstring, requiredmessagestring, required
INSUFFICIENT_SCOPENO_SUBSCRIPTION
404TEMPLATE_NOT_FOUND, RUN_NOT_FOUNDerrorstring, requiredmessagestring, required
TEMPLATE_NOT_FOUNDRUN_NOT_FOUND
409IDEMPOTENCY_KEY_REUSEDerrorstring, requiredmessagestring, required
IDEMPOTENCY_KEY_REUSED
413FILE_TOO_LARGE, ROW_LIMIT_EXCEEDEDerrorstring, requiredmessagestring, required
FILE_TOO_LARGEROW_LIMIT_EXCEEDED
415UNSUPPORTED_FILE_TYPEerrorstring, requiredmessagestring, required
UNSUPPORTED_FILE_TYPE
422INVALID_PARSE_PARAMS, INVALID_IDEMPOTENCY_KEY, TEMPLATE_COLUMNS_MISSINGerrorstring, requiredmessagestring, required
INVALID_PARSE_PARAMSINVALID_IDEMPOTENCY_KEYTEMPLATE_COLUMNS_MISSING
429CONCURRENCY_LIMIT_REACHED, RATE_LIMITEDerrorstring, requiredmessagestring, required
CONCURRENCY_LIMIT_REACHEDRATE_LIMITED
503SERVER_BUSYerrorstring, requiredmessagestring, required
SERVER_BUSY
curl
curl -X POST "https://doctransform.xyz/api/v1/templates/{template_id}/runs" \
-H "Authorization: Bearer $DOCTRANSFORM_API_KEY" \
-H "Idempotency-Key: <Idempotency-Key>" \
-F "file=@/path/to/your/file.csv"