@forge/util

2.0.12.0.1-experimental-7890858
packages/ari/ecosystem/index.js
~packages/ari/ecosystem/index.jsModified
+62−48
Index: package/packages/ari/ecosystem/index.js
===================================================================
--- package/packages/ari/ecosystem/index.js
+++ package/packages/ari/ecosystem/index.js
@@ -17,8 +17,9 @@
 // src/ecosystem/index.ts
 var ecosystem_exports = {};
 __export(ecosystem_exports, {
   EcosystemAppAri: () => EcosystemAppAri,
+  EcosystemAppBuilderProjectAri: () => EcosystemAppBuilderProjectAri,
   EcosystemAppEnvironmentVersionAri: () => EcosystemAppEnvironmentVersionAri,
   EcosystemConnectAppAri: () => EcosystemConnectAppAri,
   EcosystemConnectModuleAri: () => EcosystemConnectModuleAri,
   EcosystemEnvironmentAri: () => EcosystemEnvironmentAri,
@@ -283,30 +284,27 @@
   }
 };
 
 // src/ecosystem/app/types.ts
-var EcosystemAppAriResourceOwner = "ecosystem", EcosystemAppAriResourceType = "app";
+var EcosystemAppAriResourceOwner = "ecosystem";
 
 // src/ecosystem/app/manifest.ts
 var ecosystemAppAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemAppAriResourceOwner,
-  resourceType: EcosystemAppAriResourceType,
+  resourceType: "app",
   resourceIdSlug: "{appId}",
   resourceIdSegmentFormats: {
     appId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/app/index.ts
 var EcosystemAppAri = class _EcosystemAppAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appId = opts.resourceIdSegmentValues.appId;
+    super(opts), this._appId = opts.resourceIdSegmentValues.appId;
   }
   get appId() {
     return this._appId;
   }
@@ -334,35 +332,79 @@
     };
   }
 };
 
+// src/ecosystem/app-builder-project/types.ts
+var EcosystemAppBuilderProjectAriResourceOwner = "ecosystem", EcosystemAppBuilderProjectAriResourceType = "app-builder-project";
+
+// src/ecosystem/app-builder-project/manifest.ts
+var ecosystemAppBuilderProjectAriStaticOpts = {
+  qualifier: "ari",
+  platformQualifier: "cloud",
+  cloudId: new RegExp("^$"),
+  resourceOwner: EcosystemAppBuilderProjectAriResourceOwner,
+  resourceType: EcosystemAppBuilderProjectAriResourceType,
+  resourceIdSlug: "{projectId}",
+  resourceIdSegmentFormats: {
+    projectId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
+  }
+};
+
+// src/ecosystem/app-builder-project/index.ts
+var EcosystemAppBuilderProjectAri = class _EcosystemAppBuilderProjectAri extends RegisteredAri {
+  constructor(opts) {
+    super(opts), this._projectId = opts.resourceIdSegmentValues.projectId;
+  }
+  get projectId() {
+    return this._projectId;
+  }
+  static create(opts) {
+    let derivedOpts = {
+      qualifier: ecosystemAppBuilderProjectAriStaticOpts.qualifier,
+      platformQualifier: ecosystemAppBuilderProjectAriStaticOpts.platformQualifier,
+      cloudId: void 0,
+      resourceOwner: ecosystemAppBuilderProjectAriStaticOpts.resourceOwner,
+      resourceType: ecosystemAppBuilderProjectAriStaticOpts.resourceType,
+      resourceId: `${opts.projectId}`,
+      resourceIdSegmentValues: {
+        projectId: opts.projectId
+      }
+    }, ariOpts = AriParser.fromOpts(derivedOpts, ecosystemAppBuilderProjectAriStaticOpts);
+    return new _EcosystemAppBuilderProjectAri(ariOpts);
+  }
+  static parse(maybeAri) {
+    let opts = AriParser.fromString(maybeAri, ecosystemAppBuilderProjectAriStaticOpts);
+    return new _EcosystemAppBuilderProjectAri(opts);
+  }
+  getVariables() {
+    return {
+      projectId: this.projectId
+    };
+  }
+};
+
 // src/ecosystem/app-environment-version/types.ts
 var EcosystemAppEnvironmentVersionAriResourceOwner = "ecosystem", EcosystemAppEnvironmentVersionAriResourceType = "app-environment-version";
 
 // src/ecosystem/app-environment-version/manifest.ts
 var ecosystemAppEnvironmentVersionAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemAppEnvironmentVersionAriResourceOwner,
   resourceType: EcosystemAppEnvironmentVersionAriResourceType,
   resourceIdSlug: "{appId}/{environmentId}/{versionId}",
   resourceIdSegmentFormats: {
     appId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     environmentId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     versionId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/app-environment-version/index.ts
 var EcosystemAppEnvironmentVersionAri = class _EcosystemAppEnvironmentVersionAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._versionId = opts.resourceIdSegmentValues.versionId;
+    super(opts), this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._versionId = opts.resourceIdSegmentValues.versionId;
   }
   get appId() {
     return this._appId;
   }
@@ -408,23 +450,20 @@
 var ecosystemConnectAppAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemConnectAppAriResourceOwner,
   resourceType: EcosystemConnectAppAriResourceType,
   resourceIdSlug: "{appKey}",
   resourceIdSegmentFormats: {
     appKey: /[a-zA-Z0-9-._]+/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/connect-app/index.ts
 var EcosystemConnectAppAri = class _EcosystemConnectAppAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appKey = opts.resourceIdSegmentValues.appKey;
+    super(opts), this._appKey = opts.resourceIdSegmentValues.appKey;
   }
   get appKey() {
     return this._appKey;
   }
@@ -460,25 +499,21 @@
 var ecosystemConnectModuleAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemConnectModuleAriResourceOwner,
   resourceType: EcosystemConnectModuleAriResourceType,
   resourceIdSlug: "{appKey}/{moduleKey}",
   resourceIdSegmentFormats: {
     appKey: /[a-zA-Z0-9-._]+/,
-    // eslint-disable-line no-useless-escape
     moduleKey: /[a-zA-Z0-9-]+/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/connect-module/index.ts
 var EcosystemConnectModuleAri = class _EcosystemConnectModuleAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appKey = opts.resourceIdSegmentValues.appKey, this._moduleKey = opts.resourceIdSegmentValues.moduleKey;
+    super(opts), this._appKey = opts.resourceIdSegmentValues.appKey, this._moduleKey = opts.resourceIdSegmentValues.moduleKey;
   }
   get appKey() {
     return this._appKey;
   }
@@ -519,25 +554,21 @@
 var ecosystemEnvironmentAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemEnvironmentAriResourceOwner,
   resourceType: EcosystemEnvironmentAriResourceType,
   resourceIdSlug: "{appId}/{environmentId}",
   resourceIdSegmentFormats: {
     appId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     environmentId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/environment/index.ts
 var EcosystemEnvironmentAri = class _EcosystemEnvironmentAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId;
+    super(opts), this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId;
   }
   get appId() {
     return this._appId;
   }
@@ -578,29 +609,23 @@
 var ecosystemExtensionAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemExtensionAriResourceOwner,
   resourceType: EcosystemExtensionAriResourceType,
   resourceIdSlug: "{appId}/{environmentId}/{groupId}/{extensionKey}",
   resourceIdSegmentFormats: {
     appId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     environmentId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     groupId: /([0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}|static)/,
-    // eslint-disable-line no-useless-escape
     extensionKey: /[a-zA-Z0-9-._]+/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/extension/index.ts
 var EcosystemExtensionAri = class _EcosystemExtensionAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._groupId = opts.resourceIdSegmentValues.groupId, this._extensionKey = opts.resourceIdSegmentValues.extensionKey;
+    super(opts), this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._groupId = opts.resourceIdSegmentValues.groupId, this._extensionKey = opts.resourceIdSegmentValues.extensionKey;
   }
   get appId() {
     return this._appId;
   }
@@ -651,27 +676,22 @@
 var ecosystemExtensionGroupAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemExtensionGroupAriResourceOwner,
   resourceType: EcosystemExtensionGroupAriResourceType,
   resourceIdSlug: "{appId}/{environmentId}/{groupId}",
   resourceIdSegmentFormats: {
     appId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     environmentId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     groupId: /([0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}|static)/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/extension-group/index.ts
 var EcosystemExtensionGroupAri = class _EcosystemExtensionGroupAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._groupId = opts.resourceIdSegmentValues.groupId;
+    super(opts), this._appId = opts.resourceIdSegmentValues.appId, this._environmentId = opts.resourceIdSegmentValues.environmentId, this._groupId = opts.resourceIdSegmentValues.groupId;
   }
   get appId() {
     return this._appId;
   }
@@ -717,23 +737,20 @@
 var ecosystemInstallationAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemInstallationAriResourceOwner,
   resourceType: EcosystemInstallationAriResourceType,
   resourceIdSlug: "{installationId}",
   resourceIdSegmentFormats: {
     installationId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/installation/index.ts
 var EcosystemInstallationAri = class _EcosystemInstallationAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._installationId = opts.resourceIdSegmentValues.installationId;
+    super(opts), this._installationId = opts.resourceIdSegmentValues.installationId;
   }
   get installationId() {
     return this._installationId;
   }
@@ -769,25 +786,21 @@
 var ecosystemInstallationLinkAriStaticOpts = {
   qualifier: "ari",
   platformQualifier: "cloud",
   cloudId: new RegExp("^$"),
-  // eslint-disable-line no-useless-escape
   resourceOwner: EcosystemInstallationLinkAriResourceOwner,
   resourceType: EcosystemInstallationLinkAriResourceType,
   resourceIdSlug: "{installationId}/{installationLinkId}",
   resourceIdSegmentFormats: {
     installationId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
-    // eslint-disable-line no-useless-escape
     installationLinkId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
-    // eslint-disable-line no-useless-escape
   }
 };
 
 // src/ecosystem/installation-link/index.ts
 var EcosystemInstallationLinkAri = class _EcosystemInstallationLinkAri extends RegisteredAri {
   constructor(opts) {
-    super(opts);
-    this._installationId = opts.resourceIdSegmentValues.installationId, this._installationLinkId = opts.resourceIdSegmentValues.installationLinkId;
+    super(opts), this._installationId = opts.resourceIdSegmentValues.installationId, this._installationLinkId = opts.resourceIdSegmentValues.installationLinkId;
   }
   get installationId() {
     return this._installationId;
   }
@@ -822,8 +835,9 @@
 };
 // Annotate the CommonJS export names for ESM import in node:
 0 && (module.exports = {
   EcosystemAppAri,
+  EcosystemAppBuilderProjectAri,
   EcosystemAppEnvironmentVersionAri,
   EcosystemConnectAppAri,
   EcosystemConnectModuleAri,
   EcosystemEnvironmentAri,