casedev 0.3.0__py3-none-any.whl → 0.4.0__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.
- casedev/_client.py +275 -1
- casedev/_version.py +1 -1
- casedev/resources/__init__.py +98 -0
- casedev/resources/applications/__init__.py +33 -0
- casedev/resources/applications/applications.py +102 -0
- casedev/resources/applications/v1/__init__.py +61 -0
- casedev/resources/applications/v1/deployments.py +867 -0
- casedev/resources/applications/v1/projects.py +1377 -0
- casedev/resources/applications/v1/v1.py +166 -0
- casedev/resources/applications/v1/workflows.py +182 -0
- casedev/resources/compute/v1/__init__.py +28 -0
- casedev/resources/compute/v1/instance_types.py +145 -0
- casedev/resources/compute/v1/instances.py +448 -0
- casedev/resources/compute/v1/v1.py +64 -0
- casedev/resources/database/__init__.py +33 -0
- casedev/resources/database/database.py +102 -0
- casedev/resources/database/v1/__init__.py +33 -0
- casedev/resources/database/v1/projects.py +771 -0
- casedev/resources/database/v1/v1.py +175 -0
- casedev/resources/legal/__init__.py +33 -0
- casedev/resources/legal/legal.py +102 -0
- casedev/resources/legal/v1.py +924 -0
- casedev/resources/memory/__init__.py +33 -0
- casedev/resources/memory/memory.py +102 -0
- casedev/resources/memory/v1.py +1100 -0
- casedev/resources/privilege/__init__.py +33 -0
- casedev/resources/privilege/privilege.py +102 -0
- casedev/resources/privilege/v1.py +260 -0
- casedev/resources/superdoc/__init__.py +33 -0
- casedev/resources/superdoc/superdoc.py +102 -0
- casedev/resources/superdoc/v1.py +349 -0
- casedev/resources/translate/__init__.py +33 -0
- casedev/resources/translate/translate.py +102 -0
- casedev/resources/translate/v1.py +418 -0
- casedev/resources/vault/__init__.py +14 -0
- casedev/resources/vault/graphrag.py +91 -0
- casedev/resources/vault/multipart.py +549 -0
- casedev/resources/vault/objects.py +475 -5
- casedev/resources/vault/vault.py +262 -5
- casedev/types/__init__.py +4 -0
- casedev/types/applications/v1/__init__.py +20 -0
- casedev/types/applications/v1/deployment_cancel_params.py +14 -0
- casedev/types/applications/v1/deployment_create_params.py +20 -0
- casedev/types/applications/v1/deployment_get_logs_params.py +14 -0
- casedev/types/applications/v1/deployment_list_params.py +23 -0
- casedev/types/applications/v1/deployment_retrieve_params.py +17 -0
- casedev/types/applications/v1/deployment_stream_params.py +17 -0
- casedev/types/applications/v1/project_create_deployment_params.py +29 -0
- casedev/types/applications/v1/project_create_domain_params.py +17 -0
- casedev/types/applications/v1/project_create_env_params.py +27 -0
- casedev/types/applications/v1/project_create_params.py +53 -0
- casedev/types/applications/v1/project_delete_params.py +14 -0
- casedev/types/applications/v1/project_get_runtime_logs_params.py +12 -0
- casedev/types/applications/v1/project_list_deployments_params.py +18 -0
- casedev/types/applications/v1/project_list_env_params.py +12 -0
- casedev/types/applications/v1/project_list_response.py +45 -0
- casedev/types/applications/v1/workflow_get_status_params.py +14 -0
- casedev/types/compute/v1/__init__.py +6 -0
- casedev/types/compute/v1/instance_create_params.py +28 -0
- casedev/types/compute/v1/instance_create_response.py +35 -0
- casedev/types/compute/v1/instance_delete_response.py +23 -0
- casedev/types/compute/v1/instance_list_response.py +45 -0
- casedev/types/compute/v1/instance_retrieve_response.py +55 -0
- casedev/types/compute/v1/instance_type_list_response.py +46 -0
- casedev/types/database/__init__.py +5 -0
- casedev/types/database/v1/__init__.py +14 -0
- casedev/types/database/v1/project_create_branch_params.py +17 -0
- casedev/types/database/v1/project_create_branch_response.py +30 -0
- casedev/types/database/v1/project_create_params.py +27 -0
- casedev/types/database/v1/project_create_response.py +47 -0
- casedev/types/database/v1/project_delete_response.py +13 -0
- casedev/types/database/v1/project_get_connection_params.py +15 -0
- casedev/types/database/v1/project_get_connection_response.py +18 -0
- casedev/types/database/v1/project_list_branches_response.py +37 -0
- casedev/types/database/v1/project_list_response.py +64 -0
- casedev/types/database/v1/project_retrieve_response.py +100 -0
- casedev/types/database/v1_get_usage_response.py +116 -0
- casedev/types/legal/__init__.py +20 -0
- casedev/types/legal/v1_find_params.py +23 -0
- casedev/types/legal/v1_find_response.py +37 -0
- casedev/types/legal/v1_get_citations_from_url_params.py +12 -0
- casedev/types/legal/v1_get_citations_from_url_response.py +69 -0
- casedev/types/legal/v1_get_citations_params.py +16 -0
- casedev/types/legal/v1_get_citations_response.py +60 -0
- casedev/types/legal/v1_get_full_text_params.py +23 -0
- casedev/types/legal/v1_get_full_text_response.py +35 -0
- casedev/types/legal/v1_list_jurisdictions_params.py +12 -0
- casedev/types/legal/v1_list_jurisdictions_response.py +35 -0
- casedev/types/legal/v1_research_params.py +27 -0
- casedev/types/legal/v1_research_response.py +51 -0
- casedev/types/legal/v1_similar_params.py +25 -0
- casedev/types/legal/v1_similar_response.py +42 -0
- casedev/types/legal/v1_verify_params.py +16 -0
- casedev/types/legal/v1_verify_response.py +92 -0
- casedev/types/memory/__init__.py +14 -0
- casedev/types/memory/v1_create_params.py +69 -0
- casedev/types/memory/v1_create_response.py +23 -0
- casedev/types/memory/v1_delete_all_params.py +45 -0
- casedev/types/memory/v1_delete_all_response.py +12 -0
- casedev/types/memory/v1_delete_response.py +13 -0
- casedev/types/memory/v1_list_params.py +54 -0
- casedev/types/memory/v1_list_response.py +29 -0
- casedev/types/memory/v1_retrieve_response.py +23 -0
- casedev/types/memory/v1_search_params.py +54 -0
- casedev/types/memory/v1_search_response.py +61 -0
- casedev/types/privilege/__init__.py +6 -0
- casedev/types/privilege/v1_detect_params.py +34 -0
- casedev/types/privilege/v1_detect_response.py +41 -0
- casedev/types/superdoc/__init__.py +6 -0
- casedev/types/superdoc/v1_annotate_params.py +56 -0
- casedev/types/superdoc/v1_convert_params.py +23 -0
- casedev/types/translate/__init__.py +10 -0
- casedev/types/translate/v1_detect_params.py +18 -0
- casedev/types/translate/v1_detect_response.py +28 -0
- casedev/types/translate/v1_list_languages_params.py +18 -0
- casedev/types/translate/v1_list_languages_response.py +23 -0
- casedev/types/translate/v1_translate_params.py +30 -0
- casedev/types/translate/v1_translate_response.py +28 -0
- casedev/types/vault/__init__.py +14 -0
- casedev/types/vault/graphrag_process_object_response.py +45 -0
- casedev/types/vault/multipart_abort_params.py +15 -0
- casedev/types/vault/multipart_complete_params.py +26 -0
- casedev/types/vault/multipart_get_part_urls_params.py +24 -0
- casedev/types/vault/multipart_get_part_urls_response.py +19 -0
- casedev/types/vault/multipart_init_params.py +32 -0
- casedev/types/vault/multipart_init_response.py +23 -0
- casedev/types/vault/object_create_presigned_url_params.py +1 -1
- casedev/types/vault/object_delete_params.py +17 -0
- casedev/types/vault/object_delete_response.py +29 -0
- casedev/types/vault/object_get_ocr_words_params.py +28 -0
- casedev/types/vault/object_get_ocr_words_response.py +48 -0
- casedev/types/vault/object_get_summarize_job_response.py +40 -0
- casedev/types/vault/object_update_params.py +24 -0
- casedev/types/vault/object_update_response.py +39 -0
- casedev/types/vault_delete_params.py +17 -0
- casedev/types/vault_delete_response.py +30 -0
- casedev/types/vault_update_params.py +21 -0
- casedev/types/vault_update_response.py +60 -0
- casedev/types/vault_upload_params.py +1 -1
- {casedev-0.3.0.dist-info → casedev-0.4.0.dist-info}/METADATA +1 -1
- casedev-0.4.0.dist-info/RECORD +275 -0
- casedev-0.3.0.dist-info/RECORD +0 -150
- /casedev/types/{webhooks → applications}/__init__.py +0 -0
- {casedev-0.3.0.dist-info → casedev-0.4.0.dist-info}/WHEEL +0 -0
- {casedev-0.3.0.dist-info → casedev-0.4.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,1377 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
from typing import List, Iterable
|
|
6
|
+
from typing_extensions import Literal
|
|
7
|
+
|
|
8
|
+
import httpx
|
|
9
|
+
|
|
10
|
+
from ...._types import Body, Omit, Query, Headers, NoneType, NotGiven, omit, not_given
|
|
11
|
+
from ...._utils import maybe_transform, async_maybe_transform
|
|
12
|
+
from ...._compat import cached_property
|
|
13
|
+
from ...._resource import SyncAPIResource, AsyncAPIResource
|
|
14
|
+
from ...._response import (
|
|
15
|
+
to_raw_response_wrapper,
|
|
16
|
+
to_streamed_response_wrapper,
|
|
17
|
+
async_to_raw_response_wrapper,
|
|
18
|
+
async_to_streamed_response_wrapper,
|
|
19
|
+
)
|
|
20
|
+
from ...._base_client import make_request_options
|
|
21
|
+
from ....types.applications.v1 import (
|
|
22
|
+
project_create_params,
|
|
23
|
+
project_delete_params,
|
|
24
|
+
project_list_env_params,
|
|
25
|
+
project_create_env_params,
|
|
26
|
+
project_create_domain_params,
|
|
27
|
+
project_get_runtime_logs_params,
|
|
28
|
+
project_list_deployments_params,
|
|
29
|
+
project_create_deployment_params,
|
|
30
|
+
)
|
|
31
|
+
from ....types.applications.v1.project_list_response import ProjectListResponse
|
|
32
|
+
|
|
33
|
+
__all__ = ["ProjectsResource", "AsyncProjectsResource"]
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
class ProjectsResource(SyncAPIResource):
|
|
37
|
+
@cached_property
|
|
38
|
+
def with_raw_response(self) -> ProjectsResourceWithRawResponse:
|
|
39
|
+
"""
|
|
40
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
41
|
+
the raw response object instead of the parsed content.
|
|
42
|
+
|
|
43
|
+
For more information, see https://www.github.com/CaseMark/casedev-python#accessing-raw-response-data-eg-headers
|
|
44
|
+
"""
|
|
45
|
+
return ProjectsResourceWithRawResponse(self)
|
|
46
|
+
|
|
47
|
+
@cached_property
|
|
48
|
+
def with_streaming_response(self) -> ProjectsResourceWithStreamingResponse:
|
|
49
|
+
"""
|
|
50
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
51
|
+
|
|
52
|
+
For more information, see https://www.github.com/CaseMark/casedev-python#with_streaming_response
|
|
53
|
+
"""
|
|
54
|
+
return ProjectsResourceWithStreamingResponse(self)
|
|
55
|
+
|
|
56
|
+
def create(
|
|
57
|
+
self,
|
|
58
|
+
*,
|
|
59
|
+
git_repo: str,
|
|
60
|
+
name: str,
|
|
61
|
+
build_command: str | Omit = omit,
|
|
62
|
+
environment_variables: Iterable[project_create_params.EnvironmentVariable] | Omit = omit,
|
|
63
|
+
framework: str | Omit = omit,
|
|
64
|
+
git_branch: str | Omit = omit,
|
|
65
|
+
install_command: str | Omit = omit,
|
|
66
|
+
output_directory: str | Omit = omit,
|
|
67
|
+
root_directory: str | Omit = omit,
|
|
68
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
69
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
70
|
+
extra_headers: Headers | None = None,
|
|
71
|
+
extra_query: Query | None = None,
|
|
72
|
+
extra_body: Body | None = None,
|
|
73
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
74
|
+
) -> None:
|
|
75
|
+
"""
|
|
76
|
+
Create a new web application project
|
|
77
|
+
|
|
78
|
+
Args:
|
|
79
|
+
git_repo: GitHub repository URL or "owner/repo"
|
|
80
|
+
|
|
81
|
+
name: Project name
|
|
82
|
+
|
|
83
|
+
build_command: Custom build command
|
|
84
|
+
|
|
85
|
+
environment_variables: Environment variables to set on the project
|
|
86
|
+
|
|
87
|
+
framework: Framework (e.g., "nextjs", "remix", "astro")
|
|
88
|
+
|
|
89
|
+
git_branch: Git branch to deploy
|
|
90
|
+
|
|
91
|
+
install_command: Custom install command
|
|
92
|
+
|
|
93
|
+
output_directory: Build output directory
|
|
94
|
+
|
|
95
|
+
root_directory: Root directory of the project
|
|
96
|
+
|
|
97
|
+
extra_headers: Send extra headers
|
|
98
|
+
|
|
99
|
+
extra_query: Add additional query parameters to the request
|
|
100
|
+
|
|
101
|
+
extra_body: Add additional JSON properties to the request
|
|
102
|
+
|
|
103
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
104
|
+
"""
|
|
105
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
106
|
+
return self._post(
|
|
107
|
+
"/applications/v1/projects",
|
|
108
|
+
body=maybe_transform(
|
|
109
|
+
{
|
|
110
|
+
"git_repo": git_repo,
|
|
111
|
+
"name": name,
|
|
112
|
+
"build_command": build_command,
|
|
113
|
+
"environment_variables": environment_variables,
|
|
114
|
+
"framework": framework,
|
|
115
|
+
"git_branch": git_branch,
|
|
116
|
+
"install_command": install_command,
|
|
117
|
+
"output_directory": output_directory,
|
|
118
|
+
"root_directory": root_directory,
|
|
119
|
+
},
|
|
120
|
+
project_create_params.ProjectCreateParams,
|
|
121
|
+
),
|
|
122
|
+
options=make_request_options(
|
|
123
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
124
|
+
),
|
|
125
|
+
cast_to=NoneType,
|
|
126
|
+
)
|
|
127
|
+
|
|
128
|
+
def retrieve(
|
|
129
|
+
self,
|
|
130
|
+
id: str,
|
|
131
|
+
*,
|
|
132
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
133
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
134
|
+
extra_headers: Headers | None = None,
|
|
135
|
+
extra_query: Query | None = None,
|
|
136
|
+
extra_body: Body | None = None,
|
|
137
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
138
|
+
) -> None:
|
|
139
|
+
"""
|
|
140
|
+
Get details of a specific web application project
|
|
141
|
+
|
|
142
|
+
Args:
|
|
143
|
+
extra_headers: Send extra headers
|
|
144
|
+
|
|
145
|
+
extra_query: Add additional query parameters to the request
|
|
146
|
+
|
|
147
|
+
extra_body: Add additional JSON properties to the request
|
|
148
|
+
|
|
149
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
150
|
+
"""
|
|
151
|
+
if not id:
|
|
152
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
153
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
154
|
+
return self._get(
|
|
155
|
+
f"/applications/v1/projects/{id}",
|
|
156
|
+
options=make_request_options(
|
|
157
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
158
|
+
),
|
|
159
|
+
cast_to=NoneType,
|
|
160
|
+
)
|
|
161
|
+
|
|
162
|
+
def list(
|
|
163
|
+
self,
|
|
164
|
+
*,
|
|
165
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
166
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
167
|
+
extra_headers: Headers | None = None,
|
|
168
|
+
extra_query: Query | None = None,
|
|
169
|
+
extra_body: Body | None = None,
|
|
170
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
171
|
+
) -> ProjectListResponse:
|
|
172
|
+
"""List all web application projects"""
|
|
173
|
+
return self._get(
|
|
174
|
+
"/applications/v1/projects",
|
|
175
|
+
options=make_request_options(
|
|
176
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
177
|
+
),
|
|
178
|
+
cast_to=ProjectListResponse,
|
|
179
|
+
)
|
|
180
|
+
|
|
181
|
+
def delete(
|
|
182
|
+
self,
|
|
183
|
+
id: str,
|
|
184
|
+
*,
|
|
185
|
+
delete_from_hosting: bool | Omit = omit,
|
|
186
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
187
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
188
|
+
extra_headers: Headers | None = None,
|
|
189
|
+
extra_query: Query | None = None,
|
|
190
|
+
extra_body: Body | None = None,
|
|
191
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
192
|
+
) -> None:
|
|
193
|
+
"""
|
|
194
|
+
Delete a web application project
|
|
195
|
+
|
|
196
|
+
Args:
|
|
197
|
+
delete_from_hosting: Also delete the project from hosting (default: true)
|
|
198
|
+
|
|
199
|
+
extra_headers: Send extra headers
|
|
200
|
+
|
|
201
|
+
extra_query: Add additional query parameters to the request
|
|
202
|
+
|
|
203
|
+
extra_body: Add additional JSON properties to the request
|
|
204
|
+
|
|
205
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
206
|
+
"""
|
|
207
|
+
if not id:
|
|
208
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
209
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
210
|
+
return self._delete(
|
|
211
|
+
f"/applications/v1/projects/{id}",
|
|
212
|
+
options=make_request_options(
|
|
213
|
+
extra_headers=extra_headers,
|
|
214
|
+
extra_query=extra_query,
|
|
215
|
+
extra_body=extra_body,
|
|
216
|
+
timeout=timeout,
|
|
217
|
+
query=maybe_transform(
|
|
218
|
+
{"delete_from_hosting": delete_from_hosting}, project_delete_params.ProjectDeleteParams
|
|
219
|
+
),
|
|
220
|
+
),
|
|
221
|
+
cast_to=NoneType,
|
|
222
|
+
)
|
|
223
|
+
|
|
224
|
+
def create_deployment(
|
|
225
|
+
self,
|
|
226
|
+
id: str,
|
|
227
|
+
*,
|
|
228
|
+
environment_variables: Iterable[project_create_deployment_params.EnvironmentVariable] | Omit = omit,
|
|
229
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
230
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
231
|
+
extra_headers: Headers | None = None,
|
|
232
|
+
extra_query: Query | None = None,
|
|
233
|
+
extra_body: Body | None = None,
|
|
234
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
235
|
+
) -> None:
|
|
236
|
+
"""
|
|
237
|
+
Trigger a new deployment for a project.
|
|
238
|
+
|
|
239
|
+
Args:
|
|
240
|
+
environment_variables: Additional environment variables to set or update before deployment
|
|
241
|
+
|
|
242
|
+
extra_headers: Send extra headers
|
|
243
|
+
|
|
244
|
+
extra_query: Add additional query parameters to the request
|
|
245
|
+
|
|
246
|
+
extra_body: Add additional JSON properties to the request
|
|
247
|
+
|
|
248
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
249
|
+
"""
|
|
250
|
+
if not id:
|
|
251
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
252
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
253
|
+
return self._post(
|
|
254
|
+
f"/applications/v1/projects/{id}/deployments",
|
|
255
|
+
body=maybe_transform(
|
|
256
|
+
{"environment_variables": environment_variables},
|
|
257
|
+
project_create_deployment_params.ProjectCreateDeploymentParams,
|
|
258
|
+
),
|
|
259
|
+
options=make_request_options(
|
|
260
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
261
|
+
),
|
|
262
|
+
cast_to=NoneType,
|
|
263
|
+
)
|
|
264
|
+
|
|
265
|
+
def create_domain(
|
|
266
|
+
self,
|
|
267
|
+
id: str,
|
|
268
|
+
*,
|
|
269
|
+
domain: str,
|
|
270
|
+
git_branch: str | Omit = omit,
|
|
271
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
272
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
273
|
+
extra_headers: Headers | None = None,
|
|
274
|
+
extra_query: Query | None = None,
|
|
275
|
+
extra_body: Body | None = None,
|
|
276
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
277
|
+
) -> None:
|
|
278
|
+
"""
|
|
279
|
+
Add a custom domain to a project
|
|
280
|
+
|
|
281
|
+
Args:
|
|
282
|
+
domain: Domain name to add
|
|
283
|
+
|
|
284
|
+
git_branch: Git branch to associate with this domain
|
|
285
|
+
|
|
286
|
+
extra_headers: Send extra headers
|
|
287
|
+
|
|
288
|
+
extra_query: Add additional query parameters to the request
|
|
289
|
+
|
|
290
|
+
extra_body: Add additional JSON properties to the request
|
|
291
|
+
|
|
292
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
293
|
+
"""
|
|
294
|
+
if not id:
|
|
295
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
296
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
297
|
+
return self._post(
|
|
298
|
+
f"/applications/v1/projects/{id}/domains",
|
|
299
|
+
body=maybe_transform(
|
|
300
|
+
{
|
|
301
|
+
"domain": domain,
|
|
302
|
+
"git_branch": git_branch,
|
|
303
|
+
},
|
|
304
|
+
project_create_domain_params.ProjectCreateDomainParams,
|
|
305
|
+
),
|
|
306
|
+
options=make_request_options(
|
|
307
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
308
|
+
),
|
|
309
|
+
cast_to=NoneType,
|
|
310
|
+
)
|
|
311
|
+
|
|
312
|
+
def create_env(
|
|
313
|
+
self,
|
|
314
|
+
id: str,
|
|
315
|
+
*,
|
|
316
|
+
key: str,
|
|
317
|
+
target: List[Literal["production", "preview", "development"]],
|
|
318
|
+
value: str,
|
|
319
|
+
git_branch: str | Omit = omit,
|
|
320
|
+
type: Literal["plain", "encrypted", "secret"] | Omit = omit,
|
|
321
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
322
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
323
|
+
extra_headers: Headers | None = None,
|
|
324
|
+
extra_query: Query | None = None,
|
|
325
|
+
extra_body: Body | None = None,
|
|
326
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
327
|
+
) -> None:
|
|
328
|
+
"""
|
|
329
|
+
Create a new environment variable for a project
|
|
330
|
+
|
|
331
|
+
Args:
|
|
332
|
+
key: Environment variable name
|
|
333
|
+
|
|
334
|
+
target: Deployment targets for this variable
|
|
335
|
+
|
|
336
|
+
value: Environment variable value
|
|
337
|
+
|
|
338
|
+
git_branch: Specific git branch (for preview deployments)
|
|
339
|
+
|
|
340
|
+
type: Variable type
|
|
341
|
+
|
|
342
|
+
extra_headers: Send extra headers
|
|
343
|
+
|
|
344
|
+
extra_query: Add additional query parameters to the request
|
|
345
|
+
|
|
346
|
+
extra_body: Add additional JSON properties to the request
|
|
347
|
+
|
|
348
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
349
|
+
"""
|
|
350
|
+
if not id:
|
|
351
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
352
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
353
|
+
return self._post(
|
|
354
|
+
f"/applications/v1/projects/{id}/env",
|
|
355
|
+
body=maybe_transform(
|
|
356
|
+
{
|
|
357
|
+
"key": key,
|
|
358
|
+
"target": target,
|
|
359
|
+
"value": value,
|
|
360
|
+
"git_branch": git_branch,
|
|
361
|
+
"type": type,
|
|
362
|
+
},
|
|
363
|
+
project_create_env_params.ProjectCreateEnvParams,
|
|
364
|
+
),
|
|
365
|
+
options=make_request_options(
|
|
366
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
367
|
+
),
|
|
368
|
+
cast_to=NoneType,
|
|
369
|
+
)
|
|
370
|
+
|
|
371
|
+
def delete_domain(
|
|
372
|
+
self,
|
|
373
|
+
domain: str,
|
|
374
|
+
*,
|
|
375
|
+
id: str,
|
|
376
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
377
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
378
|
+
extra_headers: Headers | None = None,
|
|
379
|
+
extra_query: Query | None = None,
|
|
380
|
+
extra_body: Body | None = None,
|
|
381
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
382
|
+
) -> None:
|
|
383
|
+
"""
|
|
384
|
+
Remove a domain from a project
|
|
385
|
+
|
|
386
|
+
Args:
|
|
387
|
+
extra_headers: Send extra headers
|
|
388
|
+
|
|
389
|
+
extra_query: Add additional query parameters to the request
|
|
390
|
+
|
|
391
|
+
extra_body: Add additional JSON properties to the request
|
|
392
|
+
|
|
393
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
394
|
+
"""
|
|
395
|
+
if not id:
|
|
396
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
397
|
+
if not domain:
|
|
398
|
+
raise ValueError(f"Expected a non-empty value for `domain` but received {domain!r}")
|
|
399
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
400
|
+
return self._delete(
|
|
401
|
+
f"/applications/v1/projects/{id}/domains/{domain}",
|
|
402
|
+
options=make_request_options(
|
|
403
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
404
|
+
),
|
|
405
|
+
cast_to=NoneType,
|
|
406
|
+
)
|
|
407
|
+
|
|
408
|
+
def delete_env(
|
|
409
|
+
self,
|
|
410
|
+
env_id: str,
|
|
411
|
+
*,
|
|
412
|
+
id: str,
|
|
413
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
414
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
415
|
+
extra_headers: Headers | None = None,
|
|
416
|
+
extra_query: Query | None = None,
|
|
417
|
+
extra_body: Body | None = None,
|
|
418
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
419
|
+
) -> None:
|
|
420
|
+
"""
|
|
421
|
+
Delete an environment variable from a project
|
|
422
|
+
|
|
423
|
+
Args:
|
|
424
|
+
extra_headers: Send extra headers
|
|
425
|
+
|
|
426
|
+
extra_query: Add additional query parameters to the request
|
|
427
|
+
|
|
428
|
+
extra_body: Add additional JSON properties to the request
|
|
429
|
+
|
|
430
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
431
|
+
"""
|
|
432
|
+
if not id:
|
|
433
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
434
|
+
if not env_id:
|
|
435
|
+
raise ValueError(f"Expected a non-empty value for `env_id` but received {env_id!r}")
|
|
436
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
437
|
+
return self._delete(
|
|
438
|
+
f"/applications/v1/projects/{id}/env/{env_id}",
|
|
439
|
+
options=make_request_options(
|
|
440
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
441
|
+
),
|
|
442
|
+
cast_to=NoneType,
|
|
443
|
+
)
|
|
444
|
+
|
|
445
|
+
def get_runtime_logs(
|
|
446
|
+
self,
|
|
447
|
+
id: str,
|
|
448
|
+
*,
|
|
449
|
+
limit: float | Omit = omit,
|
|
450
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
451
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
452
|
+
extra_headers: Headers | None = None,
|
|
453
|
+
extra_query: Query | None = None,
|
|
454
|
+
extra_body: Body | None = None,
|
|
455
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
456
|
+
) -> None:
|
|
457
|
+
"""
|
|
458
|
+
Get runtime/function logs for a project
|
|
459
|
+
|
|
460
|
+
Args:
|
|
461
|
+
limit: Maximum number of logs to return
|
|
462
|
+
|
|
463
|
+
extra_headers: Send extra headers
|
|
464
|
+
|
|
465
|
+
extra_query: Add additional query parameters to the request
|
|
466
|
+
|
|
467
|
+
extra_body: Add additional JSON properties to the request
|
|
468
|
+
|
|
469
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
470
|
+
"""
|
|
471
|
+
if not id:
|
|
472
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
473
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
474
|
+
return self._get(
|
|
475
|
+
f"/applications/v1/projects/{id}/runtime-logs",
|
|
476
|
+
options=make_request_options(
|
|
477
|
+
extra_headers=extra_headers,
|
|
478
|
+
extra_query=extra_query,
|
|
479
|
+
extra_body=extra_body,
|
|
480
|
+
timeout=timeout,
|
|
481
|
+
query=maybe_transform({"limit": limit}, project_get_runtime_logs_params.ProjectGetRuntimeLogsParams),
|
|
482
|
+
),
|
|
483
|
+
cast_to=NoneType,
|
|
484
|
+
)
|
|
485
|
+
|
|
486
|
+
def list_deployments(
|
|
487
|
+
self,
|
|
488
|
+
id: str,
|
|
489
|
+
*,
|
|
490
|
+
limit: float | Omit = omit,
|
|
491
|
+
state: str | Omit = omit,
|
|
492
|
+
target: Literal["production", "staging"] | Omit = omit,
|
|
493
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
494
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
495
|
+
extra_headers: Headers | None = None,
|
|
496
|
+
extra_query: Query | None = None,
|
|
497
|
+
extra_body: Body | None = None,
|
|
498
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
499
|
+
) -> None:
|
|
500
|
+
"""
|
|
501
|
+
List deployments for a specific project
|
|
502
|
+
|
|
503
|
+
Args:
|
|
504
|
+
limit: Maximum number of deployments to return
|
|
505
|
+
|
|
506
|
+
state: Filter by deployment state
|
|
507
|
+
|
|
508
|
+
target: Filter by deployment target
|
|
509
|
+
|
|
510
|
+
extra_headers: Send extra headers
|
|
511
|
+
|
|
512
|
+
extra_query: Add additional query parameters to the request
|
|
513
|
+
|
|
514
|
+
extra_body: Add additional JSON properties to the request
|
|
515
|
+
|
|
516
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
517
|
+
"""
|
|
518
|
+
if not id:
|
|
519
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
520
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
521
|
+
return self._get(
|
|
522
|
+
f"/applications/v1/projects/{id}/deployments",
|
|
523
|
+
options=make_request_options(
|
|
524
|
+
extra_headers=extra_headers,
|
|
525
|
+
extra_query=extra_query,
|
|
526
|
+
extra_body=extra_body,
|
|
527
|
+
timeout=timeout,
|
|
528
|
+
query=maybe_transform(
|
|
529
|
+
{
|
|
530
|
+
"limit": limit,
|
|
531
|
+
"state": state,
|
|
532
|
+
"target": target,
|
|
533
|
+
},
|
|
534
|
+
project_list_deployments_params.ProjectListDeploymentsParams,
|
|
535
|
+
),
|
|
536
|
+
),
|
|
537
|
+
cast_to=NoneType,
|
|
538
|
+
)
|
|
539
|
+
|
|
540
|
+
def list_domains(
|
|
541
|
+
self,
|
|
542
|
+
id: str,
|
|
543
|
+
*,
|
|
544
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
545
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
546
|
+
extra_headers: Headers | None = None,
|
|
547
|
+
extra_query: Query | None = None,
|
|
548
|
+
extra_body: Body | None = None,
|
|
549
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
550
|
+
) -> None:
|
|
551
|
+
"""
|
|
552
|
+
List all domains configured for a project
|
|
553
|
+
|
|
554
|
+
Args:
|
|
555
|
+
extra_headers: Send extra headers
|
|
556
|
+
|
|
557
|
+
extra_query: Add additional query parameters to the request
|
|
558
|
+
|
|
559
|
+
extra_body: Add additional JSON properties to the request
|
|
560
|
+
|
|
561
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
562
|
+
"""
|
|
563
|
+
if not id:
|
|
564
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
565
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
566
|
+
return self._get(
|
|
567
|
+
f"/applications/v1/projects/{id}/domains",
|
|
568
|
+
options=make_request_options(
|
|
569
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
570
|
+
),
|
|
571
|
+
cast_to=NoneType,
|
|
572
|
+
)
|
|
573
|
+
|
|
574
|
+
def list_env(
|
|
575
|
+
self,
|
|
576
|
+
id: str,
|
|
577
|
+
*,
|
|
578
|
+
decrypt: bool | Omit = omit,
|
|
579
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
580
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
581
|
+
extra_headers: Headers | None = None,
|
|
582
|
+
extra_query: Query | None = None,
|
|
583
|
+
extra_body: Body | None = None,
|
|
584
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
585
|
+
) -> None:
|
|
586
|
+
"""
|
|
587
|
+
List all environment variables for a project (values are hidden unless
|
|
588
|
+
decrypt=true)
|
|
589
|
+
|
|
590
|
+
Args:
|
|
591
|
+
decrypt: Whether to decrypt and return values (requires appropriate permissions)
|
|
592
|
+
|
|
593
|
+
extra_headers: Send extra headers
|
|
594
|
+
|
|
595
|
+
extra_query: Add additional query parameters to the request
|
|
596
|
+
|
|
597
|
+
extra_body: Add additional JSON properties to the request
|
|
598
|
+
|
|
599
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
600
|
+
"""
|
|
601
|
+
if not id:
|
|
602
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
603
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
604
|
+
return self._get(
|
|
605
|
+
f"/applications/v1/projects/{id}/env",
|
|
606
|
+
options=make_request_options(
|
|
607
|
+
extra_headers=extra_headers,
|
|
608
|
+
extra_query=extra_query,
|
|
609
|
+
extra_body=extra_body,
|
|
610
|
+
timeout=timeout,
|
|
611
|
+
query=maybe_transform({"decrypt": decrypt}, project_list_env_params.ProjectListEnvParams),
|
|
612
|
+
),
|
|
613
|
+
cast_to=NoneType,
|
|
614
|
+
)
|
|
615
|
+
|
|
616
|
+
|
|
617
|
+
class AsyncProjectsResource(AsyncAPIResource):
|
|
618
|
+
@cached_property
|
|
619
|
+
def with_raw_response(self) -> AsyncProjectsResourceWithRawResponse:
|
|
620
|
+
"""
|
|
621
|
+
This property can be used as a prefix for any HTTP method call to return
|
|
622
|
+
the raw response object instead of the parsed content.
|
|
623
|
+
|
|
624
|
+
For more information, see https://www.github.com/CaseMark/casedev-python#accessing-raw-response-data-eg-headers
|
|
625
|
+
"""
|
|
626
|
+
return AsyncProjectsResourceWithRawResponse(self)
|
|
627
|
+
|
|
628
|
+
@cached_property
|
|
629
|
+
def with_streaming_response(self) -> AsyncProjectsResourceWithStreamingResponse:
|
|
630
|
+
"""
|
|
631
|
+
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
|
632
|
+
|
|
633
|
+
For more information, see https://www.github.com/CaseMark/casedev-python#with_streaming_response
|
|
634
|
+
"""
|
|
635
|
+
return AsyncProjectsResourceWithStreamingResponse(self)
|
|
636
|
+
|
|
637
|
+
async def create(
|
|
638
|
+
self,
|
|
639
|
+
*,
|
|
640
|
+
git_repo: str,
|
|
641
|
+
name: str,
|
|
642
|
+
build_command: str | Omit = omit,
|
|
643
|
+
environment_variables: Iterable[project_create_params.EnvironmentVariable] | Omit = omit,
|
|
644
|
+
framework: str | Omit = omit,
|
|
645
|
+
git_branch: str | Omit = omit,
|
|
646
|
+
install_command: str | Omit = omit,
|
|
647
|
+
output_directory: str | Omit = omit,
|
|
648
|
+
root_directory: str | Omit = omit,
|
|
649
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
650
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
651
|
+
extra_headers: Headers | None = None,
|
|
652
|
+
extra_query: Query | None = None,
|
|
653
|
+
extra_body: Body | None = None,
|
|
654
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
655
|
+
) -> None:
|
|
656
|
+
"""
|
|
657
|
+
Create a new web application project
|
|
658
|
+
|
|
659
|
+
Args:
|
|
660
|
+
git_repo: GitHub repository URL or "owner/repo"
|
|
661
|
+
|
|
662
|
+
name: Project name
|
|
663
|
+
|
|
664
|
+
build_command: Custom build command
|
|
665
|
+
|
|
666
|
+
environment_variables: Environment variables to set on the project
|
|
667
|
+
|
|
668
|
+
framework: Framework (e.g., "nextjs", "remix", "astro")
|
|
669
|
+
|
|
670
|
+
git_branch: Git branch to deploy
|
|
671
|
+
|
|
672
|
+
install_command: Custom install command
|
|
673
|
+
|
|
674
|
+
output_directory: Build output directory
|
|
675
|
+
|
|
676
|
+
root_directory: Root directory of the project
|
|
677
|
+
|
|
678
|
+
extra_headers: Send extra headers
|
|
679
|
+
|
|
680
|
+
extra_query: Add additional query parameters to the request
|
|
681
|
+
|
|
682
|
+
extra_body: Add additional JSON properties to the request
|
|
683
|
+
|
|
684
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
685
|
+
"""
|
|
686
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
687
|
+
return await self._post(
|
|
688
|
+
"/applications/v1/projects",
|
|
689
|
+
body=await async_maybe_transform(
|
|
690
|
+
{
|
|
691
|
+
"git_repo": git_repo,
|
|
692
|
+
"name": name,
|
|
693
|
+
"build_command": build_command,
|
|
694
|
+
"environment_variables": environment_variables,
|
|
695
|
+
"framework": framework,
|
|
696
|
+
"git_branch": git_branch,
|
|
697
|
+
"install_command": install_command,
|
|
698
|
+
"output_directory": output_directory,
|
|
699
|
+
"root_directory": root_directory,
|
|
700
|
+
},
|
|
701
|
+
project_create_params.ProjectCreateParams,
|
|
702
|
+
),
|
|
703
|
+
options=make_request_options(
|
|
704
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
705
|
+
),
|
|
706
|
+
cast_to=NoneType,
|
|
707
|
+
)
|
|
708
|
+
|
|
709
|
+
async def retrieve(
|
|
710
|
+
self,
|
|
711
|
+
id: str,
|
|
712
|
+
*,
|
|
713
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
714
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
715
|
+
extra_headers: Headers | None = None,
|
|
716
|
+
extra_query: Query | None = None,
|
|
717
|
+
extra_body: Body | None = None,
|
|
718
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
719
|
+
) -> None:
|
|
720
|
+
"""
|
|
721
|
+
Get details of a specific web application project
|
|
722
|
+
|
|
723
|
+
Args:
|
|
724
|
+
extra_headers: Send extra headers
|
|
725
|
+
|
|
726
|
+
extra_query: Add additional query parameters to the request
|
|
727
|
+
|
|
728
|
+
extra_body: Add additional JSON properties to the request
|
|
729
|
+
|
|
730
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
731
|
+
"""
|
|
732
|
+
if not id:
|
|
733
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
734
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
735
|
+
return await self._get(
|
|
736
|
+
f"/applications/v1/projects/{id}",
|
|
737
|
+
options=make_request_options(
|
|
738
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
739
|
+
),
|
|
740
|
+
cast_to=NoneType,
|
|
741
|
+
)
|
|
742
|
+
|
|
743
|
+
async def list(
|
|
744
|
+
self,
|
|
745
|
+
*,
|
|
746
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
747
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
748
|
+
extra_headers: Headers | None = None,
|
|
749
|
+
extra_query: Query | None = None,
|
|
750
|
+
extra_body: Body | None = None,
|
|
751
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
752
|
+
) -> ProjectListResponse:
|
|
753
|
+
"""List all web application projects"""
|
|
754
|
+
return await self._get(
|
|
755
|
+
"/applications/v1/projects",
|
|
756
|
+
options=make_request_options(
|
|
757
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
758
|
+
),
|
|
759
|
+
cast_to=ProjectListResponse,
|
|
760
|
+
)
|
|
761
|
+
|
|
762
|
+
async def delete(
|
|
763
|
+
self,
|
|
764
|
+
id: str,
|
|
765
|
+
*,
|
|
766
|
+
delete_from_hosting: bool | Omit = omit,
|
|
767
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
768
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
769
|
+
extra_headers: Headers | None = None,
|
|
770
|
+
extra_query: Query | None = None,
|
|
771
|
+
extra_body: Body | None = None,
|
|
772
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
773
|
+
) -> None:
|
|
774
|
+
"""
|
|
775
|
+
Delete a web application project
|
|
776
|
+
|
|
777
|
+
Args:
|
|
778
|
+
delete_from_hosting: Also delete the project from hosting (default: true)
|
|
779
|
+
|
|
780
|
+
extra_headers: Send extra headers
|
|
781
|
+
|
|
782
|
+
extra_query: Add additional query parameters to the request
|
|
783
|
+
|
|
784
|
+
extra_body: Add additional JSON properties to the request
|
|
785
|
+
|
|
786
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
787
|
+
"""
|
|
788
|
+
if not id:
|
|
789
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
790
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
791
|
+
return await self._delete(
|
|
792
|
+
f"/applications/v1/projects/{id}",
|
|
793
|
+
options=make_request_options(
|
|
794
|
+
extra_headers=extra_headers,
|
|
795
|
+
extra_query=extra_query,
|
|
796
|
+
extra_body=extra_body,
|
|
797
|
+
timeout=timeout,
|
|
798
|
+
query=await async_maybe_transform(
|
|
799
|
+
{"delete_from_hosting": delete_from_hosting}, project_delete_params.ProjectDeleteParams
|
|
800
|
+
),
|
|
801
|
+
),
|
|
802
|
+
cast_to=NoneType,
|
|
803
|
+
)
|
|
804
|
+
|
|
805
|
+
async def create_deployment(
|
|
806
|
+
self,
|
|
807
|
+
id: str,
|
|
808
|
+
*,
|
|
809
|
+
environment_variables: Iterable[project_create_deployment_params.EnvironmentVariable] | Omit = omit,
|
|
810
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
811
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
812
|
+
extra_headers: Headers | None = None,
|
|
813
|
+
extra_query: Query | None = None,
|
|
814
|
+
extra_body: Body | None = None,
|
|
815
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
816
|
+
) -> None:
|
|
817
|
+
"""
|
|
818
|
+
Trigger a new deployment for a project.
|
|
819
|
+
|
|
820
|
+
Args:
|
|
821
|
+
environment_variables: Additional environment variables to set or update before deployment
|
|
822
|
+
|
|
823
|
+
extra_headers: Send extra headers
|
|
824
|
+
|
|
825
|
+
extra_query: Add additional query parameters to the request
|
|
826
|
+
|
|
827
|
+
extra_body: Add additional JSON properties to the request
|
|
828
|
+
|
|
829
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
830
|
+
"""
|
|
831
|
+
if not id:
|
|
832
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
833
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
834
|
+
return await self._post(
|
|
835
|
+
f"/applications/v1/projects/{id}/deployments",
|
|
836
|
+
body=await async_maybe_transform(
|
|
837
|
+
{"environment_variables": environment_variables},
|
|
838
|
+
project_create_deployment_params.ProjectCreateDeploymentParams,
|
|
839
|
+
),
|
|
840
|
+
options=make_request_options(
|
|
841
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
842
|
+
),
|
|
843
|
+
cast_to=NoneType,
|
|
844
|
+
)
|
|
845
|
+
|
|
846
|
+
async def create_domain(
|
|
847
|
+
self,
|
|
848
|
+
id: str,
|
|
849
|
+
*,
|
|
850
|
+
domain: str,
|
|
851
|
+
git_branch: str | Omit = omit,
|
|
852
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
853
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
854
|
+
extra_headers: Headers | None = None,
|
|
855
|
+
extra_query: Query | None = None,
|
|
856
|
+
extra_body: Body | None = None,
|
|
857
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
858
|
+
) -> None:
|
|
859
|
+
"""
|
|
860
|
+
Add a custom domain to a project
|
|
861
|
+
|
|
862
|
+
Args:
|
|
863
|
+
domain: Domain name to add
|
|
864
|
+
|
|
865
|
+
git_branch: Git branch to associate with this domain
|
|
866
|
+
|
|
867
|
+
extra_headers: Send extra headers
|
|
868
|
+
|
|
869
|
+
extra_query: Add additional query parameters to the request
|
|
870
|
+
|
|
871
|
+
extra_body: Add additional JSON properties to the request
|
|
872
|
+
|
|
873
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
874
|
+
"""
|
|
875
|
+
if not id:
|
|
876
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
877
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
878
|
+
return await self._post(
|
|
879
|
+
f"/applications/v1/projects/{id}/domains",
|
|
880
|
+
body=await async_maybe_transform(
|
|
881
|
+
{
|
|
882
|
+
"domain": domain,
|
|
883
|
+
"git_branch": git_branch,
|
|
884
|
+
},
|
|
885
|
+
project_create_domain_params.ProjectCreateDomainParams,
|
|
886
|
+
),
|
|
887
|
+
options=make_request_options(
|
|
888
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
889
|
+
),
|
|
890
|
+
cast_to=NoneType,
|
|
891
|
+
)
|
|
892
|
+
|
|
893
|
+
async def create_env(
|
|
894
|
+
self,
|
|
895
|
+
id: str,
|
|
896
|
+
*,
|
|
897
|
+
key: str,
|
|
898
|
+
target: List[Literal["production", "preview", "development"]],
|
|
899
|
+
value: str,
|
|
900
|
+
git_branch: str | Omit = omit,
|
|
901
|
+
type: Literal["plain", "encrypted", "secret"] | Omit = omit,
|
|
902
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
903
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
904
|
+
extra_headers: Headers | None = None,
|
|
905
|
+
extra_query: Query | None = None,
|
|
906
|
+
extra_body: Body | None = None,
|
|
907
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
908
|
+
) -> None:
|
|
909
|
+
"""
|
|
910
|
+
Create a new environment variable for a project
|
|
911
|
+
|
|
912
|
+
Args:
|
|
913
|
+
key: Environment variable name
|
|
914
|
+
|
|
915
|
+
target: Deployment targets for this variable
|
|
916
|
+
|
|
917
|
+
value: Environment variable value
|
|
918
|
+
|
|
919
|
+
git_branch: Specific git branch (for preview deployments)
|
|
920
|
+
|
|
921
|
+
type: Variable type
|
|
922
|
+
|
|
923
|
+
extra_headers: Send extra headers
|
|
924
|
+
|
|
925
|
+
extra_query: Add additional query parameters to the request
|
|
926
|
+
|
|
927
|
+
extra_body: Add additional JSON properties to the request
|
|
928
|
+
|
|
929
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
930
|
+
"""
|
|
931
|
+
if not id:
|
|
932
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
933
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
934
|
+
return await self._post(
|
|
935
|
+
f"/applications/v1/projects/{id}/env",
|
|
936
|
+
body=await async_maybe_transform(
|
|
937
|
+
{
|
|
938
|
+
"key": key,
|
|
939
|
+
"target": target,
|
|
940
|
+
"value": value,
|
|
941
|
+
"git_branch": git_branch,
|
|
942
|
+
"type": type,
|
|
943
|
+
},
|
|
944
|
+
project_create_env_params.ProjectCreateEnvParams,
|
|
945
|
+
),
|
|
946
|
+
options=make_request_options(
|
|
947
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
948
|
+
),
|
|
949
|
+
cast_to=NoneType,
|
|
950
|
+
)
|
|
951
|
+
|
|
952
|
+
async def delete_domain(
|
|
953
|
+
self,
|
|
954
|
+
domain: str,
|
|
955
|
+
*,
|
|
956
|
+
id: str,
|
|
957
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
958
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
959
|
+
extra_headers: Headers | None = None,
|
|
960
|
+
extra_query: Query | None = None,
|
|
961
|
+
extra_body: Body | None = None,
|
|
962
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
963
|
+
) -> None:
|
|
964
|
+
"""
|
|
965
|
+
Remove a domain from a project
|
|
966
|
+
|
|
967
|
+
Args:
|
|
968
|
+
extra_headers: Send extra headers
|
|
969
|
+
|
|
970
|
+
extra_query: Add additional query parameters to the request
|
|
971
|
+
|
|
972
|
+
extra_body: Add additional JSON properties to the request
|
|
973
|
+
|
|
974
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
975
|
+
"""
|
|
976
|
+
if not id:
|
|
977
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
978
|
+
if not domain:
|
|
979
|
+
raise ValueError(f"Expected a non-empty value for `domain` but received {domain!r}")
|
|
980
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
981
|
+
return await self._delete(
|
|
982
|
+
f"/applications/v1/projects/{id}/domains/{domain}",
|
|
983
|
+
options=make_request_options(
|
|
984
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
985
|
+
),
|
|
986
|
+
cast_to=NoneType,
|
|
987
|
+
)
|
|
988
|
+
|
|
989
|
+
async def delete_env(
|
|
990
|
+
self,
|
|
991
|
+
env_id: str,
|
|
992
|
+
*,
|
|
993
|
+
id: str,
|
|
994
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
995
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
996
|
+
extra_headers: Headers | None = None,
|
|
997
|
+
extra_query: Query | None = None,
|
|
998
|
+
extra_body: Body | None = None,
|
|
999
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
1000
|
+
) -> None:
|
|
1001
|
+
"""
|
|
1002
|
+
Delete an environment variable from a project
|
|
1003
|
+
|
|
1004
|
+
Args:
|
|
1005
|
+
extra_headers: Send extra headers
|
|
1006
|
+
|
|
1007
|
+
extra_query: Add additional query parameters to the request
|
|
1008
|
+
|
|
1009
|
+
extra_body: Add additional JSON properties to the request
|
|
1010
|
+
|
|
1011
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
1012
|
+
"""
|
|
1013
|
+
if not id:
|
|
1014
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
1015
|
+
if not env_id:
|
|
1016
|
+
raise ValueError(f"Expected a non-empty value for `env_id` but received {env_id!r}")
|
|
1017
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
1018
|
+
return await self._delete(
|
|
1019
|
+
f"/applications/v1/projects/{id}/env/{env_id}",
|
|
1020
|
+
options=make_request_options(
|
|
1021
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
1022
|
+
),
|
|
1023
|
+
cast_to=NoneType,
|
|
1024
|
+
)
|
|
1025
|
+
|
|
1026
|
+
async def get_runtime_logs(
|
|
1027
|
+
self,
|
|
1028
|
+
id: str,
|
|
1029
|
+
*,
|
|
1030
|
+
limit: float | Omit = omit,
|
|
1031
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
1032
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
1033
|
+
extra_headers: Headers | None = None,
|
|
1034
|
+
extra_query: Query | None = None,
|
|
1035
|
+
extra_body: Body | None = None,
|
|
1036
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
1037
|
+
) -> None:
|
|
1038
|
+
"""
|
|
1039
|
+
Get runtime/function logs for a project
|
|
1040
|
+
|
|
1041
|
+
Args:
|
|
1042
|
+
limit: Maximum number of logs to return
|
|
1043
|
+
|
|
1044
|
+
extra_headers: Send extra headers
|
|
1045
|
+
|
|
1046
|
+
extra_query: Add additional query parameters to the request
|
|
1047
|
+
|
|
1048
|
+
extra_body: Add additional JSON properties to the request
|
|
1049
|
+
|
|
1050
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
1051
|
+
"""
|
|
1052
|
+
if not id:
|
|
1053
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
1054
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
1055
|
+
return await self._get(
|
|
1056
|
+
f"/applications/v1/projects/{id}/runtime-logs",
|
|
1057
|
+
options=make_request_options(
|
|
1058
|
+
extra_headers=extra_headers,
|
|
1059
|
+
extra_query=extra_query,
|
|
1060
|
+
extra_body=extra_body,
|
|
1061
|
+
timeout=timeout,
|
|
1062
|
+
query=await async_maybe_transform(
|
|
1063
|
+
{"limit": limit}, project_get_runtime_logs_params.ProjectGetRuntimeLogsParams
|
|
1064
|
+
),
|
|
1065
|
+
),
|
|
1066
|
+
cast_to=NoneType,
|
|
1067
|
+
)
|
|
1068
|
+
|
|
1069
|
+
async def list_deployments(
|
|
1070
|
+
self,
|
|
1071
|
+
id: str,
|
|
1072
|
+
*,
|
|
1073
|
+
limit: float | Omit = omit,
|
|
1074
|
+
state: str | Omit = omit,
|
|
1075
|
+
target: Literal["production", "staging"] | Omit = omit,
|
|
1076
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
1077
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
1078
|
+
extra_headers: Headers | None = None,
|
|
1079
|
+
extra_query: Query | None = None,
|
|
1080
|
+
extra_body: Body | None = None,
|
|
1081
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
1082
|
+
) -> None:
|
|
1083
|
+
"""
|
|
1084
|
+
List deployments for a specific project
|
|
1085
|
+
|
|
1086
|
+
Args:
|
|
1087
|
+
limit: Maximum number of deployments to return
|
|
1088
|
+
|
|
1089
|
+
state: Filter by deployment state
|
|
1090
|
+
|
|
1091
|
+
target: Filter by deployment target
|
|
1092
|
+
|
|
1093
|
+
extra_headers: Send extra headers
|
|
1094
|
+
|
|
1095
|
+
extra_query: Add additional query parameters to the request
|
|
1096
|
+
|
|
1097
|
+
extra_body: Add additional JSON properties to the request
|
|
1098
|
+
|
|
1099
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
1100
|
+
"""
|
|
1101
|
+
if not id:
|
|
1102
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
1103
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
1104
|
+
return await self._get(
|
|
1105
|
+
f"/applications/v1/projects/{id}/deployments",
|
|
1106
|
+
options=make_request_options(
|
|
1107
|
+
extra_headers=extra_headers,
|
|
1108
|
+
extra_query=extra_query,
|
|
1109
|
+
extra_body=extra_body,
|
|
1110
|
+
timeout=timeout,
|
|
1111
|
+
query=await async_maybe_transform(
|
|
1112
|
+
{
|
|
1113
|
+
"limit": limit,
|
|
1114
|
+
"state": state,
|
|
1115
|
+
"target": target,
|
|
1116
|
+
},
|
|
1117
|
+
project_list_deployments_params.ProjectListDeploymentsParams,
|
|
1118
|
+
),
|
|
1119
|
+
),
|
|
1120
|
+
cast_to=NoneType,
|
|
1121
|
+
)
|
|
1122
|
+
|
|
1123
|
+
async def list_domains(
|
|
1124
|
+
self,
|
|
1125
|
+
id: str,
|
|
1126
|
+
*,
|
|
1127
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
1128
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
1129
|
+
extra_headers: Headers | None = None,
|
|
1130
|
+
extra_query: Query | None = None,
|
|
1131
|
+
extra_body: Body | None = None,
|
|
1132
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
1133
|
+
) -> None:
|
|
1134
|
+
"""
|
|
1135
|
+
List all domains configured for a project
|
|
1136
|
+
|
|
1137
|
+
Args:
|
|
1138
|
+
extra_headers: Send extra headers
|
|
1139
|
+
|
|
1140
|
+
extra_query: Add additional query parameters to the request
|
|
1141
|
+
|
|
1142
|
+
extra_body: Add additional JSON properties to the request
|
|
1143
|
+
|
|
1144
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
1145
|
+
"""
|
|
1146
|
+
if not id:
|
|
1147
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
1148
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
1149
|
+
return await self._get(
|
|
1150
|
+
f"/applications/v1/projects/{id}/domains",
|
|
1151
|
+
options=make_request_options(
|
|
1152
|
+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
|
1153
|
+
),
|
|
1154
|
+
cast_to=NoneType,
|
|
1155
|
+
)
|
|
1156
|
+
|
|
1157
|
+
async def list_env(
|
|
1158
|
+
self,
|
|
1159
|
+
id: str,
|
|
1160
|
+
*,
|
|
1161
|
+
decrypt: bool | Omit = omit,
|
|
1162
|
+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
|
1163
|
+
# The extra values given here take precedence over values defined on the client or passed to this method.
|
|
1164
|
+
extra_headers: Headers | None = None,
|
|
1165
|
+
extra_query: Query | None = None,
|
|
1166
|
+
extra_body: Body | None = None,
|
|
1167
|
+
timeout: float | httpx.Timeout | None | NotGiven = not_given,
|
|
1168
|
+
) -> None:
|
|
1169
|
+
"""
|
|
1170
|
+
List all environment variables for a project (values are hidden unless
|
|
1171
|
+
decrypt=true)
|
|
1172
|
+
|
|
1173
|
+
Args:
|
|
1174
|
+
decrypt: Whether to decrypt and return values (requires appropriate permissions)
|
|
1175
|
+
|
|
1176
|
+
extra_headers: Send extra headers
|
|
1177
|
+
|
|
1178
|
+
extra_query: Add additional query parameters to the request
|
|
1179
|
+
|
|
1180
|
+
extra_body: Add additional JSON properties to the request
|
|
1181
|
+
|
|
1182
|
+
timeout: Override the client-level default timeout for this request, in seconds
|
|
1183
|
+
"""
|
|
1184
|
+
if not id:
|
|
1185
|
+
raise ValueError(f"Expected a non-empty value for `id` but received {id!r}")
|
|
1186
|
+
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
|
1187
|
+
return await self._get(
|
|
1188
|
+
f"/applications/v1/projects/{id}/env",
|
|
1189
|
+
options=make_request_options(
|
|
1190
|
+
extra_headers=extra_headers,
|
|
1191
|
+
extra_query=extra_query,
|
|
1192
|
+
extra_body=extra_body,
|
|
1193
|
+
timeout=timeout,
|
|
1194
|
+
query=await async_maybe_transform({"decrypt": decrypt}, project_list_env_params.ProjectListEnvParams),
|
|
1195
|
+
),
|
|
1196
|
+
cast_to=NoneType,
|
|
1197
|
+
)
|
|
1198
|
+
|
|
1199
|
+
|
|
1200
|
+
class ProjectsResourceWithRawResponse:
|
|
1201
|
+
def __init__(self, projects: ProjectsResource) -> None:
|
|
1202
|
+
self._projects = projects
|
|
1203
|
+
|
|
1204
|
+
self.create = to_raw_response_wrapper(
|
|
1205
|
+
projects.create,
|
|
1206
|
+
)
|
|
1207
|
+
self.retrieve = to_raw_response_wrapper(
|
|
1208
|
+
projects.retrieve,
|
|
1209
|
+
)
|
|
1210
|
+
self.list = to_raw_response_wrapper(
|
|
1211
|
+
projects.list,
|
|
1212
|
+
)
|
|
1213
|
+
self.delete = to_raw_response_wrapper(
|
|
1214
|
+
projects.delete,
|
|
1215
|
+
)
|
|
1216
|
+
self.create_deployment = to_raw_response_wrapper(
|
|
1217
|
+
projects.create_deployment,
|
|
1218
|
+
)
|
|
1219
|
+
self.create_domain = to_raw_response_wrapper(
|
|
1220
|
+
projects.create_domain,
|
|
1221
|
+
)
|
|
1222
|
+
self.create_env = to_raw_response_wrapper(
|
|
1223
|
+
projects.create_env,
|
|
1224
|
+
)
|
|
1225
|
+
self.delete_domain = to_raw_response_wrapper(
|
|
1226
|
+
projects.delete_domain,
|
|
1227
|
+
)
|
|
1228
|
+
self.delete_env = to_raw_response_wrapper(
|
|
1229
|
+
projects.delete_env,
|
|
1230
|
+
)
|
|
1231
|
+
self.get_runtime_logs = to_raw_response_wrapper(
|
|
1232
|
+
projects.get_runtime_logs,
|
|
1233
|
+
)
|
|
1234
|
+
self.list_deployments = to_raw_response_wrapper(
|
|
1235
|
+
projects.list_deployments,
|
|
1236
|
+
)
|
|
1237
|
+
self.list_domains = to_raw_response_wrapper(
|
|
1238
|
+
projects.list_domains,
|
|
1239
|
+
)
|
|
1240
|
+
self.list_env = to_raw_response_wrapper(
|
|
1241
|
+
projects.list_env,
|
|
1242
|
+
)
|
|
1243
|
+
|
|
1244
|
+
|
|
1245
|
+
class AsyncProjectsResourceWithRawResponse:
|
|
1246
|
+
def __init__(self, projects: AsyncProjectsResource) -> None:
|
|
1247
|
+
self._projects = projects
|
|
1248
|
+
|
|
1249
|
+
self.create = async_to_raw_response_wrapper(
|
|
1250
|
+
projects.create,
|
|
1251
|
+
)
|
|
1252
|
+
self.retrieve = async_to_raw_response_wrapper(
|
|
1253
|
+
projects.retrieve,
|
|
1254
|
+
)
|
|
1255
|
+
self.list = async_to_raw_response_wrapper(
|
|
1256
|
+
projects.list,
|
|
1257
|
+
)
|
|
1258
|
+
self.delete = async_to_raw_response_wrapper(
|
|
1259
|
+
projects.delete,
|
|
1260
|
+
)
|
|
1261
|
+
self.create_deployment = async_to_raw_response_wrapper(
|
|
1262
|
+
projects.create_deployment,
|
|
1263
|
+
)
|
|
1264
|
+
self.create_domain = async_to_raw_response_wrapper(
|
|
1265
|
+
projects.create_domain,
|
|
1266
|
+
)
|
|
1267
|
+
self.create_env = async_to_raw_response_wrapper(
|
|
1268
|
+
projects.create_env,
|
|
1269
|
+
)
|
|
1270
|
+
self.delete_domain = async_to_raw_response_wrapper(
|
|
1271
|
+
projects.delete_domain,
|
|
1272
|
+
)
|
|
1273
|
+
self.delete_env = async_to_raw_response_wrapper(
|
|
1274
|
+
projects.delete_env,
|
|
1275
|
+
)
|
|
1276
|
+
self.get_runtime_logs = async_to_raw_response_wrapper(
|
|
1277
|
+
projects.get_runtime_logs,
|
|
1278
|
+
)
|
|
1279
|
+
self.list_deployments = async_to_raw_response_wrapper(
|
|
1280
|
+
projects.list_deployments,
|
|
1281
|
+
)
|
|
1282
|
+
self.list_domains = async_to_raw_response_wrapper(
|
|
1283
|
+
projects.list_domains,
|
|
1284
|
+
)
|
|
1285
|
+
self.list_env = async_to_raw_response_wrapper(
|
|
1286
|
+
projects.list_env,
|
|
1287
|
+
)
|
|
1288
|
+
|
|
1289
|
+
|
|
1290
|
+
class ProjectsResourceWithStreamingResponse:
|
|
1291
|
+
def __init__(self, projects: ProjectsResource) -> None:
|
|
1292
|
+
self._projects = projects
|
|
1293
|
+
|
|
1294
|
+
self.create = to_streamed_response_wrapper(
|
|
1295
|
+
projects.create,
|
|
1296
|
+
)
|
|
1297
|
+
self.retrieve = to_streamed_response_wrapper(
|
|
1298
|
+
projects.retrieve,
|
|
1299
|
+
)
|
|
1300
|
+
self.list = to_streamed_response_wrapper(
|
|
1301
|
+
projects.list,
|
|
1302
|
+
)
|
|
1303
|
+
self.delete = to_streamed_response_wrapper(
|
|
1304
|
+
projects.delete,
|
|
1305
|
+
)
|
|
1306
|
+
self.create_deployment = to_streamed_response_wrapper(
|
|
1307
|
+
projects.create_deployment,
|
|
1308
|
+
)
|
|
1309
|
+
self.create_domain = to_streamed_response_wrapper(
|
|
1310
|
+
projects.create_domain,
|
|
1311
|
+
)
|
|
1312
|
+
self.create_env = to_streamed_response_wrapper(
|
|
1313
|
+
projects.create_env,
|
|
1314
|
+
)
|
|
1315
|
+
self.delete_domain = to_streamed_response_wrapper(
|
|
1316
|
+
projects.delete_domain,
|
|
1317
|
+
)
|
|
1318
|
+
self.delete_env = to_streamed_response_wrapper(
|
|
1319
|
+
projects.delete_env,
|
|
1320
|
+
)
|
|
1321
|
+
self.get_runtime_logs = to_streamed_response_wrapper(
|
|
1322
|
+
projects.get_runtime_logs,
|
|
1323
|
+
)
|
|
1324
|
+
self.list_deployments = to_streamed_response_wrapper(
|
|
1325
|
+
projects.list_deployments,
|
|
1326
|
+
)
|
|
1327
|
+
self.list_domains = to_streamed_response_wrapper(
|
|
1328
|
+
projects.list_domains,
|
|
1329
|
+
)
|
|
1330
|
+
self.list_env = to_streamed_response_wrapper(
|
|
1331
|
+
projects.list_env,
|
|
1332
|
+
)
|
|
1333
|
+
|
|
1334
|
+
|
|
1335
|
+
class AsyncProjectsResourceWithStreamingResponse:
|
|
1336
|
+
def __init__(self, projects: AsyncProjectsResource) -> None:
|
|
1337
|
+
self._projects = projects
|
|
1338
|
+
|
|
1339
|
+
self.create = async_to_streamed_response_wrapper(
|
|
1340
|
+
projects.create,
|
|
1341
|
+
)
|
|
1342
|
+
self.retrieve = async_to_streamed_response_wrapper(
|
|
1343
|
+
projects.retrieve,
|
|
1344
|
+
)
|
|
1345
|
+
self.list = async_to_streamed_response_wrapper(
|
|
1346
|
+
projects.list,
|
|
1347
|
+
)
|
|
1348
|
+
self.delete = async_to_streamed_response_wrapper(
|
|
1349
|
+
projects.delete,
|
|
1350
|
+
)
|
|
1351
|
+
self.create_deployment = async_to_streamed_response_wrapper(
|
|
1352
|
+
projects.create_deployment,
|
|
1353
|
+
)
|
|
1354
|
+
self.create_domain = async_to_streamed_response_wrapper(
|
|
1355
|
+
projects.create_domain,
|
|
1356
|
+
)
|
|
1357
|
+
self.create_env = async_to_streamed_response_wrapper(
|
|
1358
|
+
projects.create_env,
|
|
1359
|
+
)
|
|
1360
|
+
self.delete_domain = async_to_streamed_response_wrapper(
|
|
1361
|
+
projects.delete_domain,
|
|
1362
|
+
)
|
|
1363
|
+
self.delete_env = async_to_streamed_response_wrapper(
|
|
1364
|
+
projects.delete_env,
|
|
1365
|
+
)
|
|
1366
|
+
self.get_runtime_logs = async_to_streamed_response_wrapper(
|
|
1367
|
+
projects.get_runtime_logs,
|
|
1368
|
+
)
|
|
1369
|
+
self.list_deployments = async_to_streamed_response_wrapper(
|
|
1370
|
+
projects.list_deployments,
|
|
1371
|
+
)
|
|
1372
|
+
self.list_domains = async_to_streamed_response_wrapper(
|
|
1373
|
+
projects.list_domains,
|
|
1374
|
+
)
|
|
1375
|
+
self.list_env = async_to_streamed_response_wrapper(
|
|
1376
|
+
projects.list_env,
|
|
1377
|
+
)
|