From 78c030d8697dec5c3bfb71f2bb7d845fcca3342b Mon Sep 17 00:00:00 2001 From: Annie Luc Date: Wed, 7 Jan 2026 14:33:29 -0800 Subject: [PATCH] chore: Change MIME type fields from string to enums PiperOrigin-RevId: 853416159 --- src/interactions/resources/interactions.ts | 52 +++++++++++++--------- 1 file changed, 31 insertions(+), 21 deletions(-) diff --git a/src/interactions/resources/interactions.ts b/src/interactions/resources/interactions.ts index 6bf5f786c..8e9812bc0 100644 --- a/src/interactions/resources/interactions.ts +++ b/src/interactions/resources/interactions.ts @@ -82,7 +82,8 @@ export class BaseInteractions extends APIResource { } /** - * Cancels an interaction by id. This only applies to background interactions that are still running. + * Cancels an interaction by id. This only applies to background interactions that + * are still running. * * @example * ```ts @@ -99,7 +100,8 @@ export class BaseInteractions extends APIResource { } /** - * Retrieves the full details of a single interaction based on its `Interaction.id`. + * Retrieves the full details of a single interaction based on its + * `Interaction.id`. * * @example * ```ts @@ -161,8 +163,8 @@ export interface Annotation { end_index?: number; /** - * Source attributed for a portion of the text. Could be a URL, title, or - * other identifier. + * Source attributed for a portion of the text. Could be a URL, title, or other + * identifier. */ source?: string; @@ -1118,7 +1120,8 @@ export namespace MCPServerToolResultContent { } /** - * The model that will complete your prompt.\n\nSee [models](https://ai.google.dev/gemini-api/docs/models) for additional details. + * The model that will complete your prompt.\n\nSee + * [models](https://ai.google.dev/gemini-api/docs/models) for additional details. */ export type Model = | 'gemini-2.5-pro' @@ -1262,8 +1265,7 @@ export namespace Tool { name?: string; /** - * The full URL for the MCPServer endpoint. - * Example: "https://api.example.com/mcp" + * The full URL for the MCPServer endpoint. Example: "https://api.example.com/mcp" */ url?: string; } @@ -1312,8 +1314,7 @@ export interface Turn { content?: string | Array; /** - * The originator of this turn. Must be user for input or model for - * model output. + * The originator of this turn. Must be user for input or model for model output. */ role?: string; } @@ -1601,13 +1602,14 @@ export interface BaseCreateModelInteractionParams { previous_interaction_id?: string; /** - * Body param: Enforces that the generated response is a JSON object that complies with - * the JSON schema specified in this field. + * Body param: Enforces that the generated response is a JSON object that complies + * with the JSON schema specified in this field. */ response_format?: unknown; /** - * Body param: The mime type of the response. This is required if response_format is set. + * Body param: The mime type of the response. This is required if response_format + * is set. */ response_mime_type?: string; @@ -1617,7 +1619,8 @@ export interface BaseCreateModelInteractionParams { response_modalities?: Array<'text' | 'image' | 'audio'>; /** - * Body param: Input only. Whether to store the response and request for later retrieval. + * Body param: Input only. Whether to store the response and request for later + * retrieval. */ store?: boolean; @@ -1689,13 +1692,14 @@ export interface BaseCreateAgentInteractionParams { previous_interaction_id?: string; /** - * Body param: Enforces that the generated response is a JSON object that complies with - * the JSON schema specified in this field. + * Body param: Enforces that the generated response is a JSON object that complies + * with the JSON schema specified in this field. */ response_format?: unknown; /** - * Body param: The mime type of the response. This is required if response_format is set. + * Body param: The mime type of the response. This is required if response_format + * is set. */ response_mime_type?: string; @@ -1705,7 +1709,8 @@ export interface BaseCreateAgentInteractionParams { response_modalities?: Array<'text' | 'image' | 'audio'>; /** - * Body param: Input only. Whether to store the response and request for later retrieval. + * Body param: Input only. Whether to store the response and request for later + * retrieval. */ store?: boolean; @@ -1776,12 +1781,15 @@ export interface InteractionGetParamsBase { api_version?: string; /** - * Query param: Optional. If set, resumes the interaction stream from the next chunk after the event marked by the event id. Can only be used if `stream` is true. + * Query param: Optional. If set, resumes the interaction stream from the next + * chunk after the event marked by the event id. Can only be used if `stream` is + * true. */ last_event_id?: string; /** - * Query param: If set to true, the generated content will be streamed incrementally. + * Query param: If set to true, the generated content will be streamed + * incrementally. */ stream?: boolean; } @@ -1793,14 +1801,16 @@ export namespace InteractionGetParams { export interface InteractionGetParamsNonStreaming extends InteractionGetParamsBase { /** - * Query param: If set to true, the generated content will be streamed incrementally. + * Query param: If set to true, the generated content will be streamed + * incrementally. */ stream?: false; } export interface InteractionGetParamsStreaming extends InteractionGetParamsBase { /** - * Query param: If set to true, the generated content will be streamed incrementally. + * Query param: If set to true, the generated content will be streamed + * incrementally. */ stream: true; }