@uipath/solution-tool 1.201.0-preview.133 → 1.202.0-preview.134
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/deploy.d.ts +6 -1
- package/dist/deploy.js +15 -16
- package/dist/{index-2fj08e7n.js → index-gpd94m28.js} +27 -27
- package/dist/{index-w03qc9m8.js → index-sby22td6.js} +4 -4
- package/dist/index.js +16 -19
- package/dist/init.js +10 -13
- package/dist/{js-yaml-4ypbq2tt.js → js-yaml-b2jq67kn.js} +16 -16
- package/dist/{list-skbehtq2.js → list-3mrc9s3f.js} +7 -11
- package/dist/models/pack-command-types.d.ts +8 -0
- package/dist/pack.js +9 -12
- package/dist/{packager-tool-krd5v2r5.js → packager-tool-0qva0ebq.js} +129 -53
- package/dist/{packager-tool-0v6na3yp.js → packager-tool-1de529jm.js} +9 -7
- package/dist/{packager-tool-9vehmnke.js → packager-tool-3hbsdwjm.js} +6 -661
- package/dist/{packager-tool-fzwxq48d.js → packager-tool-3y92zbg2.js} +3 -3
- package/dist/{packager-tool-f7kj5fpa.js → packager-tool-5pfxgc8z.js} +19 -11
- package/dist/{packager-tool-9w3k4e77.js → packager-tool-b16qemg2.js} +494 -198
- package/dist/{packager-tool-zbp5p149.js → packager-tool-bahvrjbv.js} +592 -264
- package/dist/{packager-tool-129wn232.js → packager-tool-dfrk01gn.js} +198 -2
- package/dist/{packager-tool-67ssxgph.js → packager-tool-fh8pb2th.js} +3 -5
- package/dist/{packager-tool-c29pg93e.js → packager-tool-hc6ybtdw.js} +5 -5
- package/dist/{packager-tool-bcpknnr8.js → packager-tool-hgx66d1p.js} +1656 -558
- package/dist/{packager-tool-2yz7m5ny.js → packager-tool-nq2nq71y.js} +21282 -20197
- package/dist/{packager-tool-wjhn59ft.js → packager-tool-t89r1edr.js} +596 -180
- package/dist/{packager-tool-vpr77gre.js → packager-tool-x3ehbhsn.js} +3 -2
- package/dist/{packager-tool-yktm4v4r.js → packager-tool-xntjj1bt.js} +1 -1
- package/dist/packager-tool.d.ts +4 -3
- package/dist/packager-tool.js +4 -4
- package/dist/publish.js +8 -11
- package/dist/resource.js +7 -10
- package/dist/services/activation.d.ts +9 -1
- package/dist/services/deploy-run-service.d.ts +25 -1
- package/dist/services/deploy-uninstall-service.d.ts +20 -1
- package/dist/services/deploy-upgrade-service.d.ts +94 -0
- package/dist/services/deployment-feed-locator.d.ts +36 -0
- package/dist/services/deployment-search.d.ts +88 -7
- package/dist/services/pack-command-service.d.ts +15 -0
- package/dist/services/package-metadata-rewrite.d.ts +9 -5
- package/dist/services/publish-service.d.ts +11 -9
- package/dist/services/solution-path.d.ts +34 -0
- package/dist/templates/AGENTS.md +183 -16
- package/dist/tool.js +18 -21
- package/package.json +2 -2
- package/dist/browser-strategy-yccf8mtd.js +0 -99
- package/dist/node-strategy-12qfy0nv.js +0 -348
- package/dist/packager-tool-5arsyj36.js +0 -11
- package/dist/packager-tool-7eva0peq.js +0 -265
- package/dist/packager-tool-9qecd4wb.js +0 -14
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
installSdkUserAgentHeader,
|
|
6
6
|
logger,
|
|
7
7
|
readUipxFile
|
|
8
|
-
} from "./packager-tool-
|
|
8
|
+
} from "./packager-tool-hgx66d1p.js";
|
|
9
9
|
import {
|
|
10
10
|
zipSync
|
|
11
|
-
} from "./packager-tool-
|
|
11
|
+
} from "./packager-tool-dfrk01gn.js";
|
|
12
12
|
|
|
13
13
|
// ../solution-sdk/generated/src/runtime.ts
|
|
14
14
|
var BASE_PATH = "https://alpha.uipath.com/uipattycyrhx/abizon_1/automationsolutions_".replace(/\/+$/, "");
|
|
@@ -269,6 +269,33 @@ class TextApiResponse {
|
|
|
269
269
|
}
|
|
270
270
|
}
|
|
271
271
|
|
|
272
|
+
// ../solution-sdk/generated/src/models/DeploymentOperationStatus.ts
|
|
273
|
+
var DeploymentOperationStatus = {
|
|
274
|
+
Draft: "Draft",
|
|
275
|
+
Successful: "Successful",
|
|
276
|
+
Failed: "Failed",
|
|
277
|
+
InProgress: "InProgress",
|
|
278
|
+
FailedRollback: "FailedRollback"
|
|
279
|
+
};
|
|
280
|
+
function DeploymentOperationStatusFromJSON(json) {
|
|
281
|
+
return DeploymentOperationStatusFromJSONTyped(json, false);
|
|
282
|
+
}
|
|
283
|
+
function DeploymentOperationStatusFromJSONTyped(json, ignoreDiscriminator) {
|
|
284
|
+
return json;
|
|
285
|
+
}
|
|
286
|
+
function DeploymentOperationStatusToJSON(value) {
|
|
287
|
+
return value;
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
// ../solution-sdk/generated/src/models/SolutionDeploymentAction.ts
|
|
291
|
+
var SolutionDeploymentAction = {
|
|
292
|
+
Install: "Install",
|
|
293
|
+
Uninstall: "Uninstall",
|
|
294
|
+
Upgrade: "Upgrade",
|
|
295
|
+
Rollback: "Rollback",
|
|
296
|
+
Activate: "Activate"
|
|
297
|
+
};
|
|
298
|
+
|
|
272
299
|
// ../solution-sdk/generated/src/models/ResponseDictionaryDto.ts
|
|
273
300
|
function ResponseDictionaryDtoFromJSON(json) {
|
|
274
301
|
return ResponseDictionaryDtoFromJSONTyped(json, false);
|
|
@@ -433,24 +460,6 @@ function PackageVersionOriginFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
433
460
|
return json;
|
|
434
461
|
}
|
|
435
462
|
|
|
436
|
-
// ../solution-sdk/generated/src/models/DeploymentOperationStatus.ts
|
|
437
|
-
var DeploymentOperationStatus = {
|
|
438
|
-
Draft: "Draft",
|
|
439
|
-
Successful: "Successful",
|
|
440
|
-
Failed: "Failed",
|
|
441
|
-
InProgress: "InProgress",
|
|
442
|
-
FailedRollback: "FailedRollback"
|
|
443
|
-
};
|
|
444
|
-
function DeploymentOperationStatusFromJSON(json) {
|
|
445
|
-
return DeploymentOperationStatusFromJSONTyped(json, false);
|
|
446
|
-
}
|
|
447
|
-
function DeploymentOperationStatusFromJSONTyped(json, ignoreDiscriminator) {
|
|
448
|
-
return json;
|
|
449
|
-
}
|
|
450
|
-
function DeploymentOperationStatusToJSON(value) {
|
|
451
|
-
return value;
|
|
452
|
-
}
|
|
453
|
-
|
|
454
463
|
// ../solution-sdk/generated/src/models/DeploymentUpgradeType.ts
|
|
455
464
|
function DeploymentUpgradeTypeFromJSON(json) {
|
|
456
465
|
return DeploymentUpgradeTypeFromJSONTyped(json, false);
|
|
@@ -526,6 +535,58 @@ function DeploymentRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
526
535
|
runtimeSetup: RuntimeSetupToJSON(value["runtimeSetup"])
|
|
527
536
|
};
|
|
528
537
|
}
|
|
538
|
+
// ../solution-sdk/generated/src/models/DeploymentResourceValidationAction.ts
|
|
539
|
+
function DeploymentResourceValidationActionFromJSON(json) {
|
|
540
|
+
return DeploymentResourceValidationActionFromJSONTyped(json, false);
|
|
541
|
+
}
|
|
542
|
+
function DeploymentResourceValidationActionFromJSONTyped(json, ignoreDiscriminator) {
|
|
543
|
+
return json;
|
|
544
|
+
}
|
|
545
|
+
// ../solution-sdk/generated/src/models/DeploymentResourceValidationErrorKind.ts
|
|
546
|
+
function DeploymentResourceValidationErrorKindFromJSON(json) {
|
|
547
|
+
return DeploymentResourceValidationErrorKindFromJSONTyped(json, false);
|
|
548
|
+
}
|
|
549
|
+
function DeploymentResourceValidationErrorKindFromJSONTyped(json, ignoreDiscriminator) {
|
|
550
|
+
return json;
|
|
551
|
+
}
|
|
552
|
+
// ../solution-sdk/generated/src/models/DeploymentResourceValidationErrorLevel.ts
|
|
553
|
+
function DeploymentResourceValidationErrorLevelFromJSON(json) {
|
|
554
|
+
return DeploymentResourceValidationErrorLevelFromJSONTyped(json, false);
|
|
555
|
+
}
|
|
556
|
+
function DeploymentResourceValidationErrorLevelFromJSONTyped(json, ignoreDiscriminator) {
|
|
557
|
+
return json;
|
|
558
|
+
}
|
|
559
|
+
// ../solution-sdk/generated/src/models/ServiceMessage.ts
|
|
560
|
+
function ServiceMessageFromJSON(json) {
|
|
561
|
+
return ServiceMessageFromJSONTyped(json, false);
|
|
562
|
+
}
|
|
563
|
+
function ServiceMessageFromJSONTyped(json, ignoreDiscriminator) {
|
|
564
|
+
if (json == null) {
|
|
565
|
+
return json;
|
|
566
|
+
}
|
|
567
|
+
return {
|
|
568
|
+
resource: json["resource"],
|
|
569
|
+
text: json["text"],
|
|
570
|
+
parameters: json["parameters"],
|
|
571
|
+
errorCode: json["errorCode"] == null ? undefined : json["errorCode"]
|
|
572
|
+
};
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
// ../solution-sdk/generated/src/models/DeploymentRunResponse.ts
|
|
576
|
+
function DeploymentRunResponseFromJSON(json) {
|
|
577
|
+
return DeploymentRunResponseFromJSONTyped(json, false);
|
|
578
|
+
}
|
|
579
|
+
function DeploymentRunResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
580
|
+
if (json == null) {
|
|
581
|
+
return json;
|
|
582
|
+
}
|
|
583
|
+
return {
|
|
584
|
+
instanceId: json["instanceId"] == null ? undefined : json["instanceId"],
|
|
585
|
+
scheduled: json["scheduled"],
|
|
586
|
+
errors: json["errors"].map(ServiceMessageFromJSON),
|
|
587
|
+
complete: json["complete"]
|
|
588
|
+
};
|
|
589
|
+
}
|
|
529
590
|
// ../solution-sdk/generated/src/models/DeploymentType.ts
|
|
530
591
|
function DeploymentTypeFromJSON(json) {
|
|
531
592
|
return DeploymentTypeFromJSONTyped(json, false);
|
|
@@ -587,6 +648,58 @@ function DeploymentUpgradeRequestToJSONTyped(value, ignoreDiscriminator = false)
|
|
|
587
648
|
packageVersionKey: value["packageVersionKey"]
|
|
588
649
|
};
|
|
589
650
|
}
|
|
651
|
+
// ../solution-sdk/generated/src/models/ResourceValidationError.ts
|
|
652
|
+
function ResourceValidationErrorFromJSON(json) {
|
|
653
|
+
return ResourceValidationErrorFromJSONTyped(json, false);
|
|
654
|
+
}
|
|
655
|
+
function ResourceValidationErrorFromJSONTyped(json, ignoreDiscriminator) {
|
|
656
|
+
if (json == null) {
|
|
657
|
+
return json;
|
|
658
|
+
}
|
|
659
|
+
return {
|
|
660
|
+
resource: json["resource"],
|
|
661
|
+
text: json["text"],
|
|
662
|
+
parameters: json["parameters"],
|
|
663
|
+
errorCode: json["errorCode"] == null ? undefined : json["errorCode"],
|
|
664
|
+
kind: DeploymentResourceValidationErrorKindFromJSON(json["kind"]),
|
|
665
|
+
level: DeploymentResourceValidationErrorLevelFromJSON(json["level"]),
|
|
666
|
+
propertyName: json["propertyName"] == null ? undefined : json["propertyName"],
|
|
667
|
+
allowedActions: json["allowedActions"].map(DeploymentResourceValidationActionFromJSON)
|
|
668
|
+
};
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
// ../solution-sdk/generated/src/models/ResourceValidationDto.ts
|
|
672
|
+
function ResourceValidationDtoFromJSON(json) {
|
|
673
|
+
return ResourceValidationDtoFromJSONTyped(json, false);
|
|
674
|
+
}
|
|
675
|
+
function ResourceValidationDtoFromJSONTyped(json, ignoreDiscriminator) {
|
|
676
|
+
if (json == null) {
|
|
677
|
+
return json;
|
|
678
|
+
}
|
|
679
|
+
return {
|
|
680
|
+
key: json["key"],
|
|
681
|
+
name: json["name"],
|
|
682
|
+
kind: json["kind"],
|
|
683
|
+
serviceName: json["serviceName"],
|
|
684
|
+
type: json["type"] == null ? undefined : json["type"],
|
|
685
|
+
errors: json["errors"].map(ResourceValidationErrorFromJSON)
|
|
686
|
+
};
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
// ../solution-sdk/generated/src/models/DeploymentValidationResultDto.ts
|
|
690
|
+
function DeploymentValidationResultDtoFromJSON(json) {
|
|
691
|
+
return DeploymentValidationResultDtoFromJSONTyped(json, false);
|
|
692
|
+
}
|
|
693
|
+
function DeploymentValidationResultDtoFromJSONTyped(json, ignoreDiscriminator) {
|
|
694
|
+
if (json == null) {
|
|
695
|
+
return json;
|
|
696
|
+
}
|
|
697
|
+
return {
|
|
698
|
+
success: json["success"] == null ? undefined : json["success"],
|
|
699
|
+
validationErrors: json["validationErrors"].map(ServiceMessageFromJSON),
|
|
700
|
+
resourceValidationErrors: json["resourceValidationErrors"].map(ResourceValidationDtoFromJSON)
|
|
701
|
+
};
|
|
702
|
+
}
|
|
590
703
|
// ../solution-sdk/generated/src/models/OrderByDirection.ts
|
|
591
704
|
function OrderByDirectionToJSON(value) {
|
|
592
705
|
return value;
|
|
@@ -787,6 +900,203 @@ function SearchFilterToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
787
900
|
searchTerm: value["searchTerm"]
|
|
788
901
|
};
|
|
789
902
|
}
|
|
903
|
+
// ../solution-sdk/generated/src/apis/DeploymentsApi.ts
|
|
904
|
+
class DeploymentsApi extends BaseAPI {
|
|
905
|
+
async deploymentsDeployRaw(requestParameters, initOverrides) {
|
|
906
|
+
if (requestParameters["deploymentAutoRequest"] == null) {
|
|
907
|
+
throw new RequiredError("deploymentAutoRequest", 'Required parameter "deploymentAutoRequest" was null or undefined when calling deploymentsDeploy().');
|
|
908
|
+
}
|
|
909
|
+
const queryParameters = {};
|
|
910
|
+
const headerParameters = {};
|
|
911
|
+
headerParameters["Content-Type"] = "application/json";
|
|
912
|
+
if (requestParameters["xUIPATHFolderKey"] != null) {
|
|
913
|
+
headerParameters["X-UIPATH-FolderKey"] = String(requestParameters["xUIPATHFolderKey"]);
|
|
914
|
+
}
|
|
915
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
916
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
917
|
+
}
|
|
918
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
919
|
+
const token = this.configuration.accessToken;
|
|
920
|
+
const tokenString = await token("Bearer", []);
|
|
921
|
+
if (tokenString) {
|
|
922
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
let urlPath = `/api/deployments/deploy`;
|
|
926
|
+
const response = await this.request({
|
|
927
|
+
path: urlPath,
|
|
928
|
+
method: "POST",
|
|
929
|
+
headers: headerParameters,
|
|
930
|
+
query: queryParameters,
|
|
931
|
+
body: DeploymentAutoRequestToJSON(requestParameters["deploymentAutoRequest"])
|
|
932
|
+
}, initOverrides);
|
|
933
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentDtoFromJSON(jsonValue));
|
|
934
|
+
}
|
|
935
|
+
async deploymentsDeploy(requestParameters, initOverrides) {
|
|
936
|
+
const response = await this.deploymentsDeployRaw(requestParameters, initOverrides);
|
|
937
|
+
return await response.value();
|
|
938
|
+
}
|
|
939
|
+
async deploymentsGetByKeyRaw(requestParameters, initOverrides) {
|
|
940
|
+
if (requestParameters["deploymentKey"] == null) {
|
|
941
|
+
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsGetByKey().');
|
|
942
|
+
}
|
|
943
|
+
const queryParameters = {};
|
|
944
|
+
const headerParameters = {};
|
|
945
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
946
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
947
|
+
}
|
|
948
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
949
|
+
const token = this.configuration.accessToken;
|
|
950
|
+
const tokenString = await token("Bearer", []);
|
|
951
|
+
if (tokenString) {
|
|
952
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
953
|
+
}
|
|
954
|
+
}
|
|
955
|
+
let urlPath = `/api/deployments/{deploymentKey}`;
|
|
956
|
+
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
957
|
+
const response = await this.request({
|
|
958
|
+
path: urlPath,
|
|
959
|
+
method: "GET",
|
|
960
|
+
headers: headerParameters,
|
|
961
|
+
query: queryParameters
|
|
962
|
+
}, initOverrides);
|
|
963
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
964
|
+
}
|
|
965
|
+
async deploymentsGetByKey(requestParameters, initOverrides) {
|
|
966
|
+
const response = await this.deploymentsGetByKeyRaw(requestParameters, initOverrides);
|
|
967
|
+
return await response.value();
|
|
968
|
+
}
|
|
969
|
+
async deploymentsGetValidationResultRaw(requestParameters, initOverrides) {
|
|
970
|
+
if (requestParameters["deploymentKey"] == null) {
|
|
971
|
+
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsGetValidationResult().');
|
|
972
|
+
}
|
|
973
|
+
const queryParameters = {};
|
|
974
|
+
if (requestParameters["deploymentAction"] != null) {
|
|
975
|
+
queryParameters["deploymentAction"] = requestParameters["deploymentAction"];
|
|
976
|
+
}
|
|
977
|
+
const headerParameters = {};
|
|
978
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
979
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
980
|
+
}
|
|
981
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
982
|
+
const token = this.configuration.accessToken;
|
|
983
|
+
const tokenString = await token("Bearer", []);
|
|
984
|
+
if (tokenString) {
|
|
985
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
986
|
+
}
|
|
987
|
+
}
|
|
988
|
+
let urlPath = `/api/deployments/{deploymentKey}/validation-result`;
|
|
989
|
+
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
990
|
+
const response = await this.request({
|
|
991
|
+
path: urlPath,
|
|
992
|
+
method: "GET",
|
|
993
|
+
headers: headerParameters,
|
|
994
|
+
query: queryParameters
|
|
995
|
+
}, initOverrides);
|
|
996
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentValidationResultDtoFromJSON(jsonValue));
|
|
997
|
+
}
|
|
998
|
+
async deploymentsGetValidationResult(requestParameters, initOverrides) {
|
|
999
|
+
const response = await this.deploymentsGetValidationResultRaw(requestParameters, initOverrides);
|
|
1000
|
+
return await response.value();
|
|
1001
|
+
}
|
|
1002
|
+
async deploymentsPostRaw(requestParameters, initOverrides) {
|
|
1003
|
+
if (requestParameters["deploymentRequest"] == null) {
|
|
1004
|
+
throw new RequiredError("deploymentRequest", 'Required parameter "deploymentRequest" was null or undefined when calling deploymentsPost().');
|
|
1005
|
+
}
|
|
1006
|
+
const queryParameters = {};
|
|
1007
|
+
const headerParameters = {};
|
|
1008
|
+
headerParameters["Content-Type"] = "application/json";
|
|
1009
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
1010
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
1011
|
+
}
|
|
1012
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
1013
|
+
const token = this.configuration.accessToken;
|
|
1014
|
+
const tokenString = await token("Bearer", []);
|
|
1015
|
+
if (tokenString) {
|
|
1016
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
let urlPath = `/api/deployments`;
|
|
1020
|
+
const response = await this.request({
|
|
1021
|
+
path: urlPath,
|
|
1022
|
+
method: "POST",
|
|
1023
|
+
headers: headerParameters,
|
|
1024
|
+
query: queryParameters,
|
|
1025
|
+
body: DeploymentRequestToJSON(requestParameters["deploymentRequest"])
|
|
1026
|
+
}, initOverrides);
|
|
1027
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
1028
|
+
}
|
|
1029
|
+
async deploymentsPost(requestParameters, initOverrides) {
|
|
1030
|
+
const response = await this.deploymentsPostRaw(requestParameters, initOverrides);
|
|
1031
|
+
return await response.value();
|
|
1032
|
+
}
|
|
1033
|
+
async deploymentsRunRaw(requestParameters, initOverrides) {
|
|
1034
|
+
if (requestParameters["deploymentKey"] == null) {
|
|
1035
|
+
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsRun().');
|
|
1036
|
+
}
|
|
1037
|
+
const queryParameters = {};
|
|
1038
|
+
const headerParameters = {};
|
|
1039
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
1040
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
1041
|
+
}
|
|
1042
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
1043
|
+
const token = this.configuration.accessToken;
|
|
1044
|
+
const tokenString = await token("Bearer", []);
|
|
1045
|
+
if (tokenString) {
|
|
1046
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
1047
|
+
}
|
|
1048
|
+
}
|
|
1049
|
+
let urlPath = `/api/deployments/{deploymentKey}/run`;
|
|
1050
|
+
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
1051
|
+
const response = await this.request({
|
|
1052
|
+
path: urlPath,
|
|
1053
|
+
method: "POST",
|
|
1054
|
+
headers: headerParameters,
|
|
1055
|
+
query: queryParameters
|
|
1056
|
+
}, initOverrides);
|
|
1057
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentRunResponseFromJSON(jsonValue));
|
|
1058
|
+
}
|
|
1059
|
+
async deploymentsRun(requestParameters, initOverrides) {
|
|
1060
|
+
const response = await this.deploymentsRunRaw(requestParameters, initOverrides);
|
|
1061
|
+
return await response.value();
|
|
1062
|
+
}
|
|
1063
|
+
async deploymentsUpgradeRaw(requestParameters, initOverrides) {
|
|
1064
|
+
if (requestParameters["deploymentKey"] == null) {
|
|
1065
|
+
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsUpgrade().');
|
|
1066
|
+
}
|
|
1067
|
+
const queryParameters = {};
|
|
1068
|
+
if (requestParameters["packageVersionKey"] != null) {
|
|
1069
|
+
queryParameters["packageVersionKey"] = requestParameters["packageVersionKey"];
|
|
1070
|
+
}
|
|
1071
|
+
const headerParameters = {};
|
|
1072
|
+
headerParameters["Content-Type"] = "application/json";
|
|
1073
|
+
if (requestParameters["xUipathAsVersion"] != null) {
|
|
1074
|
+
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
1075
|
+
}
|
|
1076
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
1077
|
+
const token = this.configuration.accessToken;
|
|
1078
|
+
const tokenString = await token("Bearer", []);
|
|
1079
|
+
if (tokenString) {
|
|
1080
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
1081
|
+
}
|
|
1082
|
+
}
|
|
1083
|
+
let urlPath = `/api/deployments/{deploymentKey}/upgrade`;
|
|
1084
|
+
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
1085
|
+
const response = await this.request({
|
|
1086
|
+
path: urlPath,
|
|
1087
|
+
method: "POST",
|
|
1088
|
+
headers: headerParameters,
|
|
1089
|
+
query: queryParameters,
|
|
1090
|
+
body: DeploymentUpgradeRequestToJSON(requestParameters["deploymentUpgradeRequest"])
|
|
1091
|
+
}, initOverrides);
|
|
1092
|
+
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
1093
|
+
}
|
|
1094
|
+
async deploymentsUpgrade(requestParameters, initOverrides) {
|
|
1095
|
+
const response = await this.deploymentsUpgradeRaw(requestParameters, initOverrides);
|
|
1096
|
+
return await response.value();
|
|
1097
|
+
}
|
|
1098
|
+
}
|
|
1099
|
+
|
|
790
1100
|
// ../solution-sdk/generated/src/apis/PackagesApi.ts
|
|
791
1101
|
class PackagesApi extends BaseAPI {
|
|
792
1102
|
async packagesDeletePackageRaw(requestParameters, initOverrides) {
|
|
@@ -1066,12 +1376,31 @@ class SearchApi extends BaseAPI {
|
|
|
1066
1376
|
}
|
|
1067
1377
|
}
|
|
1068
1378
|
|
|
1379
|
+
// ../solution-sdk/src/studio-web-compat.ts
|
|
1380
|
+
var API_PROJECT_TYPES = new Set(["api", "apiautomation"]);
|
|
1381
|
+
|
|
1382
|
+
class StudioWebIncompatibleProjectError extends Error {
|
|
1383
|
+
offendingProjects;
|
|
1384
|
+
constructor(offendingProjects) {
|
|
1385
|
+
super(`Studio Web cannot import API Workflow project(s) manifested by project.json: ${offendingProjects.join(", ")}. Studio Web's solution import accepts only project.uiproj-manifested projects.`);
|
|
1386
|
+
this.offendingProjects = offendingProjects;
|
|
1387
|
+
this.name = "StudioWebIncompatibleProjectError";
|
|
1388
|
+
}
|
|
1389
|
+
}
|
|
1390
|
+
function assertStudioWebCompatibleProjects(projects) {
|
|
1391
|
+
const incompatible = projects.filter((p) => typeof p.Type === "string" && API_PROJECT_TYPES.has(p.Type.toLowerCase()) && p.ProjectRelativePath.replace(/\\/g, "/").split("/").pop() === "project.json");
|
|
1392
|
+
if (incompatible.length > 0) {
|
|
1393
|
+
throw new StudioWebIncompatibleProjectError(incompatible.map((p) => p.ProjectRelativePath));
|
|
1394
|
+
}
|
|
1395
|
+
}
|
|
1396
|
+
|
|
1069
1397
|
// ../solution-sdk/src/zip-utils.ts
|
|
1070
1398
|
var DEFAULT_EXCLUDED_DIR_NAMES = new Set([
|
|
1071
1399
|
".venv",
|
|
1072
1400
|
"node_modules",
|
|
1073
1401
|
"__pycache__",
|
|
1074
|
-
".git"
|
|
1402
|
+
".git",
|
|
1403
|
+
".local"
|
|
1075
1404
|
]);
|
|
1076
1405
|
var DEFAULT_EXCLUDED_FILE_PATTERNS = [
|
|
1077
1406
|
/^\.env($|\..+)/
|
|
@@ -1152,7 +1481,76 @@ async function createZipFromDir(fs, dir, options = {}) {
|
|
|
1152
1481
|
}
|
|
1153
1482
|
zippable[`${relPath}/`] = new Uint8Array(0);
|
|
1154
1483
|
}
|
|
1155
|
-
return zipSync(zippable, { level: 6 });
|
|
1484
|
+
return finalizeZip64(zipSync(zippable, { level: 6 }));
|
|
1485
|
+
}
|
|
1486
|
+
var EOCD_SIZE = 22;
|
|
1487
|
+
var EOCD_SIGNATURE = 101010256;
|
|
1488
|
+
var CD_HEADER_SIGNATURE = 33639248;
|
|
1489
|
+
var ZIP64_EOCD_SIGNATURE = 101075792;
|
|
1490
|
+
var ZIP64_EOCD_SIZE = 56;
|
|
1491
|
+
var ZIP64_LOCATOR_SIGNATURE = 117853008;
|
|
1492
|
+
var ZIP64_LOCATOR_SIZE = 20;
|
|
1493
|
+
var MAX_ZIP32_ENTRIES = 65535;
|
|
1494
|
+
var MAX_ZIP32_OFFSET = 4294967295;
|
|
1495
|
+
function finalizeZip64(zip) {
|
|
1496
|
+
const view = new DataView(zip.buffer, zip.byteOffset, zip.byteLength);
|
|
1497
|
+
const eocdStart = zip.byteLength - EOCD_SIZE;
|
|
1498
|
+
if (eocdStart < 0 || view.getUint32(eocdStart, true) !== EOCD_SIGNATURE) {
|
|
1499
|
+
throw new Error("Cannot finalize the solution archive: it does not end with an end-of-central-directory record.");
|
|
1500
|
+
}
|
|
1501
|
+
const cdSize = view.getUint32(eocdStart + 12, true);
|
|
1502
|
+
const cdOffset = view.getUint32(eocdStart + 16, true);
|
|
1503
|
+
const entryCount = countCentralDirectoryEntries(view, cdOffset, cdSize);
|
|
1504
|
+
if (entryCount <= MAX_ZIP32_ENTRIES) {
|
|
1505
|
+
return zip;
|
|
1506
|
+
}
|
|
1507
|
+
if (cdOffset >= MAX_ZIP32_OFFSET || zip.byteLength >= MAX_ZIP32_OFFSET) {
|
|
1508
|
+
throw new Error(`The solution archive is ${zip.byteLength} bytes, past the 4 GB limit this packer supports. Exclude large directories from the solution with a .uipignore file.`);
|
|
1509
|
+
}
|
|
1510
|
+
const tail = new Uint8Array(ZIP64_EOCD_SIZE + ZIP64_LOCATOR_SIZE + EOCD_SIZE);
|
|
1511
|
+
const tailView = new DataView(tail.buffer);
|
|
1512
|
+
const count = BigInt(entryCount);
|
|
1513
|
+
tailView.setUint32(0, ZIP64_EOCD_SIGNATURE, true);
|
|
1514
|
+
tailView.setBigUint64(4, BigInt(ZIP64_EOCD_SIZE - 12), true);
|
|
1515
|
+
tailView.setUint16(12, 45, true);
|
|
1516
|
+
tailView.setUint16(14, 45, true);
|
|
1517
|
+
tailView.setUint32(16, 0, true);
|
|
1518
|
+
tailView.setUint32(20, 0, true);
|
|
1519
|
+
tailView.setBigUint64(24, count, true);
|
|
1520
|
+
tailView.setBigUint64(32, count, true);
|
|
1521
|
+
tailView.setBigUint64(40, BigInt(cdSize), true);
|
|
1522
|
+
tailView.setBigUint64(48, BigInt(cdOffset), true);
|
|
1523
|
+
const locator = ZIP64_EOCD_SIZE;
|
|
1524
|
+
tailView.setUint32(locator, ZIP64_LOCATOR_SIGNATURE, true);
|
|
1525
|
+
tailView.setUint32(locator + 4, 0, true);
|
|
1526
|
+
tailView.setBigUint64(locator + 8, BigInt(eocdStart), true);
|
|
1527
|
+
tailView.setUint32(locator + 16, 1, true);
|
|
1528
|
+
const eocd = ZIP64_EOCD_SIZE + ZIP64_LOCATOR_SIZE;
|
|
1529
|
+
tailView.setUint32(eocd, EOCD_SIGNATURE, true);
|
|
1530
|
+
tailView.setUint16(eocd + 4, 0, true);
|
|
1531
|
+
tailView.setUint16(eocd + 6, 0, true);
|
|
1532
|
+
tailView.setUint16(eocd + 8, MAX_ZIP32_ENTRIES, true);
|
|
1533
|
+
tailView.setUint16(eocd + 10, MAX_ZIP32_ENTRIES, true);
|
|
1534
|
+
tailView.setUint32(eocd + 12, cdSize, true);
|
|
1535
|
+
tailView.setUint32(eocd + 16, cdOffset, true);
|
|
1536
|
+
tailView.setUint16(eocd + 20, 0, true);
|
|
1537
|
+
const out = new Uint8Array(eocdStart + tail.byteLength);
|
|
1538
|
+
out.set(zip.subarray(0, eocdStart), 0);
|
|
1539
|
+
out.set(tail, eocdStart);
|
|
1540
|
+
return out;
|
|
1541
|
+
}
|
|
1542
|
+
function countCentralDirectoryEntries(view, cdOffset, cdSize) {
|
|
1543
|
+
const end = cdOffset + cdSize;
|
|
1544
|
+
let position = cdOffset;
|
|
1545
|
+
let count = 0;
|
|
1546
|
+
while (position + 46 <= end && view.getUint32(position, true) === CD_HEADER_SIGNATURE) {
|
|
1547
|
+
const nameLength = view.getUint16(position + 28, true);
|
|
1548
|
+
const extraLength = view.getUint16(position + 30, true);
|
|
1549
|
+
const commentLength = view.getUint16(position + 32, true);
|
|
1550
|
+
position += 46 + nameLength + extraLength + commentLength;
|
|
1551
|
+
count++;
|
|
1552
|
+
}
|
|
1553
|
+
return count;
|
|
1156
1554
|
}
|
|
1157
1555
|
|
|
1158
1556
|
// ../solution-sdk/src/bundle-service.ts
|
|
@@ -1270,6 +1668,7 @@ async function bundleSolution(fs, solutionDir, outputDir, outputName) {
|
|
|
1270
1668
|
for (const project of uipx.Projects) {
|
|
1271
1669
|
project.ProjectRelativePath = toForwardSlash(project.ProjectRelativePath);
|
|
1272
1670
|
}
|
|
1671
|
+
assertStudioWebCompatibleProjects(uipx.Projects);
|
|
1273
1672
|
const solutionStorage = {
|
|
1274
1673
|
SolutionId: uipx.SolutionId,
|
|
1275
1674
|
Projects: uipx.Projects.map((p) => ({
|
|
@@ -2704,7 +3103,7 @@ async function listStudioWebSolutions(config, organizationName, options = {}) {
|
|
|
2704
3103
|
var package_default = {
|
|
2705
3104
|
name: "@uipath/solution-sdk",
|
|
2706
3105
|
license: "MIT",
|
|
2707
|
-
version: "1.
|
|
3106
|
+
version: "1.202.0-preview.134",
|
|
2708
3107
|
repository: {
|
|
2709
3108
|
type: "git",
|
|
2710
3109
|
url: "https://github.com/UiPath/cli.git",
|
|
@@ -2776,6 +3175,49 @@ class HttpError extends Error {
|
|
|
2776
3175
|
this.status = status;
|
|
2777
3176
|
}
|
|
2778
3177
|
}
|
|
3178
|
+
|
|
3179
|
+
class SolutionUploadHttpError extends Error {
|
|
3180
|
+
status;
|
|
3181
|
+
operation;
|
|
3182
|
+
method;
|
|
3183
|
+
endpoint;
|
|
3184
|
+
url;
|
|
3185
|
+
body;
|
|
3186
|
+
solutionId;
|
|
3187
|
+
parsedErrorCode;
|
|
3188
|
+
parsedErrorMessage;
|
|
3189
|
+
constructor(details) {
|
|
3190
|
+
super(details.message);
|
|
3191
|
+
this.name = "SolutionUploadHttpError";
|
|
3192
|
+
this.status = details.status;
|
|
3193
|
+
this.operation = details.operation;
|
|
3194
|
+
this.method = details.method;
|
|
3195
|
+
this.endpoint = details.endpoint;
|
|
3196
|
+
this.url = details.url;
|
|
3197
|
+
this.body = details.body;
|
|
3198
|
+
if (details.operation === "overwrite") {
|
|
3199
|
+
this.solutionId = details.solutionId;
|
|
3200
|
+
}
|
|
3201
|
+
const parsed = parseUploadErrorBody(details.body);
|
|
3202
|
+
this.parsedErrorCode = parsed.code;
|
|
3203
|
+
this.parsedErrorMessage = parsed.message;
|
|
3204
|
+
}
|
|
3205
|
+
}
|
|
3206
|
+
function parseUploadErrorBody(body) {
|
|
3207
|
+
const [, parsed] = catchError(() => JSON.parse(body));
|
|
3208
|
+
if (!parsed || typeof parsed !== "object")
|
|
3209
|
+
return {};
|
|
3210
|
+
const rawCode = parsed.code ?? parsed.Code;
|
|
3211
|
+
const rawMessage = parsed.message ?? parsed.Message;
|
|
3212
|
+
return {
|
|
3213
|
+
code: typeof rawCode === "string" || typeof rawCode === "number" ? String(rawCode) : undefined,
|
|
3214
|
+
message: typeof rawMessage === "string" && rawMessage.trim() ? rawMessage : undefined
|
|
3215
|
+
};
|
|
3216
|
+
}
|
|
3217
|
+
function requestPath(url) {
|
|
3218
|
+
const [, parsed] = catchError(() => new URL(url));
|
|
3219
|
+
return parsed ? `${parsed.pathname}${parsed.search}` : url;
|
|
3220
|
+
}
|
|
2779
3221
|
var DEFAULT_UPLOAD_TIMEOUT_MS = 120000;
|
|
2780
3222
|
function resolveUploadTimeoutMs() {
|
|
2781
3223
|
const raw = Number(process.env?.UIPATH_SOLUTION_UPLOAD_TIMEOUT_MS);
|
|
@@ -2828,7 +3270,7 @@ async function solutionExistsOnStudioWeb(config, organizationName, solutionId) {
|
|
|
2828
3270
|
}
|
|
2829
3271
|
}
|
|
2830
3272
|
async function importSolution(config, organizationName, fileBuffer, fileName) {
|
|
2831
|
-
const importUrl = `${config.baseUrl}/${organizationName}/studio_/backend/api/Solution/Import?desktopJit=true&useFileRest=true&enableUnifiedBuild=true`;
|
|
3273
|
+
const importUrl = `${config.baseUrl}/${encodeURIComponent(organizationName)}/studio_/backend/api/Solution/Import?desktopJit=true&useFileRest=true&enableUnifiedBuild=true`;
|
|
2832
3274
|
const formData = new FormData;
|
|
2833
3275
|
const fileBlob = new Blob([fileBuffer], {
|
|
2834
3276
|
type: "application/octet-stream"
|
|
@@ -2843,18 +3285,29 @@ async function importSolution(config, organizationName, fileBuffer, fileName) {
|
|
|
2843
3285
|
}
|
|
2844
3286
|
const response = await fetchWithUploadTimeout(importUrl, { method: "POST", headers, body: formData }, "Studio Web solution import");
|
|
2845
3287
|
if (!response.ok) {
|
|
2846
|
-
const text = await response.text();
|
|
2847
|
-
throw new
|
|
3288
|
+
const text = await response.text().catch(() => "");
|
|
3289
|
+
throw new SolutionUploadHttpError({
|
|
3290
|
+
operation: "import",
|
|
3291
|
+
status: response.status,
|
|
3292
|
+
method: "POST",
|
|
3293
|
+
endpoint: requestPath(importUrl),
|
|
3294
|
+
url: importUrl,
|
|
3295
|
+
body: text,
|
|
3296
|
+
message: `Import failed (${response.status}): ${text}`
|
|
3297
|
+
});
|
|
2848
3298
|
}
|
|
2849
3299
|
return await response.json();
|
|
2850
3300
|
}
|
|
2851
|
-
async function overwriteSolution(config, organizationName, fileBuffer, fileName, solutionId) {
|
|
2852
|
-
const overwriteUrl = `${config.baseUrl}/${organizationName}/studio_/backend/api/Solution/${solutionId}/Overwrite`;
|
|
3301
|
+
async function overwriteSolution(config, organizationName, fileBuffer, fileName, solutionId, createSnapshot = false) {
|
|
3302
|
+
const overwriteUrl = `${config.baseUrl}/${encodeURIComponent(organizationName)}/studio_/backend/api/Solution/${encodeURIComponent(solutionId)}/Overwrite`;
|
|
2853
3303
|
const formData = new FormData;
|
|
2854
3304
|
const fileBlob = new Blob([fileBuffer], {
|
|
2855
3305
|
type: "application/octet-stream"
|
|
2856
3306
|
});
|
|
2857
3307
|
formData.append("UploadFile", fileBlob, fileName);
|
|
3308
|
+
if (createSnapshot) {
|
|
3309
|
+
formData.append("createSnapshot", "true");
|
|
3310
|
+
}
|
|
2858
3311
|
const headers = addSdkUserAgentHeader({
|
|
2859
3312
|
Authorization: `Bearer ${config.authToken}`
|
|
2860
3313
|
}, SDK_USER_AGENT);
|
|
@@ -2863,176 +3316,19 @@ async function overwriteSolution(config, organizationName, fileBuffer, fileName,
|
|
|
2863
3316
|
}
|
|
2864
3317
|
const response = await fetchWithUploadTimeout(overwriteUrl, { method: "POST", headers, body: formData }, "Studio Web solution overwrite");
|
|
2865
3318
|
if (!response.ok) {
|
|
2866
|
-
const text = await response.text();
|
|
2867
|
-
throw new
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
}
|
|
2871
|
-
async function uploadOrOverwriteSolution(config, organizationName, fileBufferOrPath, solutionId, fs) {
|
|
2872
|
-
let fileBuffer;
|
|
2873
|
-
let fileName;
|
|
2874
|
-
if (typeof fileBufferOrPath === "string") {
|
|
2875
|
-
if (!fs) {
|
|
2876
|
-
throw new Error("IFileSystem is required when passing a file path to uploadOrOverwriteSolution");
|
|
2877
|
-
}
|
|
2878
|
-
const content = await fs.readFile(fileBufferOrPath);
|
|
2879
|
-
if (content === null) {
|
|
2880
|
-
throw new Error(`Failed to read file: ${fileBufferOrPath}`);
|
|
2881
|
-
}
|
|
2882
|
-
fileBuffer = new Uint8Array(content);
|
|
2883
|
-
fileName = fs.path.basename(fileBufferOrPath);
|
|
2884
|
-
} else {
|
|
2885
|
-
fileBuffer = fileBufferOrPath;
|
|
2886
|
-
fileName = "solution.uis";
|
|
2887
|
-
}
|
|
2888
|
-
if (solutionId) {
|
|
2889
|
-
logger.info(`Attempting to overwrite existing solution ${solutionId} on Studio Web...`);
|
|
2890
|
-
const [overwriteError, overwriteResult] = await catchError(overwriteSolution(config, organizationName, fileBuffer, fileName, solutionId));
|
|
2891
|
-
if (!overwriteError) {
|
|
2892
|
-
logger.info("Solution overwritten successfully.");
|
|
2893
|
-
return overwriteResult;
|
|
2894
|
-
}
|
|
2895
|
-
if (overwriteError instanceof HttpError && overwriteError.status === 404) {
|
|
2896
|
-
logger.info(`Solution ${solutionId} not found on Studio Web. Importing as new solution...`);
|
|
2897
|
-
} else {
|
|
2898
|
-
throw overwriteError;
|
|
2899
|
-
}
|
|
2900
|
-
}
|
|
2901
|
-
logger.info("Importing new solution to Studio Web...");
|
|
2902
|
-
return importSolution(config, organizationName, fileBuffer, fileName);
|
|
2903
|
-
}
|
|
2904
|
-
// ../solution-sdk/generated/src/apis/DeploymentsApi.ts
|
|
2905
|
-
class DeploymentsApi extends BaseAPI {
|
|
2906
|
-
async deploymentsDeployRaw(requestParameters, initOverrides) {
|
|
2907
|
-
if (requestParameters["deploymentAutoRequest"] == null) {
|
|
2908
|
-
throw new RequiredError("deploymentAutoRequest", 'Required parameter "deploymentAutoRequest" was null or undefined when calling deploymentsDeploy().');
|
|
2909
|
-
}
|
|
2910
|
-
const queryParameters = {};
|
|
2911
|
-
const headerParameters = {};
|
|
2912
|
-
headerParameters["Content-Type"] = "application/json";
|
|
2913
|
-
if (requestParameters["xUIPATHFolderKey"] != null) {
|
|
2914
|
-
headerParameters["X-UIPATH-FolderKey"] = String(requestParameters["xUIPATHFolderKey"]);
|
|
2915
|
-
}
|
|
2916
|
-
if (requestParameters["xUipathAsVersion"] != null) {
|
|
2917
|
-
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
2918
|
-
}
|
|
2919
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
2920
|
-
const token = this.configuration.accessToken;
|
|
2921
|
-
const tokenString = await token("Bearer", []);
|
|
2922
|
-
if (tokenString) {
|
|
2923
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
2924
|
-
}
|
|
2925
|
-
}
|
|
2926
|
-
let urlPath = `/api/deployments/deploy`;
|
|
2927
|
-
const response = await this.request({
|
|
2928
|
-
path: urlPath,
|
|
3319
|
+
const text = await response.text().catch(() => "");
|
|
3320
|
+
throw new SolutionUploadHttpError({
|
|
3321
|
+
operation: "overwrite",
|
|
3322
|
+
status: response.status,
|
|
2929
3323
|
method: "POST",
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
body:
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
async deploymentsDeploy(requestParameters, initOverrides) {
|
|
2937
|
-
const response = await this.deploymentsDeployRaw(requestParameters, initOverrides);
|
|
2938
|
-
return await response.value();
|
|
2939
|
-
}
|
|
2940
|
-
async deploymentsGetByKeyRaw(requestParameters, initOverrides) {
|
|
2941
|
-
if (requestParameters["deploymentKey"] == null) {
|
|
2942
|
-
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsGetByKey().');
|
|
2943
|
-
}
|
|
2944
|
-
const queryParameters = {};
|
|
2945
|
-
const headerParameters = {};
|
|
2946
|
-
if (requestParameters["xUipathAsVersion"] != null) {
|
|
2947
|
-
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
2948
|
-
}
|
|
2949
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
2950
|
-
const token = this.configuration.accessToken;
|
|
2951
|
-
const tokenString = await token("Bearer", []);
|
|
2952
|
-
if (tokenString) {
|
|
2953
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
2954
|
-
}
|
|
2955
|
-
}
|
|
2956
|
-
let urlPath = `/api/deployments/{deploymentKey}`;
|
|
2957
|
-
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
2958
|
-
const response = await this.request({
|
|
2959
|
-
path: urlPath,
|
|
2960
|
-
method: "GET",
|
|
2961
|
-
headers: headerParameters,
|
|
2962
|
-
query: queryParameters
|
|
2963
|
-
}, initOverrides);
|
|
2964
|
-
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
2965
|
-
}
|
|
2966
|
-
async deploymentsGetByKey(requestParameters, initOverrides) {
|
|
2967
|
-
const response = await this.deploymentsGetByKeyRaw(requestParameters, initOverrides);
|
|
2968
|
-
return await response.value();
|
|
2969
|
-
}
|
|
2970
|
-
async deploymentsPostRaw(requestParameters, initOverrides) {
|
|
2971
|
-
if (requestParameters["deploymentRequest"] == null) {
|
|
2972
|
-
throw new RequiredError("deploymentRequest", 'Required parameter "deploymentRequest" was null or undefined when calling deploymentsPost().');
|
|
2973
|
-
}
|
|
2974
|
-
const queryParameters = {};
|
|
2975
|
-
const headerParameters = {};
|
|
2976
|
-
headerParameters["Content-Type"] = "application/json";
|
|
2977
|
-
if (requestParameters["xUipathAsVersion"] != null) {
|
|
2978
|
-
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
2979
|
-
}
|
|
2980
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
2981
|
-
const token = this.configuration.accessToken;
|
|
2982
|
-
const tokenString = await token("Bearer", []);
|
|
2983
|
-
if (tokenString) {
|
|
2984
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
2985
|
-
}
|
|
2986
|
-
}
|
|
2987
|
-
let urlPath = `/api/deployments`;
|
|
2988
|
-
const response = await this.request({
|
|
2989
|
-
path: urlPath,
|
|
2990
|
-
method: "POST",
|
|
2991
|
-
headers: headerParameters,
|
|
2992
|
-
query: queryParameters,
|
|
2993
|
-
body: DeploymentRequestToJSON(requestParameters["deploymentRequest"])
|
|
2994
|
-
}, initOverrides);
|
|
2995
|
-
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
2996
|
-
}
|
|
2997
|
-
async deploymentsPost(requestParameters, initOverrides) {
|
|
2998
|
-
const response = await this.deploymentsPostRaw(requestParameters, initOverrides);
|
|
2999
|
-
return await response.value();
|
|
3000
|
-
}
|
|
3001
|
-
async deploymentsUpgradeRaw(requestParameters, initOverrides) {
|
|
3002
|
-
if (requestParameters["deploymentKey"] == null) {
|
|
3003
|
-
throw new RequiredError("deploymentKey", 'Required parameter "deploymentKey" was null or undefined when calling deploymentsUpgrade().');
|
|
3004
|
-
}
|
|
3005
|
-
const queryParameters = {};
|
|
3006
|
-
if (requestParameters["packageVersionKey"] != null) {
|
|
3007
|
-
queryParameters["packageVersionKey"] = requestParameters["packageVersionKey"];
|
|
3008
|
-
}
|
|
3009
|
-
const headerParameters = {};
|
|
3010
|
-
headerParameters["Content-Type"] = "application/json";
|
|
3011
|
-
if (requestParameters["xUipathAsVersion"] != null) {
|
|
3012
|
-
headerParameters["x-uipath-as-version"] = String(requestParameters["xUipathAsVersion"]);
|
|
3013
|
-
}
|
|
3014
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
3015
|
-
const token = this.configuration.accessToken;
|
|
3016
|
-
const tokenString = await token("Bearer", []);
|
|
3017
|
-
if (tokenString) {
|
|
3018
|
-
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
3019
|
-
}
|
|
3020
|
-
}
|
|
3021
|
-
let urlPath = `/api/deployments/{deploymentKey}/upgrade`;
|
|
3022
|
-
urlPath = urlPath.replace(`{${"deploymentKey"}}`, encodeURIComponent(String(requestParameters["deploymentKey"])));
|
|
3023
|
-
const response = await this.request({
|
|
3024
|
-
path: urlPath,
|
|
3025
|
-
method: "POST",
|
|
3026
|
-
headers: headerParameters,
|
|
3027
|
-
query: queryParameters,
|
|
3028
|
-
body: DeploymentUpgradeRequestToJSON(requestParameters["deploymentUpgradeRequest"])
|
|
3029
|
-
}, initOverrides);
|
|
3030
|
-
return new JSONApiResponse(response, (jsonValue) => DeploymentItemDtoFromJSON(jsonValue));
|
|
3031
|
-
}
|
|
3032
|
-
async deploymentsUpgrade(requestParameters, initOverrides) {
|
|
3033
|
-
const response = await this.deploymentsUpgradeRaw(requestParameters, initOverrides);
|
|
3034
|
-
return await response.value();
|
|
3324
|
+
endpoint: requestPath(overwriteUrl),
|
|
3325
|
+
url: overwriteUrl,
|
|
3326
|
+
body: text,
|
|
3327
|
+
message: `Overwrite failed (${response.status}): ${text}`,
|
|
3328
|
+
solutionId
|
|
3329
|
+
});
|
|
3035
3330
|
}
|
|
3331
|
+
return await response.json();
|
|
3036
3332
|
}
|
|
3037
3333
|
// ../solution-sdk/src/deployments-auto-install.ts
|
|
3038
3334
|
async function deploymentsAutoInstall(config, request, feedFolderKey) {
|
|
@@ -3096,6 +3392,6 @@ async function searchPackageVersions(config, packageKey, filter, feedFolderKey)
|
|
|
3096
3392
|
const raw = await response.json();
|
|
3097
3393
|
return { count: raw.count, values: raw.values ?? [] };
|
|
3098
3394
|
}
|
|
3099
|
-
export { Configuration, getAvailablePublishLocationsV2, DeploymentActivationStatus, DeploymentOperationStatus, DeploymentsApi, PackagesApi, SearchApi, bundleSolution, deploymentsAutoInstall, isDebugProvisioningTerminal, isDebugProvisioningSucceeded, getProjectDebugStatus, searchPackageVersions, getStudioWebSolutionProjects, listStudioWebSolutions, solutionExistsOnStudioWeb, importSolution,
|
|
3395
|
+
export { Configuration, getAvailablePublishLocationsV2, DeploymentActivationStatus, DeploymentOperationStatus, SolutionDeploymentAction, DeploymentsApi, PackagesApi, SearchApi, StudioWebIncompatibleProjectError, bundleSolution, deploymentsAutoInstall, isDebugProvisioningTerminal, isDebugProvisioningSucceeded, getProjectDebugStatus, searchPackageVersions, getStudioWebSolutionProjects, listStudioWebSolutions, solutionExistsOnStudioWeb, importSolution, overwriteSolution };
|
|
3100
3396
|
|
|
3101
|
-
//# debugId=
|
|
3397
|
+
//# debugId=696F8E3EF0A1226664756E2164756E21
|