Skip to content

Commit cfddae4

Browse files
stainless-app[bot]Stainless Bot
authored andcommitted
feat(api): OpenAPI spec update via Stainless API (#112)
1 parent 82a1581 commit cfddae4

5 files changed

Lines changed: 18 additions & 2 deletions

File tree

.stats.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
configured_endpoints: 22
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai%2Frunloop-f290dcd103e3a6d5650256bea5942db1508e0dd85e76483242c5556aace4ae48.yml
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai%2Frunloop-6577301ad49bd3086f3dd9cb0848407834eaf00a58446772426f7186b6ba582b.yml

src/runloop_api_client/resources/devboxes/devboxes.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ def create(
6767
environment_variables: Dict[str, str] | NotGiven = NOT_GIVEN,
6868
file_mounts: Dict[str, str] | NotGiven = NOT_GIVEN,
6969
launch_parameters: devbox_create_params.LaunchParameters | NotGiven = NOT_GIVEN,
70+
metadata: Dict[str, str] | NotGiven = NOT_GIVEN,
7071
name: str | NotGiven = NOT_GIVEN,
7172
setup_commands: List[str] | NotGiven = NOT_GIVEN,
7273
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -98,6 +99,8 @@ def create(
9899
99100
launch_parameters: Parameters to configure the resources and launch time behavior of the Devbox.
100101
102+
metadata: User defined metadata to attach to the devbox for organization.
103+
101104
name: (Optional) A user specified name to give the Devbox.
102105
103106
setup_commands: (Optional) List of commands needed to set up your Devbox. Examples might include
@@ -122,6 +125,7 @@ def create(
122125
"environment_variables": environment_variables,
123126
"file_mounts": file_mounts,
124127
"launch_parameters": launch_parameters,
128+
"metadata": metadata,
125129
"name": name,
126130
"setup_commands": setup_commands,
127131
},
@@ -447,6 +451,7 @@ async def create(
447451
environment_variables: Dict[str, str] | NotGiven = NOT_GIVEN,
448452
file_mounts: Dict[str, str] | NotGiven = NOT_GIVEN,
449453
launch_parameters: devbox_create_params.LaunchParameters | NotGiven = NOT_GIVEN,
454+
metadata: Dict[str, str] | NotGiven = NOT_GIVEN,
450455
name: str | NotGiven = NOT_GIVEN,
451456
setup_commands: List[str] | NotGiven = NOT_GIVEN,
452457
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
@@ -478,6 +483,8 @@ async def create(
478483
479484
launch_parameters: Parameters to configure the resources and launch time behavior of the Devbox.
480485
486+
metadata: User defined metadata to attach to the devbox for organization.
487+
481488
name: (Optional) A user specified name to give the Devbox.
482489
483490
setup_commands: (Optional) List of commands needed to set up your Devbox. Examples might include
@@ -502,6 +509,7 @@ async def create(
502509
"environment_variables": environment_variables,
503510
"file_mounts": file_mounts,
504511
"launch_parameters": launch_parameters,
512+
"metadata": metadata,
505513
"name": name,
506514
"setup_commands": setup_commands,
507515
},

src/runloop_api_client/types/devbox_create_params.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ class DevboxCreateParams(TypedDict, total=False):
4040
launch_parameters: LaunchParameters
4141
"""Parameters to configure the resources and launch time behavior of the Devbox."""
4242

43+
metadata: Dict[str, str]
44+
"""User defined metadata to attach to the devbox for organization."""
45+
4346
name: str
4447
"""(Optional) A user specified name to give the Devbox."""
4548

src/runloop_api_client/types/devbox_view.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

3-
from typing import Optional
3+
from typing import Dict, Optional
44
from typing_extensions import Literal
55

66
from .._models import BaseModel
@@ -27,6 +27,9 @@ class DevboxView(BaseModel):
2727
initiator_type: Optional[Literal["unknown", "api", "invocation"]] = None
2828
"""The initiator of the devbox."""
2929

30+
metadata: Optional[Dict[str, str]] = None
31+
"""The user defined Devbox metadata."""
32+
3033
name: Optional[str] = None
3134
"""The name of the Devbox."""
3235

tests/api_resources/test_devboxes.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ def test_method_create_with_all_params(self, client: Runloop) -> None:
3939
"launch_commands": ["string", "string", "string"],
4040
"resource_size_request": "MINI",
4141
},
42+
metadata={"foo": "string"},
4243
name="name",
4344
setup_commands=["string", "string", "string"],
4445
)
@@ -382,6 +383,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncRunloop) -
382383
"launch_commands": ["string", "string", "string"],
383384
"resource_size_request": "MINI",
384385
},
386+
metadata={"foo": "string"},
385387
name="name",
386388
setup_commands=["string", "string", "string"],
387389
)

0 commit comments

Comments
 (0)