@@ -9,16 +9,15 @@ import { FirebaseApp } from '@firebase/app';
9
9
import { FirebaseAuthTokenData } from ' @firebase/auth-interop-types' ;
10
10
import { FirebaseError } from ' @firebase/util' ;
11
11
12
- // @public (undocumented)
12
+ // @public
13
13
export class ArraySchema extends Schema {
14
- // Warning: (ae-forgotten-export) The symbol "SchemaParams" needs to be exported by the entry point index.d.ts
15
14
constructor (schemaParams : SchemaParams , items : TypedSchema );
16
15
// (undocumented)
17
16
items: TypedSchema ;
18
- // Warning: (ae-forgotten-export ) The symbol "_SchemaRequest" needs to be exported by the entry point index.d.ts
17
+ // Warning: (ae-incompatible-release-tags ) The symbol "toRequest" is marked as @public, but its signature references "_SchemaRequest" which is marked as @internal
19
18
//
20
19
// (undocumented)
21
- toJSON (): _SchemaRequest ;
20
+ toRequest (): _SchemaRequest ;
22
21
}
23
22
24
23
// @public
@@ -39,7 +38,7 @@ export enum BlockReason {
39
38
SAFETY = " SAFETY"
40
39
}
41
40
42
- // @public (undocumented)
41
+ // @public
43
42
export class BooleanSchema extends Schema {
44
43
constructor (schemaParams ? : SchemaParams );
45
44
}
@@ -220,7 +219,7 @@ export interface FunctionCallPart {
220
219
export interface FunctionDeclaration {
221
220
description? : string ;
222
221
name: string ;
223
- parameters? : ObjectSchema ;
222
+ parameters? : ObjectSchemaInterface ;
224
223
}
225
224
226
225
// @public
@@ -313,7 +312,6 @@ export interface GenerationConfig {
313
312
// (undocumented)
314
313
presencePenalty? : number ;
315
314
responseMimeType? : string ;
316
- // (undocumented)
317
315
responseSchema? : TypedSchema ;
318
316
// (undocumented)
319
317
stopSequences? : string [];
@@ -462,7 +460,7 @@ export interface InlineDataPart {
462
460
videoMetadata? : VideoMetadata ;
463
461
}
464
462
465
- // @public (undocumented)
463
+ // @public
466
464
export class IntegerSchema extends Schema {
467
465
constructor (schemaParams ? : SchemaParams );
468
466
}
@@ -479,22 +477,34 @@ export interface ModelParams extends BaseParams {
479
477
tools? : Tool [];
480
478
}
481
479
482
- // @public (undocumented)
480
+ // @public
483
481
export class NumberSchema extends Schema {
484
482
constructor (schemaParams ? : SchemaParams );
485
483
}
486
484
487
- // @public (undocumented)
485
+ // @public
488
486
export class ObjectSchema extends Schema {
489
487
constructor (schemaParams : SchemaParams , properties : {
490
488
[k : string ]: TypedSchema ;
491
- });
489
+ }, optionalProperties ? : string []);
490
+ // (undocumented)
491
+ optionalProperties: string [];
492
492
// (undocumented)
493
493
properties: {
494
494
[k : string ]: TypedSchema ;
495
495
};
496
+ // Warning: (ae-incompatible-release-tags) The symbol "toRequest" is marked as @public, but its signature references "_SchemaRequest" which is marked as @internal
497
+ //
496
498
// (undocumented)
497
- toJSON(): _SchemaRequest ;
499
+ toRequest(): _SchemaRequest ;
500
+ }
501
+
502
+ // @public
503
+ export interface ObjectSchemaInterface extends SchemaInterface {
504
+ // (undocumented)
505
+ optionalProperties? : string [];
506
+ // (undocumented)
507
+ type: SchemaType .OBJECT ;
498
508
}
499
509
500
510
// @public
@@ -556,11 +566,10 @@ export interface SafetySetting {
556
566
threshold: HarmBlockThreshold ;
557
567
}
558
568
559
- // Warning: (ae-forgotten-export) The symbol "SchemaInterface" needs to be exported by the entry point index.d.ts
560
- //
561
- // @public (undocumented)
569
+ // @public
562
570
export abstract class Schema implements SchemaInterface {
563
571
constructor (schemaParams : SchemaInterface );
572
+ [key : string ]: unknown ;
564
573
// (undocumented)
565
574
static array(arrayParams : SchemaParams & {
566
575
items: Schema ;
@@ -579,6 +588,7 @@ export abstract class Schema implements SchemaInterface {
579
588
properties: {
580
589
[k : string ]: Schema ;
581
590
};
591
+ optionalProperties? : string [];
582
592
}): ObjectSchema ;
583
593
// (undocumented)
584
594
static integer(integerParams ? : SchemaParams ): IntegerSchema ;
@@ -590,15 +600,44 @@ export abstract class Schema implements SchemaInterface {
590
600
properties: {
591
601
[k : string ]: Schema ;
592
602
};
603
+ optionalProperties? : string [];
593
604
}): ObjectSchema ;
594
- required: boolean ;
595
605
// (undocumented)
596
606
static string(stringParams ? : SchemaParams ): StringSchema ;
597
- toJSON(): _SchemaRequest ;
598
- // Warning: (ae-forgotten-export) The symbol "SchemaType" needs to be exported by the entry point index.d.ts
607
+ // (undocumented)
608
+ toJSON(): string ;
609
+ // Warning: (ae-incompatible-release-tags) The symbol "toRequest" is marked as @public, but its signature references "_SchemaRequest" which is marked as @internal
610
+ toRequest(): _SchemaRequest ;
611
+ type: SchemaType ;
612
+ }
613
+
614
+ // Warning: (ae-forgotten-export) The symbol "SchemaShared" needs to be exported by the entry point index.d.ts
615
+ //
616
+ // @public
617
+ export interface SchemaInterface extends SchemaShared <SchemaInterface > {
618
+ type: SchemaType ;
619
+ }
620
+
621
+ // @public
622
+ export interface SchemaParams extends SchemaShared <SchemaInterface > {
623
+ }
624
+
625
+ // @internal
626
+ export interface _SchemaRequest extends SchemaShared <_SchemaRequest > {
627
+ required? : string [];
599
628
type: SchemaType ;
600
629
}
601
630
631
+ // @public
632
+ export enum SchemaType {
633
+ ARRAY = " array" ,
634
+ BOOLEAN = " boolean" ,
635
+ INTEGER = " integer" ,
636
+ NUMBER = " number" ,
637
+ OBJECT = " object" ,
638
+ STRING = " string"
639
+ }
640
+
602
641
// @public (undocumented)
603
642
export interface Segment {
604
643
// (undocumented)
@@ -621,13 +660,15 @@ export interface StartChatParams extends BaseParams {
621
660
tools? : Tool [];
622
661
}
623
662
624
- // @public (undocumented)
663
+ // @public
625
664
export class StringSchema extends Schema {
626
665
constructor (schemaParams ? : SchemaParams , enumValues ? : string []);
627
666
// (undocumented)
628
667
enum? : string [];
668
+ // Warning: (ae-incompatible-release-tags) The symbol "toRequest" is marked as @public, but its signature references "_SchemaRequest" which is marked as @internal
669
+ //
629
670
// (undocumented)
630
- toJSON (): _SchemaRequest ;
671
+ toRequest (): _SchemaRequest ;
631
672
}
632
673
633
674
// @public
@@ -651,7 +692,7 @@ export interface ToolConfig {
651
692
functionCallingConfig: FunctionCallingConfig ;
652
693
}
653
694
654
- // @public (undocumented)
695
+ // @public
655
696
export type TypedSchema = IntegerSchema | NumberSchema | StringSchema | BooleanSchema | ObjectSchema | ArraySchema ;
656
697
657
698
// @public
@@ -675,18 +716,15 @@ export interface VertexAI {
675
716
export class VertexAIError extends FirebaseError {
676
717
constructor (code : VertexAIErrorCode , message : string , customErrorData ? : CustomErrorData | undefined );
677
718
// (undocumented)
678
- readonly code: VertexAIErrorCode ;
679
- // (undocumented)
680
719
readonly customErrorData? : CustomErrorData | undefined ;
681
- // (undocumented)
682
- readonly message: string ;
683
720
}
684
721
685
722
// @public
686
723
export const enum VertexAIErrorCode {
687
724
ERROR = " error" ,
688
725
FETCH_ERROR = " fetch-error" ,
689
726
INVALID_CONTENT = " invalid-content" ,
727
+ INVALID_SCHEMA = " invalid-schema" ,
690
728
NO_API_KEY = " no-api-key" ,
691
729
NO_MODEL = " no-model" ,
692
730
NO_PROJECT_ID = " no-project-id" ,
0 commit comments