Name | closedapi_test_pythonv2 JSON |
Version |
0.0.1
JSON |
| download |
home_page | None |
Summary | Python Client SDK Generated by Speakeasy. |
upload_time | 2025-08-06 13:26:01 |
maintainer | None |
docs_url | None |
author | Speakeasy |
requires_python | >=3.9.2 |
license | None |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# openapi
Developer-friendly & type-safe Python SDK specifically catered to leverage *openapi* API.
<div align="left">
<a href="https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python"><img src="https://custom-icon-badges.demolab.com/badge/-Built%20By%20Speakeasy-212015?style=for-the-badge&logoColor=FBE331&logo=speakeasy&labelColor=545454" /></a>
<a href="https://opensource.org/licenses/MIT">
<img src="https://img.shields.io/badge/License-MIT-blue.svg" style="width: 100px; height: 28px;" />
</a>
</div>
<br /><br />
> [!IMPORTANT]
> This SDK is not yet ready for production use. Delete this section before > publishing to a package manager.
<!-- Start Summary [summary] -->
## Summary
SDK Review: A test document for reviewing the SDK.
This document will show case as many of our features as possible in as little operations/models as possible.
This will then generate a SDK that we can more easily review than the test SDKs based on uber.yaml spec.
For more information about the API: [Speakeasy Docs](https://speakeasy.com/docs)
<!-- End Summary [summary] -->
<!-- Start Table of Contents [toc] -->
## Table of Contents
<!-- $toc-max-depth=2 -->
* [openapi](#openapi)
* [SDK Installation](#sdk-installation)
* [IDE Support](#ide-support)
* [SDK Example Usage](#sdk-example-usage)
* [Authentication](#authentication)
* [Available Resources and Operations](#available-resources-and-operations)
* [Global Parameters](#global-parameters)
* [Server-sent event streaming](#server-sent-event-streaming)
* [Pagination](#pagination)
* [File uploads](#file-uploads)
* [Retries](#retries)
* [Error Handling](#error-handling)
* [Server Selection](#server-selection)
* [Custom HTTP Client](#custom-http-client)
* [Resource Management](#resource-management)
* [Debugging](#debugging)
* [Development](#development)
* [Maturity](#maturity)
* [Contributions](#contributions)
<!-- End Table of Contents [toc] -->
<!-- Start SDK Installation [installation] -->
## SDK Installation
> [!TIP]
> To finish publishing your SDK to PyPI you must [run your first generation action](https://www.speakeasy.com/docs/github-setup#step-by-step-guide).
> [!NOTE]
> **Python version upgrade policy**
>
> Once a Python version reaches its [official end of life date](https://devguide.python.org/versions/), a 3-month grace period is provided for users to upgrade. Following this grace period, the minimum python version supported in the SDK will be updated.
The SDK can be installed with *uv*, *pip*, or *poetry* package managers.
### uv (Recommended)
*uv* is a fast Python package installer and resolver, designed as a drop-in replacement for pip and pip-tools. It's recommended for its speed and modern Python tooling capabilities.
```bash
uv add git+<UNSET>.git
```
### PIP
*PIP* is the default package installer for Python, enabling easy installation and management of packages from PyPI via the command line.
```bash
pip install git+<UNSET>.git
```
### Poetry
*Poetry* is a modern tool that simplifies dependency management and package publishing by using a single `pyproject.toml` file to handle project metadata and dependencies.
```bash
poetry add git+<UNSET>.git
```
### Shell and script usage with `uv`
You can use this SDK in a Python shell with [uv](https://docs.astral.sh/uv/) and the `uvx` command that comes with it like so:
```shell
uvx --from openapi python
```
It's also possible to write a standalone Python script without needing to set up a whole project like so:
```python
#!/usr/bin/env -S uv run --script
# /// script
# requires-python = ">=3.9"
# dependencies = [
# "openapi",
# ]
# ///
from speakeasy.new_openapi import SDK
sdk = SDK(
# SDK arguments
)
# Rest of script here...
```
Once that is saved to a file, you can run it with `uv run script.py` where
`script.py` can be replaced with the actual file name.
<!-- End SDK Installation [installation] -->
<!-- Start IDE Support [idesupport] -->
## IDE Support
### PyCharm
Generally, the SDK will work well with most IDEs out of the box. However, when using PyCharm, you can enjoy much better integration with Pydantic by installing an additional plugin.
- [PyCharm Pydantic Plugin](https://docs.pydantic.dev/latest/integrations/pycharm/)
<!-- End IDE Support [idesupport] -->
<!-- Start SDK Example Usage [usage] -->
## SDK Example Usage
### Example 1
```python
# Synchronous Example
from speakeasy.new_openapi import SDK
with SDK() as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
</br>
The same SDK client can also be used to make asychronous requests by importing asyncio.
```python
# Asynchronous Example
import asyncio
from speakeasy.new_openapi import SDK
async def main():
async with SDK() as sdk:
res = await sdk.post_file_async(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
asyncio.run(main())
```
### Example 2
```python
# Synchronous Example
from datetime import date
from decimal import Decimal
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
from speakeasy.new_openapi.utils import parse_datetime
with SDK(
deprecated_query_param1="some example query param",
deprecated_query_param2="some example query param",
) as sdk:
res = sdk.test_group.tag2.post_test(test2_request=speakeasy.new_openapi.Test2Request(
obj=speakeasy.new_openapi.ExhaustiveObject(
str_="example",
bool_=True,
integer=999999,
int32=1,
num=1.1,
float32=8499.3,
date_=date.fromisoformat("2024-10-12"),
date_time=parse_datetime("2020-01-01T00:00:00Z"),
anything="<value>",
bool_opt=True,
int_opt_null=999999,
num_opt_null=1.1,
int_enum=speakeasy.new_openapi.IntEnum.THIRD,
int32_enum=speakeasy.new_openapi.Int32Enum.SIXTY_NINE,
bigint=702830,
decimal_str=Decimal("3858.6"),
obj=speakeasy.new_openapi.SimpleObject(
str_="example",
),
map={
"key": speakeasy.new_openapi.SimpleObject(
str_="example",
),
},
arr=[
speakeasy.new_openapi.SimpleObject(
str_="example",
),
speakeasy.new_openapi.SimpleObject(
str_="example",
),
],
any=speakeasy.new_openapi.SimpleObject(
str_="example",
),
nullable_int_enum=speakeasy.new_openapi.NullableIntEnum.THIRD,
nullable_string_enum=speakeasy.new_openapi.NullableStringEnum.SECOND,
color="green",
icon=speakeasy.new_openapi.Icon.TICK,
hero_width=speakeasy.new_openapi.HeroWidth.FOUR_HUNDRED_AND_EIGHTY,
),
type=speakeasy.new_openapi.Type.SUPER_TYPE1,
))
assert res is not None
# Handle response
print(res)
```
</br>
The same SDK client can also be used to make asychronous requests by importing asyncio.
```python
# Asynchronous Example
import asyncio
from datetime import date
from decimal import Decimal
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
from speakeasy.new_openapi.utils import parse_datetime
async def main():
async with SDK(
deprecated_query_param1="some example query param",
deprecated_query_param2="some example query param",
) as sdk:
res = await sdk.test_group.tag2.post_test_async(test2_request=speakeasy.new_openapi.Test2Request(
obj=speakeasy.new_openapi.ExhaustiveObject(
str_="example",
bool_=True,
integer=999999,
int32=1,
num=1.1,
float32=8499.3,
date_=date.fromisoformat("2024-10-12"),
date_time=parse_datetime("2020-01-01T00:00:00Z"),
anything="<value>",
bool_opt=True,
int_opt_null=999999,
num_opt_null=1.1,
int_enum=speakeasy.new_openapi.IntEnum.THIRD,
int32_enum=speakeasy.new_openapi.Int32Enum.SIXTY_NINE,
bigint=702830,
decimal_str=Decimal("3858.6"),
obj=speakeasy.new_openapi.SimpleObject(
str_="example",
),
map={
"key": speakeasy.new_openapi.SimpleObject(
str_="example",
),
},
arr=[
speakeasy.new_openapi.SimpleObject(
str_="example",
),
speakeasy.new_openapi.SimpleObject(
str_="example",
),
],
any=speakeasy.new_openapi.SimpleObject(
str_="example",
),
nullable_int_enum=speakeasy.new_openapi.NullableIntEnum.THIRD,
nullable_string_enum=speakeasy.new_openapi.NullableStringEnum.SECOND,
color="green",
icon=speakeasy.new_openapi.Icon.TICK,
hero_width=speakeasy.new_openapi.HeroWidth.FOUR_HUNDRED_AND_EIGHTY,
),
type=speakeasy.new_openapi.Type.SUPER_TYPE1,
))
assert res is not None
# Handle response
print(res)
asyncio.run(main())
```
### A custom readme heading
A custom usage description
```python
# Synchronous Example
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
query_param1="some example query param",
) as sdk:
res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1="some example header param")
while res is not None:
# Handle items
res = res.next()
```
</br>
The same SDK client can also be used to make asychronous requests by importing asyncio.
```python
# Asynchronous Example
import asyncio
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
async def main():
async with SDK(
query_param1="some example query param",
) as sdk:
res = await sdk.tag1.list_test1_async(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1="some example header param")
while res is not None:
# Handle items
res = res.next()
asyncio.run(main())
```
<!-- End SDK Example Usage [usage] -->
<!-- Start Authentication [security] -->
## Authentication
### Per-Client Security Schemes
This SDK supports multiple security scheme combinations globally. You can choose from one of the alternatives by setting the `security` optional parameter when initializing the SDK client instance. The selected option will be used by default to authenticate with the API for all operations that support it.
#### Option1
The `Option1` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| ------------------------- | ---- | ---------- | --------------------------------------------- |
| `username`<br/>`password` | http | HTTP Basic | `SPEAKEASY_USERNAME`<br/>`SPEAKEASY_PASSWORD` |
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option1=speakeasy.new_openapi.SecurityOption1(
username="<USERNAME>",
password="<PASSWORD>",
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option2
All of the following schemes must be satisfied to use the `Option2` alternative:
| Name | Type | Scheme | Environment Variable |
| ------------- | ------ | ----------- | ----------------------- |
| `bearer_auth` | http | HTTP Bearer | `SPEAKEASY_BEARER_AUTH` |
| `api_key` | apiKey | API key | `SPEAKEASY_API_KEY` |
```python
import os
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option2=speakeasy.new_openapi.SecurityOption2(
bearer_auth="<YOUR_JWT>",
api_key=os.getenv("SPEAKEASY_API_KEY", ""),
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option3
The `Option3` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| -------- | ------ | ------------ | -------------------- |
| `oauth2` | oauth2 | OAuth2 token | `SPEAKEASY_OAUTH2` |
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option3=speakeasy.new_openapi.SecurityOption3(
oauth2="Bearer <YOUR_OAUTH2_TOKEN>",
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option4
The `Option4` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| --------------------- | ---- | ----------- | ----------------------------------------- |
| `app_id`<br/>`secret` | http | Custom HTTP | `SPEAKEASY_APP_ID`<br/>`SPEAKEASY_SECRET` |
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option4=speakeasy.new_openapi.SecurityOption4(
app_id="app-speakeasy-123",
secret="MTIzNDU2Nzg5MDEyMzQ1Njc4OTAxMjM0NTY3ODkwMTI",
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option5
The `Option5` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| ------------- | ------ | ------------ | ----------------------- |
| `mobile_auth` | oauth2 | OAuth2 token | `SPEAKEASY_MOBILE_AUTH` |
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option5=speakeasy.new_openapi.SecurityOption5(
mobile_auth="Bearer <YOUR_OAUTH2_TOKEN>",
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option6
The `Option6` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| ------------------------------- | ------ | ------------------------------ | ----------------------------------------------------------------------------- |
| `client_id`<br/>`client_secret` | oauth2 | OAuth2 Client Credentials Flow | `SPEAKEASY_CLIENT_ID`<br/>`SPEAKEASY_CLIENT_SECRET`<br/>`SPEAKEASY_TOKEN_URL` |
```python
import os
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option6=speakeasy.new_openapi.SecurityOption6(
client_id=os.getenv("SPEAKEASY_CLIENT_ID", ""),
client_secret=os.getenv("SPEAKEASY_CLIENT_SECRET", ""),
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
#### Option7
The `Option7` alternative relies on the following scheme:
| Name | Type | Scheme | Environment Variable |
| --------- | ------ | ------- | -------------------- |
| `api_key` | apiKey | API key | `SPEAKEASY_API_KEY` |
```python
import os
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
security=speakeasy.new_openapi.Security(
option7=speakeasy.new_openapi.SecurityOption7(
api_key=os.getenv("SPEAKEASY_API_KEY", ""),
),
),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
<!-- End Authentication [security] -->
<!-- Start Available Resources and Operations [operations] -->
## Available Resources and Operations
<details open>
<summary>Available methods</summary>
### [SDK](docs/sdks/sdk/README.md)
* [operation_with_leading_and_trailing_underscores_](docs/sdks/sdk/README.md#operation_with_leading_and_trailing_underscores_)
* [post_file](docs/sdks/sdk/README.md#post_file) - Post File
* [get_polymorphism](docs/sdks/sdk/README.md#get_polymorphism)
* [get_union_errors](docs/sdks/sdk/README.md#get_union_errors)
* [get_request_body_flattened_away](docs/sdks/sdk/README.md#get_request_body_flattened_away)
* [get_fully_flattened_request](docs/sdks/sdk/README.md#get_fully_flattened_request)
* [test_endpoint](docs/sdks/sdk/README.md#test_endpoint)
* [create_user](docs/sdks/sdk/README.md#create_user) - Create User
* [get_user](docs/sdks/sdk/README.md#get_user) - Get User
* [update_user](docs/sdks/sdk/README.md#update_user) - Update User
* [delete_user](docs/sdks/sdk/README.md#delete_user) - Delete User
* [login](docs/sdks/sdk/README.md#login) - Login
* [validate](docs/sdks/sdk/README.md#validate) - Validate
* [chat](docs/sdks/sdk/README.md#chat)
* [get_binary_default_response](docs/sdks/sdk/README.md#get_binary_default_response)
* [test_enum_formats](docs/sdks/sdk/README.md#test_enum_formats) - Test x-speakeasy-enums in different formats
* [binary_and_string_upload](docs/sdks/sdk/README.md#binary_and_string_upload)
* [get_error_in_union](docs/sdks/sdk/README.md#get_error_in_union)
### [tag1](docs/sdks/tag1/README.md)
* [~~deprecated1~~](docs/sdks/tag1/README.md#deprecated1) - Deprecated Operation :warning: **Deprecated** Use [get_request_body_flattened_away](docs/sdks/sdk/README.md#get_request_body_flattened_away) instead.
* [list_test1](docs/sdks/tag1/README.md#list_test1) - Get Test1
### [test_group](docs/sdks/testgroup/README.md)
#### [test_group.tag2](docs/sdks/tag2/README.md)
* [post_test](docs/sdks/tag2/README.md#post_test) - Post Test2
#### [test_group.tag3](docs/sdks/tag3/README.md)
* [post_test](docs/sdks/tag3/README.md#post_test) - Post Test2
</details>
<!-- End Available Resources and Operations [operations] -->
<!-- Start Global Parameters [global-parameters] -->
## Global Parameters
Certain parameters are configured globally. These parameters may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, These global values will be used as defaults on the operations that use them. When such operations are called, there is a place in each to override the global value, if needed.
For example, you can set `queryParam1` to `"some example query param"` at SDK initialization and then you do not have to pass the same value on calls to operations like `get_request_body_flattened_away`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
### Available Globals
The following global parameters are available.
Global parameters can also be set via environment variable.
| Name | Type | Description | Environment |
| ----------------------- | ---- | ---------------------------------------------------------------------------------- | --------------------------------- |
| query_param1 | str | A long winded, multi-line description<br/>for the query parameter number one.<br/> | SPEAKEASY_QUERY_PARAM1 |
| deprecated_query_param1 | str | A deprecated description | SPEAKEASY_DEPRECATED_QUERY_PARAM1 |
| deprecated_query_param2 | str | The deprecated_query_param2 parameter. | SPEAKEASY_DEPRECATED_QUERY_PARAM2 |
| lone_query_param | str | The lone_query_param parameter. | SPEAKEASY_LONE_QUERY_PARAM |
### Example
```python
from speakeasy.new_openapi import SDK
with SDK(
lone_query_param="<value>",
query_param1="some example query param",
deprecated_query_param1="some example query param",
deprecated_query_param2="some example query param",
) as sdk:
sdk.get_request_body_flattened_away()
# Use the SDK ...
```
<!-- End Global Parameters [global-parameters] -->
<!-- Start Server-sent event streaming [eventstream] -->
## Server-sent event streaming
[Server-sent events][mdn-sse] are used to stream content from certain
operations. These operations will expose the stream as [Generator][generator] that
can be consumed using a simple `for` loop. The loop will
terminate when the server no longer has any events to send and closes the
underlying connection.
The stream is also a [Context Manager][context-manager] and can be used with the `with` statement and will close the
underlying connection when the context is exited.
```python
from speakeasy.new_openapi import SDK
with SDK() as sdk:
res = sdk.chat(request={
"prompt": "What is the largest city in the world?",
})
with res as event_stream:
for event in event_stream:
# handle event
print(event, flush=True)
```
[mdn-sse]: https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events
[generator]: https://book.pythontips.com/en/latest/generators.html
[context-manager]: https://book.pythontips.com/en/latest/context_managers.html
<!-- End Server-sent event streaming [eventstream] -->
<!-- Start Pagination [pagination] -->
## Pagination
Some of the endpoints in this SDK support pagination. To use pagination, you make your SDK calls as usual, but the
returned response object will have a `Next` method that can be called to pull down the next group of results. If the
return value of `Next` is `None`, then there are no more pages to be fetched.
Here's an example of one such pagination call:
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
query_param1="some example query param",
) as sdk:
res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1="some example header param")
while res is not None:
# Handle items
res = res.next()
```
<!-- End Pagination [pagination] -->
<!-- Start File uploads [file-upload] -->
## File uploads
Certain SDK methods accept file objects as part of a request body or multi-part request. It is possible and typically recommended to upload files as a stream rather than reading the entire contents into memory. This avoids excessive memory consumption and potentially crashing with out-of-memory errors when working with very large files. The following example demonstrates how to attach a file stream to a request.
> [!TIP]
>
> For endpoints that handle file uploads bytes arrays can also be used. However, using streams is recommended for large files.
>
```python
from speakeasy.new_openapi import SDK
with SDK() as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
<!-- End File uploads [file-upload] -->
<!-- Start Retries [retries] -->
## Retries
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.
To change the default retry strategy for a single API call, simply provide a `RetryConfig` object to the call:
```python
from speakeasy.new_openapi import SDK
from speakeasy.new_openapi.utils import BackoffStrategy, RetryConfig
with SDK() as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
},
RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False))
# Handle response
print(res)
```
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:
```python
from speakeasy.new_openapi import SDK
from speakeasy.new_openapi.utils import BackoffStrategy, RetryConfig
with SDK(
retry_config=RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False),
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
<!-- End Retries [retries] -->
<!-- Start Error Handling [errors] -->
## Error Handling
[`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py) is the base class for all HTTP error responses. It has the following properties:
| Property | Type | Description |
| ------------------ | ---------------- | --------------------------------------------------------------------------------------- |
| `err.message` | `str` | Error message |
| `err.status_code` | `int` | HTTP response status code eg `404` |
| `err.headers` | `httpx.Headers` | HTTP response headers |
| `err.body` | `str` | HTTP body. Can be empty string if no body is returned. |
| `err.raw_response` | `httpx.Response` | Raw HTTP response |
| `err.data` | | Optional. Some errors may contain structured data. [See Error Classes](#error-classes). |
### Example
```python
from speakeasy.new_openapi import SDK, models
with SDK() as sdk:
res = None
try:
res = sdk.get_union_errors(page=12)
while res is not None:
# Handle items
res = res.next()
except models.SDKBaseError as e:
# The base class for HTTP error responses
print(e.message)
print(e.status_code)
print(e.body)
print(e.headers)
print(e.raw_response)
# Depending on the method different errors may be thrown
if isinstance(e, models.ErrorsError):
print(e.data.error) # str
print(e.data.code) # int
```
### Error Classes
**Primary error:**
* [`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py): The base class for HTTP error responses.
<details><summary>Less common errors (12)</summary>
<br />
**Network errors:**
* [`httpx.RequestError`](https://www.python-httpx.org/exceptions/#httpx.RequestError): Base class for request errors.
* [`httpx.ConnectError`](https://www.python-httpx.org/exceptions/#httpx.ConnectError): HTTP client was unable to make a request to a server.
* [`httpx.TimeoutException`](https://www.python-httpx.org/exceptions/#httpx.TimeoutException): HTTP request timed out.
**Inherit from [`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py)**:
* [`ErrorsError`](./src/speakeasy/new_openapi/models/errorserror.py): Applicable to 5 of 22 methods.*
* [`BadRequestResponseError`](./src/speakeasy/new_openapi/models/badrequestresponseerror.py): Bad Request. Status code `400`. Applicable to 2 of 22 methods.*
* [`TaggedError1`](./src/speakeasy/new_openapi/models/taggederror1.py): Applicable to 2 of 22 methods.*
* [`TaggedError2`](./src/speakeasy/new_openapi/models/taggederror2.py): Something went wrong. Status code `4XX`. Applicable to 1 of 22 methods.*
* [`ErrorType1`](./src/speakeasy/new_openapi/models/errortype1.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*
* [`ErrorType2`](./src/speakeasy/new_openapi/models/errortype2.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*
* [`Test2ResponseError`](./src/speakeasy/new_openapi/models/test2responseerror.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*
* [`ResponseValidationError`](./src/speakeasy/new_openapi/models/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute.
</details>
\* Check [the method documentation](#available-resources-and-operations) to see if the error is applicable.
<!-- End Error Handling [errors] -->
<!-- Start Server Selection [server] -->
## Server Selection
### Select Server by Index
You can override the default server globally by passing a server index to the `server_idx: int` optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the indexes associated with the available servers:
| # | Server | Variables | Description |
| --- | ------------------------------------------ | ------------------------- | ------------------------------- |
| 0 | `http://localhost:35123` | | The default server. |
| 1 | `http://{subdomain}.domain.com/v{version}` | `subdomain`<br/>`version` | |
| 2 | `http://{HostName}:{PORT}` | `HostName`<br/>`PORT` | A server with an enum variable. |
If the selected server has variables, you may override its default values through the additional parameters made available in the SDK constructor:
| Variable | Parameter | Supported Values | Default | Description |
| ----------- | ------------------------- | ------------------------------------- | ------------- | ---------------------------------------- |
| `subdomain` | `subdomain: str` | str | `"api"` | |
| `version` | `version: str` | str | `"1"` | |
| `HostName` | `host_name: str` | str | `"localhost"` | The hostname of the server. |
| `PORT` | `port: models.ServerPORT` | - `"80"`<br/>- `"8080"`<br/>- `"443"` | `"8080"` | The port on which the server is running. |
#### Example
```python
from speakeasy.new_openapi import SDK
with SDK(
server_idx=2,
host_name="heavy-bowler.org"
port="443"
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
### Override Server URL Per-Client
The default server can also be overridden globally by passing a URL to the `server_url: str` optional parameter when initializing the SDK client instance. For example:
```python
from speakeasy.new_openapi import SDK
with SDK(
server_url="http://localhost:8080",
) as sdk:
res = sdk.post_file(request={
"file": {
"file_name": "example.file",
"content": open("example.file", "rb"),
},
})
# Handle response
print(res)
```
### Override Server URL Per-Operation
The server URL can also be overridden on a per-operation basis, provided a server list was specified for the operation. For example:
```python
import speakeasy.new_openapi
from speakeasy.new_openapi import SDK
with SDK(
query_param1="some example query param",
) as sdk:
res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1="some example header param", server_url="http://localhost:35123")
while res is not None:
# Handle items
res = res.next()
```
<!-- End Server Selection [server] -->
<!-- Start Custom HTTP Client [http-client] -->
## Custom HTTP Client
The Python SDK makes API calls using the [httpx](https://www.python-httpx.org/) HTTP library. In order to provide a convenient way to configure timeouts, cookies, proxies, custom headers, and other low-level configuration, you can initialize the SDK client with your own HTTP client instance.
Depending on whether you are using the sync or async version of the SDK, you can pass an instance of `HttpClient` or `AsyncHttpClient` respectively, which are Protocol's ensuring that the client has the necessary methods to make API calls.
This allows you to wrap the client with your own custom logic, such as adding custom headers, logging, or error handling, or you can just pass an instance of `httpx.Client` or `httpx.AsyncClient` directly.
For example, you could specify a header for every request that this sdk makes as follows:
```python
from speakeasy.new_openapi import SDK
import httpx
http_client = httpx.Client(headers={"x-custom-header": "someValue"})
s = SDK(client=http_client)
```
or you could wrap the client with your own custom logic:
```python
from speakeasy.new_openapi import SDK
from speakeasy.new_openapi.httpclient import AsyncHttpClient
import httpx
class CustomClient(AsyncHttpClient):
client: AsyncHttpClient
def __init__(self, client: AsyncHttpClient):
self.client = client
async def send(
self,
request: httpx.Request,
*,
stream: bool = False,
auth: Union[
httpx._types.AuthTypes, httpx._client.UseClientDefault, None
] = httpx.USE_CLIENT_DEFAULT,
follow_redirects: Union[
bool, httpx._client.UseClientDefault
] = httpx.USE_CLIENT_DEFAULT,
) -> httpx.Response:
request.headers["Client-Level-Header"] = "added by client"
return await self.client.send(
request, stream=stream, auth=auth, follow_redirects=follow_redirects
)
def build_request(
self,
method: str,
url: httpx._types.URLTypes,
*,
content: Optional[httpx._types.RequestContent] = None,
data: Optional[httpx._types.RequestData] = None,
files: Optional[httpx._types.RequestFiles] = None,
json: Optional[Any] = None,
params: Optional[httpx._types.QueryParamTypes] = None,
headers: Optional[httpx._types.HeaderTypes] = None,
cookies: Optional[httpx._types.CookieTypes] = None,
timeout: Union[
httpx._types.TimeoutTypes, httpx._client.UseClientDefault
] = httpx.USE_CLIENT_DEFAULT,
extensions: Optional[httpx._types.RequestExtensions] = None,
) -> httpx.Request:
return self.client.build_request(
method,
url,
content=content,
data=data,
files=files,
json=json,
params=params,
headers=headers,
cookies=cookies,
timeout=timeout,
extensions=extensions,
)
s = SDK(async_client=CustomClient(httpx.AsyncClient()))
```
<!-- End Custom HTTP Client [http-client] -->
<!-- Start Resource Management [resource-management] -->
## Resource Management
The `SDK` class implements the context manager protocol and registers a finalizer function to close the underlying sync and async HTTPX clients it uses under the hood. This will close HTTP connections, release memory and free up other resources held by the SDK. In short-lived Python programs and notebooks that make a few SDK method calls, resource management may not be a concern. However, in longer-lived programs, it is beneficial to create a single SDK instance via a [context manager][context-manager] and reuse it across the application.
[context-manager]: https://docs.python.org/3/reference/datamodel.html#context-managers
```python
from speakeasy.new_openapi import SDK
def main():
with SDK() as sdk:
# Rest of application here...
# Or when using async:
async def amain():
async with SDK() as sdk:
# Rest of application here...
```
<!-- End Resource Management [resource-management] -->
<!-- Start Debugging [debug] -->
## Debugging
You can setup your SDK to emit debug logs for SDK requests and responses.
You can pass your own logger class directly into your SDK.
```python
from speakeasy.new_openapi import SDK
import logging
logging.basicConfig(level=logging.DEBUG)
s = SDK(debug_logger=logging.getLogger("speakeasy.new_openapi"))
```
You can also enable a default debug logger by setting an environment variable `SPEAKEASY_DEBUG` to true.
<!-- End Debugging [debug] -->
<!-- Placeholder for Future Speakeasy SDK Sections -->
# Development
## Maturity
This SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage
to a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally
looking for the latest version.
## Contributions
While we value open-source contributions to this SDK, this library is generated programmatically. Any manual changes added to internal files will be overwritten on the next generation.
We look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release.
### SDK Created by [Speakeasy](https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python)
Raw data
{
"_id": null,
"home_page": null,
"name": "closedapi_test_pythonv2",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9.2",
"maintainer_email": null,
"keywords": null,
"author": "Speakeasy",
"author_email": null,
"download_url": null,
"platform": null,
"description": "# openapi\n\nDeveloper-friendly & type-safe Python SDK specifically catered to leverage *openapi* API.\n\n<div align=\"left\">\n <a href=\"https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python\"><img src=\"https://custom-icon-badges.demolab.com/badge/-Built%20By%20Speakeasy-212015?style=for-the-badge&logoColor=FBE331&logo=speakeasy&labelColor=545454\" /></a>\n <a href=\"https://opensource.org/licenses/MIT\">\n <img src=\"https://img.shields.io/badge/License-MIT-blue.svg\" style=\"width: 100px; height: 28px;\" />\n </a>\n</div>\n\n\n<br /><br />\n> [!IMPORTANT]\n> This SDK is not yet ready for production use. Delete this section before > publishing to a package manager.\n\n<!-- Start Summary [summary] -->\n## Summary\n\nSDK Review: A test document for reviewing the SDK.\n\nThis document will show case as many of our features as possible in as little operations/models as possible.\nThis will then generate a SDK that we can more easily review than the test SDKs based on uber.yaml spec.\n\nFor more information about the API: [Speakeasy Docs](https://speakeasy.com/docs)\n<!-- End Summary [summary] -->\n\n<!-- Start Table of Contents [toc] -->\n## Table of Contents\n<!-- $toc-max-depth=2 -->\n* [openapi](#openapi)\n * [SDK Installation](#sdk-installation)\n * [IDE Support](#ide-support)\n * [SDK Example Usage](#sdk-example-usage)\n * [Authentication](#authentication)\n * [Available Resources and Operations](#available-resources-and-operations)\n * [Global Parameters](#global-parameters)\n * [Server-sent event streaming](#server-sent-event-streaming)\n * [Pagination](#pagination)\n * [File uploads](#file-uploads)\n * [Retries](#retries)\n * [Error Handling](#error-handling)\n * [Server Selection](#server-selection)\n * [Custom HTTP Client](#custom-http-client)\n * [Resource Management](#resource-management)\n * [Debugging](#debugging)\n* [Development](#development)\n * [Maturity](#maturity)\n * [Contributions](#contributions)\n\n<!-- End Table of Contents [toc] -->\n\n<!-- Start SDK Installation [installation] -->\n## SDK Installation\n\n> [!TIP]\n> To finish publishing your SDK to PyPI you must [run your first generation action](https://www.speakeasy.com/docs/github-setup#step-by-step-guide).\n\n\n> [!NOTE]\n> **Python version upgrade policy**\n>\n> Once a Python version reaches its [official end of life date](https://devguide.python.org/versions/), a 3-month grace period is provided for users to upgrade. Following this grace period, the minimum python version supported in the SDK will be updated.\n\nThe SDK can be installed with *uv*, *pip*, or *poetry* package managers.\n\n### uv (Recommended)\n\n*uv* is a fast Python package installer and resolver, designed as a drop-in replacement for pip and pip-tools. It's recommended for its speed and modern Python tooling capabilities.\n\n```bash\nuv add git+<UNSET>.git\n```\n\n### PIP\n\n*PIP* is the default package installer for Python, enabling easy installation and management of packages from PyPI via the command line.\n\n```bash\npip install git+<UNSET>.git\n```\n\n### Poetry\n\n*Poetry* is a modern tool that simplifies dependency management and package publishing by using a single `pyproject.toml` file to handle project metadata and dependencies.\n\n```bash\npoetry add git+<UNSET>.git\n```\n\n### Shell and script usage with `uv`\n\nYou can use this SDK in a Python shell with [uv](https://docs.astral.sh/uv/) and the `uvx` command that comes with it like so:\n\n```shell\nuvx --from openapi python\n```\n\nIt's also possible to write a standalone Python script without needing to set up a whole project like so:\n\n```python\n#!/usr/bin/env -S uv run --script\n# /// script\n# requires-python = \">=3.9\"\n# dependencies = [\n# \"openapi\",\n# ]\n# ///\n\nfrom speakeasy.new_openapi import SDK\n\nsdk = SDK(\n # SDK arguments\n)\n\n# Rest of script here...\n```\n\nOnce that is saved to a file, you can run it with `uv run script.py` where\n`script.py` can be replaced with the actual file name.\n<!-- End SDK Installation [installation] -->\n\n<!-- Start IDE Support [idesupport] -->\n## IDE Support\n\n### PyCharm\n\nGenerally, the SDK will work well with most IDEs out of the box. However, when using PyCharm, you can enjoy much better integration with Pydantic by installing an additional plugin.\n\n- [PyCharm Pydantic Plugin](https://docs.pydantic.dev/latest/integrations/pycharm/)\n<!-- End IDE Support [idesupport] -->\n\n<!-- Start SDK Example Usage [usage] -->\n## SDK Example Usage\n\n### Example 1\n\n```python\n# Synchronous Example\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK() as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n```\n\n</br>\n\nThe same SDK client can also be used to make asychronous requests by importing asyncio.\n```python\n# Asynchronous Example\nimport asyncio\nfrom speakeasy.new_openapi import SDK\n\nasync def main():\n\n async with SDK() as sdk:\n\n res = await sdk.post_file_async(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\nasyncio.run(main())\n```\n\n### Example 2\n\n```python\n# Synchronous Example\nfrom datetime import date\nfrom decimal import Decimal\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\nfrom speakeasy.new_openapi.utils import parse_datetime\n\n\nwith SDK(\n deprecated_query_param1=\"some example query param\",\n deprecated_query_param2=\"some example query param\",\n) as sdk:\n\n res = sdk.test_group.tag2.post_test(test2_request=speakeasy.new_openapi.Test2Request(\n obj=speakeasy.new_openapi.ExhaustiveObject(\n str_=\"example\",\n bool_=True,\n integer=999999,\n int32=1,\n num=1.1,\n float32=8499.3,\n date_=date.fromisoformat(\"2024-10-12\"),\n date_time=parse_datetime(\"2020-01-01T00:00:00Z\"),\n anything=\"<value>\",\n bool_opt=True,\n int_opt_null=999999,\n num_opt_null=1.1,\n int_enum=speakeasy.new_openapi.IntEnum.THIRD,\n int32_enum=speakeasy.new_openapi.Int32Enum.SIXTY_NINE,\n bigint=702830,\n decimal_str=Decimal(\"3858.6\"),\n obj=speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n map={\n \"key\": speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n },\n arr=[\n speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n ],\n any=speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n nullable_int_enum=speakeasy.new_openapi.NullableIntEnum.THIRD,\n nullable_string_enum=speakeasy.new_openapi.NullableStringEnum.SECOND,\n color=\"green\",\n icon=speakeasy.new_openapi.Icon.TICK,\n hero_width=speakeasy.new_openapi.HeroWidth.FOUR_HUNDRED_AND_EIGHTY,\n ),\n type=speakeasy.new_openapi.Type.SUPER_TYPE1,\n ))\n\n assert res is not None\n\n # Handle response\n print(res)\n```\n\n</br>\n\nThe same SDK client can also be used to make asychronous requests by importing asyncio.\n```python\n# Asynchronous Example\nimport asyncio\nfrom datetime import date\nfrom decimal import Decimal\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\nfrom speakeasy.new_openapi.utils import parse_datetime\n\nasync def main():\n\n async with SDK(\n deprecated_query_param1=\"some example query param\",\n deprecated_query_param2=\"some example query param\",\n ) as sdk:\n\n res = await sdk.test_group.tag2.post_test_async(test2_request=speakeasy.new_openapi.Test2Request(\n obj=speakeasy.new_openapi.ExhaustiveObject(\n str_=\"example\",\n bool_=True,\n integer=999999,\n int32=1,\n num=1.1,\n float32=8499.3,\n date_=date.fromisoformat(\"2024-10-12\"),\n date_time=parse_datetime(\"2020-01-01T00:00:00Z\"),\n anything=\"<value>\",\n bool_opt=True,\n int_opt_null=999999,\n num_opt_null=1.1,\n int_enum=speakeasy.new_openapi.IntEnum.THIRD,\n int32_enum=speakeasy.new_openapi.Int32Enum.SIXTY_NINE,\n bigint=702830,\n decimal_str=Decimal(\"3858.6\"),\n obj=speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n map={\n \"key\": speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n },\n arr=[\n speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n ],\n any=speakeasy.new_openapi.SimpleObject(\n str_=\"example\",\n ),\n nullable_int_enum=speakeasy.new_openapi.NullableIntEnum.THIRD,\n nullable_string_enum=speakeasy.new_openapi.NullableStringEnum.SECOND,\n color=\"green\",\n icon=speakeasy.new_openapi.Icon.TICK,\n hero_width=speakeasy.new_openapi.HeroWidth.FOUR_HUNDRED_AND_EIGHTY,\n ),\n type=speakeasy.new_openapi.Type.SUPER_TYPE1,\n ))\n\n assert res is not None\n\n # Handle response\n print(res)\n\nasyncio.run(main())\n```\n\n### A custom readme heading\n\nA custom usage description\n\n```python\n# Synchronous Example\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n query_param1=\"some example query param\",\n) as sdk:\n\n res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1=\"some example header param\")\n\n while res is not None:\n # Handle items\n\n res = res.next()\n```\n\n</br>\n\nThe same SDK client can also be used to make asychronous requests by importing asyncio.\n```python\n# Asynchronous Example\nimport asyncio\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\nasync def main():\n\n async with SDK(\n query_param1=\"some example query param\",\n ) as sdk:\n\n res = await sdk.tag1.list_test1_async(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1=\"some example header param\")\n\n while res is not None:\n # Handle items\n\n res = res.next()\n\nasyncio.run(main())\n```\n<!-- End SDK Example Usage [usage] -->\n\n<!-- Start Authentication [security] -->\n## Authentication\n\n### Per-Client Security Schemes\n\nThis SDK supports multiple security scheme combinations globally. You can choose from one of the alternatives by setting the `security` optional parameter when initializing the SDK client instance. The selected option will be used by default to authenticate with the API for all operations that support it.\n\n#### Option1\n\nThe `Option1` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| ------------------------- | ---- | ---------- | --------------------------------------------- |\n| `username`<br/>`password` | http | HTTP Basic | `SPEAKEASY_USERNAME`<br/>`SPEAKEASY_PASSWORD` |\n\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option1=speakeasy.new_openapi.SecurityOption1(\n username=\"<USERNAME>\",\n password=\"<PASSWORD>\",\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option2\n\nAll of the following schemes must be satisfied to use the `Option2` alternative:\n\n| Name | Type | Scheme | Environment Variable |\n| ------------- | ------ | ----------- | ----------------------- |\n| `bearer_auth` | http | HTTP Bearer | `SPEAKEASY_BEARER_AUTH` |\n| `api_key` | apiKey | API key | `SPEAKEASY_API_KEY` |\n\n```python\nimport os\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option2=speakeasy.new_openapi.SecurityOption2(\n bearer_auth=\"<YOUR_JWT>\",\n api_key=os.getenv(\"SPEAKEASY_API_KEY\", \"\"),\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option3\n\nThe `Option3` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| -------- | ------ | ------------ | -------------------- |\n| `oauth2` | oauth2 | OAuth2 token | `SPEAKEASY_OAUTH2` |\n\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option3=speakeasy.new_openapi.SecurityOption3(\n oauth2=\"Bearer <YOUR_OAUTH2_TOKEN>\",\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option4\n\nThe `Option4` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| --------------------- | ---- | ----------- | ----------------------------------------- |\n| `app_id`<br/>`secret` | http | Custom HTTP | `SPEAKEASY_APP_ID`<br/>`SPEAKEASY_SECRET` |\n\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option4=speakeasy.new_openapi.SecurityOption4(\n app_id=\"app-speakeasy-123\",\n secret=\"MTIzNDU2Nzg5MDEyMzQ1Njc4OTAxMjM0NTY3ODkwMTI\",\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option5\n\nThe `Option5` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| ------------- | ------ | ------------ | ----------------------- |\n| `mobile_auth` | oauth2 | OAuth2 token | `SPEAKEASY_MOBILE_AUTH` |\n\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option5=speakeasy.new_openapi.SecurityOption5(\n mobile_auth=\"Bearer <YOUR_OAUTH2_TOKEN>\",\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option6\n\nThe `Option6` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| ------------------------------- | ------ | ------------------------------ | ----------------------------------------------------------------------------- |\n| `client_id`<br/>`client_secret` | oauth2 | OAuth2 Client Credentials Flow | `SPEAKEASY_CLIENT_ID`<br/>`SPEAKEASY_CLIENT_SECRET`<br/>`SPEAKEASY_TOKEN_URL` |\n\n```python\nimport os\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option6=speakeasy.new_openapi.SecurityOption6(\n client_id=os.getenv(\"SPEAKEASY_CLIENT_ID\", \"\"),\n client_secret=os.getenv(\"SPEAKEASY_CLIENT_SECRET\", \"\"),\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n#### Option7\n\nThe `Option7` alternative relies on the following scheme:\n\n| Name | Type | Scheme | Environment Variable |\n| --------- | ------ | ------- | -------------------- |\n| `api_key` | apiKey | API key | `SPEAKEASY_API_KEY` |\n\n```python\nimport os\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n security=speakeasy.new_openapi.Security(\n option7=speakeasy.new_openapi.SecurityOption7(\n api_key=os.getenv(\"SPEAKEASY_API_KEY\", \"\"),\n ),\n ),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n<!-- End Authentication [security] -->\n\n<!-- Start Available Resources and Operations [operations] -->\n## Available Resources and Operations\n\n<details open>\n<summary>Available methods</summary>\n\n### [SDK](docs/sdks/sdk/README.md)\n\n* [operation_with_leading_and_trailing_underscores_](docs/sdks/sdk/README.md#operation_with_leading_and_trailing_underscores_)\n* [post_file](docs/sdks/sdk/README.md#post_file) - Post File\n* [get_polymorphism](docs/sdks/sdk/README.md#get_polymorphism)\n* [get_union_errors](docs/sdks/sdk/README.md#get_union_errors)\n* [get_request_body_flattened_away](docs/sdks/sdk/README.md#get_request_body_flattened_away)\n* [get_fully_flattened_request](docs/sdks/sdk/README.md#get_fully_flattened_request)\n* [test_endpoint](docs/sdks/sdk/README.md#test_endpoint)\n* [create_user](docs/sdks/sdk/README.md#create_user) - Create User\n* [get_user](docs/sdks/sdk/README.md#get_user) - Get User\n* [update_user](docs/sdks/sdk/README.md#update_user) - Update User\n* [delete_user](docs/sdks/sdk/README.md#delete_user) - Delete User\n* [login](docs/sdks/sdk/README.md#login) - Login\n* [validate](docs/sdks/sdk/README.md#validate) - Validate\n* [chat](docs/sdks/sdk/README.md#chat)\n* [get_binary_default_response](docs/sdks/sdk/README.md#get_binary_default_response)\n* [test_enum_formats](docs/sdks/sdk/README.md#test_enum_formats) - Test x-speakeasy-enums in different formats\n* [binary_and_string_upload](docs/sdks/sdk/README.md#binary_and_string_upload)\n* [get_error_in_union](docs/sdks/sdk/README.md#get_error_in_union)\n\n### [tag1](docs/sdks/tag1/README.md)\n\n* [~~deprecated1~~](docs/sdks/tag1/README.md#deprecated1) - Deprecated Operation :warning: **Deprecated** Use [get_request_body_flattened_away](docs/sdks/sdk/README.md#get_request_body_flattened_away) instead.\n* [list_test1](docs/sdks/tag1/README.md#list_test1) - Get Test1\n\n### [test_group](docs/sdks/testgroup/README.md)\n\n\n#### [test_group.tag2](docs/sdks/tag2/README.md)\n\n* [post_test](docs/sdks/tag2/README.md#post_test) - Post Test2\n\n#### [test_group.tag3](docs/sdks/tag3/README.md)\n\n* [post_test](docs/sdks/tag3/README.md#post_test) - Post Test2\n\n</details>\n<!-- End Available Resources and Operations [operations] -->\n\n<!-- Start Global Parameters [global-parameters] -->\n## Global Parameters\n\nCertain parameters are configured globally. These parameters may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, These global values will be used as defaults on the operations that use them. When such operations are called, there is a place in each to override the global value, if needed.\n\nFor example, you can set `queryParam1` to `\"some example query param\"` at SDK initialization and then you do not have to pass the same value on calls to operations like `get_request_body_flattened_away`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.\n\n\n### Available Globals\n\nThe following global parameters are available.\nGlobal parameters can also be set via environment variable.\n\n| Name | Type | Description | Environment |\n| ----------------------- | ---- | ---------------------------------------------------------------------------------- | --------------------------------- |\n| query_param1 | str | A long winded, multi-line description<br/>for the query parameter number one.<br/> | SPEAKEASY_QUERY_PARAM1 |\n| deprecated_query_param1 | str | A deprecated description | SPEAKEASY_DEPRECATED_QUERY_PARAM1 |\n| deprecated_query_param2 | str | The deprecated_query_param2 parameter. | SPEAKEASY_DEPRECATED_QUERY_PARAM2 |\n| lone_query_param | str | The lone_query_param parameter. | SPEAKEASY_LONE_QUERY_PARAM |\n\n### Example\n\n```python\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n lone_query_param=\"<value>\",\n query_param1=\"some example query param\",\n deprecated_query_param1=\"some example query param\",\n deprecated_query_param2=\"some example query param\",\n) as sdk:\n\n sdk.get_request_body_flattened_away()\n\n # Use the SDK ...\n\n```\n<!-- End Global Parameters [global-parameters] -->\n\n<!-- Start Server-sent event streaming [eventstream] -->\n## Server-sent event streaming\n\n[Server-sent events][mdn-sse] are used to stream content from certain\noperations. These operations will expose the stream as [Generator][generator] that\ncan be consumed using a simple `for` loop. The loop will\nterminate when the server no longer has any events to send and closes the\nunderlying connection. \n\nThe stream is also a [Context Manager][context-manager] and can be used with the `with` statement and will close the\nunderlying connection when the context is exited.\n\n```python\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK() as sdk:\n\n res = sdk.chat(request={\n \"prompt\": \"What is the largest city in the world?\",\n })\n\n with res as event_stream:\n for event in event_stream:\n # handle event\n print(event, flush=True)\n\n```\n\n[mdn-sse]: https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events\n[generator]: https://book.pythontips.com/en/latest/generators.html\n[context-manager]: https://book.pythontips.com/en/latest/context_managers.html\n<!-- End Server-sent event streaming [eventstream] -->\n\n<!-- Start Pagination [pagination] -->\n## Pagination\n\nSome of the endpoints in this SDK support pagination. To use pagination, you make your SDK calls as usual, but the\nreturned response object will have a `Next` method that can be called to pull down the next group of results. If the\nreturn value of `Next` is `None`, then there are no more pages to be fetched.\n\nHere's an example of one such pagination call:\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n query_param1=\"some example query param\",\n) as sdk:\n\n res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1=\"some example header param\")\n\n while res is not None:\n # Handle items\n\n res = res.next()\n\n```\n<!-- End Pagination [pagination] -->\n\n<!-- Start File uploads [file-upload] -->\n## File uploads\n\nCertain SDK methods accept file objects as part of a request body or multi-part request. It is possible and typically recommended to upload files as a stream rather than reading the entire contents into memory. This avoids excessive memory consumption and potentially crashing with out-of-memory errors when working with very large files. The following example demonstrates how to attach a file stream to a request.\n\n> [!TIP]\n>\n> For endpoints that handle file uploads bytes arrays can also be used. However, using streams is recommended for large files.\n>\n\n```python\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK() as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n<!-- End File uploads [file-upload] -->\n\n<!-- Start Retries [retries] -->\n## Retries\n\nSome 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.\n\nTo change the default retry strategy for a single API call, simply provide a `RetryConfig` object to the call:\n```python\nfrom speakeasy.new_openapi import SDK\nfrom speakeasy.new_openapi.utils import BackoffStrategy, RetryConfig\n\n\nwith SDK() as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n },\n RetryConfig(\"backoff\", BackoffStrategy(1, 50, 1.1, 100), False))\n\n # Handle response\n print(res)\n\n```\n\nIf 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:\n```python\nfrom speakeasy.new_openapi import SDK\nfrom speakeasy.new_openapi.utils import BackoffStrategy, RetryConfig\n\n\nwith SDK(\n retry_config=RetryConfig(\"backoff\", BackoffStrategy(1, 50, 1.1, 100), False),\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n<!-- End Retries [retries] -->\n\n<!-- Start Error Handling [errors] -->\n## Error Handling\n\n[`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py) is the base class for all HTTP error responses. It has the following properties:\n\n| Property | Type | Description |\n| ------------------ | ---------------- | --------------------------------------------------------------------------------------- |\n| `err.message` | `str` | Error message |\n| `err.status_code` | `int` | HTTP response status code eg `404` |\n| `err.headers` | `httpx.Headers` | HTTP response headers |\n| `err.body` | `str` | HTTP body. Can be empty string if no body is returned. |\n| `err.raw_response` | `httpx.Response` | Raw HTTP response |\n| `err.data` | | Optional. Some errors may contain structured data. [See Error Classes](#error-classes). |\n\n### Example\n```python\nfrom speakeasy.new_openapi import SDK, models\n\n\nwith SDK() as sdk:\n res = None\n try:\n\n res = sdk.get_union_errors(page=12)\n\n while res is not None:\n # Handle items\n\n res = res.next()\n\n\n except models.SDKBaseError as e:\n # The base class for HTTP error responses\n print(e.message)\n print(e.status_code)\n print(e.body)\n print(e.headers)\n print(e.raw_response)\n\n # Depending on the method different errors may be thrown\n if isinstance(e, models.ErrorsError):\n print(e.data.error) # str\n print(e.data.code) # int\n```\n\n### Error Classes\n**Primary error:**\n* [`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py): The base class for HTTP error responses.\n\n<details><summary>Less common errors (12)</summary>\n\n<br />\n\n**Network errors:**\n* [`httpx.RequestError`](https://www.python-httpx.org/exceptions/#httpx.RequestError): Base class for request errors.\n * [`httpx.ConnectError`](https://www.python-httpx.org/exceptions/#httpx.ConnectError): HTTP client was unable to make a request to a server.\n * [`httpx.TimeoutException`](https://www.python-httpx.org/exceptions/#httpx.TimeoutException): HTTP request timed out.\n\n\n**Inherit from [`SDKBaseError`](./src/speakeasy/new_openapi/models/sdkbaseerror.py)**:\n* [`ErrorsError`](./src/speakeasy/new_openapi/models/errorserror.py): Applicable to 5 of 22 methods.*\n* [`BadRequestResponseError`](./src/speakeasy/new_openapi/models/badrequestresponseerror.py): Bad Request. Status code `400`. Applicable to 2 of 22 methods.*\n* [`TaggedError1`](./src/speakeasy/new_openapi/models/taggederror1.py): Applicable to 2 of 22 methods.*\n* [`TaggedError2`](./src/speakeasy/new_openapi/models/taggederror2.py): Something went wrong. Status code `4XX`. Applicable to 1 of 22 methods.*\n* [`ErrorType1`](./src/speakeasy/new_openapi/models/errortype1.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*\n* [`ErrorType2`](./src/speakeasy/new_openapi/models/errortype2.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*\n* [`Test2ResponseError`](./src/speakeasy/new_openapi/models/test2responseerror.py): Internal Server Error. Status code `500`. Applicable to 1 of 22 methods.*\n* [`ResponseValidationError`](./src/speakeasy/new_openapi/models/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute.\n\n</details>\n\n\\* Check [the method documentation](#available-resources-and-operations) to see if the error is applicable.\n<!-- End Error Handling [errors] -->\n\n<!-- Start Server Selection [server] -->\n## Server Selection\n\n### Select Server by Index\n\nYou can override the default server globally by passing a server index to the `server_idx: int` optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the indexes associated with the available servers:\n\n| # | Server | Variables | Description |\n| --- | ------------------------------------------ | ------------------------- | ------------------------------- |\n| 0 | `http://localhost:35123` | | The default server. |\n| 1 | `http://{subdomain}.domain.com/v{version}` | `subdomain`<br/>`version` | |\n| 2 | `http://{HostName}:{PORT}` | `HostName`<br/>`PORT` | A server with an enum variable. |\n\nIf the selected server has variables, you may override its default values through the additional parameters made available in the SDK constructor:\n\n| Variable | Parameter | Supported Values | Default | Description |\n| ----------- | ------------------------- | ------------------------------------- | ------------- | ---------------------------------------- |\n| `subdomain` | `subdomain: str` | str | `\"api\"` | |\n| `version` | `version: str` | str | `\"1\"` | |\n| `HostName` | `host_name: str` | str | `\"localhost\"` | The hostname of the server. |\n| `PORT` | `port: models.ServerPORT` | - `\"80\"`<br/>- `\"8080\"`<br/>- `\"443\"` | `\"8080\"` | The port on which the server is running. |\n\n#### Example\n\n```python\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n server_idx=2,\n host_name=\"heavy-bowler.org\"\n port=\"443\"\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n### Override Server URL Per-Client\n\nThe default server can also be overridden globally by passing a URL to the `server_url: str` optional parameter when initializing the SDK client instance. For example:\n```python\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n server_url=\"http://localhost:8080\",\n) as sdk:\n\n res = sdk.post_file(request={\n \"file\": {\n \"file_name\": \"example.file\",\n \"content\": open(\"example.file\", \"rb\"),\n },\n })\n\n # Handle response\n print(res)\n\n```\n\n### Override Server URL Per-Operation\n\nThe server URL can also be overridden on a per-operation basis, provided a server list was specified for the operation. For example:\n```python\nimport speakeasy.new_openapi\nfrom speakeasy.new_openapi import SDK\n\n\nwith SDK(\n query_param1=\"some example query param\",\n) as sdk:\n\n res = sdk.tag1.list_test1(query_param2=speakeasy.new_openapi.QueryParam2.ONE, page=100, header_param1=\"some example header param\", server_url=\"http://localhost:35123\")\n\n while res is not None:\n # Handle items\n\n res = res.next()\n\n```\n<!-- End Server Selection [server] -->\n\n<!-- Start Custom HTTP Client [http-client] -->\n## Custom HTTP Client\n\nThe Python SDK makes API calls using the [httpx](https://www.python-httpx.org/) HTTP library. In order to provide a convenient way to configure timeouts, cookies, proxies, custom headers, and other low-level configuration, you can initialize the SDK client with your own HTTP client instance.\nDepending on whether you are using the sync or async version of the SDK, you can pass an instance of `HttpClient` or `AsyncHttpClient` respectively, which are Protocol's ensuring that the client has the necessary methods to make API calls.\nThis allows you to wrap the client with your own custom logic, such as adding custom headers, logging, or error handling, or you can just pass an instance of `httpx.Client` or `httpx.AsyncClient` directly.\n\nFor example, you could specify a header for every request that this sdk makes as follows:\n```python\nfrom speakeasy.new_openapi import SDK\nimport httpx\n\nhttp_client = httpx.Client(headers={\"x-custom-header\": \"someValue\"})\ns = SDK(client=http_client)\n```\n\nor you could wrap the client with your own custom logic:\n```python\nfrom speakeasy.new_openapi import SDK\nfrom speakeasy.new_openapi.httpclient import AsyncHttpClient\nimport httpx\n\nclass CustomClient(AsyncHttpClient):\n client: AsyncHttpClient\n\n def __init__(self, client: AsyncHttpClient):\n self.client = client\n\n async def send(\n self,\n request: httpx.Request,\n *,\n stream: bool = False,\n auth: Union[\n httpx._types.AuthTypes, httpx._client.UseClientDefault, None\n ] = httpx.USE_CLIENT_DEFAULT,\n follow_redirects: Union[\n bool, httpx._client.UseClientDefault\n ] = httpx.USE_CLIENT_DEFAULT,\n ) -> httpx.Response:\n request.headers[\"Client-Level-Header\"] = \"added by client\"\n\n return await self.client.send(\n request, stream=stream, auth=auth, follow_redirects=follow_redirects\n )\n\n def build_request(\n self,\n method: str,\n url: httpx._types.URLTypes,\n *,\n content: Optional[httpx._types.RequestContent] = None,\n data: Optional[httpx._types.RequestData] = None,\n files: Optional[httpx._types.RequestFiles] = None,\n json: Optional[Any] = None,\n params: Optional[httpx._types.QueryParamTypes] = None,\n headers: Optional[httpx._types.HeaderTypes] = None,\n cookies: Optional[httpx._types.CookieTypes] = None,\n timeout: Union[\n httpx._types.TimeoutTypes, httpx._client.UseClientDefault\n ] = httpx.USE_CLIENT_DEFAULT,\n extensions: Optional[httpx._types.RequestExtensions] = None,\n ) -> httpx.Request:\n return self.client.build_request(\n method,\n url,\n content=content,\n data=data,\n files=files,\n json=json,\n params=params,\n headers=headers,\n cookies=cookies,\n timeout=timeout,\n extensions=extensions,\n )\n\ns = SDK(async_client=CustomClient(httpx.AsyncClient()))\n```\n<!-- End Custom HTTP Client [http-client] -->\n\n<!-- Start Resource Management [resource-management] -->\n## Resource Management\n\nThe `SDK` class implements the context manager protocol and registers a finalizer function to close the underlying sync and async HTTPX clients it uses under the hood. This will close HTTP connections, release memory and free up other resources held by the SDK. In short-lived Python programs and notebooks that make a few SDK method calls, resource management may not be a concern. However, in longer-lived programs, it is beneficial to create a single SDK instance via a [context manager][context-manager] and reuse it across the application.\n\n[context-manager]: https://docs.python.org/3/reference/datamodel.html#context-managers\n\n```python\nfrom speakeasy.new_openapi import SDK\ndef main():\n\n with SDK() as sdk:\n # Rest of application here...\n\n\n# Or when using async:\nasync def amain():\n\n async with SDK() as sdk:\n # Rest of application here...\n```\n<!-- End Resource Management [resource-management] -->\n\n<!-- Start Debugging [debug] -->\n## Debugging\n\nYou can setup your SDK to emit debug logs for SDK requests and responses.\n\nYou can pass your own logger class directly into your SDK.\n```python\nfrom speakeasy.new_openapi import SDK\nimport logging\n\nlogging.basicConfig(level=logging.DEBUG)\ns = SDK(debug_logger=logging.getLogger(\"speakeasy.new_openapi\"))\n```\n\nYou can also enable a default debug logger by setting an environment variable `SPEAKEASY_DEBUG` to true.\n<!-- End Debugging [debug] -->\n\n<!-- Placeholder for Future Speakeasy SDK Sections -->\n\n# Development\n\n## Maturity\n\nThis SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage\nto a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally\nlooking for the latest version.\n\n## Contributions\n\nWhile we value open-source contributions to this SDK, this library is generated programmatically. Any manual changes added to internal files will be overwritten on the next generation. \nWe look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release. \n\n### SDK Created by [Speakeasy](https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python)\n",
"bugtrack_url": null,
"license": null,
"summary": "Python Client SDK Generated by Speakeasy.",
"version": "0.0.1",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "75e7302d221a124c8c126cade752be3829dd4442753ca8d7de14f21ad54cad72",
"md5": "fdd2fda927a05f82ef145e91450ab83a",
"sha256": "d9bd384ff02a135d2df190c063c5e7d62b1a72f2c1b931765db713a9dc7a51d4"
},
"downloads": -1,
"filename": "closedapi_test_pythonv2-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "fdd2fda927a05f82ef145e91450ab83a",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9.2",
"size": 93439,
"upload_time": "2025-08-06T13:26:01",
"upload_time_iso_8601": "2025-08-06T13:26:01.156599Z",
"url": "https://files.pythonhosted.org/packages/75/e7/302d221a124c8c126cade752be3829dd4442753ca8d7de14f21ad54cad72/closedapi_test_pythonv2-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-06 13:26:01",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "closedapi_test_pythonv2"
}