Skip to content

Commit 87524c3

Browse files
feat(api): update via SDK Studio
1 parent 497ae18 commit 87524c3

File tree

64 files changed

+4739
-952
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+4739
-952
lines changed

Diff for: .stats.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
configured_endpoints: 54
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-6d44c8845e1deee92c3e6406d5b67aa72616ec5e21ab8c722ae0a2c214c14784.yml
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-7e374f66c50c3d639f586ea9e146d57787b1b72a9edf1c552ba67ddd5bd4b190.yml

Diff for: api.md

+6-13
Original file line numberDiff line numberDiff line change
@@ -133,26 +133,19 @@ Methods:
133133
Types:
134134

135135
```python
136-
from gitpod.types import OrganizationLeaveResponse, OrganizationSetRoleResponse
136+
from gitpod.types import (
137+
OrganizationLeaveResponse,
138+
OrganizationListMembersResponse,
139+
OrganizationSetRoleResponse,
140+
)
137141
```
138142

139143
Methods:
140144

141145
- <code title="post /gitpod.v1.OrganizationService/LeaveOrganization">client.organizations.<a href="./src/gitpod/resources/organizations/organizations.py">leave</a>(\*\*<a href="src/gitpod/types/organization_leave_params.py">params</a>) -> <a href="./src/gitpod/types/organization_leave_response.py">object</a></code>
146+
- <code title="post /gitpod.v1.OrganizationService/ListMembers">client.organizations.<a href="./src/gitpod/resources/organizations/organizations.py">list_members</a>(\*\*<a href="src/gitpod/types/organization_list_members_params.py">params</a>) -> <a href="./src/gitpod/types/organization_list_members_response.py">OrganizationListMembersResponse</a></code>
142147
- <code title="post /gitpod.v1.OrganizationService/SetRole">client.organizations.<a href="./src/gitpod/resources/organizations/organizations.py">set_role</a>(\*\*<a href="src/gitpod/types/organization_set_role_params.py">params</a>) -> <a href="./src/gitpod/types/organization_set_role_response.py">object</a></code>
143148

144-
## Members
145-
146-
Types:
147-
148-
```python
149-
from gitpod.types.organizations import MemberListResponse
150-
```
151-
152-
Methods:
153-
154-
- <code title="post /gitpod.v1.OrganizationService/ListMembers">client.organizations.members.<a href="./src/gitpod/resources/organizations/members.py">list</a>(\*\*<a href="src/gitpod/types/organizations/member_list_params.py">params</a>) -> <a href="./src/gitpod/types/organizations/member_list_response.py">MemberListResponse</a></code>
155-
156149
## Invite
157150

158151
Types:

Diff for: src/gitpod/resources/environment_classes.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def list(
5252
self,
5353
*,
5454
connect_protocol_version: Literal[1],
55-
filter: object | NotGiven = NOT_GIVEN,
55+
filter: environment_class_list_params.Filter | NotGiven = NOT_GIVEN,
5656
pagination: environment_class_list_params.Pagination | NotGiven = NOT_GIVEN,
5757
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
5858
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -132,7 +132,7 @@ async def list(
132132
self,
133133
*,
134134
connect_protocol_version: Literal[1],
135-
filter: object | NotGiven = NOT_GIVEN,
135+
filter: environment_class_list_params.Filter | NotGiven = NOT_GIVEN,
136136
pagination: environment_class_list_params.Pagination | NotGiven = NOT_GIVEN,
137137
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
138138
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.

Diff for: src/gitpod/resources/environments/automations/task_executions.py

+136-5
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22

33
from __future__ import annotations
44

5-
from typing_extensions import Literal
5+
from typing_extensions import Literal, overload
66

77
import httpx
88

99
from ...._types import NOT_GIVEN, Body, Query, Headers, NotGiven
1010
from ...._utils import (
1111
is_given,
12+
required_args,
1213
maybe_transform,
1314
strip_not_given,
1415
async_maybe_transform,
@@ -206,10 +207,11 @@ def stop(
206207
cast_to=object,
207208
)
208209

210+
@overload
209211
def update_task_execution_status(
210212
self,
211213
*,
212-
body: task_execution_update_task_execution_status_params.Body,
214+
failure_message: str,
213215
connect_protocol_version: Literal[1],
214216
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
215217
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -225,6 +227,12 @@ def update_task_execution_status(
225227
environment executing a task execution is expected to call this function.
226228
227229
Args:
230+
failure_message: failure_message marks the task execution as failed and provides a message
231+
explaining the failure.
232+
233+
If an individual step has failed, callers are NOT expected to set this message;
234+
only if the task execution as a whole has failed/cannot be started.
235+
228236
connect_protocol_version: Define the version of the Connect protocol
229237
230238
connect_timeout_ms: Define the timeout, in ms
@@ -237,6 +245,60 @@ def update_task_execution_status(
237245
238246
timeout: Override the client-level default timeout for this request, in seconds
239247
"""
248+
...
249+
250+
@overload
251+
def update_task_execution_status(
252+
self,
253+
*,
254+
log_url: str,
255+
connect_protocol_version: Literal[1],
256+
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
257+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
258+
# The extra values given here take precedence over values defined on the client or passed to this method.
259+
extra_headers: Headers | None = None,
260+
extra_query: Query | None = None,
261+
extra_body: Body | None = None,
262+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
263+
) -> object:
264+
"""UpdateTaskExecutionStatus updates the status of a task execution.
265+
266+
Only the
267+
environment executing a task execution is expected to call this function.
268+
269+
Args:
270+
log_url: log_url is the URL to the logs of the task's steps. If this is empty, the task
271+
either has no logs or has not yet started.
272+
273+
connect_protocol_version: Define the version of the Connect protocol
274+
275+
connect_timeout_ms: Define the timeout, in ms
276+
277+
extra_headers: Send extra headers
278+
279+
extra_query: Add additional query parameters to the request
280+
281+
extra_body: Add additional JSON properties to the request
282+
283+
timeout: Override the client-level default timeout for this request, in seconds
284+
"""
285+
...
286+
287+
@required_args(["failure_message", "connect_protocol_version"], ["log_url", "connect_protocol_version"])
288+
def update_task_execution_status(
289+
self,
290+
*,
291+
failure_message: str | NotGiven = NOT_GIVEN,
292+
connect_protocol_version: Literal[1],
293+
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
294+
log_url: str | NotGiven = NOT_GIVEN,
295+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
296+
# The extra values given here take precedence over values defined on the client or passed to this method.
297+
extra_headers: Headers | None = None,
298+
extra_query: Query | None = None,
299+
extra_body: Body | None = None,
300+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
301+
) -> object:
240302
extra_headers = {
241303
**strip_not_given(
242304
{
@@ -249,7 +311,11 @@ def update_task_execution_status(
249311
return self._post(
250312
"/gitpod.v1.EnvironmentAutomationService/UpdateTaskExecutionStatus",
251313
body=maybe_transform(
252-
body, task_execution_update_task_execution_status_params.TaskExecutionUpdateTaskExecutionStatusParams
314+
{
315+
"failure_message": failure_message,
316+
"log_url": log_url,
317+
},
318+
task_execution_update_task_execution_status_params.TaskExecutionUpdateTaskExecutionStatusParams,
253319
),
254320
options=make_request_options(
255321
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
@@ -430,10 +496,11 @@ async def stop(
430496
cast_to=object,
431497
)
432498

499+
@overload
433500
async def update_task_execution_status(
434501
self,
435502
*,
436-
body: task_execution_update_task_execution_status_params.Body,
503+
failure_message: str,
437504
connect_protocol_version: Literal[1],
438505
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
439506
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -449,6 +516,12 @@ async def update_task_execution_status(
449516
environment executing a task execution is expected to call this function.
450517
451518
Args:
519+
failure_message: failure_message marks the task execution as failed and provides a message
520+
explaining the failure.
521+
522+
If an individual step has failed, callers are NOT expected to set this message;
523+
only if the task execution as a whole has failed/cannot be started.
524+
452525
connect_protocol_version: Define the version of the Connect protocol
453526
454527
connect_timeout_ms: Define the timeout, in ms
@@ -461,6 +534,60 @@ async def update_task_execution_status(
461534
462535
timeout: Override the client-level default timeout for this request, in seconds
463536
"""
537+
...
538+
539+
@overload
540+
async def update_task_execution_status(
541+
self,
542+
*,
543+
log_url: str,
544+
connect_protocol_version: Literal[1],
545+
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
546+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
547+
# The extra values given here take precedence over values defined on the client or passed to this method.
548+
extra_headers: Headers | None = None,
549+
extra_query: Query | None = None,
550+
extra_body: Body | None = None,
551+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
552+
) -> object:
553+
"""UpdateTaskExecutionStatus updates the status of a task execution.
554+
555+
Only the
556+
environment executing a task execution is expected to call this function.
557+
558+
Args:
559+
log_url: log_url is the URL to the logs of the task's steps. If this is empty, the task
560+
either has no logs or has not yet started.
561+
562+
connect_protocol_version: Define the version of the Connect protocol
563+
564+
connect_timeout_ms: Define the timeout, in ms
565+
566+
extra_headers: Send extra headers
567+
568+
extra_query: Add additional query parameters to the request
569+
570+
extra_body: Add additional JSON properties to the request
571+
572+
timeout: Override the client-level default timeout for this request, in seconds
573+
"""
574+
...
575+
576+
@required_args(["failure_message", "connect_protocol_version"], ["log_url", "connect_protocol_version"])
577+
async def update_task_execution_status(
578+
self,
579+
*,
580+
failure_message: str | NotGiven = NOT_GIVEN,
581+
connect_protocol_version: Literal[1],
582+
connect_timeout_ms: float | NotGiven = NOT_GIVEN,
583+
log_url: str | NotGiven = NOT_GIVEN,
584+
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
585+
# The extra values given here take precedence over values defined on the client or passed to this method.
586+
extra_headers: Headers | None = None,
587+
extra_query: Query | None = None,
588+
extra_body: Body | None = None,
589+
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
590+
) -> object:
464591
extra_headers = {
465592
**strip_not_given(
466593
{
@@ -473,7 +600,11 @@ async def update_task_execution_status(
473600
return await self._post(
474601
"/gitpod.v1.EnvironmentAutomationService/UpdateTaskExecutionStatus",
475602
body=await async_maybe_transform(
476-
body, task_execution_update_task_execution_status_params.TaskExecutionUpdateTaskExecutionStatusParams
603+
{
604+
"failure_message": failure_message,
605+
"log_url": log_url,
606+
},
607+
task_execution_update_task_execution_status_params.TaskExecutionUpdateTaskExecutionStatusParams,
477608
),
478609
options=make_request_options(
479610
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout

Diff for: src/gitpod/resources/organizations/__init__.py

-14
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,6 @@
88
InviteResourceWithStreamingResponse,
99
AsyncInviteResourceWithStreamingResponse,
1010
)
11-
from .members import (
12-
MembersResource,
13-
AsyncMembersResource,
14-
MembersResourceWithRawResponse,
15-
AsyncMembersResourceWithRawResponse,
16-
MembersResourceWithStreamingResponse,
17-
AsyncMembersResourceWithStreamingResponse,
18-
)
1911
from .organizations import (
2012
OrganizationsResource,
2113
AsyncOrganizationsResource,
@@ -26,12 +18,6 @@
2618
)
2719

2820
__all__ = [
29-
"MembersResource",
30-
"AsyncMembersResource",
31-
"MembersResourceWithRawResponse",
32-
"AsyncMembersResourceWithRawResponse",
33-
"MembersResourceWithStreamingResponse",
34-
"AsyncMembersResourceWithStreamingResponse",
3521
"InviteResource",
3622
"AsyncInviteResource",
3723
"InviteResourceWithRawResponse",

0 commit comments

Comments
 (0)