@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.cjs
CHANGED
|
@@ -3797,23 +3797,23 @@ function authConfigToMldev$4(fromObject) {
|
|
|
3797
3797
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
3798
3798
|
}
|
|
3799
3799
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
3800
|
-
throw new Error('apiKeyConfig parameter is
|
|
3800
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3801
3801
|
}
|
|
3802
3802
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
3803
|
-
throw new Error('authType parameter is
|
|
3803
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3804
3804
|
}
|
|
3805
3805
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
3806
3806
|
undefined) {
|
|
3807
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
3807
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3808
3808
|
}
|
|
3809
3809
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
3810
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
3810
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3811
3811
|
}
|
|
3812
3812
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
3813
|
-
throw new Error('oauthConfig parameter is
|
|
3813
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3814
3814
|
}
|
|
3815
3815
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
3816
|
-
throw new Error('oidcConfig parameter is
|
|
3816
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
3817
3817
|
}
|
|
3818
3818
|
return toObject;
|
|
3819
3819
|
}
|
|
@@ -3894,14 +3894,14 @@ function batchJobDestinationToVertex(fromObject) {
|
|
|
3894
3894
|
setValueByPath(toObject, ['bigqueryDestination', 'outputUri'], fromBigqueryUri);
|
|
3895
3895
|
}
|
|
3896
3896
|
if (getValueByPath(fromObject, ['fileName']) !== undefined) {
|
|
3897
|
-
throw new Error('fileName parameter is
|
|
3897
|
+
throw new Error('fileName parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3898
3898
|
}
|
|
3899
3899
|
if (getValueByPath(fromObject, ['inlinedResponses']) !== undefined) {
|
|
3900
|
-
throw new Error('inlinedResponses parameter is
|
|
3900
|
+
throw new Error('inlinedResponses parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3901
3901
|
}
|
|
3902
3902
|
if (getValueByPath(fromObject, ['inlinedEmbedContentResponses']) !==
|
|
3903
3903
|
undefined) {
|
|
3904
|
-
throw new Error('inlinedEmbedContentResponses parameter is
|
|
3904
|
+
throw new Error('inlinedEmbedContentResponses parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
3905
3905
|
}
|
|
3906
3906
|
const fromVertexDataset = getValueByPath(fromObject, [
|
|
3907
3907
|
'vertexDataset',
|
|
@@ -4046,13 +4046,13 @@ function batchJobSourceFromVertex(fromObject) {
|
|
|
4046
4046
|
function batchJobSourceToMldev(apiClient, fromObject) {
|
|
4047
4047
|
const toObject = {};
|
|
4048
4048
|
if (getValueByPath(fromObject, ['format']) !== undefined) {
|
|
4049
|
-
throw new Error('format parameter is
|
|
4049
|
+
throw new Error('format parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4050
4050
|
}
|
|
4051
4051
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
4052
|
-
throw new Error('gcsUri parameter is
|
|
4052
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4053
4053
|
}
|
|
4054
4054
|
if (getValueByPath(fromObject, ['bigqueryUri']) !== undefined) {
|
|
4055
|
-
throw new Error('bigqueryUri parameter is
|
|
4055
|
+
throw new Error('bigqueryUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4056
4056
|
}
|
|
4057
4057
|
const fromFileName = getValueByPath(fromObject, ['fileName']);
|
|
4058
4058
|
if (fromFileName != null) {
|
|
@@ -4071,7 +4071,7 @@ function batchJobSourceToMldev(apiClient, fromObject) {
|
|
|
4071
4071
|
setValueByPath(toObject, ['requests', 'requests'], transformedList);
|
|
4072
4072
|
}
|
|
4073
4073
|
if (getValueByPath(fromObject, ['vertexDatasetName']) !== undefined) {
|
|
4074
|
-
throw new Error('vertexDatasetName parameter is
|
|
4074
|
+
throw new Error('vertexDatasetName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4075
4075
|
}
|
|
4076
4076
|
return toObject;
|
|
4077
4077
|
}
|
|
@@ -4090,10 +4090,10 @@ function batchJobSourceToVertex(fromObject) {
|
|
|
4090
4090
|
setValueByPath(toObject, ['bigquerySource', 'inputUri'], fromBigqueryUri);
|
|
4091
4091
|
}
|
|
4092
4092
|
if (getValueByPath(fromObject, ['fileName']) !== undefined) {
|
|
4093
|
-
throw new Error('fileName parameter is
|
|
4093
|
+
throw new Error('fileName parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4094
4094
|
}
|
|
4095
4095
|
if (getValueByPath(fromObject, ['inlinedRequests']) !== undefined) {
|
|
4096
|
-
throw new Error('inlinedRequests parameter is
|
|
4096
|
+
throw new Error('inlinedRequests parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4097
4097
|
}
|
|
4098
4098
|
const fromVertexDatasetName = getValueByPath(fromObject, [
|
|
4099
4099
|
'vertexDatasetName',
|
|
@@ -4110,7 +4110,7 @@ function blobToMldev$4(fromObject) {
|
|
|
4110
4110
|
setValueByPath(toObject, ['data'], fromData);
|
|
4111
4111
|
}
|
|
4112
4112
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
4113
|
-
throw new Error('displayName parameter is
|
|
4113
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4114
4114
|
}
|
|
4115
4115
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
4116
4116
|
if (fromMimeType != null) {
|
|
@@ -4233,7 +4233,7 @@ function createBatchJobConfigToMldev(fromObject, parentObject) {
|
|
|
4233
4233
|
setValueByPath(parentObject, ['batch', 'displayName'], fromDisplayName);
|
|
4234
4234
|
}
|
|
4235
4235
|
if (getValueByPath(fromObject, ['dest']) !== undefined) {
|
|
4236
|
-
throw new Error('dest parameter is
|
|
4236
|
+
throw new Error('dest parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4237
4237
|
}
|
|
4238
4238
|
const fromWebhookConfig = getValueByPath(fromObject, [
|
|
4239
4239
|
'webhookConfig',
|
|
@@ -4254,7 +4254,7 @@ function createBatchJobConfigToVertex(fromObject, parentObject) {
|
|
|
4254
4254
|
setValueByPath(parentObject, ['outputConfig'], batchJobDestinationToVertex(tBatchJobDestination(fromDest)));
|
|
4255
4255
|
}
|
|
4256
4256
|
if (getValueByPath(fromObject, ['webhookConfig']) !== undefined) {
|
|
4257
|
-
throw new Error('webhookConfig parameter is
|
|
4257
|
+
throw new Error('webhookConfig parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
4258
4258
|
}
|
|
4259
4259
|
return toObject;
|
|
4260
4260
|
}
|
|
@@ -4410,16 +4410,16 @@ function embedContentConfigToMldev$1(fromObject, parentObject) {
|
|
|
4410
4410
|
setValueByPath(parentObject, ['requests[]', 'outputDimensionality'], fromOutputDimensionality);
|
|
4411
4411
|
}
|
|
4412
4412
|
if (getValueByPath(fromObject, ['mimeType']) !== undefined) {
|
|
4413
|
-
throw new Error('mimeType parameter is
|
|
4413
|
+
throw new Error('mimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4414
4414
|
}
|
|
4415
4415
|
if (getValueByPath(fromObject, ['autoTruncate']) !== undefined) {
|
|
4416
|
-
throw new Error('autoTruncate parameter is
|
|
4416
|
+
throw new Error('autoTruncate parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4417
4417
|
}
|
|
4418
4418
|
if (getValueByPath(fromObject, ['documentOcr']) !== undefined) {
|
|
4419
|
-
throw new Error('documentOcr parameter is
|
|
4419
|
+
throw new Error('documentOcr parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4420
4420
|
}
|
|
4421
4421
|
if (getValueByPath(fromObject, ['audioTrackExtraction']) !== undefined) {
|
|
4422
|
-
throw new Error('audioTrackExtraction parameter is
|
|
4422
|
+
throw new Error('audioTrackExtraction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4423
4423
|
}
|
|
4424
4424
|
return toObject;
|
|
4425
4425
|
}
|
|
@@ -4440,7 +4440,7 @@ function embeddingsBatchJobSourceToMldev(apiClient, fromObject) {
|
|
|
4440
4440
|
function fileDataToMldev$4(fromObject) {
|
|
4441
4441
|
const toObject = {};
|
|
4442
4442
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
4443
|
-
throw new Error('displayName parameter is
|
|
4443
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4444
4444
|
}
|
|
4445
4445
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
4446
4446
|
if (fromFileUri != null) {
|
|
@@ -4467,10 +4467,10 @@ function functionCallToMldev$4(fromObject) {
|
|
|
4467
4467
|
setValueByPath(toObject, ['name'], fromName);
|
|
4468
4468
|
}
|
|
4469
4469
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
4470
|
-
throw new Error('partialArgs parameter is
|
|
4470
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4471
4471
|
}
|
|
4472
4472
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
4473
|
-
throw new Error('willContinue parameter is
|
|
4473
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4474
4474
|
}
|
|
4475
4475
|
return toObject;
|
|
4476
4476
|
}
|
|
@@ -4488,7 +4488,7 @@ function functionCallingConfigToMldev$2(fromObject) {
|
|
|
4488
4488
|
}
|
|
4489
4489
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
4490
4490
|
undefined) {
|
|
4491
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
4491
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4492
4492
|
}
|
|
4493
4493
|
return toObject;
|
|
4494
4494
|
}
|
|
@@ -4575,10 +4575,10 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4575
4575
|
setValueByPath(toObject, ['responseJsonSchema'], fromResponseJsonSchema);
|
|
4576
4576
|
}
|
|
4577
4577
|
if (getValueByPath(fromObject, ['routingConfig']) !== undefined) {
|
|
4578
|
-
throw new Error('routingConfig parameter is
|
|
4578
|
+
throw new Error('routingConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4579
4579
|
}
|
|
4580
4580
|
if (getValueByPath(fromObject, ['modelSelectionConfig']) !== undefined) {
|
|
4581
|
-
throw new Error('modelSelectionConfig parameter is
|
|
4581
|
+
throw new Error('modelSelectionConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4582
4582
|
}
|
|
4583
4583
|
const fromSafetySettings = getValueByPath(fromObject, [
|
|
4584
4584
|
'safetySettings',
|
|
@@ -4607,7 +4607,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4607
4607
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev$2(fromToolConfig));
|
|
4608
4608
|
}
|
|
4609
4609
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
4610
|
-
throw new Error('labels parameter is
|
|
4610
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4611
4611
|
}
|
|
4612
4612
|
const fromCachedContent = getValueByPath(fromObject, [
|
|
4613
4613
|
'cachedContent',
|
|
@@ -4632,7 +4632,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4632
4632
|
setValueByPath(toObject, ['speechConfig'], tSpeechConfig(fromSpeechConfig));
|
|
4633
4633
|
}
|
|
4634
4634
|
if (getValueByPath(fromObject, ['audioTimestamp']) !== undefined) {
|
|
4635
|
-
throw new Error('audioTimestamp parameter is
|
|
4635
|
+
throw new Error('audioTimestamp parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4636
4636
|
}
|
|
4637
4637
|
const fromThinkingConfig = getValueByPath(fromObject, [
|
|
4638
4638
|
'thinkingConfig',
|
|
@@ -4651,7 +4651,7 @@ function generateContentConfigToMldev$1(apiClient, fromObject, parentObject) {
|
|
|
4651
4651
|
setValueByPath(toObject, ['enableEnhancedCivicAnswers'], fromEnableEnhancedCivicAnswers);
|
|
4652
4652
|
}
|
|
4653
4653
|
if (getValueByPath(fromObject, ['modelArmorConfig']) !== undefined) {
|
|
4654
|
-
throw new Error('modelArmorConfig parameter is
|
|
4654
|
+
throw new Error('modelArmorConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4655
4655
|
}
|
|
4656
4656
|
const fromServiceTier = getValueByPath(fromObject, ['serviceTier']);
|
|
4657
4657
|
if (parentObject !== undefined && fromServiceTier != null) {
|
|
@@ -4738,10 +4738,10 @@ function googleSearchToMldev$4(fromObject) {
|
|
|
4738
4738
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
4739
4739
|
}
|
|
4740
4740
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
4741
|
-
throw new Error('blockingConfidence parameter is
|
|
4741
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4742
4742
|
}
|
|
4743
4743
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
4744
|
-
throw new Error('excludeDomains parameter is
|
|
4744
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4745
4745
|
}
|
|
4746
4746
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
4747
4747
|
'timeRangeFilter',
|
|
@@ -4762,20 +4762,20 @@ function imageConfigToMldev$1(fromObject) {
|
|
|
4762
4762
|
setValueByPath(toObject, ['imageSize'], fromImageSize);
|
|
4763
4763
|
}
|
|
4764
4764
|
if (getValueByPath(fromObject, ['personGeneration']) !== undefined) {
|
|
4765
|
-
throw new Error('personGeneration parameter is
|
|
4765
|
+
throw new Error('personGeneration parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4766
4766
|
}
|
|
4767
4767
|
if (getValueByPath(fromObject, ['prominentPeople']) !== undefined) {
|
|
4768
|
-
throw new Error('prominentPeople parameter is
|
|
4768
|
+
throw new Error('prominentPeople parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4769
4769
|
}
|
|
4770
4770
|
if (getValueByPath(fromObject, ['outputMimeType']) !== undefined) {
|
|
4771
|
-
throw new Error('outputMimeType parameter is
|
|
4771
|
+
throw new Error('outputMimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4772
4772
|
}
|
|
4773
4773
|
if (getValueByPath(fromObject, ['outputCompressionQuality']) !==
|
|
4774
4774
|
undefined) {
|
|
4775
|
-
throw new Error('outputCompressionQuality parameter is
|
|
4775
|
+
throw new Error('outputCompressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4776
4776
|
}
|
|
4777
4777
|
if (getValueByPath(fromObject, ['imageOutputOptions']) !== undefined) {
|
|
4778
|
-
throw new Error('imageOutputOptions parameter is
|
|
4778
|
+
throw new Error('imageOutputOptions parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4779
4779
|
}
|
|
4780
4780
|
return toObject;
|
|
4781
4781
|
}
|
|
@@ -4832,7 +4832,7 @@ function listBatchJobsConfigToMldev(fromObject, parentObject) {
|
|
|
4832
4832
|
setValueByPath(parentObject, ['_query', 'pageToken'], fromPageToken);
|
|
4833
4833
|
}
|
|
4834
4834
|
if (getValueByPath(fromObject, ['filter']) !== undefined) {
|
|
4835
|
-
throw new Error('filter parameter is
|
|
4835
|
+
throw new Error('filter parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
4836
4836
|
}
|
|
4837
4837
|
return toObject;
|
|
4838
4838
|
}
|
|
@@ -5001,7 +5001,7 @@ function safetySettingToMldev$3(fromObject) {
|
|
|
5001
5001
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
5002
5002
|
}
|
|
5003
5003
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
5004
|
-
throw new Error('method parameter is
|
|
5004
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5005
5005
|
}
|
|
5006
5006
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
5007
5007
|
if (fromThreshold != null) {
|
|
@@ -5032,7 +5032,7 @@ function toolConfigToMldev$2(fromObject) {
|
|
|
5032
5032
|
function toolToMldev$4(fromObject) {
|
|
5033
5033
|
const toObject = {};
|
|
5034
5034
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
5035
|
-
throw new Error('retrieval parameter is
|
|
5035
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5036
5036
|
}
|
|
5037
5037
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
5038
5038
|
if (fromComputerUse != null) {
|
|
@@ -5057,7 +5057,7 @@ function toolToMldev$4(fromObject) {
|
|
|
5057
5057
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
5058
5058
|
}
|
|
5059
5059
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
5060
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
5060
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5061
5061
|
}
|
|
5062
5062
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
5063
5063
|
'functionDeclarations',
|
|
@@ -5078,7 +5078,7 @@ function toolToMldev$4(fromObject) {
|
|
|
5078
5078
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
5079
5079
|
}
|
|
5080
5080
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
5081
|
-
throw new Error('parallelAiSearch parameter is
|
|
5081
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5082
5082
|
}
|
|
5083
5083
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
5084
5084
|
if (fromUrlContext != null) {
|
|
@@ -5825,23 +5825,23 @@ function authConfigToMldev$3(fromObject) {
|
|
|
5825
5825
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
5826
5826
|
}
|
|
5827
5827
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
5828
|
-
throw new Error('apiKeyConfig parameter is
|
|
5828
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5829
5829
|
}
|
|
5830
5830
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
5831
|
-
throw new Error('authType parameter is
|
|
5831
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5832
5832
|
}
|
|
5833
5833
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
5834
5834
|
undefined) {
|
|
5835
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
5835
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5836
5836
|
}
|
|
5837
5837
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
5838
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
5838
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5839
5839
|
}
|
|
5840
5840
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
5841
|
-
throw new Error('oauthConfig parameter is
|
|
5841
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5842
5842
|
}
|
|
5843
5843
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
5844
|
-
throw new Error('oidcConfig parameter is
|
|
5844
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5845
5845
|
}
|
|
5846
5846
|
return toObject;
|
|
5847
5847
|
}
|
|
@@ -5852,7 +5852,7 @@ function blobToMldev$3(fromObject) {
|
|
|
5852
5852
|
setValueByPath(toObject, ['data'], fromData);
|
|
5853
5853
|
}
|
|
5854
5854
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
5855
|
-
throw new Error('displayName parameter is
|
|
5855
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5856
5856
|
}
|
|
5857
5857
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
5858
5858
|
if (fromMimeType != null) {
|
|
@@ -5941,7 +5941,7 @@ function createCachedContentConfigToMldev(fromObject, parentObject) {
|
|
|
5941
5941
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev$1(fromToolConfig));
|
|
5942
5942
|
}
|
|
5943
5943
|
if (getValueByPath(fromObject, ['kmsKeyName']) !== undefined) {
|
|
5944
|
-
throw new Error('kmsKeyName parameter is
|
|
5944
|
+
throw new Error('kmsKeyName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
5945
5945
|
}
|
|
5946
5946
|
return toObject;
|
|
5947
5947
|
}
|
|
@@ -6058,7 +6058,7 @@ function deleteCachedContentResponseFromVertex(fromObject) {
|
|
|
6058
6058
|
function fileDataToMldev$3(fromObject) {
|
|
6059
6059
|
const toObject = {};
|
|
6060
6060
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
6061
|
-
throw new Error('displayName parameter is
|
|
6061
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6062
6062
|
}
|
|
6063
6063
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
6064
6064
|
if (fromFileUri != null) {
|
|
@@ -6085,10 +6085,10 @@ function functionCallToMldev$3(fromObject) {
|
|
|
6085
6085
|
setValueByPath(toObject, ['name'], fromName);
|
|
6086
6086
|
}
|
|
6087
6087
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
6088
|
-
throw new Error('partialArgs parameter is
|
|
6088
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6089
6089
|
}
|
|
6090
6090
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
6091
|
-
throw new Error('willContinue parameter is
|
|
6091
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6092
6092
|
}
|
|
6093
6093
|
return toObject;
|
|
6094
6094
|
}
|
|
@@ -6106,7 +6106,7 @@ function functionCallingConfigToMldev$1(fromObject) {
|
|
|
6106
6106
|
}
|
|
6107
6107
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
6108
6108
|
undefined) {
|
|
6109
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
6109
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6110
6110
|
}
|
|
6111
6111
|
return toObject;
|
|
6112
6112
|
}
|
|
@@ -6145,10 +6145,10 @@ function googleSearchToMldev$3(fromObject) {
|
|
|
6145
6145
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
6146
6146
|
}
|
|
6147
6147
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
6148
|
-
throw new Error('blockingConfidence parameter is
|
|
6148
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6149
6149
|
}
|
|
6150
6150
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
6151
|
-
throw new Error('excludeDomains parameter is
|
|
6151
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6152
6152
|
}
|
|
6153
6153
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
6154
6154
|
'timeRangeFilter',
|
|
@@ -6385,13 +6385,13 @@ function partToVertex$2(fromObject) {
|
|
|
6385
6385
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
6386
6386
|
}
|
|
6387
6387
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
6388
|
-
throw new Error('toolCall parameter is
|
|
6388
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6389
6389
|
}
|
|
6390
6390
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
6391
|
-
throw new Error('toolResponse parameter is
|
|
6391
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6392
6392
|
}
|
|
6393
6393
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
6394
|
-
throw new Error('partMetadata parameter is
|
|
6394
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6395
6395
|
}
|
|
6396
6396
|
return toObject;
|
|
6397
6397
|
}
|
|
@@ -6431,14 +6431,14 @@ function toolConfigToVertex$1(fromObject) {
|
|
|
6431
6431
|
}
|
|
6432
6432
|
if (getValueByPath(fromObject, ['includeServerSideToolInvocations']) !==
|
|
6433
6433
|
undefined) {
|
|
6434
|
-
throw new Error('includeServerSideToolInvocations parameter is
|
|
6434
|
+
throw new Error('includeServerSideToolInvocations parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6435
6435
|
}
|
|
6436
6436
|
return toObject;
|
|
6437
6437
|
}
|
|
6438
6438
|
function toolToMldev$3(fromObject) {
|
|
6439
6439
|
const toObject = {};
|
|
6440
6440
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
6441
|
-
throw new Error('retrieval parameter is
|
|
6441
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6442
6442
|
}
|
|
6443
6443
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
6444
6444
|
if (fromComputerUse != null) {
|
|
@@ -6463,7 +6463,7 @@ function toolToMldev$3(fromObject) {
|
|
|
6463
6463
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
6464
6464
|
}
|
|
6465
6465
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
6466
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
6466
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6467
6467
|
}
|
|
6468
6468
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
6469
6469
|
'functionDeclarations',
|
|
@@ -6484,7 +6484,7 @@ function toolToMldev$3(fromObject) {
|
|
|
6484
6484
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
6485
6485
|
}
|
|
6486
6486
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
6487
|
-
throw new Error('parallelAiSearch parameter is
|
|
6487
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
6488
6488
|
}
|
|
6489
6489
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
6490
6490
|
if (fromUrlContext != null) {
|
|
@@ -6513,7 +6513,7 @@ function toolToVertex$2(fromObject) {
|
|
|
6513
6513
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
6514
6514
|
}
|
|
6515
6515
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
6516
|
-
throw new Error('fileSearch parameter is
|
|
6516
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6517
6517
|
}
|
|
6518
6518
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
6519
6519
|
if (fromGoogleSearch != null) {
|
|
@@ -6564,7 +6564,7 @@ function toolToVertex$2(fromObject) {
|
|
|
6564
6564
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
6565
6565
|
}
|
|
6566
6566
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
6567
|
-
throw new Error('mcpServers parameter is
|
|
6567
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
6568
6568
|
}
|
|
6569
6569
|
return toObject;
|
|
6570
6570
|
}
|
|
@@ -7856,7 +7856,7 @@ class Files extends BaseModule {
|
|
|
7856
7856
|
function audioTranscriptionConfigToMldev$1(fromObject) {
|
|
7857
7857
|
const toObject = {};
|
|
7858
7858
|
if (getValueByPath(fromObject, ['languageCodes']) !== undefined) {
|
|
7859
|
-
throw new Error('languageCodes parameter is
|
|
7859
|
+
throw new Error('languageCodes parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7860
7860
|
}
|
|
7861
7861
|
return toObject;
|
|
7862
7862
|
}
|
|
@@ -7867,23 +7867,23 @@ function authConfigToMldev$2(fromObject) {
|
|
|
7867
7867
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
7868
7868
|
}
|
|
7869
7869
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
7870
|
-
throw new Error('apiKeyConfig parameter is
|
|
7870
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7871
7871
|
}
|
|
7872
7872
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
7873
|
-
throw new Error('authType parameter is
|
|
7873
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7874
7874
|
}
|
|
7875
7875
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
7876
7876
|
undefined) {
|
|
7877
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
7877
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7878
7878
|
}
|
|
7879
7879
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
7880
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
7880
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7881
7881
|
}
|
|
7882
7882
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
7883
|
-
throw new Error('oauthConfig parameter is
|
|
7883
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7884
7884
|
}
|
|
7885
7885
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
7886
|
-
throw new Error('oidcConfig parameter is
|
|
7886
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7887
7887
|
}
|
|
7888
7888
|
return toObject;
|
|
7889
7889
|
}
|
|
@@ -7894,7 +7894,7 @@ function blobToMldev$2(fromObject) {
|
|
|
7894
7894
|
setValueByPath(toObject, ['data'], fromData);
|
|
7895
7895
|
}
|
|
7896
7896
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
7897
|
-
throw new Error('displayName parameter is
|
|
7897
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7898
7898
|
}
|
|
7899
7899
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
7900
7900
|
if (fromMimeType != null) {
|
|
@@ -7941,7 +7941,7 @@ function contentToVertex$1(fromObject) {
|
|
|
7941
7941
|
function fileDataToMldev$2(fromObject) {
|
|
7942
7942
|
const toObject = {};
|
|
7943
7943
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
7944
|
-
throw new Error('displayName parameter is
|
|
7944
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7945
7945
|
}
|
|
7946
7946
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
7947
7947
|
if (fromFileUri != null) {
|
|
@@ -7968,10 +7968,10 @@ function functionCallToMldev$2(fromObject) {
|
|
|
7968
7968
|
setValueByPath(toObject, ['name'], fromName);
|
|
7969
7969
|
}
|
|
7970
7970
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
7971
|
-
throw new Error('partialArgs parameter is
|
|
7971
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7972
7972
|
}
|
|
7973
7973
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
7974
|
-
throw new Error('willContinue parameter is
|
|
7974
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
7975
7975
|
}
|
|
7976
7976
|
return toObject;
|
|
7977
7977
|
}
|
|
@@ -8099,7 +8099,7 @@ function generationConfigToVertex$1(fromObject) {
|
|
|
8099
8099
|
}
|
|
8100
8100
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
8101
8101
|
undefined) {
|
|
8102
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
8102
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8103
8103
|
}
|
|
8104
8104
|
return toObject;
|
|
8105
8105
|
}
|
|
@@ -8122,10 +8122,10 @@ function googleSearchToMldev$2(fromObject) {
|
|
|
8122
8122
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
8123
8123
|
}
|
|
8124
8124
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
8125
|
-
throw new Error('blockingConfidence parameter is
|
|
8125
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8126
8126
|
}
|
|
8127
8127
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
8128
|
-
throw new Error('excludeDomains parameter is
|
|
8128
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8129
8129
|
}
|
|
8130
8130
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
8131
8131
|
'timeRangeFilter',
|
|
@@ -8244,7 +8244,7 @@ function liveConnectConfigToMldev$1(fromObject, parentObject) {
|
|
|
8244
8244
|
setValueByPath(parentObject, ['setup', 'proactivity'], fromProactivity);
|
|
8245
8245
|
}
|
|
8246
8246
|
if (getValueByPath(fromObject, ['explicitVadSignal']) !== undefined) {
|
|
8247
|
-
throw new Error('explicitVadSignal parameter is
|
|
8247
|
+
throw new Error('explicitVadSignal parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8248
8248
|
}
|
|
8249
8249
|
const fromAvatarConfig = getValueByPath(fromObject, ['avatarConfig']);
|
|
8250
8250
|
if (parentObject !== undefined && fromAvatarConfig != null) {
|
|
@@ -8715,13 +8715,13 @@ function partToVertex$1(fromObject) {
|
|
|
8715
8715
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
8716
8716
|
}
|
|
8717
8717
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
8718
|
-
throw new Error('toolCall parameter is
|
|
8718
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8719
8719
|
}
|
|
8720
8720
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
8721
|
-
throw new Error('toolResponse parameter is
|
|
8721
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8722
8722
|
}
|
|
8723
8723
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
8724
|
-
throw new Error('partMetadata parameter is
|
|
8724
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8725
8725
|
}
|
|
8726
8726
|
return toObject;
|
|
8727
8727
|
}
|
|
@@ -8732,7 +8732,7 @@ function safetySettingToMldev$2(fromObject) {
|
|
|
8732
8732
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
8733
8733
|
}
|
|
8734
8734
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
8735
|
-
throw new Error('method parameter is
|
|
8735
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8736
8736
|
}
|
|
8737
8737
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
8738
8738
|
if (fromThreshold != null) {
|
|
@@ -8747,14 +8747,14 @@ function sessionResumptionConfigToMldev$1(fromObject) {
|
|
|
8747
8747
|
setValueByPath(toObject, ['handle'], fromHandle);
|
|
8748
8748
|
}
|
|
8749
8749
|
if (getValueByPath(fromObject, ['transparent']) !== undefined) {
|
|
8750
|
-
throw new Error('transparent parameter is
|
|
8750
|
+
throw new Error('transparent parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8751
8751
|
}
|
|
8752
8752
|
return toObject;
|
|
8753
8753
|
}
|
|
8754
8754
|
function toolToMldev$2(fromObject) {
|
|
8755
8755
|
const toObject = {};
|
|
8756
8756
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
8757
|
-
throw new Error('retrieval parameter is
|
|
8757
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8758
8758
|
}
|
|
8759
8759
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
8760
8760
|
if (fromComputerUse != null) {
|
|
@@ -8779,7 +8779,7 @@ function toolToMldev$2(fromObject) {
|
|
|
8779
8779
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
8780
8780
|
}
|
|
8781
8781
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
8782
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
8782
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8783
8783
|
}
|
|
8784
8784
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
8785
8785
|
'functionDeclarations',
|
|
@@ -8800,7 +8800,7 @@ function toolToMldev$2(fromObject) {
|
|
|
8800
8800
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
8801
8801
|
}
|
|
8802
8802
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
8803
|
-
throw new Error('parallelAiSearch parameter is
|
|
8803
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
8804
8804
|
}
|
|
8805
8805
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
8806
8806
|
if (fromUrlContext != null) {
|
|
@@ -8829,7 +8829,7 @@ function toolToVertex$1(fromObject) {
|
|
|
8829
8829
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
8830
8830
|
}
|
|
8831
8831
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
8832
|
-
throw new Error('fileSearch parameter is
|
|
8832
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8833
8833
|
}
|
|
8834
8834
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
8835
8835
|
if (fromGoogleSearch != null) {
|
|
@@ -8880,7 +8880,7 @@ function toolToVertex$1(fromObject) {
|
|
|
8880
8880
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
8881
8881
|
}
|
|
8882
8882
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
8883
|
-
throw new Error('mcpServers parameter is
|
|
8883
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
8884
8884
|
}
|
|
8885
8885
|
return toObject;
|
|
8886
8886
|
}
|
|
@@ -8997,23 +8997,23 @@ function authConfigToMldev$1(fromObject, _rootObject) {
|
|
|
8997
8997
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
8998
8998
|
}
|
|
8999
8999
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
9000
|
-
throw new Error('apiKeyConfig parameter is
|
|
9000
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9001
9001
|
}
|
|
9002
9002
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
9003
|
-
throw new Error('authType parameter is
|
|
9003
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9004
9004
|
}
|
|
9005
9005
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
9006
9006
|
undefined) {
|
|
9007
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
9007
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9008
9008
|
}
|
|
9009
9009
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
9010
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
9010
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9011
9011
|
}
|
|
9012
9012
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
9013
|
-
throw new Error('oauthConfig parameter is
|
|
9013
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9014
9014
|
}
|
|
9015
9015
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
9016
|
-
throw new Error('oidcConfig parameter is
|
|
9016
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9017
9017
|
}
|
|
9018
9018
|
return toObject;
|
|
9019
9019
|
}
|
|
@@ -9024,7 +9024,7 @@ function blobToMldev$1(fromObject, _rootObject) {
|
|
|
9024
9024
|
setValueByPath(toObject, ['data'], fromData);
|
|
9025
9025
|
}
|
|
9026
9026
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
9027
|
-
throw new Error('displayName parameter is
|
|
9027
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9028
9028
|
}
|
|
9029
9029
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
9030
9030
|
if (fromMimeType != null) {
|
|
@@ -9221,13 +9221,13 @@ function controlReferenceConfigToVertex(fromObject, _rootObject) {
|
|
|
9221
9221
|
function countTokensConfigToMldev(fromObject, _rootObject) {
|
|
9222
9222
|
const toObject = {};
|
|
9223
9223
|
if (getValueByPath(fromObject, ['systemInstruction']) !== undefined) {
|
|
9224
|
-
throw new Error('systemInstruction parameter is
|
|
9224
|
+
throw new Error('systemInstruction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9225
9225
|
}
|
|
9226
9226
|
if (getValueByPath(fromObject, ['tools']) !== undefined) {
|
|
9227
|
-
throw new Error('tools parameter is
|
|
9227
|
+
throw new Error('tools parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9228
9228
|
}
|
|
9229
9229
|
if (getValueByPath(fromObject, ['generationConfig']) !== undefined) {
|
|
9230
|
-
throw new Error('generationConfig parameter is
|
|
9230
|
+
throw new Error('generationConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9231
9231
|
}
|
|
9232
9232
|
return toObject;
|
|
9233
9233
|
}
|
|
@@ -9528,16 +9528,16 @@ function embedContentConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
9528
9528
|
setValueByPath(parentObject, ['requests[]', 'outputDimensionality'], fromOutputDimensionality);
|
|
9529
9529
|
}
|
|
9530
9530
|
if (getValueByPath(fromObject, ['mimeType']) !== undefined) {
|
|
9531
|
-
throw new Error('mimeType parameter is
|
|
9531
|
+
throw new Error('mimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9532
9532
|
}
|
|
9533
9533
|
if (getValueByPath(fromObject, ['autoTruncate']) !== undefined) {
|
|
9534
|
-
throw new Error('autoTruncate parameter is
|
|
9534
|
+
throw new Error('autoTruncate parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9535
9535
|
}
|
|
9536
9536
|
if (getValueByPath(fromObject, ['documentOcr']) !== undefined) {
|
|
9537
|
-
throw new Error('documentOcr parameter is
|
|
9537
|
+
throw new Error('documentOcr parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9538
9538
|
}
|
|
9539
9539
|
if (getValueByPath(fromObject, ['audioTrackExtraction']) !== undefined) {
|
|
9540
|
-
throw new Error('audioTrackExtraction parameter is
|
|
9540
|
+
throw new Error('audioTrackExtraction parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9541
9541
|
}
|
|
9542
9542
|
return toObject;
|
|
9543
9543
|
}
|
|
@@ -9821,7 +9821,7 @@ function endpointFromVertex(fromObject, _rootObject) {
|
|
|
9821
9821
|
function fileDataToMldev$1(fromObject, _rootObject) {
|
|
9822
9822
|
const toObject = {};
|
|
9823
9823
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
9824
|
-
throw new Error('displayName parameter is
|
|
9824
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9825
9825
|
}
|
|
9826
9826
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
9827
9827
|
if (fromFileUri != null) {
|
|
@@ -9848,10 +9848,10 @@ function functionCallToMldev$1(fromObject, _rootObject) {
|
|
|
9848
9848
|
setValueByPath(toObject, ['name'], fromName);
|
|
9849
9849
|
}
|
|
9850
9850
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
9851
|
-
throw new Error('partialArgs parameter is
|
|
9851
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9852
9852
|
}
|
|
9853
9853
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
9854
|
-
throw new Error('willContinue parameter is
|
|
9854
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9855
9855
|
}
|
|
9856
9856
|
return toObject;
|
|
9857
9857
|
}
|
|
@@ -9869,7 +9869,7 @@ function functionCallingConfigToMldev(fromObject, _rootObject) {
|
|
|
9869
9869
|
}
|
|
9870
9870
|
if (getValueByPath(fromObject, ['streamFunctionCallArguments']) !==
|
|
9871
9871
|
undefined) {
|
|
9872
|
-
throw new Error('streamFunctionCallArguments parameter is
|
|
9872
|
+
throw new Error('streamFunctionCallArguments parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9873
9873
|
}
|
|
9874
9874
|
return toObject;
|
|
9875
9875
|
}
|
|
@@ -9956,10 +9956,10 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
9956
9956
|
setValueByPath(toObject, ['responseJsonSchema'], fromResponseJsonSchema);
|
|
9957
9957
|
}
|
|
9958
9958
|
if (getValueByPath(fromObject, ['routingConfig']) !== undefined) {
|
|
9959
|
-
throw new Error('routingConfig parameter is
|
|
9959
|
+
throw new Error('routingConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9960
9960
|
}
|
|
9961
9961
|
if (getValueByPath(fromObject, ['modelSelectionConfig']) !== undefined) {
|
|
9962
|
-
throw new Error('modelSelectionConfig parameter is
|
|
9962
|
+
throw new Error('modelSelectionConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9963
9963
|
}
|
|
9964
9964
|
const fromSafetySettings = getValueByPath(fromObject, [
|
|
9965
9965
|
'safetySettings',
|
|
@@ -9988,7 +9988,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
9988
9988
|
setValueByPath(parentObject, ['toolConfig'], toolConfigToMldev(fromToolConfig));
|
|
9989
9989
|
}
|
|
9990
9990
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
9991
|
-
throw new Error('labels parameter is
|
|
9991
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
9992
9992
|
}
|
|
9993
9993
|
const fromCachedContent = getValueByPath(fromObject, [
|
|
9994
9994
|
'cachedContent',
|
|
@@ -10013,7 +10013,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
10013
10013
|
setValueByPath(toObject, ['speechConfig'], tSpeechConfig(fromSpeechConfig));
|
|
10014
10014
|
}
|
|
10015
10015
|
if (getValueByPath(fromObject, ['audioTimestamp']) !== undefined) {
|
|
10016
|
-
throw new Error('audioTimestamp parameter is
|
|
10016
|
+
throw new Error('audioTimestamp parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10017
10017
|
}
|
|
10018
10018
|
const fromThinkingConfig = getValueByPath(fromObject, [
|
|
10019
10019
|
'thinkingConfig',
|
|
@@ -10032,7 +10032,7 @@ function generateContentConfigToMldev(apiClient, fromObject, parentObject, rootO
|
|
|
10032
10032
|
setValueByPath(toObject, ['enableEnhancedCivicAnswers'], fromEnableEnhancedCivicAnswers);
|
|
10033
10033
|
}
|
|
10034
10034
|
if (getValueByPath(fromObject, ['modelArmorConfig']) !== undefined) {
|
|
10035
|
-
throw new Error('modelArmorConfig parameter is
|
|
10035
|
+
throw new Error('modelArmorConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10036
10036
|
}
|
|
10037
10037
|
const fromServiceTier = getValueByPath(fromObject, ['serviceTier']);
|
|
10038
10038
|
if (parentObject !== undefined && fromServiceTier != null) {
|
|
@@ -10204,7 +10204,7 @@ function generateContentConfigToVertex(apiClient, fromObject, parentObject, root
|
|
|
10204
10204
|
}
|
|
10205
10205
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
10206
10206
|
undefined) {
|
|
10207
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
10207
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
10208
10208
|
}
|
|
10209
10209
|
const fromModelArmorConfig = getValueByPath(fromObject, [
|
|
10210
10210
|
'modelArmorConfig',
|
|
@@ -10353,10 +10353,10 @@ function generateContentResponseFromVertex(fromObject, _rootObject) {
|
|
|
10353
10353
|
function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
10354
10354
|
const toObject = {};
|
|
10355
10355
|
if (getValueByPath(fromObject, ['outputGcsUri']) !== undefined) {
|
|
10356
|
-
throw new Error('outputGcsUri parameter is
|
|
10356
|
+
throw new Error('outputGcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10357
10357
|
}
|
|
10358
10358
|
if (getValueByPath(fromObject, ['negativePrompt']) !== undefined) {
|
|
10359
|
-
throw new Error('negativePrompt parameter is
|
|
10359
|
+
throw new Error('negativePrompt parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10360
10360
|
}
|
|
10361
10361
|
const fromNumberOfImages = getValueByPath(fromObject, [
|
|
10362
10362
|
'numberOfImages',
|
|
@@ -10375,7 +10375,7 @@ function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
10375
10375
|
setValueByPath(parentObject, ['parameters', 'guidanceScale'], fromGuidanceScale);
|
|
10376
10376
|
}
|
|
10377
10377
|
if (getValueByPath(fromObject, ['seed']) !== undefined) {
|
|
10378
|
-
throw new Error('seed parameter is
|
|
10378
|
+
throw new Error('seed parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10379
10379
|
}
|
|
10380
10380
|
const fromSafetyFilterLevel = getValueByPath(fromObject, [
|
|
10381
10381
|
'safetyFilterLevel',
|
|
@@ -10418,17 +10418,17 @@ function generateImagesConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
10418
10418
|
setValueByPath(parentObject, ['parameters', 'outputOptions', 'compressionQuality'], fromOutputCompressionQuality);
|
|
10419
10419
|
}
|
|
10420
10420
|
if (getValueByPath(fromObject, ['addWatermark']) !== undefined) {
|
|
10421
|
-
throw new Error('addWatermark parameter is
|
|
10421
|
+
throw new Error('addWatermark parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10422
10422
|
}
|
|
10423
10423
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
10424
|
-
throw new Error('labels parameter is
|
|
10424
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10425
10425
|
}
|
|
10426
10426
|
const fromImageSize = getValueByPath(fromObject, ['imageSize']);
|
|
10427
10427
|
if (parentObject !== undefined && fromImageSize != null) {
|
|
10428
10428
|
setValueByPath(parentObject, ['parameters', 'sampleImageSize'], fromImageSize);
|
|
10429
10429
|
}
|
|
10430
10430
|
if (getValueByPath(fromObject, ['enhancePrompt']) !== undefined) {
|
|
10431
|
-
throw new Error('enhancePrompt parameter is
|
|
10431
|
+
throw new Error('enhancePrompt parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10432
10432
|
}
|
|
10433
10433
|
return toObject;
|
|
10434
10434
|
}
|
|
@@ -10621,10 +10621,10 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10621
10621
|
setValueByPath(parentObject, ['parameters', 'sampleCount'], fromNumberOfVideos);
|
|
10622
10622
|
}
|
|
10623
10623
|
if (getValueByPath(fromObject, ['outputGcsUri']) !== undefined) {
|
|
10624
|
-
throw new Error('outputGcsUri parameter is
|
|
10624
|
+
throw new Error('outputGcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10625
10625
|
}
|
|
10626
10626
|
if (getValueByPath(fromObject, ['fps']) !== undefined) {
|
|
10627
|
-
throw new Error('fps parameter is
|
|
10627
|
+
throw new Error('fps parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10628
10628
|
}
|
|
10629
10629
|
const fromDurationSeconds = getValueByPath(fromObject, [
|
|
10630
10630
|
'durationSeconds',
|
|
@@ -10633,7 +10633,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10633
10633
|
setValueByPath(parentObject, ['parameters', 'durationSeconds'], fromDurationSeconds);
|
|
10634
10634
|
}
|
|
10635
10635
|
if (getValueByPath(fromObject, ['seed']) !== undefined) {
|
|
10636
|
-
throw new Error('seed parameter is
|
|
10636
|
+
throw new Error('seed parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10637
10637
|
}
|
|
10638
10638
|
const fromAspectRatio = getValueByPath(fromObject, ['aspectRatio']);
|
|
10639
10639
|
if (parentObject !== undefined && fromAspectRatio != null) {
|
|
@@ -10650,7 +10650,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10650
10650
|
setValueByPath(parentObject, ['parameters', 'personGeneration'], fromPersonGeneration);
|
|
10651
10651
|
}
|
|
10652
10652
|
if (getValueByPath(fromObject, ['pubsubTopic']) !== undefined) {
|
|
10653
|
-
throw new Error('pubsubTopic parameter is
|
|
10653
|
+
throw new Error('pubsubTopic parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10654
10654
|
}
|
|
10655
10655
|
const fromNegativePrompt = getValueByPath(fromObject, [
|
|
10656
10656
|
'negativePrompt',
|
|
@@ -10665,7 +10665,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10665
10665
|
setValueByPath(parentObject, ['parameters', 'enhancePrompt'], fromEnhancePrompt);
|
|
10666
10666
|
}
|
|
10667
10667
|
if (getValueByPath(fromObject, ['generateAudio']) !== undefined) {
|
|
10668
|
-
throw new Error('generateAudio parameter is
|
|
10668
|
+
throw new Error('generateAudio parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10669
10669
|
}
|
|
10670
10670
|
const fromLastFrame = getValueByPath(fromObject, ['lastFrame']);
|
|
10671
10671
|
if (parentObject !== undefined && fromLastFrame != null) {
|
|
@@ -10684,13 +10684,13 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10684
10684
|
setValueByPath(parentObject, ['instances[0]', 'referenceImages'], transformedList);
|
|
10685
10685
|
}
|
|
10686
10686
|
if (getValueByPath(fromObject, ['mask']) !== undefined) {
|
|
10687
|
-
throw new Error('mask parameter is
|
|
10687
|
+
throw new Error('mask parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10688
10688
|
}
|
|
10689
10689
|
if (getValueByPath(fromObject, ['compressionQuality']) !== undefined) {
|
|
10690
|
-
throw new Error('compressionQuality parameter is
|
|
10690
|
+
throw new Error('compressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10691
10691
|
}
|
|
10692
10692
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
10693
|
-
throw new Error('labels parameter is
|
|
10693
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10694
10694
|
}
|
|
10695
10695
|
const fromWebhookConfig = getValueByPath(fromObject, [
|
|
10696
10696
|
'webhookConfig',
|
|
@@ -10699,7 +10699,7 @@ function generateVideosConfigToMldev(fromObject, parentObject, rootObject) {
|
|
|
10699
10699
|
setValueByPath(parentObject, ['webhookConfig'], fromWebhookConfig);
|
|
10700
10700
|
}
|
|
10701
10701
|
if (getValueByPath(fromObject, ['resizeMode']) !== undefined) {
|
|
10702
|
-
throw new Error('resizeMode parameter is
|
|
10702
|
+
throw new Error('resizeMode parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
10703
10703
|
}
|
|
10704
10704
|
return toObject;
|
|
10705
10705
|
}
|
|
@@ -10796,7 +10796,7 @@ function generateVideosConfigToVertex(fromObject, parentObject, rootObject) {
|
|
|
10796
10796
|
setValueByPath(parentObject, ['labels'], fromLabels);
|
|
10797
10797
|
}
|
|
10798
10798
|
if (getValueByPath(fromObject, ['webhookConfig']) !== undefined) {
|
|
10799
|
-
throw new Error('webhookConfig parameter is
|
|
10799
|
+
throw new Error('webhookConfig parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
10800
10800
|
}
|
|
10801
10801
|
const fromResizeMode = getValueByPath(fromObject, ['resizeMode']);
|
|
10802
10802
|
if (parentObject !== undefined && fromResizeMode != null) {
|
|
@@ -11195,7 +11195,7 @@ function generationConfigToVertex(fromObject, _rootObject) {
|
|
|
11195
11195
|
}
|
|
11196
11196
|
if (getValueByPath(fromObject, ['enableEnhancedCivicAnswers']) !==
|
|
11197
11197
|
undefined) {
|
|
11198
|
-
throw new Error('enableEnhancedCivicAnswers parameter is
|
|
11198
|
+
throw new Error('enableEnhancedCivicAnswers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11199
11199
|
}
|
|
11200
11200
|
return toObject;
|
|
11201
11201
|
}
|
|
@@ -11234,10 +11234,10 @@ function googleSearchToMldev$1(fromObject, _rootObject) {
|
|
|
11234
11234
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
11235
11235
|
}
|
|
11236
11236
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
11237
|
-
throw new Error('blockingConfidence parameter is
|
|
11237
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11238
11238
|
}
|
|
11239
11239
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
11240
|
-
throw new Error('excludeDomains parameter is
|
|
11240
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11241
11241
|
}
|
|
11242
11242
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
11243
11243
|
'timeRangeFilter',
|
|
@@ -11258,20 +11258,20 @@ function imageConfigToMldev(fromObject, _rootObject) {
|
|
|
11258
11258
|
setValueByPath(toObject, ['imageSize'], fromImageSize);
|
|
11259
11259
|
}
|
|
11260
11260
|
if (getValueByPath(fromObject, ['personGeneration']) !== undefined) {
|
|
11261
|
-
throw new Error('personGeneration parameter is
|
|
11261
|
+
throw new Error('personGeneration parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11262
11262
|
}
|
|
11263
11263
|
if (getValueByPath(fromObject, ['prominentPeople']) !== undefined) {
|
|
11264
|
-
throw new Error('prominentPeople parameter is
|
|
11264
|
+
throw new Error('prominentPeople parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11265
11265
|
}
|
|
11266
11266
|
if (getValueByPath(fromObject, ['outputMimeType']) !== undefined) {
|
|
11267
|
-
throw new Error('outputMimeType parameter is
|
|
11267
|
+
throw new Error('outputMimeType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11268
11268
|
}
|
|
11269
11269
|
if (getValueByPath(fromObject, ['outputCompressionQuality']) !==
|
|
11270
11270
|
undefined) {
|
|
11271
|
-
throw new Error('outputCompressionQuality parameter is
|
|
11271
|
+
throw new Error('outputCompressionQuality parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11272
11272
|
}
|
|
11273
11273
|
if (getValueByPath(fromObject, ['imageOutputOptions']) !== undefined) {
|
|
11274
|
-
throw new Error('imageOutputOptions parameter is
|
|
11274
|
+
throw new Error('imageOutputOptions parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11275
11275
|
}
|
|
11276
11276
|
return toObject;
|
|
11277
11277
|
}
|
|
@@ -11352,7 +11352,7 @@ function imageFromVertex(fromObject, _rootObject) {
|
|
|
11352
11352
|
function imageToMldev(fromObject, _rootObject) {
|
|
11353
11353
|
const toObject = {};
|
|
11354
11354
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
11355
|
-
throw new Error('gcsUri parameter is
|
|
11355
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11356
11356
|
}
|
|
11357
11357
|
const fromImageBytes = getValueByPath(fromObject, ['imageBytes']);
|
|
11358
11358
|
if (fromImageBytes != null) {
|
|
@@ -11755,13 +11755,13 @@ function partToVertex(fromObject, _rootObject) {
|
|
|
11755
11755
|
setValueByPath(toObject, ['videoMetadata'], fromVideoMetadata);
|
|
11756
11756
|
}
|
|
11757
11757
|
if (getValueByPath(fromObject, ['toolCall']) !== undefined) {
|
|
11758
|
-
throw new Error('toolCall parameter is
|
|
11758
|
+
throw new Error('toolCall parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11759
11759
|
}
|
|
11760
11760
|
if (getValueByPath(fromObject, ['toolResponse']) !== undefined) {
|
|
11761
|
-
throw new Error('toolResponse parameter is
|
|
11761
|
+
throw new Error('toolResponse parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11762
11762
|
}
|
|
11763
11763
|
if (getValueByPath(fromObject, ['partMetadata']) !== undefined) {
|
|
11764
|
-
throw new Error('partMetadata parameter is
|
|
11764
|
+
throw new Error('partMetadata parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
11765
11765
|
}
|
|
11766
11766
|
return toObject;
|
|
11767
11767
|
}
|
|
@@ -11984,7 +11984,7 @@ function safetySettingToMldev$1(fromObject, _rootObject) {
|
|
|
11984
11984
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
11985
11985
|
}
|
|
11986
11986
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
11987
|
-
throw new Error('method parameter is
|
|
11987
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
11988
11988
|
}
|
|
11989
11989
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
11990
11990
|
if (fromThreshold != null) {
|
|
@@ -12118,14 +12118,14 @@ function toolConfigToVertex(fromObject, _rootObject) {
|
|
|
12118
12118
|
}
|
|
12119
12119
|
if (getValueByPath(fromObject, ['includeServerSideToolInvocations']) !==
|
|
12120
12120
|
undefined) {
|
|
12121
|
-
throw new Error('includeServerSideToolInvocations parameter is
|
|
12121
|
+
throw new Error('includeServerSideToolInvocations parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12122
12122
|
}
|
|
12123
12123
|
return toObject;
|
|
12124
12124
|
}
|
|
12125
12125
|
function toolToMldev$1(fromObject, rootObject) {
|
|
12126
12126
|
const toObject = {};
|
|
12127
12127
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
12128
|
-
throw new Error('retrieval parameter is
|
|
12128
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12129
12129
|
}
|
|
12130
12130
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
12131
12131
|
if (fromComputerUse != null) {
|
|
@@ -12150,7 +12150,7 @@ function toolToMldev$1(fromObject, rootObject) {
|
|
|
12150
12150
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
12151
12151
|
}
|
|
12152
12152
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
12153
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
12153
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12154
12154
|
}
|
|
12155
12155
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
12156
12156
|
'functionDeclarations',
|
|
@@ -12171,7 +12171,7 @@ function toolToMldev$1(fromObject, rootObject) {
|
|
|
12171
12171
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
12172
12172
|
}
|
|
12173
12173
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
12174
|
-
throw new Error('parallelAiSearch parameter is
|
|
12174
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
12175
12175
|
}
|
|
12176
12176
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
12177
12177
|
if (fromUrlContext != null) {
|
|
@@ -12200,7 +12200,7 @@ function toolToVertex(fromObject, _rootObject) {
|
|
|
12200
12200
|
setValueByPath(toObject, ['computerUse'], fromComputerUse);
|
|
12201
12201
|
}
|
|
12202
12202
|
if (getValueByPath(fromObject, ['fileSearch']) !== undefined) {
|
|
12203
|
-
throw new Error('fileSearch parameter is
|
|
12203
|
+
throw new Error('fileSearch parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12204
12204
|
}
|
|
12205
12205
|
const fromGoogleSearch = getValueByPath(fromObject, ['googleSearch']);
|
|
12206
12206
|
if (fromGoogleSearch != null) {
|
|
@@ -12251,7 +12251,7 @@ function toolToVertex(fromObject, _rootObject) {
|
|
|
12251
12251
|
setValueByPath(toObject, ['urlContext'], fromUrlContext);
|
|
12252
12252
|
}
|
|
12253
12253
|
if (getValueByPath(fromObject, ['mcpServers']) !== undefined) {
|
|
12254
|
-
throw new Error('mcpServers parameter is
|
|
12254
|
+
throw new Error('mcpServers parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
12255
12255
|
}
|
|
12256
12256
|
return toObject;
|
|
12257
12257
|
}
|
|
@@ -12814,7 +12814,7 @@ const CONTENT_TYPE_HEADER = 'Content-Type';
|
|
|
12814
12814
|
const SERVER_TIMEOUT_HEADER = 'X-Server-Timeout';
|
|
12815
12815
|
const USER_AGENT_HEADER = 'User-Agent';
|
|
12816
12816
|
const GOOGLE_API_CLIENT_HEADER = 'x-goog-api-client';
|
|
12817
|
-
const SDK_VERSION = '2.
|
|
12817
|
+
const SDK_VERSION = '2.2.0'; // x-release-please-version
|
|
12818
12818
|
const LIBRARY_LABEL = `google-genai-sdk/${SDK_VERSION}`;
|
|
12819
12819
|
const VERTEX_AI_API_DEFAULT_VERSION = 'v1beta1';
|
|
12820
12820
|
const GOOGLE_AI_API_DEFAULT_VERSION = 'v1beta';
|
|
@@ -14710,7 +14710,7 @@ class Models extends BaseModule {
|
|
|
14710
14710
|
if (this.apiClient.isVertexAI()) {
|
|
14711
14711
|
if (!actualParams.config.queryBase) {
|
|
14712
14712
|
if ((_a = actualParams.config) === null || _a === void 0 ? void 0 : _a.filter) {
|
|
14713
|
-
throw new Error('Filtering tuned models list
|
|
14713
|
+
throw new Error('Filtering tuned models list is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
14714
14714
|
}
|
|
14715
14715
|
else {
|
|
14716
14716
|
actualParams.config.filter = 'labels.tune-type:*';
|
|
@@ -16166,7 +16166,7 @@ class Operations extends BaseModule {
|
|
|
16166
16166
|
function audioTranscriptionConfigToMldev(fromObject) {
|
|
16167
16167
|
const toObject = {};
|
|
16168
16168
|
if (getValueByPath(fromObject, ['languageCodes']) !== undefined) {
|
|
16169
|
-
throw new Error('languageCodes parameter is
|
|
16169
|
+
throw new Error('languageCodes parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16170
16170
|
}
|
|
16171
16171
|
return toObject;
|
|
16172
16172
|
}
|
|
@@ -16177,23 +16177,23 @@ function authConfigToMldev(fromObject) {
|
|
|
16177
16177
|
setValueByPath(toObject, ['apiKey'], fromApiKey);
|
|
16178
16178
|
}
|
|
16179
16179
|
if (getValueByPath(fromObject, ['apiKeyConfig']) !== undefined) {
|
|
16180
|
-
throw new Error('apiKeyConfig parameter is
|
|
16180
|
+
throw new Error('apiKeyConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16181
16181
|
}
|
|
16182
16182
|
if (getValueByPath(fromObject, ['authType']) !== undefined) {
|
|
16183
|
-
throw new Error('authType parameter is
|
|
16183
|
+
throw new Error('authType parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16184
16184
|
}
|
|
16185
16185
|
if (getValueByPath(fromObject, ['googleServiceAccountConfig']) !==
|
|
16186
16186
|
undefined) {
|
|
16187
|
-
throw new Error('googleServiceAccountConfig parameter is
|
|
16187
|
+
throw new Error('googleServiceAccountConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16188
16188
|
}
|
|
16189
16189
|
if (getValueByPath(fromObject, ['httpBasicAuthConfig']) !== undefined) {
|
|
16190
|
-
throw new Error('httpBasicAuthConfig parameter is
|
|
16190
|
+
throw new Error('httpBasicAuthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16191
16191
|
}
|
|
16192
16192
|
if (getValueByPath(fromObject, ['oauthConfig']) !== undefined) {
|
|
16193
|
-
throw new Error('oauthConfig parameter is
|
|
16193
|
+
throw new Error('oauthConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16194
16194
|
}
|
|
16195
16195
|
if (getValueByPath(fromObject, ['oidcConfig']) !== undefined) {
|
|
16196
|
-
throw new Error('oidcConfig parameter is
|
|
16196
|
+
throw new Error('oidcConfig parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16197
16197
|
}
|
|
16198
16198
|
return toObject;
|
|
16199
16199
|
}
|
|
@@ -16204,7 +16204,7 @@ function blobToMldev(fromObject) {
|
|
|
16204
16204
|
setValueByPath(toObject, ['data'], fromData);
|
|
16205
16205
|
}
|
|
16206
16206
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
16207
|
-
throw new Error('displayName parameter is
|
|
16207
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16208
16208
|
}
|
|
16209
16209
|
const fromMimeType = getValueByPath(fromObject, ['mimeType']);
|
|
16210
16210
|
if (fromMimeType != null) {
|
|
@@ -16271,7 +16271,7 @@ function createAuthTokenParametersToMldev(apiClient, fromObject) {
|
|
|
16271
16271
|
function fileDataToMldev(fromObject) {
|
|
16272
16272
|
const toObject = {};
|
|
16273
16273
|
if (getValueByPath(fromObject, ['displayName']) !== undefined) {
|
|
16274
|
-
throw new Error('displayName parameter is
|
|
16274
|
+
throw new Error('displayName parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16275
16275
|
}
|
|
16276
16276
|
const fromFileUri = getValueByPath(fromObject, ['fileUri']);
|
|
16277
16277
|
if (fromFileUri != null) {
|
|
@@ -16298,10 +16298,10 @@ function functionCallToMldev(fromObject) {
|
|
|
16298
16298
|
setValueByPath(toObject, ['name'], fromName);
|
|
16299
16299
|
}
|
|
16300
16300
|
if (getValueByPath(fromObject, ['partialArgs']) !== undefined) {
|
|
16301
|
-
throw new Error('partialArgs parameter is
|
|
16301
|
+
throw new Error('partialArgs parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16302
16302
|
}
|
|
16303
16303
|
if (getValueByPath(fromObject, ['willContinue']) !== undefined) {
|
|
16304
|
-
throw new Error('willContinue parameter is
|
|
16304
|
+
throw new Error('willContinue parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16305
16305
|
}
|
|
16306
16306
|
return toObject;
|
|
16307
16307
|
}
|
|
@@ -16324,10 +16324,10 @@ function googleSearchToMldev(fromObject) {
|
|
|
16324
16324
|
setValueByPath(toObject, ['searchTypes'], fromSearchTypes);
|
|
16325
16325
|
}
|
|
16326
16326
|
if (getValueByPath(fromObject, ['blockingConfidence']) !== undefined) {
|
|
16327
|
-
throw new Error('blockingConfidence parameter is
|
|
16327
|
+
throw new Error('blockingConfidence parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16328
16328
|
}
|
|
16329
16329
|
if (getValueByPath(fromObject, ['excludeDomains']) !== undefined) {
|
|
16330
|
-
throw new Error('excludeDomains parameter is
|
|
16330
|
+
throw new Error('excludeDomains parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16331
16331
|
}
|
|
16332
16332
|
const fromTimeRangeFilter = getValueByPath(fromObject, [
|
|
16333
16333
|
'timeRangeFilter',
|
|
@@ -16446,7 +16446,7 @@ function liveConnectConfigToMldev(fromObject, parentObject) {
|
|
|
16446
16446
|
setValueByPath(parentObject, ['setup', 'proactivity'], fromProactivity);
|
|
16447
16447
|
}
|
|
16448
16448
|
if (getValueByPath(fromObject, ['explicitVadSignal']) !== undefined) {
|
|
16449
|
-
throw new Error('explicitVadSignal parameter is
|
|
16449
|
+
throw new Error('explicitVadSignal parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16450
16450
|
}
|
|
16451
16451
|
const fromAvatarConfig = getValueByPath(fromObject, ['avatarConfig']);
|
|
16452
16452
|
if (parentObject !== undefined && fromAvatarConfig != null) {
|
|
@@ -16557,7 +16557,7 @@ function safetySettingToMldev(fromObject) {
|
|
|
16557
16557
|
setValueByPath(toObject, ['category'], fromCategory);
|
|
16558
16558
|
}
|
|
16559
16559
|
if (getValueByPath(fromObject, ['method']) !== undefined) {
|
|
16560
|
-
throw new Error('method parameter is
|
|
16560
|
+
throw new Error('method parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16561
16561
|
}
|
|
16562
16562
|
const fromThreshold = getValueByPath(fromObject, ['threshold']);
|
|
16563
16563
|
if (fromThreshold != null) {
|
|
@@ -16572,14 +16572,14 @@ function sessionResumptionConfigToMldev(fromObject) {
|
|
|
16572
16572
|
setValueByPath(toObject, ['handle'], fromHandle);
|
|
16573
16573
|
}
|
|
16574
16574
|
if (getValueByPath(fromObject, ['transparent']) !== undefined) {
|
|
16575
|
-
throw new Error('transparent parameter is
|
|
16575
|
+
throw new Error('transparent parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16576
16576
|
}
|
|
16577
16577
|
return toObject;
|
|
16578
16578
|
}
|
|
16579
16579
|
function toolToMldev(fromObject) {
|
|
16580
16580
|
const toObject = {};
|
|
16581
16581
|
if (getValueByPath(fromObject, ['retrieval']) !== undefined) {
|
|
16582
|
-
throw new Error('retrieval parameter is
|
|
16582
|
+
throw new Error('retrieval parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16583
16583
|
}
|
|
16584
16584
|
const fromComputerUse = getValueByPath(fromObject, ['computerUse']);
|
|
16585
16585
|
if (fromComputerUse != null) {
|
|
@@ -16604,7 +16604,7 @@ function toolToMldev(fromObject) {
|
|
|
16604
16604
|
setValueByPath(toObject, ['codeExecution'], fromCodeExecution);
|
|
16605
16605
|
}
|
|
16606
16606
|
if (getValueByPath(fromObject, ['enterpriseWebSearch']) !== undefined) {
|
|
16607
|
-
throw new Error('enterpriseWebSearch parameter is
|
|
16607
|
+
throw new Error('enterpriseWebSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16608
16608
|
}
|
|
16609
16609
|
const fromFunctionDeclarations = getValueByPath(fromObject, [
|
|
16610
16610
|
'functionDeclarations',
|
|
@@ -16625,7 +16625,7 @@ function toolToMldev(fromObject) {
|
|
|
16625
16625
|
setValueByPath(toObject, ['googleSearchRetrieval'], fromGoogleSearchRetrieval);
|
|
16626
16626
|
}
|
|
16627
16627
|
if (getValueByPath(fromObject, ['parallelAiSearch']) !== undefined) {
|
|
16628
|
-
throw new Error('parallelAiSearch parameter is
|
|
16628
|
+
throw new Error('parallelAiSearch parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
16629
16629
|
}
|
|
16630
16630
|
const fromUrlContext = getValueByPath(fromObject, ['urlContext']);
|
|
16631
16631
|
if (fromUrlContext != null) {
|
|
@@ -19726,7 +19726,7 @@ function cancelTuningJobResponseFromVertex(fromObject, _rootObject) {
|
|
|
19726
19726
|
function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
19727
19727
|
const toObject = {};
|
|
19728
19728
|
if (getValueByPath(fromObject, ['validationDataset']) !== undefined) {
|
|
19729
|
-
throw new Error('validationDataset parameter is
|
|
19729
|
+
throw new Error('validationDataset parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19730
19730
|
}
|
|
19731
19731
|
const fromTunedModelDisplayName = getValueByPath(fromObject, [
|
|
19732
19732
|
'tunedModelDisplayName',
|
|
@@ -19735,7 +19735,7 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19735
19735
|
setValueByPath(parentObject, ['displayName'], fromTunedModelDisplayName);
|
|
19736
19736
|
}
|
|
19737
19737
|
if (getValueByPath(fromObject, ['description']) !== undefined) {
|
|
19738
|
-
throw new Error('description parameter is
|
|
19738
|
+
throw new Error('description parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19739
19739
|
}
|
|
19740
19740
|
const fromEpochCount = getValueByPath(fromObject, ['epochCount']);
|
|
19741
19741
|
if (parentObject !== undefined && fromEpochCount != null) {
|
|
@@ -19749,20 +19749,20 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19749
19749
|
}
|
|
19750
19750
|
if (getValueByPath(fromObject, ['exportLastCheckpointOnly']) !==
|
|
19751
19751
|
undefined) {
|
|
19752
|
-
throw new Error('exportLastCheckpointOnly parameter is
|
|
19752
|
+
throw new Error('exportLastCheckpointOnly parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19753
19753
|
}
|
|
19754
19754
|
if (getValueByPath(fromObject, ['preTunedModelCheckpointId']) !==
|
|
19755
19755
|
undefined) {
|
|
19756
|
-
throw new Error('preTunedModelCheckpointId parameter is
|
|
19756
|
+
throw new Error('preTunedModelCheckpointId parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19757
19757
|
}
|
|
19758
19758
|
if (getValueByPath(fromObject, ['adapterSize']) !== undefined) {
|
|
19759
|
-
throw new Error('adapterSize parameter is
|
|
19759
|
+
throw new Error('adapterSize parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19760
19760
|
}
|
|
19761
19761
|
if (getValueByPath(fromObject, ['tuningMode']) !== undefined) {
|
|
19762
|
-
throw new Error('tuningMode parameter is
|
|
19762
|
+
throw new Error('tuningMode parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19763
19763
|
}
|
|
19764
19764
|
if (getValueByPath(fromObject, ['customBaseModel']) !== undefined) {
|
|
19765
|
-
throw new Error('customBaseModel parameter is
|
|
19765
|
+
throw new Error('customBaseModel parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19766
19766
|
}
|
|
19767
19767
|
const fromBatchSize = getValueByPath(fromObject, ['batchSize']);
|
|
19768
19768
|
if (parentObject !== undefined && fromBatchSize != null) {
|
|
@@ -19773,25 +19773,25 @@ function createTuningJobConfigToMldev(fromObject, parentObject, _rootObject) {
|
|
|
19773
19773
|
setValueByPath(parentObject, ['tuningTask', 'hyperparameters', 'learningRate'], fromLearningRate);
|
|
19774
19774
|
}
|
|
19775
19775
|
if (getValueByPath(fromObject, ['labels']) !== undefined) {
|
|
19776
|
-
throw new Error('labels parameter is
|
|
19776
|
+
throw new Error('labels parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19777
19777
|
}
|
|
19778
19778
|
if (getValueByPath(fromObject, ['beta']) !== undefined) {
|
|
19779
|
-
throw new Error('beta parameter is
|
|
19779
|
+
throw new Error('beta parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19780
19780
|
}
|
|
19781
19781
|
if (getValueByPath(fromObject, ['baseTeacherModel']) !== undefined) {
|
|
19782
|
-
throw new Error('baseTeacherModel parameter is
|
|
19782
|
+
throw new Error('baseTeacherModel parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19783
19783
|
}
|
|
19784
19784
|
if (getValueByPath(fromObject, ['tunedTeacherModelSource']) !== undefined) {
|
|
19785
|
-
throw new Error('tunedTeacherModelSource parameter is
|
|
19785
|
+
throw new Error('tunedTeacherModelSource parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19786
19786
|
}
|
|
19787
19787
|
if (getValueByPath(fromObject, ['sftLossWeightMultiplier']) !== undefined) {
|
|
19788
|
-
throw new Error('sftLossWeightMultiplier parameter is
|
|
19788
|
+
throw new Error('sftLossWeightMultiplier parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19789
19789
|
}
|
|
19790
19790
|
if (getValueByPath(fromObject, ['outputUri']) !== undefined) {
|
|
19791
|
-
throw new Error('outputUri parameter is
|
|
19791
|
+
throw new Error('outputUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19792
19792
|
}
|
|
19793
19793
|
if (getValueByPath(fromObject, ['encryptionSpec']) !== undefined) {
|
|
19794
|
-
throw new Error('encryptionSpec parameter is
|
|
19794
|
+
throw new Error('encryptionSpec parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
19795
19795
|
}
|
|
19796
19796
|
return toObject;
|
|
19797
19797
|
}
|
|
@@ -20185,10 +20185,10 @@ function tunedModelFromMldev(fromObject, _rootObject) {
|
|
|
20185
20185
|
function tuningDatasetToMldev(fromObject, _rootObject) {
|
|
20186
20186
|
const toObject = {};
|
|
20187
20187
|
if (getValueByPath(fromObject, ['gcsUri']) !== undefined) {
|
|
20188
|
-
throw new Error('gcsUri parameter is
|
|
20188
|
+
throw new Error('gcsUri parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
20189
20189
|
}
|
|
20190
20190
|
if (getValueByPath(fromObject, ['vertexDatasetResource']) !== undefined) {
|
|
20191
|
-
throw new Error('vertexDatasetResource parameter is
|
|
20191
|
+
throw new Error('vertexDatasetResource parameter is only supported in Gemini Enterprise Agent Platform mode, not in Gemini Developer API mode.');
|
|
20192
20192
|
}
|
|
20193
20193
|
const fromExamples = getValueByPath(fromObject, ['examples']);
|
|
20194
20194
|
if (fromExamples != null) {
|
|
@@ -20261,7 +20261,7 @@ function tuningDatasetToVertex(fromObject, parentObject, rootObject) {
|
|
|
20261
20261
|
}
|
|
20262
20262
|
}
|
|
20263
20263
|
if (getValueByPath(fromObject, ['examples']) !== undefined) {
|
|
20264
|
-
throw new Error('examples parameter is
|
|
20264
|
+
throw new Error('examples parameter is only supported in Gemini Developer API mode, not in Gemini Enterprise Agent Platform mode.');
|
|
20265
20265
|
}
|
|
20266
20266
|
return toObject;
|
|
20267
20267
|
}
|