Skip to content

Commit 69df104

Browse files
feat(api): api update
1 parent c27e4c5 commit 69df104

17 files changed

Lines changed: 85 additions & 141 deletions

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 92
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai%2Frunloop-8805efc665011161897e5c4c326dc44090ae55471a36bef8d63d17fec4e289f1.yml
3-
openapi_spec_hash: 4d348158fc0b5daa3f55d831301859e4
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/runloop-ai%2Frunloop-20da49cddb76a81f77844447916c6d445b25634ff99aae15d8dfd50fe6d854e6.yml
3+
openapi_spec_hash: 2097a1bfb48092ed3b03fa606f5c5447
44
config_hash: 60681f589a9e641fdb7f19af2021a033

src/runloop_api_client/resources/benchmarks/benchmarks.py

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def create(
7171
name: str,
7272
metadata: Optional[Dict[str, str]] | NotGiven = NOT_GIVEN,
7373
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
74-
required_secrets: List[str] | NotGiven = NOT_GIVEN,
74+
required_secret_names: List[str] | NotGiven = NOT_GIVEN,
7575
scenario_ids: Optional[List[str]] | NotGiven = NOT_GIVEN,
7676
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
7777
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -92,9 +92,9 @@ def create(
9292
required_environment_variables: Environment variables required to run the benchmark. If any required variables
9393
are not supplied, the benchmark will fail to start
9494
95-
required_secrets: Secrets required to run the benchmark with (user secret name will be mapped to
96-
benchmark required secret name). If any of these secrets are not provided or the
97-
mapping is incorrect, the benchmark will fail to start.
95+
required_secret_names: Secrets required to run the benchmark with (environment variable name will be
96+
mapped to the your user secret by name). If any of these secrets are not
97+
provided or the mapping is incorrect, the benchmark will fail to start.
9898
9999
scenario_ids: The Scenario IDs that make up the Benchmark.
100100
@@ -115,7 +115,7 @@ def create(
115115
"name": name,
116116
"metadata": metadata,
117117
"required_environment_variables": required_environment_variables,
118-
"required_secrets": required_secrets,
118+
"required_secret_names": required_secret_names,
119119
"scenario_ids": scenario_ids,
120120
},
121121
benchmark_create_params.BenchmarkCreateParams,
@@ -170,7 +170,7 @@ def update(
170170
name: str,
171171
metadata: Optional[Dict[str, str]] | NotGiven = NOT_GIVEN,
172172
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
173-
required_secrets: List[str] | NotGiven = NOT_GIVEN,
173+
required_secret_names: List[str] | NotGiven = NOT_GIVEN,
174174
scenario_ids: Optional[List[str]] | NotGiven = NOT_GIVEN,
175175
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
176176
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -191,9 +191,9 @@ def update(
191191
required_environment_variables: Environment variables required to run the benchmark. If any required variables
192192
are not supplied, the benchmark will fail to start
193193
194-
required_secrets: Secrets required to run the benchmark with (user secret name will be mapped to
195-
benchmark required secret name). If any of these secrets are not provided or the
196-
mapping is incorrect, the benchmark will fail to start.
194+
required_secret_names: Secrets required to run the benchmark with (environment variable name will be
195+
mapped to the your user secret by name). If any of these secrets are not
196+
provided or the mapping is incorrect, the benchmark will fail to start.
197197
198198
scenario_ids: The Scenario IDs that make up the Benchmark.
199199
@@ -216,7 +216,7 @@ def update(
216216
"name": name,
217217
"metadata": metadata,
218218
"required_environment_variables": required_environment_variables,
219-
"required_secrets": required_secrets,
219+
"required_secret_names": required_secret_names,
220220
"scenario_ids": scenario_ids,
221221
},
222222
benchmark_update_params.BenchmarkUpdateParams,
@@ -463,7 +463,7 @@ async def create(
463463
name: str,
464464
metadata: Optional[Dict[str, str]] | NotGiven = NOT_GIVEN,
465465
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
466-
required_secrets: List[str] | NotGiven = NOT_GIVEN,
466+
required_secret_names: List[str] | NotGiven = NOT_GIVEN,
467467
scenario_ids: Optional[List[str]] | NotGiven = NOT_GIVEN,
468468
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
469469
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -484,9 +484,9 @@ async def create(
484484
required_environment_variables: Environment variables required to run the benchmark. If any required variables
485485
are not supplied, the benchmark will fail to start
486486
487-
required_secrets: Secrets required to run the benchmark with (user secret name will be mapped to
488-
benchmark required secret name). If any of these secrets are not provided or the
489-
mapping is incorrect, the benchmark will fail to start.
487+
required_secret_names: Secrets required to run the benchmark with (environment variable name will be
488+
mapped to the your user secret by name). If any of these secrets are not
489+
provided or the mapping is incorrect, the benchmark will fail to start.
490490
491491
scenario_ids: The Scenario IDs that make up the Benchmark.
492492
@@ -507,7 +507,7 @@ async def create(
507507
"name": name,
508508
"metadata": metadata,
509509
"required_environment_variables": required_environment_variables,
510-
"required_secrets": required_secrets,
510+
"required_secret_names": required_secret_names,
511511
"scenario_ids": scenario_ids,
512512
},
513513
benchmark_create_params.BenchmarkCreateParams,
@@ -562,7 +562,7 @@ async def update(
562562
name: str,
563563
metadata: Optional[Dict[str, str]] | NotGiven = NOT_GIVEN,
564564
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
565-
required_secrets: List[str] | NotGiven = NOT_GIVEN,
565+
required_secret_names: List[str] | NotGiven = NOT_GIVEN,
566566
scenario_ids: Optional[List[str]] | NotGiven = NOT_GIVEN,
567567
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
568568
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -583,9 +583,9 @@ async def update(
583583
required_environment_variables: Environment variables required to run the benchmark. If any required variables
584584
are not supplied, the benchmark will fail to start
585585
586-
required_secrets: Secrets required to run the benchmark with (user secret name will be mapped to
587-
benchmark required secret name). If any of these secrets are not provided or the
588-
mapping is incorrect, the benchmark will fail to start.
586+
required_secret_names: Secrets required to run the benchmark with (environment variable name will be
587+
mapped to the your user secret by name). If any of these secrets are not
588+
provided or the mapping is incorrect, the benchmark will fail to start.
589589
590590
scenario_ids: The Scenario IDs that make up the Benchmark.
591591
@@ -608,7 +608,7 @@ async def update(
608608
"name": name,
609609
"metadata": metadata,
610610
"required_environment_variables": required_environment_variables,
611-
"required_secrets": required_secrets,
611+
"required_secret_names": required_secret_names,
612612
"scenario_ids": scenario_ids,
613613
},
614614
benchmark_update_params.BenchmarkUpdateParams,

src/runloop_api_client/resources/devboxes/devboxes.py

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1305,9 +1305,7 @@ def upload_file(
13051305
id: str,
13061306
*,
13071307
path: str,
1308-
chmod: Optional[str] | NotGiven = NOT_GIVEN,
13091308
file: FileTypes | NotGiven = NOT_GIVEN,
1310-
owner: Optional[str] | NotGiven = NOT_GIVEN,
13111309
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
13121310
# The extra values given here take precedence over values defined on the client or passed to this method.
13131311
extra_headers: Headers | None = None,
@@ -1326,12 +1324,6 @@ def upload_file(
13261324
path: The path to write the file to on the Devbox. Path is relative to user home
13271325
directory.
13281326
1329-
chmod: File permissions in octal format (e.g., "644", "1755"). Optional. If not
1330-
specified, default system permissions will be used.
1331-
1332-
owner: File owner username. Optional. If not specified, the file will be owned by the
1333-
current user.
1334-
13351327
extra_headers: Send extra headers
13361328
13371329
extra_query: Add additional query parameters to the request
@@ -1349,9 +1341,7 @@ def upload_file(
13491341
body = deepcopy_minimal(
13501342
{
13511343
"path": path,
1352-
"chmod": chmod,
13531344
"file": file,
1354-
"owner": owner,
13551345
}
13561346
)
13571347
files = extract_files(cast(Mapping[str, object], body), paths=[["file"]])
@@ -1379,8 +1369,6 @@ def write_file_contents(
13791369
*,
13801370
contents: str,
13811371
file_path: str,
1382-
chmod: Optional[str] | NotGiven = NOT_GIVEN,
1383-
owner: Optional[str] | NotGiven = NOT_GIVEN,
13841372
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
13851373
# The extra values given here take precedence over values defined on the client or passed to this method.
13861374
extra_headers: Headers | None = None,
@@ -1400,12 +1388,6 @@ def write_file_contents(
14001388
file_path: The path to write the file to on the Devbox. Path is relative to user home
14011389
directory.
14021390
1403-
chmod: File permissions in octal format (e.g., "644", "1755"). Optional. If not
1404-
specified, default system permissions will be used.
1405-
1406-
owner: File owner username. Optional. If not specified, the file will be owned by the
1407-
current user.
1408-
14091391
extra_headers: Send extra headers
14101392
14111393
extra_query: Add additional query parameters to the request
@@ -1426,8 +1408,6 @@ def write_file_contents(
14261408
{
14271409
"contents": contents,
14281410
"file_path": file_path,
1429-
"chmod": chmod,
1430-
"owner": owner,
14311411
},
14321412
devbox_write_file_contents_params.DevboxWriteFileContentsParams,
14331413
),
@@ -2618,9 +2598,7 @@ async def upload_file(
26182598
id: str,
26192599
*,
26202600
path: str,
2621-
chmod: Optional[str] | NotGiven = NOT_GIVEN,
26222601
file: FileTypes | NotGiven = NOT_GIVEN,
2623-
owner: Optional[str] | NotGiven = NOT_GIVEN,
26242602
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
26252603
# The extra values given here take precedence over values defined on the client or passed to this method.
26262604
extra_headers: Headers | None = None,
@@ -2639,12 +2617,6 @@ async def upload_file(
26392617
path: The path to write the file to on the Devbox. Path is relative to user home
26402618
directory.
26412619
2642-
chmod: File permissions in octal format (e.g., "644", "1755"). Optional. If not
2643-
specified, default system permissions will be used.
2644-
2645-
owner: File owner username. Optional. If not specified, the file will be owned by the
2646-
current user.
2647-
26482620
extra_headers: Send extra headers
26492621
26502622
extra_query: Add additional query parameters to the request
@@ -2662,9 +2634,7 @@ async def upload_file(
26622634
body = deepcopy_minimal(
26632635
{
26642636
"path": path,
2665-
"chmod": chmod,
26662637
"file": file,
2667-
"owner": owner,
26682638
}
26692639
)
26702640
files = extract_files(cast(Mapping[str, object], body), paths=[["file"]])
@@ -2692,8 +2662,6 @@ async def write_file_contents(
26922662
*,
26932663
contents: str,
26942664
file_path: str,
2695-
chmod: Optional[str] | NotGiven = NOT_GIVEN,
2696-
owner: Optional[str] | NotGiven = NOT_GIVEN,
26972665
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
26982666
# The extra values given here take precedence over values defined on the client or passed to this method.
26992667
extra_headers: Headers | None = None,
@@ -2713,12 +2681,6 @@ async def write_file_contents(
27132681
file_path: The path to write the file to on the Devbox. Path is relative to user home
27142682
directory.
27152683
2716-
chmod: File permissions in octal format (e.g., "644", "1755"). Optional. If not
2717-
specified, default system permissions will be used.
2718-
2719-
owner: File owner username. Optional. If not specified, the file will be owned by the
2720-
current user.
2721-
27222684
extra_headers: Send extra headers
27232685
27242686
extra_query: Add additional query parameters to the request
@@ -2739,8 +2701,6 @@ async def write_file_contents(
27392701
{
27402702
"contents": contents,
27412703
"file_path": file_path,
2742-
"chmod": chmod,
2743-
"owner": owner,
27442704
},
27452705
devbox_write_file_contents_params.DevboxWriteFileContentsParams,
27462706
),

src/runloop_api_client/resources/scenarios/scenarios.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def update(
204204
name: Optional[str] | NotGiven = NOT_GIVEN,
205205
reference_output: Optional[str] | NotGiven = NOT_GIVEN,
206206
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
207-
required_secrets: Optional[List[str]] | NotGiven = NOT_GIVEN,
207+
required_secret_names: Optional[List[str]] | NotGiven = NOT_GIVEN,
208208
scoring_contract: Optional[ScoringContractUpdateParam] | NotGiven = NOT_GIVEN,
209209
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
210210
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -234,7 +234,7 @@ def update(
234234
235235
required_environment_variables: Environment variables required to run the scenario.
236236
237-
required_secrets: Secrets required to run the scenario.
237+
required_secret_names: Secrets required to run the scenario.
238238
239239
scoring_contract: The scoring contract for the Scenario.
240240
@@ -260,7 +260,7 @@ def update(
260260
"name": name,
261261
"reference_output": reference_output,
262262
"required_environment_variables": required_environment_variables,
263-
"required_secrets": required_secrets,
263+
"required_secret_names": required_secret_names,
264264
"scoring_contract": scoring_contract,
265265
},
266266
scenario_update_params.ScenarioUpdateParams,
@@ -650,7 +650,7 @@ async def update(
650650
name: Optional[str] | NotGiven = NOT_GIVEN,
651651
reference_output: Optional[str] | NotGiven = NOT_GIVEN,
652652
required_environment_variables: Optional[List[str]] | NotGiven = NOT_GIVEN,
653-
required_secrets: Optional[List[str]] | NotGiven = NOT_GIVEN,
653+
required_secret_names: Optional[List[str]] | NotGiven = NOT_GIVEN,
654654
scoring_contract: Optional[ScoringContractUpdateParam] | NotGiven = NOT_GIVEN,
655655
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
656656
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -680,7 +680,7 @@ async def update(
680680
681681
required_environment_variables: Environment variables required to run the scenario.
682682
683-
required_secrets: Secrets required to run the scenario.
683+
required_secret_names: Secrets required to run the scenario.
684684
685685
scoring_contract: The scoring contract for the Scenario.
686686
@@ -706,7 +706,7 @@ async def update(
706706
"name": name,
707707
"reference_output": reference_output,
708708
"required_environment_variables": required_environment_variables,
709-
"required_secrets": required_secrets,
709+
"required_secret_names": required_secret_names,
710710
"scoring_contract": scoring_contract,
711711
},
712712
scenario_update_params.ScenarioUpdateParams,

src/runloop_api_client/types/benchmark_create_params.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ class BenchmarkCreateParams(TypedDict, total=False):
2121
If any required variables are not supplied, the benchmark will fail to start
2222
"""
2323

24-
required_secrets: List[str]
24+
required_secret_names: List[str]
2525
"""
26-
Secrets required to run the benchmark with (user secret name will be mapped to
27-
benchmark required secret name). If any of these secrets are not provided or the
28-
mapping is incorrect, the benchmark will fail to start.
26+
Secrets required to run the benchmark with (environment variable name will be
27+
mapped to the your user secret by name). If any of these secrets are not
28+
provided or the mapping is incorrect, the benchmark will fail to start.
2929
"""
3030

3131
scenario_ids: Optional[List[str]]

src/runloop_api_client/types/benchmark_run_view.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,9 @@ class BenchmarkRunView(BaseModel):
4343
"""
4444

4545
secrets_provided: Optional[Dict[str, str]] = None
46-
"""User secrets used to run the benchmark."""
46+
"""User secrets used to run the benchmark.
47+
48+
Example: {"DB_PASS": "DATABASE_PASSWORD"} would set the environment variable
49+
'DB_PASS' on all scenario devboxes to the value of the secret
50+
'DATABASE_PASSWORD'.
51+
"""

src/runloop_api_client/types/benchmark_start_run_params.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,19 @@ class BenchmarkStartRunParams(TypedDict, total=False):
2626

2727
class RunProfile(TypedDict, total=False):
2828
env_vars: Annotated[Optional[Dict[str, str]], PropertyInfo(alias="envVars")]
29-
"""Environment Variables: Environment Variable to Value."""
29+
"""Mapping of Environment Variable to Value.
30+
31+
May be shown in devbox logging. Example: {"DB_PASS": "DATABASE_PASSWORD"} would
32+
set the environment variable 'DB_PASS' to the value 'DATABASE_PASSWORD_VALUE'.
33+
"""
3034

3135
purpose: Optional[str]
3236
"""Purpose of the run."""
3337

3438
secrets: Optional[Dict[str, str]]
35-
"""Secrets: Environment Variable to User Secret Name."""
39+
"""Mapping of Environment Variable to User Secret Name.
40+
41+
Never shown in devbox logging. Example: {"DB_PASS": "DATABASE_PASSWORD"} would
42+
set the environment variable 'DB_PASS' to the value of the secret
43+
'DATABASE_PASSWORD'.
44+
"""

src/runloop_api_client/types/benchmark_update_params.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ class BenchmarkUpdateParams(TypedDict, total=False):
2121
If any required variables are not supplied, the benchmark will fail to start
2222
"""
2323

24-
required_secrets: List[str]
24+
required_secret_names: List[str]
2525
"""
26-
Secrets required to run the benchmark with (user secret name will be mapped to
27-
benchmark required secret name). If any of these secrets are not provided or the
28-
mapping is incorrect, the benchmark will fail to start.
26+
Secrets required to run the benchmark with (environment variable name will be
27+
mapped to the your user secret by name). If any of these secrets are not
28+
provided or the mapping is incorrect, the benchmark will fail to start.
2929
"""
3030

3131
scenario_ids: Optional[List[str]]

0 commit comments

Comments
 (0)