Skip to content

Commit 4675ee3

Browse files
chore: 🐝 Update SDK - Generate (#110)
> [!IMPORTANT] > Linting report available at: <https://app.speakeasyapi.dev/org/unstructured/unstructured5xr/linting-report/01db84f5f80c422ff8c0ad8355dd0e2d> > OpenAPI Change report available at: <https://app.speakeasyapi.dev/org/unstructured/unstructured5xr/changes-report/09afe056dfd31b90a4ab59effebe7169> # SDK update Based on: - OpenAPI Doc - Speakeasy CLI 1.300.1 (2.339.1) https://github.com/speakeasy-api/speakeasy ## PYTHON CHANGELOG Co-authored-by: speakeasybot <[email protected]>
1 parent 9933e0e commit 4675ee3

File tree

7 files changed

+86
-17
lines changed

7 files changed

+86
-17
lines changed

Diff for: .speakeasy/gen.lock

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ id: 8b5fa338-9106-4734-abf0-e30d67044a90
33
management:
44
docChecksum: 2cabb51a37782b691a9f16fbbf8df52b
55
docVersion: 1.0.33
6-
speakeasyVersion: 1.300.0
7-
generationVersion: 2.338.14
8-
releaseVersion: 0.23.1
9-
configChecksum: 1ff015a4f01b59b8410c220d105f05a2
6+
speakeasyVersion: 1.300.1
7+
generationVersion: 2.339.1
8+
releaseVersion: 0.23.2
9+
configChecksum: a468a45a33e1c1f49b439ef4ac9f9de9
1010
repoURL: https://github.com/Unstructured-IO/unstructured-python-client.git
1111
repoSubDirectory: .
1212
installationURL: https://github.com/Unstructured-IO/unstructured-python-client.git

Diff for: .speakeasy/workflow.lock

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
speakeasyVersion: 1.300.0
1+
speakeasyVersion: 1.300.1
22
sources:
33
my-source:
44
sourceNamespace: my-source
5-
sourceRevisionDigest: sha256:9185f612fb7b29e3977b6a818d07a5e05274d149c2f1e5faef03980913817bd2
6-
sourceBlobDigest: sha256:ca32fe0602b577603a80b173976350fddad466232f4b971f2b90ae2405ead69b
5+
sourceRevisionDigest: sha256:2d784171c0d3cf861c9b0e03a73d0eb4e99bdd1dd73f59aaf11490110af5f4ac
6+
sourceBlobDigest: sha256:9f004e6ecd506c665f6de41a3b5c6d6dc0918c0df0680808e6a218d9b86d24b8
77
tags:
88
- latest
99
- main
1010
targets:
1111
unstructured-python:
1212
source: my-source
1313
sourceNamespace: my-source
14-
sourceRevisionDigest: sha256:9185f612fb7b29e3977b6a818d07a5e05274d149c2f1e5faef03980913817bd2
15-
sourceBlobDigest: sha256:ca32fe0602b577603a80b173976350fddad466232f4b971f2b90ae2405ead69b
14+
sourceRevisionDigest: sha256:2d784171c0d3cf861c9b0e03a73d0eb4e99bdd1dd73f59aaf11490110af5f4ac
15+
sourceBlobDigest: sha256:9f004e6ecd506c665f6de41a3b5c6d6dc0918c0df0680808e6a218d9b86d24b8
1616
outLocation: /github/workspace/repo
1717
workflow:
1818
workflowVersion: 1.0.0

Diff for: README.md

+61-2
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,67 @@ req = shared.PartitionParameters(
8787
split_pdf_concurrency_level=8
8888
)
8989
```
90-
<!-- Start Retries -->
91-
<!-- End Retries -->
90+
<!-- Start Retries [retries] -->
91+
## Retries
92+
93+
Some of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.
94+
95+
To change the default retry strategy for a single API call, simply provide a `RetryConfig` object to the call:
96+
```python
97+
import unstructured_client
98+
from unstructured_client.models import operations, shared
99+
from unstructured_client.utils import BackoffStrategy, RetryConfig
100+
101+
s = unstructured_client.UnstructuredClient(
102+
api_key_auth="YOUR_API_KEY",
103+
)
104+
105+
106+
res = s.general.partition(request=operations.PartitionRequest(
107+
partition_parameters=shared.PartitionParameters(
108+
files=shared.Files(
109+
content='0x2cC94b2FEF'.encode(),
110+
file_name='your_file_here',
111+
),
112+
strategy=shared.Strategy.AUTO,
113+
),
114+
),
115+
RetryConfig('backoff', BackoffStrategy(1, 50, 1.1, 100), False))
116+
117+
if res.elements is not None:
118+
# handle response
119+
pass
120+
121+
```
122+
123+
If you'd like to override the default retry strategy for all operations that support retries, you can use the `retry_config` optional parameter when initializing the SDK:
124+
```python
125+
import unstructured_client
126+
from unstructured_client.models import operations, shared
127+
from unstructured_client.utils import BackoffStrategy, RetryConfig
128+
129+
s = unstructured_client.UnstructuredClient(
130+
retry_config=RetryConfig('backoff', BackoffStrategy(1, 50, 1.1, 100), False),
131+
api_key_auth="YOUR_API_KEY",
132+
)
133+
134+
135+
res = s.general.partition(request=operations.PartitionRequest(
136+
partition_parameters=shared.PartitionParameters(
137+
files=shared.Files(
138+
content='0x2cC94b2FEF'.encode(),
139+
file_name='your_file_here',
140+
),
141+
strategy=shared.Strategy.AUTO,
142+
),
143+
))
144+
145+
if res.elements is not None:
146+
# handle response
147+
pass
148+
149+
```
150+
<!-- End Retries [retries] -->
92151

93152
<!-- Start Custom HTTP Client [http-client] -->
94153
## Custom HTTP Client

Diff for: RELEASES.md

+11-1
Original file line numberDiff line numberDiff line change
@@ -494,4 +494,14 @@ Based on:
494494
### Generated
495495
- [python v0.23.1] .
496496
### Releases
497-
- [PyPI v0.23.1] https://pypi.org/project/unstructured-client/0.23.1 - .
497+
- [PyPI v0.23.1] https://pypi.org/project/unstructured-client/0.23.1 - .
498+
499+
## 2024-06-08 00:46:23
500+
### Changes
501+
Based on:
502+
- OpenAPI Doc
503+
- Speakeasy CLI 1.300.1 (2.339.1) https://github.com/speakeasy-api/speakeasy
504+
### Generated
505+
- [python v0.23.2] .
506+
### Releases
507+
- [PyPI v0.23.2] https://pypi.org/project/unstructured-client/0.23.2 - .

Diff for: gen.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ generation:
1010
auth:
1111
oAuth2ClientCredentialsEnabled: false
1212
python:
13-
version: 0.23.1
13+
version: 0.23.2
1414
additionalDependencies:
1515
dependencies:
1616
deepdiff: '>=6.0'

Diff for: setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
setuptools.setup(
2121
name='unstructured-client',
22-
version='0.23.1',
22+
version='0.23.2',
2323
author='Unstructured',
2424
description='Python Client SDK for Unstructured API',
2525
license = 'MIT',

Diff for: src/unstructured_client/sdkconfiguration.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ class SDKConfiguration:
2929
server: Optional[str] = ''
3030
language: str = 'python'
3131
openapi_doc_version: str = '1.0.33'
32-
sdk_version: str = '0.23.1'
33-
gen_version: str = '2.338.14'
34-
user_agent: str = 'speakeasy-sdk/python 0.23.1 2.338.14 1.0.33 unstructured-client'
32+
sdk_version: str = '0.23.2'
33+
gen_version: str = '2.339.1'
34+
user_agent: str = 'speakeasy-sdk/python 0.23.2 2.339.1 1.0.33 unstructured-client'
3535
retry_config: Optional[RetryConfig] = None
3636

3737
def __post_init__(self):

0 commit comments

Comments
 (0)