@@ -1686,6 +1686,7 @@ def compact(
16861686 instructions : Optional [str ] | Omit = omit ,
16871687 previous_response_id : Optional [str ] | Omit = omit ,
16881688 prompt_cache_key : Optional [str ] | Omit = omit ,
1689+ prompt_cache_retention : Optional [Literal ["in_memory" , "24h" ]] | Omit = omit ,
16891690 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
16901691 # The extra values given here take precedence over values defined on the client or passed to this method.
16911692 extra_headers : Headers | None = None ,
@@ -1723,6 +1724,8 @@ def compact(
17231724
17241725 prompt_cache_key: A key to use when reading from or writing to the prompt cache.
17251726
1727+ prompt_cache_retention: How long to retain a prompt cache entry created by this request.
1728+
17261729 extra_headers: Send extra headers
17271730
17281731 extra_query: Add additional query parameters to the request
@@ -1740,6 +1743,7 @@ def compact(
17401743 "instructions" : instructions ,
17411744 "previous_response_id" : previous_response_id ,
17421745 "prompt_cache_key" : prompt_cache_key ,
1746+ "prompt_cache_retention" : prompt_cache_retention ,
17431747 },
17441748 response_compact_params .ResponseCompactParams ,
17451749 ),
@@ -3367,6 +3371,7 @@ async def compact(
33673371 instructions : Optional [str ] | Omit = omit ,
33683372 previous_response_id : Optional [str ] | Omit = omit ,
33693373 prompt_cache_key : Optional [str ] | Omit = omit ,
3374+ prompt_cache_retention : Optional [Literal ["in_memory" , "24h" ]] | Omit = omit ,
33703375 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
33713376 # The extra values given here take precedence over values defined on the client or passed to this method.
33723377 extra_headers : Headers | None = None ,
@@ -3404,6 +3409,8 @@ async def compact(
34043409
34053410 prompt_cache_key: A key to use when reading from or writing to the prompt cache.
34063411
3412+ prompt_cache_retention: How long to retain a prompt cache entry created by this request.
3413+
34073414 extra_headers: Send extra headers
34083415
34093416 extra_query: Add additional query parameters to the request
@@ -3421,6 +3428,7 @@ async def compact(
34213428 "instructions" : instructions ,
34223429 "previous_response_id" : previous_response_id ,
34233430 "prompt_cache_key" : prompt_cache_key ,
3431+ "prompt_cache_retention" : prompt_cache_retention ,
34243432 },
34253433 response_compact_params .ResponseCompactParams ,
34263434 ),
0 commit comments