Starting April 29, 2025, Gemini 1.5 Pro and Gemini 1.5 Flash models are not available in projects that have no prior usage of these models, including new projects. For details, see Model versions and lifecycle.
Stay organized with collections
Save and categorize content based on your preferences.
Schema is used to define the format of input/output data. Represents a select subset of an OpenAPI 3.0 schema object. More fields may be added in the future as needed.
Optional. The format of the data. Supported formats: for NUMBER type: "float", "double" for INTEGER type: "int32", "int64" for STRING type: "email", "byte", etc
Optional. Maximum number of the elements for type.ARRAY.
enum[]
string
Optional. Possible values of the element of primitive type with enum format. Examples: 1. We can define direction as : {type:STRING, format:enum, enum:["EAST", NORTH", "SOUTH", "WEST"]} 2. We can define apartment number as : {type:INTEGER, format:enum, enum:["101", "201", "301"]}
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-05 UTC."],[],[],null,["Schema is used to define the format of input/output data. Represents a select subset of an [OpenAPI 3.0 schema object](https://spec.openapis.org/oas/v3.0.3#schema-object). More fields may be added in the future as needed.\nFields `type` `enum (`[Type](/vertex-ai/generative-ai/docs/reference/rest/v1/Schema#Type)`)` \nOptional. The type of the data.\n`format` `string` \nOptional. The format of the data. Supported formats: for NUMBER type: \"float\", \"double\" for INTEGER type: \"int32\", \"int64\" for STRING type: \"email\", \"byte\", etc\n`title` `string` \nOptional. The title of the Schema.\n`description` `string` \nOptional. The description of the data.\n`nullable` `boolean` \nOptional. Indicates if the value may be null.\n`default` `value (`[Value](https://protobuf.dev/reference/protobuf/google.protobuf/#value)` format)` \nOptional. Default value of the data.\n`items` `object (`[Schema](/vertex-ai/generative-ai/docs/reference/rest/v1/Schema)`)` \nOptional. SCHEMA FIELDS FOR TYPE ARRAY Schema of the elements of type.ARRAY.\n`minItems` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. Minimum number of the elements for type.ARRAY.\n`maxItems` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. Maximum number of the elements for type.ARRAY.\n`enum[]` `string` \nOptional. Possible values of the element of primitive type with enum format. Examples: 1. We can define direction as : {type:STRING, format:enum, enum:\\[\"EAST\", NORTH\", \"SOUTH\", \"WEST\"\\]} 2. We can define apartment number as : {type:INTEGER, format:enum, enum:\\[\"101\", \"201\", \"301\"\\]}\n`properties` `map (key: string, value: object (`[Schema](/vertex-ai/generative-ai/docs/reference/rest/v1/Schema)`))` \nOptional. SCHEMA FIELDS FOR TYPE OBJECT Properties of type.OBJECT.\n`propertyOrdering[]` `string` \nOptional. The order of the properties. Not a standard field in open api spec. Only used to support the order of the properties.\n`required[]` `string` \nOptional. Required properties of type.OBJECT.\n`minProperties` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. Minimum number of the properties for type.OBJECT.\n`maxProperties` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. Maximum number of the properties for type.OBJECT.\n`minimum` `number` \nOptional. SCHEMA FIELDS FOR TYPE INTEGER and NUMBER Minimum value of the type.INTEGER and type.NUMBER\n`maximum` `number` \nOptional. Maximum value of the type.INTEGER and type.NUMBER\n`minLength` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. SCHEMA FIELDS FOR TYPE STRING Minimum length of the type.STRING\n`maxLength` `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` \nOptional. Maximum length of the type.STRING\n`pattern` `string` \nOptional. Pattern of the type.STRING to restrict a string to a regular expression.\n`example` `value (`[Value](https://protobuf.dev/reference/protobuf/google.protobuf/#value)` format)` \nOptional. Example of the object. Will only populated when the object is the root.\n`anyOf[]` `object (`[Schema](/vertex-ai/generative-ai/docs/reference/rest/v1/Schema)`)` \nOptional. The value should be validated against any (one or more) of the subschemas in the list.\n`additionalProperties` `value (`[Value](https://protobuf.dev/reference/protobuf/google.protobuf/#value)` format)` \nOptional. Can either be a boolean or an object; controls the presence of additional properties.\n`ref` `string` \nOptional. Allows indirect references between schema nodes. The value should be a valid reference to a child of the root `defs`.\n\nFor example, the following schema defines a reference to a schema node named \"Pet\":\n\ntype: object properties: pet: ref: #/defs/Pet defs: Pet: type: object properties: name: type: string\n\nThe value of the \"pet\" property is a reference to the schema node named \"Pet\". See details in \u003chttps://json-schema.org/understanding-json-schema/structuring\u003e\n`defs` `map (key: string, value: object (`[Schema](/vertex-ai/generative-ai/docs/reference/rest/v1/Schema)`))` \nOptional. A map of definitions for use by `ref` Only allowed at the root of the schema. \n\n| JSON representation |\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"type\": enum (/vertex-ai/generative-ai/docs/reference/rest/v1/Schema#Type), \"format\": string, \"title\": string, \"description\": string, \"nullable\": boolean, \"default\": value, \"items\": { object (/vertex-ai/generative-ai/docs/reference/rest/v1/Schema) }, \"minItems\": string, \"maxItems\": string, \"enum\": [ string ], \"properties\": { string: { object (/vertex-ai/generative-ai/docs/reference/rest/v1/Schema) }, ... }, \"propertyOrdering\": [ string ], \"required\": [ string ], \"minProperties\": string, \"maxProperties\": string, \"minimum\": number, \"maximum\": number, \"minLength\": string, \"maxLength\": string, \"pattern\": string, \"example\": value, \"anyOf\": [ { object (/vertex-ai/generative-ai/docs/reference/rest/v1/Schema) } ], \"additionalProperties\": value, \"ref\": string, \"defs\": { string: { object (/vertex-ai/generative-ai/docs/reference/rest/v1/Schema) }, ... } } ``` |\n\nType type contains the list of OpenAPI data types as defined by \u003chttps://swagger.io/docs/specification/data-models/data-types/\u003e\n\n| Enums ||\n|--------------------|------------------------------------|\n| `TYPE_UNSPECIFIED` | Not specified, should not be used. |\n| `STRING` | OpenAPI string type |\n| `NUMBER` | OpenAPI number type |\n| `INTEGER` | OpenAPI integer type |\n| `BOOLEAN` | OpenAPI boolean type |\n| `ARRAY` | OpenAPI array type |\n| `OBJECT` | OpenAPI object type |\n| `NULL` | Null type |"]]