Commit fcf8f6b
committed
feat: add DocSplitterClient and GenericUnstractClient support
Add support for two new API patterns:
1. Doc-splitter APIs (job_id-based workflow)
2. Generic Unstract APIs (execution_id-based workflow)
## New Features
### DocSplitterClient
- File upload with form-data support
- Job status polling with configurable intervals
- Binary file download (zip files)
- Methods: upload(), get_job_status(), download_result(), wait_for_completion()
### GenericUnstractClient
- Dynamic endpoint support (invoice, contract, receipt, etc.)
- Execution ID-based tracking
- Multipart form-data uploads with 'files' field
- Methods: process(), get_result(), wait_for_completion(), check_status()
## Implementation Details
- Both clients follow existing patterns for consistency
- Comprehensive test coverage (55 new tests)
- Full type safety with proper error handling
- Updated README with usage examples and API documentation
- All clients share the same ApiHubClientException
## Testing
- 94/94 tests passing
- Comprehensive coverage of success/failure paths
- Performance benchmarks included
- Real-world usage scenarios tested1 parent 877986c commit fcf8f6b
File tree
7 files changed
+1848
-7
lines changed- src/apihub_client
- test
7 files changed
+1848
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
| 69 | + | |
0 commit comments