You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit bb5dc1c
Browse filesBrowse the repository at this point in the historyBrowse files
***api:** support monthly spend limits on project API keys ([#4366](https://github.com/openai/openai-python/issues/4366)) ([83f5849](https://github.com/openai/openai-python/commit/83f5849fc7948c9fd72a16de1f55b810780554d3))
***api:** clarify environment file uploads and model examples ([#4364](https://github.com/openai/openai-python/issues/4364)) ([ccc5732](https://github.com/openai/openai-python/commit/ccc573291d5830c1cb4a8991edf104a3ea171cf9))
Updates the scopes and/or expiration of an existing API key in the project, including a
13154
-
service-account-owned key. Requires permission to write project API keys.
13167
+
Updates the scopes, expiration, or monthly hard spend limit of an existing
13168
+
project API key, including keys owned by service accounts. Requires
13169
+
permission to write project API keys.
13155
13170
13156
-
Provide at least one of `scopes` or `expires_in_seconds`. Omitted fields stay
13157
-
unchanged; neither field accepts `null`. Both changes are saved together.
13171
+
Provide at least one of `scopes`, `expires_in_seconds`, or `spend_limit`.
13172
+
Omitted fields stay unchanged. Set `spend_limit` to `null` to remove the limit.
13158
13173
13159
13174
`scopes` replaces the key's scope restrictions using the same scope identifiers
13160
13175
as the dashboard. An empty array means All permissions, subject to the owner's
@@ -32636,7 +32651,7 @@ paths:
32636
32651
post:
32637
32652
operationId: createAgentEnvironmentFile
32638
32653
summary: Write an agent environment file
32639
-
description: Copies inline bytes or a Files API file into a connected execution environment, replacing an existing regular file at the same path. Upload between turns and wait for success before starting the next turn. See [environment files](https://developers.openai.com/api/docs/guides/agents-api/environments/files).
32654
+
description: Writes inline bytes or a Files API file, replacing an existing regular file at the same path. Uploading wakes a suspended session-owned sandbox that supports restore. Early in that restore, uploads can return success once their files are durably saved. Later uploads wait for the sandbox to connect. Upload between turns and wait for all uploads to succeed before sending input. The next turn waits for all accepted files to be installed. If installation fails after a successful upload, the session fails and its error identifies the file. See [environment files](https://developers.openai.com/api/docs/guides/agents-api/environments/files).
description: The Unix timestamp (in seconds) when the API key expires, or null if it does not expire.
56332
56349
id:
56333
56350
type: string
56351
+
spend_limit:
56352
+
$ref: '#/components/schemas/spend_limit'
56334
56353
required:
56335
56354
- object
56336
56355
- value
@@ -56355,6 +56374,8 @@ components:
56355
56374
maximum: 31536000
56356
56375
- type: 'null'
56357
56376
description: Number of seconds until the initial API key expires. If omitted or null, the key does not expire unless the effective organization or project policy requires an expiration. When a policy sets a maximum lifetime, this value must be provided and must not exceed that limit. A non-null value cannot be used when `create_service_account_only` is true.
description: Replace the API key scope restrictions. Omit to leave scopes unchanged. An empty array removes key restrictions (All permissions), subject to the owner's effective permissions. Use ["api.all.read"] for read-only access. Scopes do not change the owner's roles or grant administrative permissions.
description: The hard spend limit for this API key, or null if no limit is configured.
84135
+
- type: 'null'
84098
84136
type: object
84099
84137
required:
84100
84138
- object
@@ -87704,7 +87742,7 @@ components:
87704
87742
properties:
87705
87743
async:
87706
87744
type: boolean
87707
-
description: Whether context is compacted in the background. Defaults to false.
87745
+
description: Always false. Context compaction is blocking.
87708
87746
required:
87709
87747
- async
87710
87748
additionalProperties: false
@@ -88771,7 +88809,7 @@ components:
88771
88809
type:
88772
88810
- boolean
88773
88811
- 'null'
88774
-
description: Whether to compact context in the background. Omission or null defaults to false. Set to true to enable background compaction. Background compaction may increase token usage.
88812
+
description: Accepted for compatibility and ignored. Context compaction is always blocking.
88775
88813
additionalProperties: false
88776
88814
description: Settings for compacting the agent's context.
88777
88815
AgentToolConfigParamFunction:
@@ -89235,7 +89273,7 @@ components:
89235
89273
anyOf:
89236
89274
- $ref: '#/components/schemas/CompactionParam'
89237
89275
- type: 'null'
89238
-
description: Context compaction settings. Omit to keep the current settings. A supplied object replaces the settings; null or an empty object uses blocking compaction.
89276
+
description: Context compaction settings.
89239
89277
tools:
89240
89278
type:
89241
89279
- array
@@ -90664,7 +90702,7 @@ components:
90664
90702
- path
90665
90703
- size_bytes
90666
90704
additionalProperties: false
90667
-
description: A live file in an execution environment.
90705
+
description: A file accepted for or present in an execution environment.
90668
90706
EnvironmentFileListResource:
90669
90707
type: object
90670
90708
properties:
@@ -93205,7 +93243,7 @@ components:
93205
93243
anyOf:
93206
93244
- $ref: '#/components/schemas/CompactionParam'
93207
93245
- type: 'null'
93208
-
description: Context compaction settings. Omission or null uses blocking compaction.
93246
+
description: Context compaction settings.
93209
93247
required:
93210
93248
- model
93211
93249
additionalProperties: false
@@ -93253,7 +93291,7 @@ components:
93253
93291
anyOf:
93254
93292
- $ref: '#/components/schemas/CompactionParam'
93255
93293
- type: 'null'
93256
-
description: Context compaction settings. Omit to keep the current settings. A supplied object replaces the settings; null or an empty object uses blocking compaction.
0 commit comments