cliV1 0.0.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (92) hide show
  1. cliv1-0.0.6.dist-info/METADATA +212 -0
  2. cliv1-0.0.6.dist-info/RECORD +92 -0
  3. cliv1-0.0.6.dist-info/WHEEL +4 -0
  4. cliv1-0.0.6.dist-info/licenses/LICENSE +21 -0
  5. swagger_petstore_open_api_3_1_0/__init__.py +15 -0
  6. swagger_petstore_open_api_3_1_0/apis/__init__.py +5 -0
  7. swagger_petstore_open_api_3_1_0/apis/pet_api.py +922 -0
  8. swagger_petstore_open_api_3_1_0/apis/store.py +432 -0
  9. swagger_petstore_open_api_3_1_0/apis/user_api.py +829 -0
  10. swagger_petstore_open_api_3_1_0/async_client.py +87 -0
  11. swagger_petstore_open_api_3_1_0/auth.py +17 -0
  12. swagger_petstore_open_api_3_1_0/base_client.py +27 -0
  13. swagger_petstore_open_api_3_1_0/client.py +85 -0
  14. swagger_petstore_open_api_3_1_0/core/__init__.py +395 -0
  15. swagger_petstore_open_api_3_1_0/core/_internal/__init__.py +9 -0
  16. swagger_petstore_open_api_3_1_0/core/_internal/content_disposition.py +154 -0
  17. swagger_petstore_open_api_3_1_0/core/_internal/flattening.py +104 -0
  18. swagger_petstore_open_api_3_1_0/core/_internal/headers.py +243 -0
  19. swagger_petstore_open_api_3_1_0/core/_internal/redaction.py +208 -0
  20. swagger_petstore_open_api_3_1_0/core/_internal/sse_parser.py +124 -0
  21. swagger_petstore_open_api_3_1_0/core/_internal/subscripts.py +50 -0
  22. swagger_petstore_open_api_3_1_0/core/_internal/urls.py +172 -0
  23. swagger_petstore_open_api_3_1_0/core/_internal/wire.py +201 -0
  24. swagger_petstore_open_api_3_1_0/core/adapters.py +177 -0
  25. swagger_petstore_open_api_3_1_0/core/auth/__init__.py +70 -0
  26. swagger_petstore_open_api_3_1_0/core/auth/composition.py +175 -0
  27. swagger_petstore_open_api_3_1_0/core/auth/models.py +216 -0
  28. swagger_petstore_open_api_3_1_0/core/auth/protocols.py +103 -0
  29. swagger_petstore_open_api_3_1_0/core/auth/schemes/__init__.py +94 -0
  30. swagger_petstore_open_api_3_1_0/core/auth/schemes/api_key_auth.py +53 -0
  31. swagger_petstore_open_api_3_1_0/core/auth/schemes/basic_auth.py +73 -0
  32. swagger_petstore_open_api_3_1_0/core/auth/schemes/bearer_auth.py +21 -0
  33. swagger_petstore_open_api_3_1_0/core/auth/schemes/oauth2_authorization_code.py +395 -0
  34. swagger_petstore_open_api_3_1_0/core/auth/schemes/oauth2_client_credentials.py +130 -0
  35. swagger_petstore_open_api_3_1_0/core/auth/schemes/oauth2_password.py +145 -0
  36. swagger_petstore_open_api_3_1_0/core/auth/schemes/oauth2_schemes.py +300 -0
  37. swagger_petstore_open_api_3_1_0/core/base_raw_response.py +49 -0
  38. swagger_petstore_open_api_3_1_0/core/bodies.py +590 -0
  39. swagger_petstore_open_api_3_1_0/core/converters/__init__.py +68 -0
  40. swagger_petstore_open_api_3_1_0/core/converters/date_time.py +237 -0
  41. swagger_petstore_open_api_3_1_0/core/converters/encoded_bytes.py +273 -0
  42. swagger_petstore_open_api_3_1_0/core/converters/open_enum.py +35 -0
  43. swagger_petstore_open_api_3_1_0/core/decoding.py +498 -0
  44. swagger_petstore_open_api_3_1_0/core/discriminators.py +129 -0
  45. swagger_petstore_open_api_3_1_0/core/event_streams.py +225 -0
  46. swagger_petstore_open_api_3_1_0/core/exceptions.py +78 -0
  47. swagger_petstore_open_api_3_1_0/core/file_responses.py +337 -0
  48. swagger_petstore_open_api_3_1_0/core/files.py +174 -0
  49. swagger_petstore_open_api_3_1_0/core/httpx2_transport.py +748 -0
  50. swagger_petstore_open_api_3_1_0/core/logging.py +472 -0
  51. swagger_petstore_open_api_3_1_0/core/models.py +143 -0
  52. swagger_petstore_open_api_3_1_0/core/optionality.py +144 -0
  53. swagger_petstore_open_api_3_1_0/core/pagination.py +452 -0
  54. swagger_petstore_open_api_3_1_0/core/paginator.py +55 -0
  55. swagger_petstore_open_api_3_1_0/core/params.py +157 -0
  56. swagger_petstore_open_api_3_1_0/core/raw_client.py +480 -0
  57. swagger_petstore_open_api_3_1_0/core/request_options.py +172 -0
  58. swagger_petstore_open_api_3_1_0/core/results.py +178 -0
  59. swagger_petstore_open_api_3_1_0/core/retries.py +237 -0
  60. swagger_petstore_open_api_3_1_0/core/runtime_env.py +43 -0
  61. swagger_petstore_open_api_3_1_0/core/servers.py +33 -0
  62. swagger_petstore_open_api_3_1_0/core/transport.py +218 -0
  63. swagger_petstore_open_api_3_1_0/errors/__init__.py +48 -0
  64. swagger_petstore_open_api_3_1_0/errors/add_pet_error.py +21 -0
  65. swagger_petstore_open_api_3_1_0/errors/delete_order_error.py +21 -0
  66. swagger_petstore_open_api_3_1_0/errors/delete_pet_error.py +21 -0
  67. swagger_petstore_open_api_3_1_0/errors/delete_user_error.py +21 -0
  68. swagger_petstore_open_api_3_1_0/errors/find_pets_by_status_error.py +21 -0
  69. swagger_petstore_open_api_3_1_0/errors/find_pets_by_tags_error.py +21 -0
  70. swagger_petstore_open_api_3_1_0/errors/get_order_by_id_error.py +21 -0
  71. swagger_petstore_open_api_3_1_0/errors/get_pet_by_id_error.py +21 -0
  72. swagger_petstore_open_api_3_1_0/errors/get_user_by_name_error.py +21 -0
  73. swagger_petstore_open_api_3_1_0/errors/login_user_error.py +21 -0
  74. swagger_petstore_open_api_3_1_0/errors/place_order_error.py +21 -0
  75. swagger_petstore_open_api_3_1_0/errors/update_pet_error.py +21 -0
  76. swagger_petstore_open_api_3_1_0/errors/update_pet_with_form_error.py +21 -0
  77. swagger_petstore_open_api_3_1_0/errors/update_user_error.py +21 -0
  78. swagger_petstore_open_api_3_1_0/errors/upload_file_error.py +21 -0
  79. swagger_petstore_open_api_3_1_0/models/__init__.py +23 -0
  80. swagger_petstore_open_api_3_1_0/models/api_response.py +18 -0
  81. swagger_petstore_open_api_3_1_0/models/category.py +15 -0
  82. swagger_petstore_open_api_3_1_0/models/enums/__init__.py +4 -0
  83. swagger_petstore_open_api_3_1_0/models/enums/order_status.py +17 -0
  84. swagger_petstore_open_api_3_1_0/models/enums/pet_status.py +17 -0
  85. swagger_petstore_open_api_3_1_0/models/order.py +27 -0
  86. swagger_petstore_open_api_3_1_0/models/pet.py +28 -0
  87. swagger_petstore_open_api_3_1_0/models/tag_model.py +15 -0
  88. swagger_petstore_open_api_3_1_0/models/user.py +29 -0
  89. swagger_petstore_open_api_3_1_0/py.typed +0 -0
  90. swagger_petstore_open_api_3_1_0/server/__init__.py +21 -0
  91. swagger_petstore_open_api_3_1_0/server/server.py +17 -0
  92. swagger_petstore_open_api_3_1_0/server/server_config.py +52 -0
@@ -0,0 +1,87 @@
1
+ from __future__ import annotations
2
+
3
+ from functools import cached_property
4
+ from types import TracebackType
5
+
6
+ from typing_extensions import Self
7
+
8
+ from .apis.pet_api import AsyncPetApi
9
+ from .apis.store import AsyncStore
10
+ from .apis.user_api import AsyncUserApi
11
+ from .auth import AsyncAuthSchemes
12
+ from .base_client import DEFAULT_TIMEOUT, BaseSwaggerPetstoreOpenApi310Client
13
+ from .core import (
14
+ OPERATING_SYSTEM,
15
+ PYTHON_RUNTIME,
16
+ ApiKeyHeaderScheme,
17
+ AsyncHttpClient,
18
+ AsyncHttpx2Client,
19
+ AsyncRawClient,
20
+ LoggingOptionsOrDict,
21
+ RetryOptionsOrDict,
22
+ no_auth,
23
+ param,
24
+ )
25
+ from .server.server_config import ServerConfigOrDict
26
+
27
+
28
+ class AsyncSwaggerPetstoreOpenApi310Client(BaseSwaggerPetstoreOpenApi310Client[AsyncRawClient]):
29
+ def __init__(
30
+ self,
31
+ *,
32
+ server_config: ServerConfigOrDict | None = None,
33
+ timeout: float = DEFAULT_TIMEOUT,
34
+ retry_options: int | RetryOptionsOrDict | None = None,
35
+ logging_options: LoggingOptionsOrDict | None = None,
36
+ custom_async_http_client: AsyncHttpClient | None = None,
37
+ petstore_auth: str | None = None,
38
+ api_key: str | None = None,
39
+ ) -> None:
40
+ super().__init__(
41
+ server_config=server_config, timeout=timeout, retry_options=retry_options, logging_options=logging_options
42
+ )
43
+ self._raw_client = AsyncRawClient(
44
+ http_client=(
45
+ custom_async_http_client if custom_async_http_client is not None else AsyncHttpx2Client(timeout=timeout)
46
+ ),
47
+ retry_options=self._retry_options,
48
+ logging_options=self._logging_options,
49
+ global_headers=[
50
+ param[str]("User-Agent", "SwaggerPetstoreOpenApi310Client/1.0.26 Python"),
51
+ param[str]("X-APIMatic-Lang", "Python"),
52
+ param[str]("X-APIMatic-Package-Version", "1.0.26"),
53
+ param[str]("X-APIMatic-Gen-Version", "4.0.0"),
54
+ param[str]("X-APIMatic-OS", OPERATING_SYSTEM),
55
+ param[str]("X-APIMatic-Runtime", PYTHON_RUNTIME),
56
+ ],
57
+ )
58
+ self._auth = AsyncAuthSchemes(
59
+ petstore_auth=ApiKeyHeaderScheme("Authorization", petstore_auth) if petstore_auth is not None else no_auth,
60
+ api_key=ApiKeyHeaderScheme("api_key", api_key) if api_key is not None else no_auth,
61
+ )
62
+
63
+ @cached_property
64
+ def pet_api(self) -> AsyncPetApi:
65
+ return AsyncPetApi(self._raw_client, self._server, self._auth)
66
+
67
+ @cached_property
68
+ def store(self) -> AsyncStore:
69
+ return AsyncStore(self._raw_client, self._server, self._auth)
70
+
71
+ @cached_property
72
+ def user_api(self) -> AsyncUserApi:
73
+ return AsyncUserApi(self._raw_client, self._server)
74
+
75
+ async def aclose(self) -> None:
76
+ await self._raw_client.http_client.aclose()
77
+
78
+ async def __aenter__(self) -> Self:
79
+ return self
80
+
81
+ async def __aexit__(
82
+ self, exc_type: type[BaseException] | None, exc: BaseException | None, exc_tb: TracebackType | None
83
+ ) -> None:
84
+ await self.aclose()
85
+
86
+
87
+ AsyncClient = AsyncSwaggerPetstoreOpenApi310Client
@@ -0,0 +1,17 @@
1
+ from __future__ import annotations
2
+
3
+ from dataclasses import dataclass
4
+
5
+ from .core import AsyncAuthScheme, AuthScheme
6
+
7
+
8
+ @dataclass(frozen=True, slots=True, kw_only=True)
9
+ class AuthSchemes:
10
+ petstore_auth: AuthScheme
11
+ api_key: AuthScheme
12
+
13
+
14
+ @dataclass(frozen=True, slots=True, kw_only=True)
15
+ class AsyncAuthSchemes:
16
+ petstore_auth: AsyncAuthScheme
17
+ api_key: AsyncAuthScheme
@@ -0,0 +1,27 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Generic
4
+
5
+ from .core import LoggingOptions, LoggingOptionsOrDict, RawClientT, RetryOptions, RetryOptionsOrDict
6
+ from .server.server import Server
7
+ from .server.server_config import ServerConfig, ServerConfigOrDict
8
+
9
+ DEFAULT_TIMEOUT = 30.0
10
+
11
+
12
+ class BaseSwaggerPetstoreOpenApi310Client(Generic[RawClientT]):
13
+ _raw_client: RawClientT
14
+
15
+ def __init__(
16
+ self,
17
+ *,
18
+ server_config: ServerConfigOrDict | None = None,
19
+ timeout: float = DEFAULT_TIMEOUT,
20
+ retry_options: int | RetryOptionsOrDict | None = None,
21
+ logging_options: LoggingOptionsOrDict | None = None,
22
+ ) -> None:
23
+ if not timeout > 0:
24
+ raise ValueError(f"timeout must be greater than 0; got {timeout!r}")
25
+ self._server = Server(ServerConfig.coerce(server_config))
26
+ self._retry_options = RetryOptions.coerce(retry_options)
27
+ self._logging_options = LoggingOptions.coerce(logging_options, package="swagger_petstore_open_api_3_1_0")
@@ -0,0 +1,85 @@
1
+ from __future__ import annotations
2
+
3
+ from functools import cached_property
4
+ from types import TracebackType
5
+
6
+ from typing_extensions import Self
7
+
8
+ from .apis.pet_api import PetApi
9
+ from .apis.store import Store
10
+ from .apis.user_api import UserApi
11
+ from .auth import AuthSchemes
12
+ from .base_client import DEFAULT_TIMEOUT, BaseSwaggerPetstoreOpenApi310Client
13
+ from .core import (
14
+ OPERATING_SYSTEM,
15
+ PYTHON_RUNTIME,
16
+ ApiKeyHeaderScheme,
17
+ HttpClient,
18
+ Httpx2Client,
19
+ LoggingOptionsOrDict,
20
+ RawClient,
21
+ RetryOptionsOrDict,
22
+ no_auth,
23
+ param,
24
+ )
25
+ from .server.server_config import ServerConfigOrDict
26
+
27
+
28
+ class SwaggerPetstoreOpenApi310Client(BaseSwaggerPetstoreOpenApi310Client[RawClient]):
29
+ def __init__(
30
+ self,
31
+ *,
32
+ server_config: ServerConfigOrDict | None = None,
33
+ timeout: float = DEFAULT_TIMEOUT,
34
+ retry_options: int | RetryOptionsOrDict | None = None,
35
+ logging_options: LoggingOptionsOrDict | None = None,
36
+ custom_http_client: HttpClient | None = None,
37
+ petstore_auth: str | None = None,
38
+ api_key: str | None = None,
39
+ ) -> None:
40
+ super().__init__(
41
+ server_config=server_config, timeout=timeout, retry_options=retry_options, logging_options=logging_options
42
+ )
43
+ self._raw_client = RawClient(
44
+ http_client=custom_http_client if custom_http_client is not None else Httpx2Client(timeout=timeout),
45
+ retry_options=self._retry_options,
46
+ logging_options=self._logging_options,
47
+ global_headers=[
48
+ param[str]("User-Agent", "SwaggerPetstoreOpenApi310Client/1.0.26 Python"),
49
+ param[str]("X-APIMatic-Lang", "Python"),
50
+ param[str]("X-APIMatic-Package-Version", "1.0.26"),
51
+ param[str]("X-APIMatic-Gen-Version", "4.0.0"),
52
+ param[str]("X-APIMatic-OS", OPERATING_SYSTEM),
53
+ param[str]("X-APIMatic-Runtime", PYTHON_RUNTIME),
54
+ ],
55
+ )
56
+ self._auth = AuthSchemes(
57
+ petstore_auth=ApiKeyHeaderScheme("Authorization", petstore_auth) if petstore_auth is not None else no_auth,
58
+ api_key=ApiKeyHeaderScheme("api_key", api_key) if api_key is not None else no_auth,
59
+ )
60
+
61
+ @cached_property
62
+ def pet_api(self) -> PetApi:
63
+ return PetApi(self._raw_client, self._server, self._auth)
64
+
65
+ @cached_property
66
+ def store(self) -> Store:
67
+ return Store(self._raw_client, self._server, self._auth)
68
+
69
+ @cached_property
70
+ def user_api(self) -> UserApi:
71
+ return UserApi(self._raw_client, self._server)
72
+
73
+ def close(self) -> None:
74
+ self._raw_client.http_client.close()
75
+
76
+ def __enter__(self) -> Self:
77
+ return self
78
+
79
+ def __exit__(
80
+ self, exc_type: type[BaseException] | None, exc: BaseException | None, exc_tb: TracebackType | None
81
+ ) -> None:
82
+ self.close()
83
+
84
+
85
+ Client = SwaggerPetstoreOpenApi310Client
@@ -0,0 +1,395 @@
1
+ """Public surface of the SDK runtime.
2
+
3
+ Everything the generated layers (``api/``, ``models/``, ``errors/``, ``server/``, the two clients)
4
+ need from the runtime is re-exported here, so a generated module imports from one place --
5
+ ``from <sdk>.core import ApiResult, RawClient, json_decoder`` -- instead of reaching into the
6
+ runtime's internal module layout. That indirection is the point: the modules behind this facade are
7
+ free to move without touching a single generated file.
8
+
9
+ A symbol earns a place here by one test: a generator may emit it, or a caller may need to name it.
10
+ Internal machinery the runtime only calls itself -- the adapter cache, the decoder implementation
11
+ classes, the sentinel stripper -- is deliberately absent, and remains reachable at its own module
12
+ path for the unit tests that target it.
13
+
14
+ Everything remains importable from its fully-qualified module path as well."""
15
+
16
+ from ._internal.headers import find_link_target, read_header
17
+ from .auth import (
18
+ AllSchemes,
19
+ AnySchemes,
20
+ AsyncAllSchemes,
21
+ AsyncAnySchemes,
22
+ AsyncAuthScheme,
23
+ AsyncRefreshableTokenSource,
24
+ AsyncTokenSource,
25
+ AuthParams,
26
+ AuthScheme,
27
+ OAuthError,
28
+ OAuthProviderError,
29
+ OAuthToken,
30
+ OAuthTokenRefreshable,
31
+ RefreshableTokenSource,
32
+ RevocableAuthScheme,
33
+ TokenSource,
34
+ client_secret_basic,
35
+ client_secret_post,
36
+ invalidate,
37
+ is_configured,
38
+ no_auth,
39
+ oauth_error_response,
40
+ resolve_auth,
41
+ )
42
+ from .auth.schemes import (
43
+ ApiKeyCookieScheme,
44
+ ApiKeyHeaderScheme,
45
+ ApiKeyQueryScheme,
46
+ AsyncAuthorizationCodeCredentials,
47
+ AsyncAuthorizationCodeCredentialsDict,
48
+ AsyncAuthorizationCodeCredentialsOrDict,
49
+ AsyncAuthorizationCodePrompt,
50
+ AsyncAuthorizationCodeTokenSource,
51
+ AsyncClientCredentialsTokenSource,
52
+ AsyncOAuth2RefreshableScheme,
53
+ AsyncOAuth2Scheme,
54
+ AsyncPasswordTokenSource,
55
+ AuthorizationCodeCredentials,
56
+ AuthorizationCodeCredentialsDict,
57
+ AuthorizationCodeCredentialsOrDict,
58
+ AuthorizationCodePrompt,
59
+ AuthorizationCodeTokenSource,
60
+ BasicAuthCredentials,
61
+ BasicAuthCredentialsDict,
62
+ BasicAuthCredentialsOrDict,
63
+ BasicAuthScheme,
64
+ BearerAuthScheme,
65
+ ClientCredentials,
66
+ ClientCredentialsDict,
67
+ ClientCredentialsOrDict,
68
+ ClientCredentialsTokenSource,
69
+ OAuth2RefreshableScheme,
70
+ OAuth2Scheme,
71
+ PasswordCredentials,
72
+ PasswordCredentialsDict,
73
+ PasswordCredentialsOrDict,
74
+ PasswordTokenSource,
75
+ PkceMethod,
76
+ )
77
+ from .base_raw_response import BaseRawResponse, SecuredRawResponse
78
+ from .bodies import (
79
+ BinaryBody,
80
+ FormBody,
81
+ JsonBody,
82
+ MultipartBody,
83
+ MultipartFile,
84
+ MultipartPart,
85
+ MultipartText,
86
+ RequestBody,
87
+ TextBody,
88
+ binary_body,
89
+ file_part,
90
+ form_body,
91
+ json_body,
92
+ json_part,
93
+ multipart_body,
94
+ text_body,
95
+ )
96
+ from .converters import (
97
+ Base16AsciiEncodedBytes,
98
+ Base16Cp1252EncodedBytes,
99
+ Base16Latin1EncodedBytes,
100
+ Base16Utf8EncodedBytes,
101
+ Base32AsciiEncodedBytes,
102
+ Base32Cp1252EncodedBytes,
103
+ Base32HexAsciiEncodedBytes,
104
+ Base32HexCp1252EncodedBytes,
105
+ Base32HexLatin1EncodedBytes,
106
+ Base32HexUtf8EncodedBytes,
107
+ Base32Latin1EncodedBytes,
108
+ Base32Utf8EncodedBytes,
109
+ Base64AsciiEncodedBytes,
110
+ Base64Cp1252EncodedBytes,
111
+ Base64Latin1EncodedBytes,
112
+ Base64UrlAsciiEncodedBytes,
113
+ Base64UrlCp1252EncodedBytes,
114
+ Base64UrlLatin1EncodedBytes,
115
+ Base64UrlUtf8EncodedBytes,
116
+ Base64Utf8EncodedBytes,
117
+ ByteField,
118
+ Date,
119
+ RFC1123DateTime,
120
+ RFC3339DateTime,
121
+ UnixSecondsDateTime,
122
+ open_enum_validator,
123
+ )
124
+ from .decoding import (
125
+ AsyncResponseDecoder,
126
+ ErrorMapper,
127
+ ResponseDecoder,
128
+ async_empty_response,
129
+ async_file_decoder,
130
+ async_json_decoder,
131
+ async_json_event_decoder,
132
+ async_text_decoder,
133
+ async_text_event_decoder,
134
+ decode_json,
135
+ decode_text,
136
+ empty_response,
137
+ file_decoder,
138
+ json_decoder,
139
+ json_event_decoder,
140
+ raw_error_response,
141
+ text_decoder,
142
+ text_event_decoder,
143
+ )
144
+ from .discriminators import WireDiscriminator
145
+ from .event_streams import AsyncEventStream, EventStream
146
+ from .exceptions import ApiError, TransportError
147
+ from .file_responses import AsyncFileResponse, FileResponse
148
+ from .files import (
149
+ AsyncBinaryContent,
150
+ AsyncBinaryReader,
151
+ AsyncFileInput,
152
+ BinaryContent,
153
+ BinaryReader,
154
+ FileInput,
155
+ NamedFile,
156
+ )
157
+ from .httpx2_transport import AsyncHttpx2Client, Httpx2Client
158
+ from .logging import LoggingOptions, LoggingOptionsDict, LoggingOptionsOrDict
159
+ from .models import SdkBaseModel
160
+ from .optionality import UNSET, Optional, OptionalNullable, UnsetType
161
+ from .pagination import (
162
+ async_paginate,
163
+ cursor_state,
164
+ keyset_state,
165
+ link_state,
166
+ offset_state,
167
+ page_state,
168
+ paginate,
169
+ )
170
+ from .paginator import AsyncPaginator, Paginator
171
+ from .params import SerializationFormat, UrlTemplate, param
172
+ from .raw_client import (
173
+ AsyncRawClient,
174
+ RawClient,
175
+ RawClientT,
176
+ )
177
+ from .request_options import RequestOptions, RequestOptionsDict, RequestOptionsOrDict
178
+ from .results import ApiResult, Failure, RawError, Success, unwrap
179
+ from .retries import RetryOptions, RetryOptionsDict, RetryOptionsOrDict
180
+ from .runtime_env import OPERATING_SYSTEM, PYTHON_RUNTIME
181
+ from .servers import validate_one_of
182
+ from .transport import (
183
+ AsyncHttpClient,
184
+ AsyncHttpResponse,
185
+ HttpClient,
186
+ HttpMethod,
187
+ HttpRequest,
188
+ HttpResponse,
189
+ )
190
+
191
+ __all__ = [
192
+ # Result and error types
193
+ "ApiResult",
194
+ "Success",
195
+ "Failure",
196
+ "unwrap",
197
+ "RawError",
198
+ "ApiError",
199
+ "TransportError",
200
+ # HTTP transport
201
+ "HttpClient",
202
+ "AsyncHttpClient",
203
+ "HttpMethod",
204
+ "HttpRequest",
205
+ "HttpResponse",
206
+ "AsyncHttpResponse",
207
+ "Httpx2Client",
208
+ "AsyncHttpx2Client",
209
+ # Request parameters and bodies
210
+ "param",
211
+ "SerializationFormat",
212
+ "UrlTemplate",
213
+ "RequestBody",
214
+ "JsonBody",
215
+ "json_body",
216
+ "FormBody",
217
+ "form_body",
218
+ "MultipartBody",
219
+ "multipart_body",
220
+ "MultipartPart",
221
+ "MultipartText",
222
+ "MultipartFile",
223
+ "file_part",
224
+ "json_part",
225
+ "BinaryBody",
226
+ "binary_body",
227
+ "TextBody",
228
+ "text_body",
229
+ # File input
230
+ "BinaryReader",
231
+ "AsyncBinaryReader",
232
+ "BinaryContent",
233
+ "AsyncBinaryContent",
234
+ "NamedFile",
235
+ "FileInput",
236
+ "AsyncFileInput",
237
+ # Streamed payloads
238
+ "FileResponse",
239
+ "AsyncFileResponse",
240
+ "EventStream",
241
+ "AsyncEventStream",
242
+ # Per-call request options
243
+ "RequestOptions",
244
+ "RequestOptionsDict",
245
+ "RequestOptionsOrDict",
246
+ # Retries
247
+ "RetryOptions",
248
+ "RetryOptionsDict",
249
+ "RetryOptionsOrDict",
250
+ # Logging
251
+ "LoggingOptions",
252
+ "LoggingOptionsDict",
253
+ "LoggingOptionsOrDict",
254
+ # Authentication
255
+ "AuthParams",
256
+ "AuthScheme",
257
+ "AsyncAuthScheme",
258
+ "no_auth",
259
+ "is_configured",
260
+ "resolve_auth",
261
+ "BasicAuthCredentials",
262
+ "BasicAuthCredentialsDict",
263
+ "BasicAuthCredentialsOrDict",
264
+ "BasicAuthScheme",
265
+ "BearerAuthScheme",
266
+ "ApiKeyHeaderScheme",
267
+ "ApiKeyQueryScheme",
268
+ "ApiKeyCookieScheme",
269
+ "AnySchemes",
270
+ "AsyncAnySchemes",
271
+ "AllSchemes",
272
+ "AsyncAllSchemes",
273
+ "RevocableAuthScheme",
274
+ "invalidate",
275
+ # Managed OAuth 2.0
276
+ "OAuth2Scheme",
277
+ "AsyncOAuth2Scheme",
278
+ "OAuth2RefreshableScheme",
279
+ "AsyncOAuth2RefreshableScheme",
280
+ "TokenSource",
281
+ "AsyncTokenSource",
282
+ "RefreshableTokenSource",
283
+ "AsyncRefreshableTokenSource",
284
+ "client_secret_basic",
285
+ "client_secret_post",
286
+ "OAuthToken",
287
+ "OAuthTokenRefreshable",
288
+ "OAuthProviderError",
289
+ "OAuthError",
290
+ "oauth_error_response",
291
+ # oauth2 / clientCredentials
292
+ "ClientCredentials",
293
+ "ClientCredentialsDict",
294
+ "ClientCredentialsOrDict",
295
+ "ClientCredentialsTokenSource",
296
+ "AsyncClientCredentialsTokenSource",
297
+ # oauth2 / password
298
+ "PasswordCredentials",
299
+ "PasswordCredentialsDict",
300
+ "PasswordCredentialsOrDict",
301
+ "PasswordTokenSource",
302
+ "AsyncPasswordTokenSource",
303
+ # oauth2 / authorizationCode
304
+ "AuthorizationCodeCredentials",
305
+ "AuthorizationCodeCredentialsDict",
306
+ "AuthorizationCodeCredentialsOrDict",
307
+ "AsyncAuthorizationCodeCredentials",
308
+ "AsyncAuthorizationCodeCredentialsDict",
309
+ "AsyncAuthorizationCodeCredentialsOrDict",
310
+ "AuthorizationCodePrompt",
311
+ "AsyncAuthorizationCodePrompt",
312
+ "PkceMethod",
313
+ "AuthorizationCodeTokenSource",
314
+ "AsyncAuthorizationCodeTokenSource",
315
+ # Response decoding and error mapping
316
+ "ResponseDecoder",
317
+ "AsyncResponseDecoder",
318
+ "ErrorMapper",
319
+ "json_decoder",
320
+ "async_json_decoder",
321
+ "text_decoder",
322
+ "async_text_decoder",
323
+ "decode_json",
324
+ "decode_text",
325
+ "empty_response",
326
+ "async_empty_response",
327
+ "raw_error_response",
328
+ "file_decoder",
329
+ "async_file_decoder",
330
+ "json_event_decoder",
331
+ "text_event_decoder",
332
+ "async_json_event_decoder",
333
+ "async_text_event_decoder",
334
+ # Model base and optionality
335
+ "SdkBaseModel",
336
+ "UNSET",
337
+ "UnsetType",
338
+ "Optional",
339
+ "OptionalNullable",
340
+ # Union discrimination
341
+ "WireDiscriminator",
342
+ # Wire-format converters
343
+ "Date",
344
+ "RFC3339DateTime",
345
+ "RFC1123DateTime",
346
+ "UnixSecondsDateTime",
347
+ # Wire-format binary aliases -- one per (RFC 4648 alphabet, charset) pair
348
+ "Base64AsciiEncodedBytes",
349
+ "Base64Utf8EncodedBytes",
350
+ "Base64Latin1EncodedBytes",
351
+ "Base64Cp1252EncodedBytes",
352
+ "Base64UrlAsciiEncodedBytes",
353
+ "Base64UrlUtf8EncodedBytes",
354
+ "Base64UrlLatin1EncodedBytes",
355
+ "Base64UrlCp1252EncodedBytes",
356
+ "Base32AsciiEncodedBytes",
357
+ "Base32Utf8EncodedBytes",
358
+ "Base32Latin1EncodedBytes",
359
+ "Base32Cp1252EncodedBytes",
360
+ "Base32HexAsciiEncodedBytes",
361
+ "Base32HexUtf8EncodedBytes",
362
+ "Base32HexLatin1EncodedBytes",
363
+ "Base32HexCp1252EncodedBytes",
364
+ "Base16AsciiEncodedBytes",
365
+ "Base16Utf8EncodedBytes",
366
+ "Base16Latin1EncodedBytes",
367
+ "Base16Cp1252EncodedBytes",
368
+ # Binary property declaration
369
+ "ByteField",
370
+ # Open enums
371
+ "open_enum_validator",
372
+ # Raw clients and the raw-response base
373
+ "RawClient",
374
+ "AsyncRawClient",
375
+ "RawClientT",
376
+ "BaseRawResponse",
377
+ "SecuredRawResponse",
378
+ # Host environment reported in the SDK identification headers
379
+ "OPERATING_SYSTEM",
380
+ "PYTHON_RUNTIME",
381
+ # Server layer
382
+ "validate_one_of",
383
+ # Pagination
384
+ "Paginator",
385
+ "AsyncPaginator",
386
+ "paginate",
387
+ "async_paginate",
388
+ "offset_state",
389
+ "page_state",
390
+ "cursor_state",
391
+ "keyset_state",
392
+ "link_state",
393
+ "read_header",
394
+ "find_link_target",
395
+ ]
@@ -0,0 +1,9 @@
1
+ """Runtime plumbing.
2
+
3
+ Nothing here is part of the SDK's public surface: mostly the pure functions the raw client calls to
4
+ turn parameters into a URL, a header mapping, and form fields, plus the one base class the
5
+ subscripted factories share and one stateful object -- ``sse_parser``'s push parser, which is
6
+ incremental by nature because it is fed a chunk at a time. They are grouped under a private package
7
+ so this runtime's own ``__init__`` stays the whole of what generated code imports."""
8
+
9
+ __all__: list[str] = []