Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/resources/chat/completions/completions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1644,7 +1644,7 @@ export interface ChatCompletionCreateParamsBase {
* of 24 hours.
* [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
*/
prompt_cache_retention?: 'in-memory' | '24h' | null;
prompt_cache_retention?: 'in_memory' | '24h' | null;

/**
* Constrains effort on reasoning for
Expand Down
4 changes: 2 additions & 2 deletions src/resources/responses/responses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ export interface Response {
* of 24 hours.
* [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
*/
prompt_cache_retention?: 'in-memory' | '24h' | null;
prompt_cache_retention?: 'in_memory' | '24h' | null;

/**
* **gpt-5 and o-series models only**
Expand Down Expand Up @@ -6148,7 +6148,7 @@ export interface ResponseCreateParamsBase {
* of 24 hours.
* [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
*/
prompt_cache_retention?: 'in-memory' | '24h' | null;
prompt_cache_retention?: 'in_memory' | '24h' | null;

/**
* **gpt-5 and o-series models only**
Expand Down
2 changes: 1 addition & 1 deletion tests/api-resources/chat/completions/completions.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ describe('resource completions', () => {
prediction: { content: 'string', type: 'content' },
presence_penalty: -2,
prompt_cache_key: 'prompt-cache-key-1234',
prompt_cache_retention: 'in-memory',
prompt_cache_retention: 'in_memory',
reasoning_effort: 'none',
response_format: { type: 'text' },
safety_identifier: 'safety-identifier-1234',
Expand Down