Skip to content

Latest commit

 

History

History
147 lines (97 loc) · 3.9 KB

File metadata and controls

147 lines (97 loc) · 3.9 KB

Project: /docs/reference/js/_project.yaml Book: /docs/reference/_book.yaml page_type: reference

{% comment %} DO NOT EDIT THIS FILE! This is generated by the JS SDK team, and any local changes will be overwritten. Changes should be made in the source code at https://github.com/firebase/firebase-js-sdk {% endcomment %}

SchemaShared interface

Basic Schema properties shared across several Schema-related types.

Signature:

export interface SchemaShared<T> 

Properties

Property Type Description
description string Optional. The description of the property.
enum string[] Optional. The enum of the property.
example unknown Optional. The example of the property.
format string Optional. The format of the property. When using the Gemini Developer API (GoogleAIBackend), this must be either 'enum' or 'date-time', otherwise requests will fail.
items T Optional. The items of the property.
maximum number The maximum value of a numeric type.
minimum number The minimum value of a numeric type.
nullable boolean Optional. Whether the property is nullable.
properties { [k: string]: T; } Optional. Map of Schema objects.
propertyOrdering string[] A hint suggesting the order in which the keys should appear in the generated JSON string.
title string The title of the property. This helps document the schema's purpose but does not typically constrain the generated value. It can subtly guide the model by clarifying the intent of a field.

SchemaShared.description

Optional. The description of the property.

Signature:

description?: string;

SchemaShared.enum

Optional. The enum of the property.

Signature:

enum?: string[];

SchemaShared.example

Optional. The example of the property.

Signature:

example?: unknown;

SchemaShared.format

Optional. The format of the property. When using the Gemini Developer API (GoogleAIBackend), this must be either 'enum' or 'date-time', otherwise requests will fail.

Signature:

format?: string;

SchemaShared.items

Optional. The items of the property.

Signature:

items?: T;

SchemaShared.maximum

The maximum value of a numeric type.

Signature:

maximum?: number;

SchemaShared.minimum

The minimum value of a numeric type.

Signature:

minimum?: number;

SchemaShared.nullable

Optional. Whether the property is nullable.

Signature:

nullable?: boolean;

SchemaShared.properties

Optional. Map of Schema objects.

Signature:

properties?: {
        [k: string]: T;
    };

SchemaShared.propertyOrdering

A hint suggesting the order in which the keys should appear in the generated JSON string.

Signature:

propertyOrdering?: string[];

SchemaShared.title

The title of the property. This helps document the schema's purpose but does not typically constrain the generated value. It can subtly guide the model by clarifying the intent of a field.

Signature:

title?: string;