@stack-spot/portal-network 0.74.0 → 0.76.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.
@@ -8,11 +8,11 @@ import * as Oazapfts from "@oazapfts/runtime";
8
8
  import * as QS from "@oazapfts/runtime/query";
9
9
  export const defaults: Oazapfts.Defaults<Oazapfts.CustomHeaders> = {
10
10
  headers: {},
11
- baseUrl: "https://workspace-workspace-api.stg.stackspot.com",
11
+ baseUrl: "https://workspace-workspace-api.dev.stackspot.com",
12
12
  };
13
13
  const oazapfts = Oazapfts.runtime(defaults);
14
14
  export const servers = {
15
- generatedServerUrl: "https://workspace-workspace-api.stg.stackspot.com"
15
+ generatedServerUrl: "https://workspace-workspace-api.dev.stackspot.com"
16
16
  };
17
17
  export type WorkspaceVariableResponse = {
18
18
  /** Workspace variable name. */
@@ -179,6 +179,8 @@ export type PluginsStatusInCloud = {
179
179
  name: string;
180
180
  alias: string;
181
181
  "type": string;
182
+ fork?: boolean;
183
+ iacPath?: string;
182
184
  pluginVersionId: string;
183
185
  stackVersionId: string;
184
186
  inputs: {
@@ -186,6 +188,7 @@ export type PluginsStatusInCloud = {
186
188
  };
187
189
  connections: Connections;
188
190
  link?: PluginLink;
191
+ resourcesProvided?: string[];
189
192
  };
190
193
  export type UpdateRunRequest = {
191
194
  /** Activity status to update. */
@@ -563,6 +566,8 @@ export type CreateSharedInfraRequest = {
563
566
  starterId?: string;
564
567
  /** Extra repository this shared infrastructure. */
565
568
  extraRepositories?: ExtraRepositoriesRequest[];
569
+ /** Workflow id used to generate this shared infra. */
570
+ workflowVersionId?: string;
566
571
  };
567
572
  export type RecreateSharedInfraRequest = {
568
573
  /** Shared infrastructure name. */
@@ -577,6 +582,8 @@ export type RecreateSharedInfraRequest = {
577
582
  stackVersionId: string;
578
583
  /** Starter used to generate this shared infrastructure. */
579
584
  starterId?: string;
585
+ /** Workflow id used to generate this shared infra. */
586
+ workflowVersionId?: string;
580
587
  };
581
588
  export type UpdateSharedInfraRequest = {
582
589
  /** Shared infrastructure name. */
@@ -608,29 +615,6 @@ export type CreateSharedInfraLinkRequest = {
608
615
  /** Shared infra image base64. */
609
616
  image?: string;
610
617
  };
611
- export type RequiredConnectionInterface = {
612
- connectionInterfaceId: string;
613
- "type": string;
614
- existing: boolean;
615
- };
616
- export type Attribute = {
617
- key: string;
618
- value: object;
619
- };
620
- export type PluginElementSnapshot = {
621
- pluginVersionId: string;
622
- "type": string;
623
- requiredConnectionInterfaces: RequiredConnectionInterface[];
624
- attributes: Attribute[];
625
- };
626
- export type SharedInfraDeploySnapshotRequest = {
627
- /** Deployment Id. */
628
- deploymentId: string;
629
- /** Deployment Id. */
630
- environmentId: string;
631
- /** Input attributes for applied app plugin. */
632
- plugins: PluginElementSnapshot[];
633
- };
634
618
  export type StartRunRequest = {
635
619
  /** Requestor's email. */
636
620
  requestedBy: string;
@@ -741,9 +725,11 @@ export type CreateApplicationRequest = {
741
725
  /** Stack used to generate this application. */
742
726
  stackVersionId: string;
743
727
  /** Starter used to generate this application. */
744
- starterId: string;
728
+ starterId?: string;
745
729
  /** Extra repository this shared infrastructure. */
746
730
  extraRepositories?: ExtraRepositoriesRequest[];
731
+ /** Workflow id used to generate this application. */
732
+ workflowVersionId?: string;
747
733
  };
748
734
  export type RecreateApplicationRequest = {
749
735
  /** Application name. */
@@ -757,7 +743,9 @@ export type RecreateApplicationRequest = {
757
743
  /** Stack used to generate this application. */
758
744
  stackVersionId: string;
759
745
  /** Starter used to generate this application. */
760
- starterId: string;
746
+ starterId?: string;
747
+ /** Workflow id used to generate this application. */
748
+ workflowVersionId?: string;
761
749
  };
762
750
  export type UpdateApplicationRequest = {
763
751
  /** Application name. */
@@ -884,14 +872,6 @@ export type CreateApplicationEmbeddedLinkRequest = {
884
872
  /** Application embedded link image base64. */
885
873
  image?: string;
886
874
  };
887
- export type ApplicationDeploySnapshotRequest = {
888
- /** Deployment Id. */
889
- deploymentId: string;
890
- /** Deployment Id. */
891
- environmentId: string;
892
- /** Input attributes for applied app plugin. */
893
- plugins: PluginElementSnapshot[];
894
- };
895
875
  export type EnvironmentLinkedPluginResponse = {
896
876
  id: string;
897
877
  name: string;
@@ -975,12 +955,16 @@ export type EnvironmentReadResponse = {
975
955
  description: string;
976
956
  /** Environment accountId. */
977
957
  accountId: string;
958
+ /** Flag for productive environment. */
959
+ isProductive: boolean;
978
960
  };
979
961
  export type EnvironmentSaveRequest = {
980
962
  /** Environment name. */
981
963
  name: string;
982
964
  /** Environment description. */
983
965
  description: string;
966
+ /** Flag for productive environment. */
967
+ isProductive: boolean;
984
968
  };
985
969
  export type EnvironmentReadBatchResponse = {
986
970
  /** Environment id. */
@@ -1143,6 +1127,8 @@ export type EnvironmentUpdateRequest = {
1143
1127
  name?: string;
1144
1128
  /** Environment description. */
1145
1129
  description?: string;
1130
+ /** Flag for productive environment. */
1131
+ isProductive: boolean;
1146
1132
  };
1147
1133
  export type PaginatedWorkspaceVariableResponse = {
1148
1134
  currentPage: number;
@@ -1170,6 +1156,8 @@ export type AppliedPluginV2Response = {
1170
1156
  name: string;
1171
1157
  "type"?: string;
1172
1158
  alias: string;
1159
+ fork?: boolean;
1160
+ iacPath?: string;
1173
1161
  pluginVersionId: string;
1174
1162
  stackVersionId: string;
1175
1163
  status?: "PENDING" | "READY_TO_RUN" | "RUNNING" | "SUCCEEDED" | "FAILED" | "INTERNAL_ERROR" | "ABORTED" | "EXTERNAL_ERROR" | "DESTROYED";
@@ -1180,6 +1168,7 @@ export type AppliedPluginV2Response = {
1180
1168
  };
1181
1169
  connections?: ConnectionsResponse;
1182
1170
  links?: Link[];
1171
+ resourcesProvided?: string[];
1183
1172
  };
1184
1173
  export type ConnectionInterfaceSummaryV2Response = {
1185
1174
  /** Connection interface api id. */
@@ -1273,7 +1262,7 @@ export type ActivityResponse = {
1273
1262
  version?: string;
1274
1263
  owner?: string;
1275
1264
  status: "SUCCESS" | "FAILED" | "SKIPPED" | "CANCELLED" | "RUNTIME_ERROR" | "INTERNAL_ERROR" | "EXTERNAL_ERROR" | "ABORTED" | "ABORTING" | "SUCCEEDED" | "USER_ERROR" | "DRIFT" | "TIMEOUT" | "RUNNING" | "READY_TO_RUN" | "PENDING" | "NONE";
1276
- "type": "DEPLOY" | "ACTION" | "WORKFLOW" | "DRIFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW";
1265
+ "type": "DEPLOY" | "ACTION" | "WORKFLOW" | "DRAFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW" | "CREATE";
1277
1266
  requestedBy?: string;
1278
1267
  action?: "CREATE" | "UPDATE" | "DELETE" | "RUN";
1279
1268
  time: number;
@@ -1552,7 +1541,7 @@ export function contextV2ControlleraddTypedContextInWorkspace({ workspaceId, sta
1552
1541
  workspaceId: string;
1553
1542
  stackVersionId: string;
1554
1543
  externalId: string;
1555
- $type: "plugin" | "action";
1544
+ $type: "plugin" | "action" | "workflow";
1556
1545
  contextValuesRequest: ContextValuesRequest;
1557
1546
  }, opts?: Oazapfts.RequestOpts) {
1558
1547
  return oazapfts.ok(oazapfts.fetchJson<{
@@ -1612,7 +1601,7 @@ export function contextV2ControllerimportContextInWorkspace({ workspaceId, stack
1612
1601
  export function contextV2ControlleraddTypedContextInAccount({ stackVersionId, externalId, $type, contextValuesRequest }: {
1613
1602
  stackVersionId: string;
1614
1603
  externalId: string;
1615
- $type: "plugin" | "action";
1604
+ $type: "plugin" | "action" | "workflow";
1616
1605
  contextValuesRequest: ContextValuesRequest;
1617
1606
  }, opts?: Oazapfts.RequestOpts) {
1618
1607
  return oazapfts.ok(oazapfts.fetchJson<{
@@ -3050,34 +3039,6 @@ export function workspaceSharedInfrastructureControllercanBeDestroyed({ workspac
3050
3039
  })
3051
3040
  }));
3052
3041
  }
3053
- /**
3054
- * Register the snapshot of a shared infrastructure's deploy.
3055
- */
3056
- export function workspaceSharedInfrastructureControllerprocessDeploySnapshot({ workspaceId, sharedInfraId, sharedInfraDeploySnapshotRequest }: {
3057
- workspaceId: string;
3058
- sharedInfraId: string;
3059
- sharedInfraDeploySnapshotRequest: SharedInfraDeploySnapshotRequest;
3060
- }, opts?: Oazapfts.RequestOpts) {
3061
- return oazapfts.ok(oazapfts.fetchJson<{
3062
- status: 204;
3063
- } | {
3064
- status: 400;
3065
- data: ErrorResponse;
3066
- } | {
3067
- status: 403;
3068
- data: ErrorResponse;
3069
- } | {
3070
- status: 404;
3071
- data: ErrorResponse;
3072
- } | {
3073
- status: 500;
3074
- data: ErrorResponse;
3075
- }>(`/v1/workspaces/${encodeURIComponent(workspaceId)}/shared-infra/${encodeURIComponent(sharedInfraId)}/deploy`, oazapfts.json({
3076
- ...opts,
3077
- method: "POST",
3078
- body: sharedInfraDeploySnapshotRequest
3079
- })));
3080
- }
3081
3042
  /**
3082
3043
  * Runs an orchestration in a workspace.
3083
3044
  */
@@ -3676,34 +3637,6 @@ export function applicationEmbeddedLinkControllersave({ workspaceId, application
3676
3637
  body: createApplicationEmbeddedLinkRequest
3677
3638
  })));
3678
3639
  }
3679
- /**
3680
- * Register the snapshot of an application's deploy.
3681
- */
3682
- export function workspaceApplicationControllerprocessDeploySnapshot({ workspaceId, applicationId, applicationDeploySnapshotRequest }: {
3683
- workspaceId: string;
3684
- applicationId: string;
3685
- applicationDeploySnapshotRequest: ApplicationDeploySnapshotRequest;
3686
- }, opts?: Oazapfts.RequestOpts) {
3687
- return oazapfts.ok(oazapfts.fetchJson<{
3688
- status: 204;
3689
- } | {
3690
- status: 400;
3691
- data: ErrorResponse;
3692
- } | {
3693
- status: 403;
3694
- data: ErrorResponse;
3695
- } | {
3696
- status: 404;
3697
- data: ErrorResponse;
3698
- } | {
3699
- status: 500;
3700
- data: ErrorResponse;
3701
- }>(`/v1/workspaces/${encodeURIComponent(workspaceId)}/applications/${encodeURIComponent(applicationId)}/deploy`, oazapfts.json({
3702
- ...opts,
3703
- method: "POST",
3704
- body: applicationDeploySnapshotRequest
3705
- })));
3706
- }
3707
3640
  /**
3708
3641
  * List all workspaces usage by stack version list.
3709
3642
  */
@@ -4949,7 +4882,7 @@ export function workspaceStackControllerdeleteStack({ workspaceId, stackVersionI
4949
4882
  export function contextControllerlistConsolidatedContext({ workspaceId, stackVersionId, $type, envName, externalId }: {
4950
4883
  workspaceId: string;
4951
4884
  stackVersionId: string;
4952
- $type: "plugin" | "action";
4885
+ $type: "plugin" | "action" | "workflow";
4953
4886
  envName?: string;
4954
4887
  externalId?: string;
4955
4888
  }, opts?: Oazapfts.RequestOpts) {
@@ -5039,7 +4972,7 @@ export function workspaceSharedInfrastructureControllerlistActivities({ workspac
5039
4972
  workspaceId: string;
5040
4973
  sharedInfraId: string;
5041
4974
  environmentId: string;
5042
- $type?: ("DEPLOY" | "ACTION" | "WORKFLOW" | "DRIFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW")[];
4975
+ $type?: ("DEPLOY" | "ACTION" | "WORKFLOW" | "DRAFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW" | "CREATE")[];
5043
4976
  page: number;
5044
4977
  size: number;
5045
4978
  }, opts?: Oazapfts.RequestOpts) {
@@ -5314,7 +5247,7 @@ export function workspaceApplicationControllerlistActivities({ workspaceId, appl
5314
5247
  workspaceId: string;
5315
5248
  applicationId: string;
5316
5249
  environmentId: string;
5317
- $type?: ("DEPLOY" | "ACTION" | "WORKFLOW" | "DRIFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW")[];
5250
+ $type?: ("DEPLOY" | "ACTION" | "WORKFLOW" | "DRAFT" | "DESTROY" | "ROLLBACK" | "IAC" | "DEPLOY_SELF_HOSTED" | "DESTROY_SELF_HOSTED" | "ROLLBACK_SELF_HOSTED" | "IAC_SELF_HOSTED" | "CUSTOMER_WORKFLOW" | "CREATE")[];
5318
5251
  page: number;
5319
5252
  size: number;
5320
5253
  }, opts?: Oazapfts.RequestOpts) {
@@ -5463,6 +5396,23 @@ export function accountSharedInfrastructureControllergetSharedInfra({ id }: {
5463
5396
  ...opts
5464
5397
  }));
5465
5398
  }
5399
+ /**
5400
+ * Get stack version in use by applications in account
5401
+ */
5402
+ export function accountSharedInfrastructureControllergetStackVersionsInUse(opts?: Oazapfts.RequestOpts) {
5403
+ return oazapfts.ok(oazapfts.fetchJson<{
5404
+ status: 200;
5405
+ data: StacksVersionIdsResponse;
5406
+ } | {
5407
+ status: 403;
5408
+ data: ErrorResponse;
5409
+ } | {
5410
+ status: 500;
5411
+ data: ErrorResponse;
5412
+ }>("/v1/shared-infra/stacks/versions", {
5413
+ ...opts
5414
+ }));
5415
+ }
5466
5416
  /**
5467
5417
  * Check if there is/are any deployment active for the provided plugin
5468
5418
  */
@@ -5610,6 +5560,23 @@ export function availableConnectionInterfaceControllergetAvailableConnectionInte
5610
5560
  ...opts
5611
5561
  }));
5612
5562
  }
5563
+ /**
5564
+ * Get stack version in use by applications in account
5565
+ */
5566
+ export function accountApplicationControllergetStackVersionsInUse(opts?: Oazapfts.RequestOpts) {
5567
+ return oazapfts.ok(oazapfts.fetchJson<{
5568
+ status: 200;
5569
+ data: StacksVersionIdsResponse;
5570
+ } | {
5571
+ status: 403;
5572
+ data: ErrorResponse;
5573
+ } | {
5574
+ status: 500;
5575
+ data: ErrorResponse;
5576
+ }>("/v1/applications/stacks/versions", {
5577
+ ...opts
5578
+ }));
5579
+ }
5613
5580
  /**
5614
5581
  * Get action version ranges used in workflows given an actionId.
5615
5582
  */
@@ -5667,7 +5634,7 @@ export function accountVariableControllerusage({ accountId, name }: {
5667
5634
  */
5668
5635
  export function contextControllerlistAccountContext({ stackVersionId, $type, envName, externalId }: {
5669
5636
  stackVersionId: string;
5670
- $type: "plugin" | "action";
5637
+ $type: "plugin" | "action" | "workflow";
5671
5638
  envName?: string;
5672
5639
  externalId?: string;
5673
5640
  }, opts?: Oazapfts.RequestOpts) {
@@ -8,25 +8,31 @@ import {
8
8
  bindGroupMembers,
9
9
  bindRoleGroups,
10
10
  bindRoles,
11
- bindToGroups, bindToRoles, create, createAccountRole, createGroupMapping, createPartner,
11
+ bindToGroups, bindToRoles, create, createAccountRole, createExtension, createExtensionLink, createExtensionVersion, createGroupMapping,
12
+ createPartner,
12
13
  createPersonalAccessToken,
13
14
  createServiceCredential1,
14
15
  createUser,
15
16
  deactivateFidoCredentials,
16
17
  defaults,
17
18
  deleteAccountRole,
19
+ deleteExtension,
20
+ deleteExtensionLink,
21
+ deleteExtensionVersion,
18
22
  deleteGroupMapping,
19
23
  deleteMember,
20
24
  deleteMemberFavorite,
21
- deletePartner, deleteResourceFromGroup, deleteRole, deleteSso, deleteV1GroupsByGroupId, disablePersonalAccessTokenGeneration,
25
+ deletePartner, deleteProfileImage,
26
+ deleteResourceFromGroup, deleteRole, deleteSso, deleteV1GroupsByGroupId, disablePersonalAccessTokenGeneration,
22
27
  disassociateGroupToServiceCredential, enableFidoCredentials,
23
28
  getAccess,
24
29
  getAccountMembers,
25
30
  getAccountMembers2,
26
31
  getAccountSso,
32
+ getActiveExtensionVersion,
27
33
  getAllAccountSso,
28
34
  getAllGroupMapping,
29
- getAllMemberFidoCredentials, getFeatures,
35
+ getAllMemberFidoCredentials, getExtensionVersion, getFeatures,
30
36
  getGroupById,
31
37
  getGroupResources,
32
38
  getGroupResources1,
@@ -62,6 +68,9 @@ import {
62
68
  isCreatedScmCredentials,
63
69
  isCreatedScmCredentials1,
64
70
  listAccountMemberFavorites,
71
+ listExtensionLinks,
72
+ listExtensions,
73
+ listExtensionVersions,
65
74
  listMemberFavoritesByResource,
66
75
  listScmCredentials,
67
76
  listScmCredentials1, partialUpdateSso, personalAccessTokenAuthorization,
@@ -71,6 +80,8 @@ import {
71
80
  scmCredentialSave, scmCredentialSave1, scmCredentialUpdate, scmCredentialUpdate1, scmDelete, sendDownloadEmail, ssoAddAttributes,
72
81
  ssoConfigure, ssoGetAttributesConfig, ssoParseConfigurationFile, update1,
73
82
  updateAccountRole,
83
+ updateExtension,
84
+ updateExtensionLink,
74
85
  updateGroupMapping,
75
86
  updateMemberPreferences,
76
87
  updatePartnerAccountAdminData,
@@ -571,13 +582,13 @@ class AccountClient extends ReactQueryNetworkClient {
571
582
  */
572
583
  allMembersWithPagination = this.query(getAccountMembers)
573
584
  /**
574
- * Get Members Groups By Perfil
585
+ * Get Members Groups By Profile
575
586
  */
576
- allMembersGroupsByPerfilWithPagination = this.query(getMemberGroups)
587
+ allMembersGroupsByProfileWithPagination = this.query(getMemberGroups)
577
588
  /**
578
- * Get Members Roles By Perfil
589
+ * Get Members Roles By Profile
579
590
  */
580
- allMembersRolesByPerfilWithPagination = this.query(getRoles1)
591
+ allMembersRolesByProfileWithPagination = this.query(getRoles1)
581
592
  /**
582
593
  * Get all account groups with pagination
583
594
  */
@@ -610,6 +621,76 @@ class AccountClient extends ReactQueryNetworkClient {
610
621
  * Get Service Credentials
611
622
  */
612
623
  allServiceCredentialsWithPagination = this.query(getServiceCredentials)
624
+
625
+ /**
626
+ * Creates an extension.
627
+ */
628
+ createExtension = this.mutation(createExtension)
629
+
630
+ /**
631
+ * Deletes an extension.
632
+ */
633
+ deleteExtension = this.mutation(deleteExtension)
634
+
635
+ /**
636
+ * Updates an extension with a patch operation.
637
+ */
638
+ patchExtension = this.mutation(updateExtension)
639
+
640
+ /**
641
+ * Lists all extensions.
642
+ */
643
+ extensions = this.query(listExtensions)
644
+
645
+ /**
646
+ * Lists all versions of an extension.
647
+ */
648
+ extensionVersions = this.query(listExtensionVersions)
649
+
650
+ /**
651
+ * Gets a specific version of an extension.
652
+ */
653
+ getExtensionVersion = this.query(getExtensionVersion)
654
+
655
+ /**
656
+ * Gets the active version of an extension.
657
+ */
658
+ getActiveExtensionVersion = this.query(getActiveExtensionVersion)
659
+
660
+ /**
661
+ * Creates a new version of an extension.
662
+ */
663
+ createExtensionVersion = this.mutation(createExtensionVersion)
664
+
665
+ /**
666
+ * Deletes a specific version of an extension.
667
+ */
668
+ deleteExtensionVersion = this.mutation(deleteExtensionVersion)
669
+
670
+ /**
671
+ * Lists all extension links.
672
+ */
673
+ extensionLinks = this.query(listExtensionLinks)
674
+
675
+ /**
676
+ * Updates an extension link with a patch operation.
677
+ */
678
+ patchExtensionLink = this.mutation(updateExtensionLink)
679
+
680
+ /**
681
+ * Creates a new extension link.
682
+ */
683
+ createExtensionLink = this.mutation(createExtensionLink)
684
+
685
+ /**
686
+ * Deletes an extension link.
687
+ */
688
+ deleteExtensionLink = this.mutation(deleteExtensionLink)
689
+
690
+ /*
691
+ * Delete profile image
692
+ */
693
+ deleteProfileImage = this.mutation(deleteProfileImage)
613
694
  }
614
695
 
615
696
  export const accountClient = new AccountClient()