@google/genai 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/genai.d.ts +12 -1
- package/dist/index.cjs +188 -188
- package/dist/index.mjs +188 -188
- package/dist/index.mjs.map +1 -1
- package/dist/node/index.cjs +188 -188
- package/dist/node/index.mjs +188 -188
- package/dist/node/index.mjs.map +1 -1
- package/dist/node/node.d.ts +12 -1
- package/dist/vertex_internal/index.cjs +1 -1
- package/dist/vertex_internal/index.cjs.map +1 -1
- package/dist/vertex_internal/index.js +1 -1
- package/dist/vertex_internal/index.js.map +1 -1
- package/dist/web/index.mjs +188 -188
- package/dist/web/index.mjs.map +1 -1
- package/dist/web/web.d.ts +12 -1
- package/package.json +1 -1
package/dist/node/index.mjs
CHANGED
|
@@ -3775,23 +3775,23 @@ function authConfigToMldev$4(fromObject) {
|
|
|
3775
3775
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
3776
3776
|
}
|
|
3777
3777
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
3778
|
-
throw new Error('apiKeyConfig parameter is
|
|
3778
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3779
3779
|
}
|
|
3780
3780
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
3781
|
-
throw new Error('authType parameter is
|
|
3781
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3782
3782
|
}
|
|
3783
3783
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
3784
3784
|
undefined) {
|
|
3785
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
3785
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3786
3786
|
}
|
|
3787
3787
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
3788
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
3788
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3789
3789
|
}
|
|
3790
3790
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
3791
|
-
throw new Error('oauthConfig parameter is
|
|
3791
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3792
3792
|
}
|
|
3793
3793
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
3794
|
-
throw new Error('oidcConfig parameter is
|
|
3794
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3795
3795
|
}
|
|
3796
3796
|
return toObject;
|
|
3797
3797
|
}
|
|
@@ -3872,14 +3872,14 @@ function batchJobDestinationToVertex(fromObject) {
|
|
|
3872
3872
|
setValueByPath(toObject, ['bigqueryDestination', 'outputUri'], fromBigqueryUri);
|
|
3873
3873
|
}
|
|
3874
3874
|
if (getValueByPath(fromObject, ['fileName']) !== undefined) {
|
|
3875
|
-
throw new Error('fileName parameter is
|
|
3875
|
+
throw new Error('fileName parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3876
3876
|
}
|
|
3877
3877
|
if (getValueByPath(fromObject, ['inlinedResponses']) !== undefined) {
|
|
3878
|
-
throw new Error('inlinedResponses parameter is
|
|
3878
|
+
throw new Error('inlinedResponses parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3879
3879
|
}
|
|
3880
3880
|
if (getValueByPath(fromObject, ['inlinedEmbedContentResponses']) !==
|
|
3881
3881
|
undefined) {
|
|
3882
|
-
throw new Error('inlinedEmbedContentResponses parameter is
|
|
3882
|
+
throw new Error('inlinedEmbedContentResponses parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3883
3883
|
}
|
|
3884
3884
|
const fromVertexDataset = getValueByPath(fromObject, [
|
|
3885
3885
|
'vertexDataset',
|
|
@@ -4024,13 +4024,13 @@ function batchJobSourceFromVertex(fromObject) {
|
|
|
4024
4024
|
function batchJobSourceToMldev(apiClient, fromObject) {
|
|
4025
4025
|
const toObject = {};
|
|
4026
4026
|
if (getValueByPath(fromObject, ['format']) !== undefined) {
|
|
4027
|
-
throw new Error('format parameter is
|
|
4027
|
+
throw new Error('format parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4028
4028
|
}
|
|
4029
4029
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
4030
|
-
throw new Error('gcsUri parameter is
|
|
4030
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4031
4031
|
}
|
|
4032
4032
|
if (getValueByPath(fromObject, ['bigqueryUri']) !== undefined) {
|
|
4033
|
-
throw new Error('bigqueryUri parameter is
|
|
4033
|
+
throw new Error('bigqueryUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4034
4034
|
}
|
|
4035
4035
|
const fromFileName = getValueByPath(fromObject, ['fileName']);
|
|
4036
4036
|
if (fromFileName != null) {
|
|
@@ -4049,7 +4049,7 @@ function batchJobSourceToMldev(apiClient, fromObject) {
|
|
|
4049
4049
|
setValueByPath(toObject, ['requests', 'requests'], transformedList);
|
|
4050
4050
|
}
|
|
4051
4051
|
if (getValueByPath(fromObject, ['vertexDatasetName']) !== undefined) {
|
|
4052
|
-
throw new Error('vertexDatasetName parameter is
|
|
4052
|
+
throw new Error('vertexDatasetName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4053
4053
|
}
|
|
4054
4054
|
return toObject;
|
|
4055
4055
|
}
|
|
@@ -4068,10 +4068,10 @@ function batchJobSourceToVertex(fromObject) {
|
|
|
4068
4068
|
setValueByPath(toObject, ['bigquerySource', 'inputUri'], fromBigqueryUri);
|
|
4069
4069
|
}
|
|
4070
4070
|
if (getValueByPath(fromObject, ['fileName']) !== undefined) {
|
|
4071
|
-
throw new Error('fileName parameter is
|
|
4071
|
+
throw new Error('fileName parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4072
4072
|
}
|
|
4073
4073
|
if (getValueByPath(fromObject, ['inlinedRequests']) !== undefined) {
|
|
4074
|
-
throw new Error('inlinedRequests parameter is
|
|
4074
|
+
throw new Error('inlinedRequests parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4075
4075
|
}
|
|
4076
4076
|
const fromVertexDatasetName = getValueByPath(fromObject, [
|
|
4077
4077
|
'vertexDatasetName',
|
|
@@ -4088,7 +4088,7 @@ function blobToMldev$4(fromObject) {
|
|
|
4088
4088
|
setValueByPath(toObject, ['data'], fromData);
|
|
4089
4089
|
}
|
|
4090
4090
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
4091
|
-
throw new Error('displayName parameter is
|
|
4091
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4092
4092
|
}
|
|
4093
4093
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
4094
4094
|
if (fromMimeType != null) {
|
|
@@ -4211,7 +4211,7 @@ function createBatchJobConfigToMldev(fromObject, parentObject) {
|
|
|
4211
4211
|
setValueByPath(parentObject, ['batch', 'displayName'], fromDisplayName);
|
|
4212
4212
|
}
|
|
4213
4213
|
if (getValueByPath(fromObject, ['dest']) !== undefined) {
|
|
4214
|
-
throw new Error('dest parameter is
|
|
4214
|
+
throw new Error('dest parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4215
4215
|
}
|
|
4216
4216
|
const fromWebhookConfig = getValueByPath(fromObject, [
|
|
4217
4217
|
'webhookConfig',
|
|
@@ -4232,7 +4232,7 @@ function createBatchJobConfigToVertex(fromObject, parentObject) {
|
|
|
4232
4232
|
setValueByPath(parentObject, ['outputConfig'], batchJobDestinationToVertex(tBatchJobDestination(fromDest)));
|
|
4233
4233
|
}
|
|
4234
4234
|
if (getValueByPath(fromObject, ['webhookConfig']) !== undefined) {
|
|
4235
|
-
throw new Error('webhookConfig parameter is
|
|
4235
|
+
throw new Error('webhookConfig parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4236
4236
|
}
|
|
4237
4237
|
return toObject;
|
|
4238
4238
|
}
|
|
@@ -4388,16 +4388,16 @@ function embedContentConfigToMldev$1(fromObject, parentObject) {
|
|
|
4388
4388
|
setValueByPath(parentObject, ['requests[]', 'outputDimensionality'], fromOutputDimensionality);
|
|
4389
4389
|
}
|
|
4390
4390
|
if (getValueByPath(fromObject, ['mimeType']) !== undefined) {
|
|
4391
|
-
throw new Error('mimeType parameter is
|
|
4391
|
+
throw new Error('mimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4392
4392
|
}
|
|
4393
4393
|
if (getValueByPath(fromObject, ['autoTruncate']) !== undefined) {
|
|
4394
|
-
throw new Error('autoTruncate parameter is
|
|
4394
|
+
throw new Error('autoTruncate parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4395
4395
|
}
|
|
4396
4396
|
if (getValueByPath(fromObject, ['documentOcr']) !== undefined) {
|
|
4397
|
-
throw new Error('documentOcr parameter is
|
|
4397
|
+
throw new Error('documentOcr parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4398
4398
|
}
|
|
4399
4399
|
if (getValueByPath(fromObject, ['audioTrackExtraction']) !== undefined) {
|
|
4400
|
-
throw new Error('audioTrackExtraction parameter is
|
|
4400
|
+
throw new Error('audioTrackExtraction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4401
4401
|
}
|
|
4402
4402
|
return toObject;
|
|
4403
4403
|
}
|
|
@@ -4418,7 +4418,7 @@ function embeddingsBatchJobSourceToMldev(apiClient, fromObject) {
|
|
|
4418
4418
|
function fileDataToMldev$4(fromObject) {
|
|
4419
4419
|
const toObject = {};
|
|
4420
4420
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
4421
|
-
throw new Error('displayName parameter is
|
|
4421
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4422
4422
|
}
|
|
4423
4423
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
4424
4424
|
if (fromFileUri != null) {
|
|
@@ -4445,10 +4445,10 @@ function functionCallToMldev$4(fromObject) {
|
|
|
4445
4445
|
setValueByPath(toObject, ['name'], fromName);
|
|
4446
4446
|
}
|
|
4447
4447
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
4448
|
-
throw new Error('partialArgs parameter is
|
|
4448
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4449
4449
|
}
|
|
4450
4450
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
4451
|
-
throw new Error('willContinue parameter is
|
|
4451
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4452
4452
|
}
|
|
4453
4453
|
return toObject;
|
|
4454
4454
|
}
|
|
@@ -4466,7 +4466,7 @@ function functionCallingConfigToMldev$2(fromObject) {
|
|
|
4466
4466
|
}
|
|
4467
4467
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
4468
4468
|
undefined) {
|
|
4469
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
4469
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4470
4470
|
}
|
|
4471
4471
|
return toObject;
|
|
4472
4472
|
}
|
|
@@ -4553,10 +4553,10 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4553
4553
|
setValueByPath(toObject, ['responseJsonSchema'], fromResponseJsonSchema);
|
|
4554
4554
|
}
|
|
4555
4555
|
if (getValueByPath(fromObject, ['routingConfig']) !== undefined) {
|
|
4556
|
-
throw new Error('routingConfig parameter is
|
|
4556
|
+
throw new Error('routingConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4557
4557
|
}
|
|
4558
4558
|
if (getValueByPath(fromObject, ['modelSelectionConfig']) !== undefined) {
|
|
4559
|
-
throw new Error('modelSelectionConfig parameter is
|
|
4559
|
+
throw new Error('modelSelectionConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4560
4560
|
}
|
|
4561
4561
|
const fromSafetySettings = getValueByPath(fromObject, [
|
|
4562
4562
|
'safetySettings',
|
|
@@ -4585,7 +4585,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4585
4585
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev$2(fromToolConfig));
|
|
4586
4586
|
}
|
|
4587
4587
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
4588
|
-
throw new Error('labels parameter is
|
|
4588
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4589
4589
|
}
|
|
4590
4590
|
const fromCachedContent = getValueByPath(fromObject, [
|
|
4591
4591
|
'cachedContent',
|
|
@@ -4610,7 +4610,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4610
4610
|
setValueByPath(toObject, ['speechConfig'], tSpeechConfig(fromSpeechConfig));
|
|
4611
4611
|
}
|
|
4612
4612
|
if (getValueByPath(fromObject, ['audioTimestamp']) !== undefined) {
|
|
4613
|
-
throw new Error('audioTimestamp parameter is
|
|
4613
|
+
throw new Error('audioTimestamp parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4614
4614
|
}
|
|
4615
4615
|
const fromThinkingConfig = getValueByPath(fromObject, [
|
|
4616
4616
|
'thinkingConfig',
|
|
@@ -4629,7 +4629,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4629
4629
|
setValueByPath(toObject, ['enableEnhancedCivicAnswers'], fromEnableEnhancedCivicAnswers);
|
|
4630
4630
|
}
|
|
4631
4631
|
if (getValueByPath(fromObject, ['modelArmorConfig']) !== undefined) {
|
|
4632
|
-
throw new Error('modelArmorConfig parameter is
|
|
4632
|
+
throw new Error('modelArmorConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4633
4633
|
}
|
|
4634
4634
|
const fromServiceTier = getValueByPath(fromObject, ['serviceTier']);
|
|
4635
4635
|
if (parentObject !== undefined && fromServiceTier != null) {
|
|
@@ -4716,10 +4716,10 @@ function googleSearchToMldev$4(fromObject) {
|
|
|
4716
4716
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
4717
4717
|
}
|
|
4718
4718
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
4719
|
-
throw new Error('blockingConfidence parameter is
|
|
4719
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4720
4720
|
}
|
|
4721
4721
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
4722
|
-
throw new Error('excludeDomains parameter is
|
|
4722
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4723
4723
|
}
|
|
4724
4724
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
4725
4725
|
'timeRangeFilter',
|
|
@@ -4740,20 +4740,20 @@ function imageConfigToMldev$1(fromObject) {
|
|
|
4740
4740
|
setValueByPath(toObject, ['imageSize'], fromImageSize);
|
|
4741
4741
|
}
|
|
4742
4742
|
if (getValueByPath(fromObject, ['personGeneration']) !== undefined) {
|
|
4743
|
-
throw new Error('personGeneration parameter is
|
|
4743
|
+
throw new Error('personGeneration parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4744
4744
|
}
|
|
4745
4745
|
if (getValueByPath(fromObject, ['prominentPeople']) !== undefined) {
|
|
4746
|
-
throw new Error('prominentPeople parameter is
|
|
4746
|
+
throw new Error('prominentPeople parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4747
4747
|
}
|
|
4748
4748
|
if (getValueByPath(fromObject, ['outputMimeType']) !== undefined) {
|
|
4749
|
-
throw new Error('outputMimeType parameter is
|
|
4749
|
+
throw new Error('outputMimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4750
4750
|
}
|
|
4751
4751
|
if (getValueByPath(fromObject, ['outputCompressionQuality']) !==
|
|
4752
4752
|
undefined) {
|
|
4753
|
-
throw new Error('outputCompressionQuality parameter is
|
|
4753
|
+
throw new Error('outputCompressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4754
4754
|
}
|
|
4755
4755
|
if (getValueByPath(fromObject, ['imageOutputOptions']) !== undefined) {
|
|
4756
|
-
throw new Error('imageOutputOptions parameter is
|
|
4756
|
+
throw new Error('imageOutputOptions parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4757
4757
|
}
|
|
4758
4758
|
return toObject;
|
|
4759
4759
|
}
|
|
@@ -4810,7 +4810,7 @@ function listBatchJobsConfigToMldev(fromObject, parentObject) {
|
|
|
4810
4810
|
setValueByPath(parentObject, ['_query', 'pageToken'], fromPageToken);
|
|
4811
4811
|
}
|
|
4812
4812
|
if (getValueByPath(fromObject, ['filter']) !== undefined) {
|
|
4813
|
-
throw new Error('filter parameter is
|
|
4813
|
+
throw new Error('filter parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4814
4814
|
}
|
|
4815
4815
|
return toObject;
|
|
4816
4816
|
}
|
|
@@ -4979,7 +4979,7 @@ function safetySettingToMldev$3(fromObject) {
|
|
|
4979
4979
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
4980
4980
|
}
|
|
4981
4981
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
4982
|
-
throw new Error('method parameter is
|
|
4982
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4983
4983
|
}
|
|
4984
4984
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
4985
4985
|
if (fromThreshold != null) {
|
|
@@ -5010,7 +5010,7 @@ function toolConfigToMldev$2(fromObject) {
|
|
|
5010
5010
|
function toolToMldev$4(fromObject) {
|
|
5011
5011
|
const toObject = {};
|
|
5012
5012
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
5013
|
-
throw new Error('retrieval parameter is
|
|
5013
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5014
5014
|
}
|
|
5015
5015
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
5016
5016
|
if (fromComputerUse != null) {
|
|
@@ -5035,7 +5035,7 @@ function toolToMldev$4(fromObject) {
|
|
|
5035
5035
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
5036
5036
|
}
|
|
5037
5037
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
5038
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
5038
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5039
5039
|
}
|
|
5040
5040
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
5041
5041
|
'functionDeclarations',
|
|
@@ -5056,7 +5056,7 @@ function toolToMldev$4(fromObject) {
|
|
|
5056
5056
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
5057
5057
|
}
|
|
5058
5058
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
5059
|
-
throw new Error('parallelAiSearch parameter is
|
|
5059
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5060
5060
|
}
|
|
5061
5061
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
5062
5062
|
if (fromUrlContext != null) {
|
|
@@ -5803,23 +5803,23 @@ function authConfigToMldev$3(fromObject) {
|
|
|
5803
5803
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
5804
5804
|
}
|
|
5805
5805
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
5806
|
-
throw new Error('apiKeyConfig parameter is
|
|
5806
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5807
5807
|
}
|
|
5808
5808
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
5809
|
-
throw new Error('authType parameter is
|
|
5809
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5810
5810
|
}
|
|
5811
5811
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
5812
5812
|
undefined) {
|
|
5813
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
5813
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5814
5814
|
}
|
|
5815
5815
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
5816
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
5816
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5817
5817
|
}
|
|
5818
5818
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
5819
|
-
throw new Error('oauthConfig parameter is
|
|
5819
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5820
5820
|
}
|
|
5821
5821
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
5822
|
-
throw new Error('oidcConfig parameter is
|
|
5822
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5823
5823
|
}
|
|
5824
5824
|
return toObject;
|
|
5825
5825
|
}
|
|
@@ -5830,7 +5830,7 @@ function blobToMldev$3(fromObject) {
|
|
|
5830
5830
|
setValueByPath(toObject, ['data'], fromData);
|
|
5831
5831
|
}
|
|
5832
5832
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
5833
|
-
throw new Error('displayName parameter is
|
|
5833
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5834
5834
|
}
|
|
5835
5835
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
5836
5836
|
if (fromMimeType != null) {
|
|
@@ -5919,7 +5919,7 @@ function createCachedContentConfigToMldev(fromObject, parentObject) {
|
|
|
5919
5919
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev$1(fromToolConfig));
|
|
5920
5920
|
}
|
|
5921
5921
|
if (getValueByPath(fromObject, ['kmsKeyName']) !== undefined) {
|
|
5922
|
-
throw new Error('kmsKeyName parameter is
|
|
5922
|
+
throw new Error('kmsKeyName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5923
5923
|
}
|
|
5924
5924
|
return toObject;
|
|
5925
5925
|
}
|
|
@@ -6036,7 +6036,7 @@ function deleteCachedContentResponseFromVertex(fromObject) {
|
|
|
6036
6036
|
function fileDataToMldev$3(fromObject) {
|
|
6037
6037
|
const toObject = {};
|
|
6038
6038
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
6039
|
-
throw new Error('displayName parameter is
|
|
6039
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6040
6040
|
}
|
|
6041
6041
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
6042
6042
|
if (fromFileUri != null) {
|
|
@@ -6063,10 +6063,10 @@ function functionCallToMldev$3(fromObject) {
|
|
|
6063
6063
|
setValueByPath(toObject, ['name'], fromName);
|
|
6064
6064
|
}
|
|
6065
6065
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
6066
|
-
throw new Error('partialArgs parameter is
|
|
6066
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6067
6067
|
}
|
|
6068
6068
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
6069
|
-
throw new Error('willContinue parameter is
|
|
6069
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6070
6070
|
}
|
|
6071
6071
|
return toObject;
|
|
6072
6072
|
}
|
|
@@ -6084,7 +6084,7 @@ function functionCallingConfigToMldev$1(fromObject) {
|
|
|
6084
6084
|
}
|
|
6085
6085
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
6086
6086
|
undefined) {
|
|
6087
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
6087
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6088
6088
|
}
|
|
6089
6089
|
return toObject;
|
|
6090
6090
|
}
|
|
@@ -6123,10 +6123,10 @@ function googleSearchToMldev$3(fromObject) {
|
|
|
6123
6123
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
6124
6124
|
}
|
|
6125
6125
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
6126
|
-
throw new Error('blockingConfidence parameter is
|
|
6126
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6127
6127
|
}
|
|
6128
6128
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
6129
|
-
throw new Error('excludeDomains parameter is
|
|
6129
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6130
6130
|
}
|
|
6131
6131
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
6132
6132
|
'timeRangeFilter',
|
|
@@ -6363,13 +6363,13 @@ function partToVertex$2(fromObject) {
|
|
|
6363
6363
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
6364
6364
|
}
|
|
6365
6365
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
6366
|
-
throw new Error('toolCall parameter is
|
|
6366
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6367
6367
|
}
|
|
6368
6368
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
6369
|
-
throw new Error('toolResponse parameter is
|
|
6369
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6370
6370
|
}
|
|
6371
6371
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
6372
|
-
throw new Error('partMetadata parameter is
|
|
6372
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6373
6373
|
}
|
|
6374
6374
|
return toObject;
|
|
6375
6375
|
}
|
|
@@ -6409,14 +6409,14 @@ function toolConfigToVertex$1(fromObject) {
|
|
|
6409
6409
|
}
|
|
6410
6410
|
if (getValueByPath(fromObject, ['includeServerSideToolInvocations']) !==
|
|
6411
6411
|
undefined) {
|
|
6412
|
-
throw new Error('includeServerSideToolInvocations parameter is
|
|
6412
|
+
throw new Error('includeServerSideToolInvocations parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6413
6413
|
}
|
|
6414
6414
|
return toObject;
|
|
6415
6415
|
}
|
|
6416
6416
|
function toolToMldev$3(fromObject) {
|
|
6417
6417
|
const toObject = {};
|
|
6418
6418
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
6419
|
-
throw new Error('retrieval parameter is
|
|
6419
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6420
6420
|
}
|
|
6421
6421
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
6422
6422
|
if (fromComputerUse != null) {
|
|
@@ -6441,7 +6441,7 @@ function toolToMldev$3(fromObject) {
|
|
|
6441
6441
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
6442
6442
|
}
|
|
6443
6443
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
6444
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
6444
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6445
6445
|
}
|
|
6446
6446
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
6447
6447
|
'functionDeclarations',
|
|
@@ -6462,7 +6462,7 @@ function toolToMldev$3(fromObject) {
|
|
|
6462
6462
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
6463
6463
|
}
|
|
6464
6464
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
6465
|
-
throw new Error('parallelAiSearch parameter is
|
|
6465
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6466
6466
|
}
|
|
6467
6467
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
6468
6468
|
if (fromUrlContext != null) {
|
|
@@ -6491,7 +6491,7 @@ function toolToVertex$2(fromObject) {
|
|
|
6491
6491
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
6492
6492
|
}
|
|
6493
6493
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
6494
|
-
throw new Error('fileSearch parameter is
|
|
6494
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6495
6495
|
}
|
|
6496
6496
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
6497
6497
|
if (fromGoogleSearch != null) {
|
|
@@ -6542,7 +6542,7 @@ function toolToVertex$2(fromObject) {
|
|
|
6542
6542
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
6543
6543
|
}
|
|
6544
6544
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
6545
|
-
throw new Error('mcpServers parameter is
|
|
6545
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6546
6546
|
}
|
|
6547
6547
|
return toObject;
|
|
6548
6548
|
}
|
|
@@ -7834,7 +7834,7 @@ class Files extends BaseModule {
|
|
|
7834
7834
|
function audioTranscriptionConfigToMldev$1(fromObject) {
|
|
7835
7835
|
const toObject = {};
|
|
7836
7836
|
if (getValueByPath(fromObject, ['languageCodes']) !== undefined) {
|
|
7837
|
-
throw new Error('languageCodes parameter is
|
|
7837
|
+
throw new Error('languageCodes parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7838
7838
|
}
|
|
7839
7839
|
return toObject;
|
|
7840
7840
|
}
|
|
@@ -7845,23 +7845,23 @@ function authConfigToMldev$2(fromObject) {
|
|
|
7845
7845
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
7846
7846
|
}
|
|
7847
7847
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
7848
|
-
throw new Error('apiKeyConfig parameter is
|
|
7848
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7849
7849
|
}
|
|
7850
7850
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
7851
|
-
throw new Error('authType parameter is
|
|
7851
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7852
7852
|
}
|
|
7853
7853
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
7854
7854
|
undefined) {
|
|
7855
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
7855
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7856
7856
|
}
|
|
7857
7857
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
7858
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
7858
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7859
7859
|
}
|
|
7860
7860
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
7861
|
-
throw new Error('oauthConfig parameter is
|
|
7861
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7862
7862
|
}
|
|
7863
7863
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
7864
|
-
throw new Error('oidcConfig parameter is
|
|
7864
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7865
7865
|
}
|
|
7866
7866
|
return toObject;
|
|
7867
7867
|
}
|
|
@@ -7872,7 +7872,7 @@ function blobToMldev$2(fromObject) {
|
|
|
7872
7872
|
setValueByPath(toObject, ['data'], fromData);
|
|
7873
7873
|
}
|
|
7874
7874
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
7875
|
-
throw new Error('displayName parameter is
|
|
7875
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7876
7876
|
}
|
|
7877
7877
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
7878
7878
|
if (fromMimeType != null) {
|
|
@@ -7919,7 +7919,7 @@ function contentToVertex$1(fromObject) {
|
|
|
7919
7919
|
function fileDataToMldev$2(fromObject) {
|
|
7920
7920
|
const toObject = {};
|
|
7921
7921
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
7922
|
-
throw new Error('displayName parameter is
|
|
7922
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7923
7923
|
}
|
|
7924
7924
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
7925
7925
|
if (fromFileUri != null) {
|
|
@@ -7946,10 +7946,10 @@ function functionCallToMldev$2(fromObject) {
|
|
|
7946
7946
|
setValueByPath(toObject, ['name'], fromName);
|
|
7947
7947
|
}
|
|
7948
7948
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
7949
|
-
throw new Error('partialArgs parameter is
|
|
7949
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7950
7950
|
}
|
|
7951
7951
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
7952
|
-
throw new Error('willContinue parameter is
|
|
7952
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7953
7953
|
}
|
|
7954
7954
|
return toObject;
|
|
7955
7955
|
}
|
|
@@ -8077,7 +8077,7 @@ function generationConfigToVertex$1(fromObject) {
|
|
|
8077
8077
|
}
|
|
8078
8078
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
8079
8079
|
undefined) {
|
|
8080
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
8080
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8081
8081
|
}
|
|
8082
8082
|
return toObject;
|
|
8083
8083
|
}
|
|
@@ -8100,10 +8100,10 @@ function googleSearchToMldev$2(fromObject) {
|
|
|
8100
8100
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
8101
8101
|
}
|
|
8102
8102
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
8103
|
-
throw new Error('blockingConfidence parameter is
|
|
8103
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8104
8104
|
}
|
|
8105
8105
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
8106
|
-
throw new Error('excludeDomains parameter is
|
|
8106
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8107
8107
|
}
|
|
8108
8108
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
8109
8109
|
'timeRangeFilter',
|
|
@@ -8222,7 +8222,7 @@ function liveConnectConfigToMldev$1(fromObject, parentObject) {
|
|
|
8222
8222
|
setValueByPath(parentObject, ['setup', 'proactivity'], fromProactivity);
|
|
8223
8223
|
}
|
|
8224
8224
|
if (getValueByPath(fromObject, ['explicitVadSignal']) !== undefined) {
|
|
8225
|
-
throw new Error('explicitVadSignal parameter is
|
|
8225
|
+
throw new Error('explicitVadSignal parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8226
8226
|
}
|
|
8227
8227
|
const fromAvatarConfig = getValueByPath(fromObject, ['avatarConfig']);
|
|
8228
8228
|
if (parentObject !== undefined && fromAvatarConfig != null) {
|
|
@@ -8693,13 +8693,13 @@ function partToVertex$1(fromObject) {
|
|
|
8693
8693
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
8694
8694
|
}
|
|
8695
8695
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
8696
|
-
throw new Error('toolCall parameter is
|
|
8696
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8697
8697
|
}
|
|
8698
8698
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
8699
|
-
throw new Error('toolResponse parameter is
|
|
8699
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8700
8700
|
}
|
|
8701
8701
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
8702
|
-
throw new Error('partMetadata parameter is
|
|
8702
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8703
8703
|
}
|
|
8704
8704
|
return toObject;
|
|
8705
8705
|
}
|
|
@@ -8710,7 +8710,7 @@ function safetySettingToMldev$2(fromObject) {
|
|
|
8710
8710
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
8711
8711
|
}
|
|
8712
8712
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
8713
|
-
throw new Error('method parameter is
|
|
8713
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8714
8714
|
}
|
|
8715
8715
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
8716
8716
|
if (fromThreshold != null) {
|
|
@@ -8725,14 +8725,14 @@ function sessionResumptionConfigToMldev$1(fromObject) {
|
|
|
8725
8725
|
setValueByPath(toObject, ['handle'], fromHandle);
|
|
8726
8726
|
}
|
|
8727
8727
|
if (getValueByPath(fromObject, ['transparent']) !== undefined) {
|
|
8728
|
-
throw new Error('transparent parameter is
|
|
8728
|
+
throw new Error('transparent parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8729
8729
|
}
|
|
8730
8730
|
return toObject;
|
|
8731
8731
|
}
|
|
8732
8732
|
function toolToMldev$2(fromObject) {
|
|
8733
8733
|
const toObject = {};
|
|
8734
8734
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
8735
|
-
throw new Error('retrieval parameter is
|
|
8735
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8736
8736
|
}
|
|
8737
8737
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
8738
8738
|
if (fromComputerUse != null) {
|
|
@@ -8757,7 +8757,7 @@ function toolToMldev$2(fromObject) {
|
|
|
8757
8757
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
8758
8758
|
}
|
|
8759
8759
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
8760
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
8760
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8761
8761
|
}
|
|
8762
8762
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
8763
8763
|
'functionDeclarations',
|
|
@@ -8778,7 +8778,7 @@ function toolToMldev$2(fromObject) {
|
|
|
8778
8778
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
8779
8779
|
}
|
|
8780
8780
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
8781
|
-
throw new Error('parallelAiSearch parameter is
|
|
8781
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8782
8782
|
}
|
|
8783
8783
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
8784
8784
|
if (fromUrlContext != null) {
|
|
@@ -8807,7 +8807,7 @@ function toolToVertex$1(fromObject) {
|
|
|
8807
8807
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
8808
8808
|
}
|
|
8809
8809
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
8810
|
-
throw new Error('fileSearch parameter is
|
|
8810
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8811
8811
|
}
|
|
8812
8812
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
8813
8813
|
if (fromGoogleSearch != null) {
|
|
@@ -8858,7 +8858,7 @@ function toolToVertex$1(fromObject) {
|
|
|
8858
8858
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
8859
8859
|
}
|
|
8860
8860
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
8861
|
-
throw new Error('mcpServers parameter is
|
|
8861
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8862
8862
|
}
|
|
8863
8863
|
return toObject;
|
|
8864
8864
|
}
|
|
@@ -8975,23 +8975,23 @@ function authConfigToMldev$1(fromObject, _rootObject) {
|
|
|
8975
8975
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
8976
8976
|
}
|
|
8977
8977
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
8978
|
-
throw new Error('apiKeyConfig parameter is
|
|
8978
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8979
8979
|
}
|
|
8980
8980
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
8981
|
-
throw new Error('authType parameter is
|
|
8981
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8982
8982
|
}
|
|
8983
8983
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
8984
8984
|
undefined) {
|
|
8985
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
8985
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8986
8986
|
}
|
|
8987
8987
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
8988
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
8988
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8989
8989
|
}
|
|
8990
8990
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
8991
|
-
throw new Error('oauthConfig parameter is
|
|
8991
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8992
8992
|
}
|
|
8993
8993
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
8994
|
-
throw new Error('oidcConfig parameter is
|
|
8994
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8995
8995
|
}
|
|
8996
8996
|
return toObject;
|
|
8997
8997
|
}
|
|
@@ -9002,7 +9002,7 @@ function blobToMldev$1(fromObject, _rootObject) {
|
|
|
9002
9002
|
setValueByPath(toObject, ['data'], fromData);
|
|
9003
9003
|
}
|
|
9004
9004
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
9005
|
-
throw new Error('displayName parameter is
|
|
9005
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9006
9006
|
}
|
|
9007
9007
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
9008
9008
|
if (fromMimeType != null) {
|
|
@@ -9199,13 +9199,13 @@ function controlReferenceConfigToVertex(fromObject, _rootObject) {
|
|
|
9199
9199
|
function countTokensConfigToMldev(fromObject, _rootObject) {
|
|
9200
9200
|
const toObject = {};
|
|
9201
9201
|
if (getValueByPath(fromObject, ['systemInstruction']) !== undefined) {
|
|
9202
|
-
throw new Error('systemInstruction parameter is
|
|
9202
|
+
throw new Error('systemInstruction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9203
9203
|
}
|
|
9204
9204
|
if (getValueByPath(fromObject, ['tools']) !== undefined) {
|
|
9205
|
-
throw new Error('tools parameter is
|
|
9205
|
+
throw new Error('tools parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9206
9206
|
}
|
|
9207
9207
|
if (getValueByPath(fromObject, ['generationConfig']) !== undefined) {
|
|
9208
|
-
throw new Error('generationConfig parameter is
|
|
9208
|
+
throw new Error('generationConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9209
9209
|
}
|
|
9210
9210
|
return toObject;
|
|
9211
9211
|
}
|
|
@@ -9506,16 +9506,16 @@ function embedContentConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
9506
9506
|
setValueByPath(parentObject, ['requests[]', 'outputDimensionality'], fromOutputDimensionality);
|
|
9507
9507
|
}
|
|
9508
9508
|
if (getValueByPath(fromObject, ['mimeType']) !== undefined) {
|
|
9509
|
-
throw new Error('mimeType parameter is
|
|
9509
|
+
throw new Error('mimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9510
9510
|
}
|
|
9511
9511
|
if (getValueByPath(fromObject, ['autoTruncate']) !== undefined) {
|
|
9512
|
-
throw new Error('autoTruncate parameter is
|
|
9512
|
+
throw new Error('autoTruncate parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9513
9513
|
}
|
|
9514
9514
|
if (getValueByPath(fromObject, ['documentOcr']) !== undefined) {
|
|
9515
|
-
throw new Error('documentOcr parameter is
|
|
9515
|
+
throw new Error('documentOcr parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9516
9516
|
}
|
|
9517
9517
|
if (getValueByPath(fromObject, ['audioTrackExtraction']) !== undefined) {
|
|
9518
|
-
throw new Error('audioTrackExtraction parameter is
|
|
9518
|
+
throw new Error('audioTrackExtraction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9519
9519
|
}
|
|
9520
9520
|
return toObject;
|
|
9521
9521
|
}
|
|
@@ -9799,7 +9799,7 @@ function endpointFromVertex(fromObject, _rootObject) {
|
|
|
9799
9799
|
function fileDataToMldev$1(fromObject, _rootObject) {
|
|
9800
9800
|
const toObject = {};
|
|
9801
9801
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
9802
|
-
throw new Error('displayName parameter is
|
|
9802
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9803
9803
|
}
|
|
9804
9804
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
9805
9805
|
if (fromFileUri != null) {
|
|
@@ -9826,10 +9826,10 @@ function functionCallToMldev$1(fromObject, _rootObject) {
|
|
|
9826
9826
|
setValueByPath(toObject, ['name'], fromName);
|
|
9827
9827
|
}
|
|
9828
9828
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
9829
|
-
throw new Error('partialArgs parameter is
|
|
9829
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9830
9830
|
}
|
|
9831
9831
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
9832
|
-
throw new Error('willContinue parameter is
|
|
9832
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9833
9833
|
}
|
|
9834
9834
|
return toObject;
|
|
9835
9835
|
}
|
|
@@ -9847,7 +9847,7 @@ function functionCallingConfigToMldev(fromObject, _rootObject) {
|
|
|
9847
9847
|
}
|
|
9848
9848
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
9849
9849
|
undefined) {
|
|
9850
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
9850
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9851
9851
|
}
|
|
9852
9852
|
return toObject;
|
|
9853
9853
|
}
|
|
@@ -9934,10 +9934,10 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
9934
9934
|
setValueByPath(toObject, ['responseJsonSchema'], fromResponseJsonSchema);
|
|
9935
9935
|
}
|
|
9936
9936
|
if (getValueByPath(fromObject, ['routingConfig']) !== undefined) {
|
|
9937
|
-
throw new Error('routingConfig parameter is
|
|
9937
|
+
throw new Error('routingConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9938
9938
|
}
|
|
9939
9939
|
if (getValueByPath(fromObject, ['modelSelectionConfig']) !== undefined) {
|
|
9940
|
-
throw new Error('modelSelectionConfig parameter is
|
|
9940
|
+
throw new Error('modelSelectionConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9941
9941
|
}
|
|
9942
9942
|
const fromSafetySettings = getValueByPath(fromObject, [
|
|
9943
9943
|
'safetySettings',
|
|
@@ -9966,7 +9966,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
9966
9966
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev(fromToolConfig));
|
|
9967
9967
|
}
|
|
9968
9968
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
9969
|
-
throw new Error('labels parameter is
|
|
9969
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9970
9970
|
}
|
|
9971
9971
|
const fromCachedContent = getValueByPath(fromObject, [
|
|
9972
9972
|
'cachedContent',
|
|
@@ -9991,7 +9991,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
9991
9991
|
setValueByPath(toObject, ['speechConfig'], tSpeechConfig(fromSpeechConfig));
|
|
9992
9992
|
}
|
|
9993
9993
|
if (getValueByPath(fromObject, ['audioTimestamp']) !== undefined) {
|
|
9994
|
-
throw new Error('audioTimestamp parameter is
|
|
9994
|
+
throw new Error('audioTimestamp parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9995
9995
|
}
|
|
9996
9996
|
const fromThinkingConfig = getValueByPath(fromObject, [
|
|
9997
9997
|
'thinkingConfig',
|
|
@@ -10010,7 +10010,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
10010
10010
|
setValueByPath(toObject, ['enableEnhancedCivicAnswers'], fromEnableEnhancedCivicAnswers);
|
|
10011
10011
|
}
|
|
10012
10012
|
if (getValueByPath(fromObject, ['modelArmorConfig']) !== undefined) {
|
|
10013
|
-
throw new Error('modelArmorConfig parameter is
|
|
10013
|
+
throw new Error('modelArmorConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10014
10014
|
}
|
|
10015
10015
|
const fromServiceTier = getValueByPath(fromObject, ['serviceTier']);
|
|
10016
10016
|
if (parentObject !== undefined && fromServiceTier != null) {
|
|
@@ -10182,7 +10182,7 @@ function generateContentConfigToVertex(apiClient, fromObject, parentObject, root
|
|
|
10182
10182
|
}
|
|
10183
10183
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
10184
10184
|
undefined) {
|
|
10185
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
10185
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
10186
10186
|
}
|
|
10187
10187
|
const fromModelArmorConfig = getValueByPath(fromObject, [
|
|
10188
10188
|
'modelArmorConfig',
|
|
@@ -10331,10 +10331,10 @@ function generateContentResponseFromVertex(fromObject, _rootObject) {
|
|
|
10331
10331
|
function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
10332
10332
|
const toObject = {};
|
|
10333
10333
|
if (getValueByPath(fromObject, ['outputGcsUri']) !== undefined) {
|
|
10334
|
-
throw new Error('outputGcsUri parameter is
|
|
10334
|
+
throw new Error('outputGcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10335
10335
|
}
|
|
10336
10336
|
if (getValueByPath(fromObject, ['negativePrompt']) !== undefined) {
|
|
10337
|
-
throw new Error('negativePrompt parameter is
|
|
10337
|
+
throw new Error('negativePrompt parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10338
10338
|
}
|
|
10339
10339
|
const fromNumberOfImages = getValueByPath(fromObject, [
|
|
10340
10340
|
'numberOfImages',
|
|
@@ -10353,7 +10353,7 @@ function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
10353
10353
|
setValueByPath(parentObject, ['parameters', 'guidanceScale'], fromGuidanceScale);
|
|
10354
10354
|
}
|
|
10355
10355
|
if (getValueByPath(fromObject, ['seed']) !== undefined) {
|
|
10356
|
-
throw new Error('seed parameter is
|
|
10356
|
+
throw new Error('seed parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10357
10357
|
}
|
|
10358
10358
|
const fromSafetyFilterLevel = getValueByPath(fromObject, [
|
|
10359
10359
|
'safetyFilterLevel',
|
|
@@ -10396,17 +10396,17 @@ function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
10396
10396
|
setValueByPath(parentObject, ['parameters', 'outputOptions', 'compressionQuality'], fromOutputCompressionQuality);
|
|
10397
10397
|
}
|
|
10398
10398
|
if (getValueByPath(fromObject, ['addWatermark']) !== undefined) {
|
|
10399
|
-
throw new Error('addWatermark parameter is
|
|
10399
|
+
throw new Error('addWatermark parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10400
10400
|
}
|
|
10401
10401
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
10402
|
-
throw new Error('labels parameter is
|
|
10402
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10403
10403
|
}
|
|
10404
10404
|
const fromImageSize = getValueByPath(fromObject, ['imageSize']);
|
|
10405
10405
|
if (parentObject !== undefined && fromImageSize != null) {
|
|
10406
10406
|
setValueByPath(parentObject, ['parameters', 'sampleImageSize'], fromImageSize);
|
|
10407
10407
|
}
|
|
10408
10408
|
if (getValueByPath(fromObject, ['enhancePrompt']) !== undefined) {
|
|
10409
|
-
throw new Error('enhancePrompt parameter is
|
|
10409
|
+
throw new Error('enhancePrompt parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10410
10410
|
}
|
|
10411
10411
|
return toObject;
|
|
10412
10412
|
}
|
|
@@ -10599,10 +10599,10 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10599
10599
|
setValueByPath(parentObject, ['parameters', 'sampleCount'], fromNumberOfVideos);
|
|
10600
10600
|
}
|
|
10601
10601
|
if (getValueByPath(fromObject, ['outputGcsUri']) !== undefined) {
|
|
10602
|
-
throw new Error('outputGcsUri parameter is
|
|
10602
|
+
throw new Error('outputGcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10603
10603
|
}
|
|
10604
10604
|
if (getValueByPath(fromObject, ['fps']) !== undefined) {
|
|
10605
|
-
throw new Error('fps parameter is
|
|
10605
|
+
throw new Error('fps parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10606
10606
|
}
|
|
10607
10607
|
const fromDurationSeconds = getValueByPath(fromObject, [
|
|
10608
10608
|
'durationSeconds',
|
|
@@ -10611,7 +10611,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10611
10611
|
setValueByPath(parentObject, ['parameters', 'durationSeconds'], fromDurationSeconds);
|
|
10612
10612
|
}
|
|
10613
10613
|
if (getValueByPath(fromObject, ['seed']) !== undefined) {
|
|
10614
|
-
throw new Error('seed parameter is
|
|
10614
|
+
throw new Error('seed parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10615
10615
|
}
|
|
10616
10616
|
const fromAspectRatio = getValueByPath(fromObject, ['aspectRatio']);
|
|
10617
10617
|
if (parentObject !== undefined && fromAspectRatio != null) {
|
|
@@ -10628,7 +10628,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10628
10628
|
setValueByPath(parentObject, ['parameters', 'personGeneration'], fromPersonGeneration);
|
|
10629
10629
|
}
|
|
10630
10630
|
if (getValueByPath(fromObject, ['pubsubTopic']) !== undefined) {
|
|
10631
|
-
throw new Error('pubsubTopic parameter is
|
|
10631
|
+
throw new Error('pubsubTopic parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10632
10632
|
}
|
|
10633
10633
|
const fromNegativePrompt = getValueByPath(fromObject, [
|
|
10634
10634
|
'negativePrompt',
|
|
@@ -10643,7 +10643,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10643
10643
|
setValueByPath(parentObject, ['parameters', 'enhancePrompt'], fromEnhancePrompt);
|
|
10644
10644
|
}
|
|
10645
10645
|
if (getValueByPath(fromObject, ['generateAudio']) !== undefined) {
|
|
10646
|
-
throw new Error('generateAudio parameter is
|
|
10646
|
+
throw new Error('generateAudio parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10647
10647
|
}
|
|
10648
10648
|
const fromLastFrame = getValueByPath(fromObject, ['lastFrame']);
|
|
10649
10649
|
if (parentObject !== undefined && fromLastFrame != null) {
|
|
@@ -10662,13 +10662,13 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10662
10662
|
setValueByPath(parentObject, ['instances[0]', 'referenceImages'], transformedList);
|
|
10663
10663
|
}
|
|
10664
10664
|
if (getValueByPath(fromObject, ['mask']) !== undefined) {
|
|
10665
|
-
throw new Error('mask parameter is
|
|
10665
|
+
throw new Error('mask parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10666
10666
|
}
|
|
10667
10667
|
if (getValueByPath(fromObject, ['compressionQuality']) !== undefined) {
|
|
10668
|
-
throw new Error('compressionQuality parameter is
|
|
10668
|
+
throw new Error('compressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10669
10669
|
}
|
|
10670
10670
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
10671
|
-
throw new Error('labels parameter is
|
|
10671
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10672
10672
|
}
|
|
10673
10673
|
const fromWebhookConfig = getValueByPath(fromObject, [
|
|
10674
10674
|
'webhookConfig',
|
|
@@ -10677,7 +10677,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10677
10677
|
setValueByPath(parentObject, ['webhookConfig'], fromWebhookConfig);
|
|
10678
10678
|
}
|
|
10679
10679
|
if (getValueByPath(fromObject, ['resizeMode']) !== undefined) {
|
|
10680
|
-
throw new Error('resizeMode parameter is
|
|
10680
|
+
throw new Error('resizeMode parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10681
10681
|
}
|
|
10682
10682
|
return toObject;
|
|
10683
10683
|
}
|
|
@@ -10774,7 +10774,7 @@ function generateVideosConfigToVertex(fromObject, parentObject, rootObject) {
|
|
|
10774
10774
|
setValueByPath(parentObject, ['labels'], fromLabels);
|
|
10775
10775
|
}
|
|
10776
10776
|
if (getValueByPath(fromObject, ['webhookConfig']) !== undefined) {
|
|
10777
|
-
throw new Error('webhookConfig parameter is
|
|
10777
|
+
throw new Error('webhookConfig parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
10778
10778
|
}
|
|
10779
10779
|
const fromResizeMode = getValueByPath(fromObject, ['resizeMode']);
|
|
10780
10780
|
if (parentObject !== undefined && fromResizeMode != null) {
|
|
@@ -11173,7 +11173,7 @@ function generationConfigToVertex(fromObject, _rootObject) {
|
|
|
11173
11173
|
}
|
|
11174
11174
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
11175
11175
|
undefined) {
|
|
11176
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
11176
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11177
11177
|
}
|
|
11178
11178
|
return toObject;
|
|
11179
11179
|
}
|
|
@@ -11212,10 +11212,10 @@ function googleSearchToMldev$1(fromObject, _rootObject) {
|
|
|
11212
11212
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
11213
11213
|
}
|
|
11214
11214
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
11215
|
-
throw new Error('blockingConfidence parameter is
|
|
11215
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11216
11216
|
}
|
|
11217
11217
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
11218
|
-
throw new Error('excludeDomains parameter is
|
|
11218
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11219
11219
|
}
|
|
11220
11220
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
11221
11221
|
'timeRangeFilter',
|
|
@@ -11236,20 +11236,20 @@ function imageConfigToMldev(fromObject, _rootObject) {
|
|
|
11236
11236
|
setValueByPath(toObject, ['imageSize'], fromImageSize);
|
|
11237
11237
|
}
|
|
11238
11238
|
if (getValueByPath(fromObject, ['personGeneration']) !== undefined) {
|
|
11239
|
-
throw new Error('personGeneration parameter is
|
|
11239
|
+
throw new Error('personGeneration parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11240
11240
|
}
|
|
11241
11241
|
if (getValueByPath(fromObject, ['prominentPeople']) !== undefined) {
|
|
11242
|
-
throw new Error('prominentPeople parameter is
|
|
11242
|
+
throw new Error('prominentPeople parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11243
11243
|
}
|
|
11244
11244
|
if (getValueByPath(fromObject, ['outputMimeType']) !== undefined) {
|
|
11245
|
-
throw new Error('outputMimeType parameter is
|
|
11245
|
+
throw new Error('outputMimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11246
11246
|
}
|
|
11247
11247
|
if (getValueByPath(fromObject, ['outputCompressionQuality']) !==
|
|
11248
11248
|
undefined) {
|
|
11249
|
-
throw new Error('outputCompressionQuality parameter is
|
|
11249
|
+
throw new Error('outputCompressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11250
11250
|
}
|
|
11251
11251
|
if (getValueByPath(fromObject, ['imageOutputOptions']) !== undefined) {
|
|
11252
|
-
throw new Error('imageOutputOptions parameter is
|
|
11252
|
+
throw new Error('imageOutputOptions parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11253
11253
|
}
|
|
11254
11254
|
return toObject;
|
|
11255
11255
|
}
|
|
@@ -11330,7 +11330,7 @@ function imageFromVertex(fromObject, _rootObject) {
|
|
|
11330
11330
|
function imageToMldev(fromObject, _rootObject) {
|
|
11331
11331
|
const toObject = {};
|
|
11332
11332
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
11333
|
-
throw new Error('gcsUri parameter is
|
|
11333
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11334
11334
|
}
|
|
11335
11335
|
const fromImageBytes = getValueByPath(fromObject, ['imageBytes']);
|
|
11336
11336
|
if (fromImageBytes != null) {
|
|
@@ -11733,13 +11733,13 @@ function partToVertex(fromObject, _rootObject) {
|
|
|
11733
11733
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
11734
11734
|
}
|
|
11735
11735
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
11736
|
-
throw new Error('toolCall parameter is
|
|
11736
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11737
11737
|
}
|
|
11738
11738
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
11739
|
-
throw new Error('toolResponse parameter is
|
|
11739
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11740
11740
|
}
|
|
11741
11741
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
11742
|
-
throw new Error('partMetadata parameter is
|
|
11742
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11743
11743
|
}
|
|
11744
11744
|
return toObject;
|
|
11745
11745
|
}
|
|
@@ -11962,7 +11962,7 @@ function safetySettingToMldev$1(fromObject, _rootObject) {
|
|
|
11962
11962
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
11963
11963
|
}
|
|
11964
11964
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
11965
|
-
throw new Error('method parameter is
|
|
11965
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11966
11966
|
}
|
|
11967
11967
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
11968
11968
|
if (fromThreshold != null) {
|
|
@@ -12096,14 +12096,14 @@ function toolConfigToVertex(fromObject, _rootObject) {
|
|
|
12096
12096
|
}
|
|
12097
12097
|
if (getValueByPath(fromObject, ['includeServerSideToolInvocations']) !==
|
|
12098
12098
|
undefined) {
|
|
12099
|
-
throw new Error('includeServerSideToolInvocations parameter is
|
|
12099
|
+
throw new Error('includeServerSideToolInvocations parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12100
12100
|
}
|
|
12101
12101
|
return toObject;
|
|
12102
12102
|
}
|
|
12103
12103
|
function toolToMldev$1(fromObject, rootObject) {
|
|
12104
12104
|
const toObject = {};
|
|
12105
12105
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
12106
|
-
throw new Error('retrieval parameter is
|
|
12106
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12107
12107
|
}
|
|
12108
12108
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
12109
12109
|
if (fromComputerUse != null) {
|
|
@@ -12128,7 +12128,7 @@ function toolToMldev$1(fromObject, rootObject) {
|
|
|
12128
12128
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
12129
12129
|
}
|
|
12130
12130
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
12131
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
12131
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12132
12132
|
}
|
|
12133
12133
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
12134
12134
|
'functionDeclarations',
|
|
@@ -12149,7 +12149,7 @@ function toolToMldev$1(fromObject, rootObject) {
|
|
|
12149
12149
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
12150
12150
|
}
|
|
12151
12151
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
12152
|
-
throw new Error('parallelAiSearch parameter is
|
|
12152
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12153
12153
|
}
|
|
12154
12154
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
12155
12155
|
if (fromUrlContext != null) {
|
|
@@ -12178,7 +12178,7 @@ function toolToVertex(fromObject, _rootObject) {
|
|
|
12178
12178
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
12179
12179
|
}
|
|
12180
12180
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
12181
|
-
throw new Error('fileSearch parameter is
|
|
12181
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12182
12182
|
}
|
|
12183
12183
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
12184
12184
|
if (fromGoogleSearch != null) {
|
|
@@ -12229,7 +12229,7 @@ function toolToVertex(fromObject, _rootObject) {
|
|
|
12229
12229
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
12230
12230
|
}
|
|
12231
12231
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
12232
|
-
throw new Error('mcpServers parameter is
|
|
12232
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12233
12233
|
}
|
|
12234
12234
|
return toObject;
|
|
12235
12235
|
}
|
|
@@ -12792,7 +12792,7 @@ const CONTENT_TYPE_HEADER = 'Content-Type';
|
|
|
12792
12792
|
const SERVER_TIMEOUT_HEADER = 'X-Server-Timeout';
|
|
12793
12793
|
const USER_AGENT_HEADER = 'User-Agent';
|
|
12794
12794
|
const GOOGLE_API_CLIENT_HEADER = 'x-goog-api-client';
|
|
12795
|
-
const SDK_VERSION = '2.
|
|
12795
|
+
const SDK_VERSION = '2.2.0'; // x-release-please-version
|
|
12796
12796
|
const LIBRARY_LABEL = `google-genai-sdk/${SDK_VERSION}`;
|
|
12797
12797
|
const VERTEX_AI_API_DEFAULT_VERSION = 'v1beta1';
|
|
12798
12798
|
const GOOGLE_AI_API_DEFAULT_VERSION = 'v1beta';
|
|
@@ -14688,7 +14688,7 @@ class Models extends BaseModule {
|
|
|
14688
14688
|
if (this.apiClient.isVertexAI()) {
|
|
14689
14689
|
if (!actualParams.config.queryBase) {
|
|
14690
14690
|
if ((_a = actualParams.config) === null || _a === void 0 ? void 0 : _a.filter) {
|
|
14691
|
-
throw new Error('Filtering tuned models list
|
|
14691
|
+
throw new Error('Filtering tuned models list is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
14692
14692
|
}
|
|
14693
14693
|
else {
|
|
14694
14694
|
actualParams.config.filter = 'labels.tune-type:*';
|
|
@@ -16144,7 +16144,7 @@ class Operations extends BaseModule {
|
|
|
16144
16144
|
function audioTranscriptionConfigToMldev(fromObject) {
|
|
16145
16145
|
const toObject = {};
|
|
16146
16146
|
if (getValueByPath(fromObject, ['languageCodes']) !== undefined) {
|
|
16147
|
-
throw new Error('languageCodes parameter is
|
|
16147
|
+
throw new Error('languageCodes parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16148
16148
|
}
|
|
16149
16149
|
return toObject;
|
|
16150
16150
|
}
|
|
@@ -16155,23 +16155,23 @@ function authConfigToMldev(fromObject) {
|
|
|
16155
16155
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
16156
16156
|
}
|
|
16157
16157
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
16158
|
-
throw new Error('apiKeyConfig parameter is
|
|
16158
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16159
16159
|
}
|
|
16160
16160
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
16161
|
-
throw new Error('authType parameter is
|
|
16161
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16162
16162
|
}
|
|
16163
16163
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
16164
16164
|
undefined) {
|
|
16165
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
16165
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16166
16166
|
}
|
|
16167
16167
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
16168
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
16168
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16169
16169
|
}
|
|
16170
16170
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
16171
|
-
throw new Error('oauthConfig parameter is
|
|
16171
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16172
16172
|
}
|
|
16173
16173
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
16174
|
-
throw new Error('oidcConfig parameter is
|
|
16174
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16175
16175
|
}
|
|
16176
16176
|
return toObject;
|
|
16177
16177
|
}
|
|
@@ -16182,7 +16182,7 @@ function blobToMldev(fromObject) {
|
|
|
16182
16182
|
setValueByPath(toObject, ['data'], fromData);
|
|
16183
16183
|
}
|
|
16184
16184
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
16185
|
-
throw new Error('displayName parameter is
|
|
16185
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16186
16186
|
}
|
|
16187
16187
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
16188
16188
|
if (fromMimeType != null) {
|
|
@@ -16249,7 +16249,7 @@ function createAuthTokenParametersToMldev(apiClient, fromObject) {
|
|
|
16249
16249
|
function fileDataToMldev(fromObject) {
|
|
16250
16250
|
const toObject = {};
|
|
16251
16251
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
16252
|
-
throw new Error('displayName parameter is
|
|
16252
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16253
16253
|
}
|
|
16254
16254
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
16255
16255
|
if (fromFileUri != null) {
|
|
@@ -16276,10 +16276,10 @@ function functionCallToMldev(fromObject) {
|
|
|
16276
16276
|
setValueByPath(toObject, ['name'], fromName);
|
|
16277
16277
|
}
|
|
16278
16278
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
16279
|
-
throw new Error('partialArgs parameter is
|
|
16279
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16280
16280
|
}
|
|
16281
16281
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
16282
|
-
throw new Error('willContinue parameter is
|
|
16282
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16283
16283
|
}
|
|
16284
16284
|
return toObject;
|
|
16285
16285
|
}
|
|
@@ -16302,10 +16302,10 @@ function googleSearchToMldev(fromObject) {
|
|
|
16302
16302
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
16303
16303
|
}
|
|
16304
16304
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
16305
|
-
throw new Error('blockingConfidence parameter is
|
|
16305
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16306
16306
|
}
|
|
16307
16307
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
16308
|
-
throw new Error('excludeDomains parameter is
|
|
16308
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16309
16309
|
}
|
|
16310
16310
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
16311
16311
|
'timeRangeFilter',
|
|
@@ -16424,7 +16424,7 @@ function liveConnectConfigToMldev(fromObject, parentObject) {
|
|
|
16424
16424
|
setValueByPath(parentObject, ['setup', 'proactivity'], fromProactivity);
|
|
16425
16425
|
}
|
|
16426
16426
|
if (getValueByPath(fromObject, ['explicitVadSignal']) !== undefined) {
|
|
16427
|
-
throw new Error('explicitVadSignal parameter is
|
|
16427
|
+
throw new Error('explicitVadSignal parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16428
16428
|
}
|
|
16429
16429
|
const fromAvatarConfig = getValueByPath(fromObject, ['avatarConfig']);
|
|
16430
16430
|
if (parentObject !== undefined && fromAvatarConfig != null) {
|
|
@@ -16535,7 +16535,7 @@ function safetySettingToMldev(fromObject) {
|
|
|
16535
16535
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
16536
16536
|
}
|
|
16537
16537
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
16538
|
-
throw new Error('method parameter is
|
|
16538
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16539
16539
|
}
|
|
16540
16540
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
16541
16541
|
if (fromThreshold != null) {
|
|
@@ -16550,14 +16550,14 @@ function sessionResumptionConfigToMldev(fromObject) {
|
|
|
16550
16550
|
setValueByPath(toObject, ['handle'], fromHandle);
|
|
16551
16551
|
}
|
|
16552
16552
|
if (getValueByPath(fromObject, ['transparent']) !== undefined) {
|
|
16553
|
-
throw new Error('transparent parameter is
|
|
16553
|
+
throw new Error('transparent parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16554
16554
|
}
|
|
16555
16555
|
return toObject;
|
|
16556
16556
|
}
|
|
16557
16557
|
function toolToMldev(fromObject) {
|
|
16558
16558
|
const toObject = {};
|
|
16559
16559
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
16560
|
-
throw new Error('retrieval parameter is
|
|
16560
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16561
16561
|
}
|
|
16562
16562
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
16563
16563
|
if (fromComputerUse != null) {
|
|
@@ -16582,7 +16582,7 @@ function toolToMldev(fromObject) {
|
|
|
16582
16582
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
16583
16583
|
}
|
|
16584
16584
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
16585
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
16585
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16586
16586
|
}
|
|
16587
16587
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
16588
16588
|
'functionDeclarations',
|
|
@@ -16603,7 +16603,7 @@ function toolToMldev(fromObject) {
|
|
|
16603
16603
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
16604
16604
|
}
|
|
16605
16605
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
16606
|
-
throw new Error('parallelAiSearch parameter is
|
|
16606
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16607
16607
|
}
|
|
16608
16608
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
16609
16609
|
if (fromUrlContext != null) {
|
|
@@ -19704,7 +19704,7 @@ function cancelTuningJobResponseFromVertex(fromObject, _rootObject) {
|
|
|
19704
19704
|
function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
19705
19705
|
const toObject = {};
|
|
19706
19706
|
if (getValueByPath(fromObject, ['validationDataset']) !== undefined) {
|
|
19707
|
-
throw new Error('validationDataset parameter is
|
|
19707
|
+
throw new Error('validationDataset parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19708
19708
|
}
|
|
19709
19709
|
const fromTunedModelDisplayName = getValueByPath(fromObject, [
|
|
19710
19710
|
'tunedModelDisplayName',
|
|
@@ -19713,7 +19713,7 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19713
19713
|
setValueByPath(parentObject, ['displayName'], fromTunedModelDisplayName);
|
|
19714
19714
|
}
|
|
19715
19715
|
if (getValueByPath(fromObject, ['description']) !== undefined) {
|
|
19716
|
-
throw new Error('description parameter is
|
|
19716
|
+
throw new Error('description parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19717
19717
|
}
|
|
19718
19718
|
const fromEpochCount = getValueByPath(fromObject, ['epochCount']);
|
|
19719
19719
|
if (parentObject !== undefined && fromEpochCount != null) {
|
|
@@ -19727,20 +19727,20 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19727
19727
|
}
|
|
19728
19728
|
if (getValueByPath(fromObject, ['exportLastCheckpointOnly']) !==
|
|
19729
19729
|
undefined) {
|
|
19730
|
-
throw new Error('exportLastCheckpointOnly parameter is
|
|
19730
|
+
throw new Error('exportLastCheckpointOnly parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19731
19731
|
}
|
|
19732
19732
|
if (getValueByPath(fromObject, ['preTunedModelCheckpointId']) !==
|
|
19733
19733
|
undefined) {
|
|
19734
|
-
throw new Error('preTunedModelCheckpointId parameter is
|
|
19734
|
+
throw new Error('preTunedModelCheckpointId parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19735
19735
|
}
|
|
19736
19736
|
if (getValueByPath(fromObject, ['adapterSize']) !== undefined) {
|
|
19737
|
-
throw new Error('adapterSize parameter is
|
|
19737
|
+
throw new Error('adapterSize parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19738
19738
|
}
|
|
19739
19739
|
if (getValueByPath(fromObject, ['tuningMode']) !== undefined) {
|
|
19740
|
-
throw new Error('tuningMode parameter is
|
|
19740
|
+
throw new Error('tuningMode parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19741
19741
|
}
|
|
19742
19742
|
if (getValueByPath(fromObject, ['customBaseModel']) !== undefined) {
|
|
19743
|
-
throw new Error('customBaseModel parameter is
|
|
19743
|
+
throw new Error('customBaseModel parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19744
19744
|
}
|
|
19745
19745
|
const fromBatchSize = getValueByPath(fromObject, ['batchSize']);
|
|
19746
19746
|
if (parentObject !== undefined && fromBatchSize != null) {
|
|
@@ -19751,25 +19751,25 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19751
19751
|
setValueByPath(parentObject, ['tuningTask', 'hyperparameters', 'learningRate'], fromLearningRate);
|
|
19752
19752
|
}
|
|
19753
19753
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
19754
|
-
throw new Error('labels parameter is
|
|
19754
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19755
19755
|
}
|
|
19756
19756
|
if (getValueByPath(fromObject, ['beta']) !== undefined) {
|
|
19757
|
-
throw new Error('beta parameter is
|
|
19757
|
+
throw new Error('beta parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19758
19758
|
}
|
|
19759
19759
|
if (getValueByPath(fromObject, ['baseTeacherModel']) !== undefined) {
|
|
19760
|
-
throw new Error('baseTeacherModel parameter is
|
|
19760
|
+
throw new Error('baseTeacherModel parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19761
19761
|
}
|
|
19762
19762
|
if (getValueByPath(fromObject, ['tunedTeacherModelSource']) !== undefined) {
|
|
19763
|
-
throw new Error('tunedTeacherModelSource parameter is
|
|
19763
|
+
throw new Error('tunedTeacherModelSource parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19764
19764
|
}
|
|
19765
19765
|
if (getValueByPath(fromObject, ['sftLossWeightMultiplier']) !== undefined) {
|
|
19766
|
-
throw new Error('sftLossWeightMultiplier parameter is
|
|
19766
|
+
throw new Error('sftLossWeightMultiplier parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19767
19767
|
}
|
|
19768
19768
|
if (getValueByPath(fromObject, ['outputUri']) !== undefined) {
|
|
19769
|
-
throw new Error('outputUri parameter is
|
|
19769
|
+
throw new Error('outputUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19770
19770
|
}
|
|
19771
19771
|
if (getValueByPath(fromObject, ['encryptionSpec']) !== undefined) {
|
|
19772
|
-
throw new Error('encryptionSpec parameter is
|
|
19772
|
+
throw new Error('encryptionSpec parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19773
19773
|
}
|
|
19774
19774
|
return toObject;
|
|
19775
19775
|
}
|
|
@@ -20163,10 +20163,10 @@ function tunedModelFromMldev(fromObject, _rootObject) {
|
|
|
20163
20163
|
function tuningDatasetToMldev(fromObject, _rootObject) {
|
|
20164
20164
|
const toObject = {};
|
|
20165
20165
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
20166
|
-
throw new Error('gcsUri parameter is
|
|
20166
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
20167
20167
|
}
|
|
20168
20168
|
if (getValueByPath(fromObject, ['vertexDatasetResource']) !== undefined) {
|
|
20169
|
-
throw new Error('vertexDatasetResource parameter is
|
|
20169
|
+
throw new Error('vertexDatasetResource parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
20170
20170
|
}
|
|
20171
20171
|
const fromExamples = getValueByPath(fromObject, ['examples']);
|
|
20172
20172
|
if (fromExamples != null) {
|
|
@@ -20239,7 +20239,7 @@ function tuningDatasetToVertex(fromObject, parentObject, rootObject) {
|
|
|
20239
20239
|
}
|
|
20240
20240
|
}
|
|
20241
20241
|
if (getValueByPath(fromObject, ['examples']) !== undefined) {
|
|
20242
|
-
throw new Error('examples parameter is
|
|
20242
|
+
throw new Error('examples parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
20243
20243
|
}
|
|
20244
20244
|
return toObject;
|
|
20245
20245
|
}
|