Skip to content

Commit 5d86ef5

Browse files
chore: Update stainless.yml, bump AGENTS.md to keep this updated (#9268)
1 parent c9c7c37 commit 5d86ef5

13 files changed

Lines changed: 184 additions & 116 deletions

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 119
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai/runloop-d4505c10f86f4ad122bfbc2a82a519278d626ac399c9ef3780496d5d7d1b99b9.yml
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai/runloop-70af693bc68f1ed5f2678a59d9ad3bb8a9e9bf8356fac4c3080cbd1a117819f8.yml
33
openapi_spec_hash: b29dfd448505a0a3a6686202f606b8f7
4-
config_hash: 06faf3176c48bf2b258730ce50809f0f
4+
config_hash: 444e00951b440bf92e7548b2807584a4

api.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ from runloop_api_client.types import (
88
BrokerMount,
99
CodeMountParameters,
1010
LaunchParameters,
11+
LifecycleConfiguration,
12+
LifecycleHooks,
1113
Mount,
1214
ObjectMount,
15+
ResumeTriggers,
1316
RunProfile,
1417
)
1518
```

src/runloop_api_client/types/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@
1010
AgentSource as AgentSource,
1111
BrokerMount as BrokerMount,
1212
ObjectMount as ObjectMount,
13+
LifecycleHooks as LifecycleHooks,
14+
ResumeTriggers as ResumeTriggers,
1315
LaunchParameters as LaunchParameters,
1416
CodeMountParameters as CodeMountParameters,
17+
LifecycleConfiguration as LifecycleConfiguration,
1518
)
1619
from .axon_view import AxonView as AxonView
1720
from .agent_view import AgentView as AgentView

src/runloop_api_client/types/shared/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,8 @@
77
from .agent_source import AgentSource as AgentSource
88
from .broker_mount import BrokerMount as BrokerMount
99
from .object_mount import ObjectMount as ObjectMount
10+
from .lifecycle_hooks import LifecycleHooks as LifecycleHooks
11+
from .resume_triggers import ResumeTriggers as ResumeTriggers
1012
from .launch_parameters import LaunchParameters as LaunchParameters
1113
from .code_mount_parameters import CodeMountParameters as CodeMountParameters
14+
from .lifecycle_configuration import LifecycleConfiguration as LifecycleConfiguration

src/runloop_api_client/types/shared/launch_parameters.py

Lines changed: 3 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -5,63 +5,9 @@
55

66
from ..._models import BaseModel
77
from .after_idle import AfterIdle
8+
from .lifecycle_configuration import LifecycleConfiguration
89

9-
__all__ = ["LaunchParameters", "Lifecycle", "LifecycleLifecycleHooks", "LifecycleResumeTriggers", "UserParameters"]
10-
11-
12-
class LifecycleLifecycleHooks(BaseModel):
13-
"""Optional lifecycle hooks.
14-
15-
suspend_commands run through the suspend path before the Devbox suspends; see launch_commands for work on every startup.
16-
"""
17-
18-
suspend_commands: Optional[List[str]] = None
19-
"""Commands to run through the suspend path before the Devbox suspends (e.g.
20-
21-
cleanup, quiesce daemons).
22-
"""
23-
24-
suspend_deadline_ms: Optional[int] = None
25-
"""Deadline in milliseconds for broker drain and suspend_commands during suspend.
26-
27-
Defaults to 30000 ms and may not exceed 60000 ms. If exceeded, suspend work is
28-
abandoned, the timeout is logged, and the Devbox still proceeds to suspend by
29-
shutting down vmagent and killing the VM.
30-
"""
31-
32-
33-
class LifecycleResumeTriggers(BaseModel):
34-
"""Triggers that can resume a suspended Devbox."""
35-
36-
axon_event: Optional[bool] = None
37-
"""When true, axon events targeting a suspended Devbox will trigger a resume."""
38-
39-
http: Optional[bool] = None
40-
"""When true, HTTP traffic to a suspended Devbox via tunnel will trigger a resume."""
41-
42-
43-
class Lifecycle(BaseModel):
44-
"""Lifecycle configuration for idle and resume behavior.
45-
46-
Configure idle policy via lifecycle.after_idle (if both this and the top-level after_idle are set, they must match), resume triggers via lifecycle.resume_triggers, and optional lifecycle hooks via lifecycle.lifecycle_hooks.
47-
"""
48-
49-
after_idle: Optional[AfterIdle] = None
50-
"""Configure Devbox lifecycle based on idle activity.
51-
52-
If both this and the top-level after_idle are set, they must have the same
53-
value. Prefer this field for new integrations.
54-
"""
55-
56-
lifecycle_hooks: Optional[LifecycleLifecycleHooks] = None
57-
"""Optional lifecycle hooks.
58-
59-
suspend_commands run through the suspend path before the Devbox suspends; see
60-
launch_commands for work on every startup.
61-
"""
62-
63-
resume_triggers: Optional[LifecycleResumeTriggers] = None
64-
"""Triggers that can resume a suspended Devbox."""
10+
__all__ = ["LaunchParameters", "UserParameters"]
6511

6612

6713
class UserParameters(BaseModel):
@@ -117,7 +63,7 @@ class LaunchParameters(BaseModel):
11763
launch_commands: Optional[List[str]] = None
11864
"""Set of commands to be run at launch time, before the entrypoint process is run."""
11965

120-
lifecycle: Optional[Lifecycle] = None
66+
lifecycle: Optional[LifecycleConfiguration] = None
12167
"""Lifecycle configuration for idle and resume behavior.
12268
12369
Configure idle policy via lifecycle.after_idle (if both this and the top-level
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from typing import Optional
4+
5+
from ..._models import BaseModel
6+
from .after_idle import AfterIdle
7+
from .lifecycle_hooks import LifecycleHooks
8+
from .resume_triggers import ResumeTriggers
9+
10+
__all__ = ["LifecycleConfiguration"]
11+
12+
13+
class LifecycleConfiguration(BaseModel):
14+
"""Lifecycle configuration for Devbox idle and resume behavior.
15+
16+
Configure idle policy via after_idle, resume triggers via resume_triggers, and optional lifecycle hooks via lifecycle_hooks.
17+
"""
18+
19+
after_idle: Optional[AfterIdle] = None
20+
"""Configure Devbox lifecycle based on idle activity.
21+
22+
If both this and the top-level after_idle are set, they must have the same
23+
value. Prefer this field for new integrations.
24+
"""
25+
26+
lifecycle_hooks: Optional[LifecycleHooks] = None
27+
"""Optional lifecycle hooks.
28+
29+
suspend_commands run through the suspend path before the Devbox suspends; see
30+
launch_commands for work on every startup.
31+
"""
32+
33+
resume_triggers: Optional[ResumeTriggers] = None
34+
"""Triggers that can resume a suspended Devbox."""
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from typing import List, Optional
4+
5+
from ..._models import BaseModel
6+
7+
__all__ = ["LifecycleHooks"]
8+
9+
10+
class LifecycleHooks(BaseModel):
11+
"""Lifecycle hooks for Devbox suspend.
12+
13+
suspend_commands run sequentially as the configured Devbox user through the rage/vmagent suspend path before the Devbox suspends; failures are logged but do not block suspending. The suspend_deadline_ms budget defaults to 30000 ms, may not exceed 60000 ms, and covers broker drain plus suspend_commands. If the deadline is exceeded, suspend work is abandoned, the timeout is logged, and the Devbox still proceeds to suspend by shutting down vmagent and killing the VM. Resume hooks and resume deadline settings are persistence/internal only and hidden from the public API reference. launch_commands still run on every startup, including after resume.
14+
"""
15+
16+
suspend_commands: Optional[List[str]] = None
17+
"""Commands to run through the suspend path before the Devbox suspends (e.g.
18+
19+
cleanup, quiesce daemons).
20+
"""
21+
22+
suspend_deadline_ms: Optional[int] = None
23+
"""Deadline in milliseconds for broker drain and suspend_commands during suspend.
24+
25+
Defaults to 30000 ms and may not exceed 60000 ms. If exceeded, suspend work is
26+
abandoned, the timeout is logged, and the Devbox still proceeds to suspend by
27+
shutting down vmagent and killing the VM.
28+
"""
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2+
3+
from typing import Optional
4+
5+
from ..._models import BaseModel
6+
7+
__all__ = ["ResumeTriggers"]
8+
9+
10+
class ResumeTriggers(BaseModel):
11+
"""Triggers that can resume a suspended Devbox."""
12+
13+
axon_event: Optional[bool] = None
14+
"""When true, axon events targeting a suspended Devbox will trigger a resume."""
15+
16+
http: Optional[bool] = None
17+
"""When true, HTTP traffic to a suspended Devbox via tunnel will trigger a resume."""

src/runloop_api_client/types/shared_params/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,8 @@
77
from .agent_source import AgentSource as AgentSource
88
from .broker_mount import BrokerMount as BrokerMount
99
from .object_mount import ObjectMount as ObjectMount
10+
from .lifecycle_hooks import LifecycleHooks as LifecycleHooks
11+
from .resume_triggers import ResumeTriggers as ResumeTriggers
1012
from .launch_parameters import LaunchParameters as LaunchParameters
1113
from .code_mount_parameters import CodeMountParameters as CodeMountParameters
14+
from .lifecycle_configuration import LifecycleConfiguration as LifecycleConfiguration

src/runloop_api_client/types/shared_params/launch_parameters.py

Lines changed: 3 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -7,63 +7,9 @@
77

88
from ..._types import SequenceNotStr
99
from .after_idle import AfterIdle
10+
from .lifecycle_configuration import LifecycleConfiguration
1011

11-
__all__ = ["LaunchParameters", "Lifecycle", "LifecycleLifecycleHooks", "LifecycleResumeTriggers", "UserParameters"]
12-
13-
14-
class LifecycleLifecycleHooks(TypedDict, total=False):
15-
"""Optional lifecycle hooks.
16-
17-
suspend_commands run through the suspend path before the Devbox suspends; see launch_commands for work on every startup.
18-
"""
19-
20-
suspend_commands: Optional[SequenceNotStr[str]]
21-
"""Commands to run through the suspend path before the Devbox suspends (e.g.
22-
23-
cleanup, quiesce daemons).
24-
"""
25-
26-
suspend_deadline_ms: Optional[int]
27-
"""Deadline in milliseconds for broker drain and suspend_commands during suspend.
28-
29-
Defaults to 30000 ms and may not exceed 60000 ms. If exceeded, suspend work is
30-
abandoned, the timeout is logged, and the Devbox still proceeds to suspend by
31-
shutting down vmagent and killing the VM.
32-
"""
33-
34-
35-
class LifecycleResumeTriggers(TypedDict, total=False):
36-
"""Triggers that can resume a suspended Devbox."""
37-
38-
axon_event: Optional[bool]
39-
"""When true, axon events targeting a suspended Devbox will trigger a resume."""
40-
41-
http: Optional[bool]
42-
"""When true, HTTP traffic to a suspended Devbox via tunnel will trigger a resume."""
43-
44-
45-
class Lifecycle(TypedDict, total=False):
46-
"""Lifecycle configuration for idle and resume behavior.
47-
48-
Configure idle policy via lifecycle.after_idle (if both this and the top-level after_idle are set, they must match), resume triggers via lifecycle.resume_triggers, and optional lifecycle hooks via lifecycle.lifecycle_hooks.
49-
"""
50-
51-
after_idle: Optional[AfterIdle]
52-
"""Configure Devbox lifecycle based on idle activity.
53-
54-
If both this and the top-level after_idle are set, they must have the same
55-
value. Prefer this field for new integrations.
56-
"""
57-
58-
lifecycle_hooks: Optional[LifecycleLifecycleHooks]
59-
"""Optional lifecycle hooks.
60-
61-
suspend_commands run through the suspend path before the Devbox suspends; see
62-
launch_commands for work on every startup.
63-
"""
64-
65-
resume_triggers: Optional[LifecycleResumeTriggers]
66-
"""Triggers that can resume a suspended Devbox."""
12+
__all__ = ["LaunchParameters", "UserParameters"]
6713

6814

6915
class UserParameters(TypedDict, total=False):
@@ -119,7 +65,7 @@ class LaunchParameters(TypedDict, total=False):
11965
launch_commands: Optional[SequenceNotStr[str]]
12066
"""Set of commands to be run at launch time, before the entrypoint process is run."""
12167

122-
lifecycle: Optional[Lifecycle]
68+
lifecycle: Optional[LifecycleConfiguration]
12369
"""Lifecycle configuration for idle and resume behavior.
12470
12571
Configure idle policy via lifecycle.after_idle (if both this and the top-level

0 commit comments

Comments
 (0)