@epilot/app-client 0.13.5 → 0.13.7

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.
@@ -1 +1 @@
1
- (()=>{"use strict";var e={438(e,r,t){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0});var p=n(t(466));r.default=p.default},466(e){e.exports=JSON.parse('{"openapi":"3.1.0","info":{"title":"","version":""},"servers":[{"url":"https://app.sls.epilot.io"}],"paths":{"/v1/public/app/{appId}/components/{componentId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration to install"},{"name":"componentId","in":"path","required":true,"description":"ID of the component to retrieve"}],"get":{"operationId":"getPublicFacingComponent","responses":{}}},"/v1/app-configurations":{"get":{"operationId":"listConfigurations","parameters":[{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}},"post":{"operationId":"createConfiguration","requestBody":{"$ref":"#/components/requestBodies/CreateConfigRequest"},"responses":{}}},"/v1/app-configurations/public":{"get":{"operationId":"listPublicConfigurations","parameters":[{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app-configurations/public/{appId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration to install"}],"get":{"operationId":"getPublicConfiguration","parameters":[{"name":"version","in":"query"}],"responses":{}}},"/v1/app-configurations/{appId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration"}],"get":{"operationId":"getConfiguration","parameters":[{"name":"version","in":"query"}],"responses":{}},"patch":{"operationId":"patchMetadata","requestBody":{"$ref":"#/components/requestBodies/PatchConfigMetadataRequest"},"responses":{}},"delete":{"operationId":"deleteConfiguration","responses":{}}},"/v1/app-configurations/{appId}/events":{"post":{"operationId":"queryEvents","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/app-configurations/{appId}/bundle":{"post":{"operationId":"createBundleUploadUrl","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/CreateBundlePresignedRequest"},"responses":{}}},"/v1/app-configurations/{appId}/zip":{"post":{"operationId":"createZipUploadUrl","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/app-configurations/{appId}/logo":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration"}],"post":{"operationId":"createLogoUploadUrl","requestBody":{"$ref":"#/components/requestBodies/CreateLogoPresignedRequest"},"responses":{}},"delete":{"operationId":"deleteLogo","responses":{}}},"/v1/app-configurations/{appId}/versions":{"get":{"operationId":"listVersions","parameters":[{"name":"appId","in":"path","required":true},{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}":{"get":{"operationId":"getVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"delete":{"operationId":"deleteVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"patch":{"operationId":"patchVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/PatchVersionRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/review":{"get":{"operationId":"getReview","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"post":{"operationId":"createReview","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/CreateReviewRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/components":{"post":{"operationId":"createComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/UpsertComponentRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/components/{componentId}":{"patch":{"operationId":"patchComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true},{"name":"componentId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/UpsertComponentRequest"},"responses":{}},"delete":{"operationId":"deleteComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true},{"name":"componentId","in":"path","required":true}],"responses":{}}},"/v1/app-configurations/{appId}/versions/{sourceVersion}/clone-to/{targetVersion}":{"post":{"operationId":"cloneVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"sourceVersion","in":"path","required":true},{"name":"targetVersion","in":"path","required":true}],"responses":{}}},"/v1/app":{"get":{"operationId":"listInstallations","parameters":[{"name":"componentType","in":"query"},{"name":"enabled","in":"query"},{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app/{appId}":{"get":{"operationId":"getInstallation","parameters":[{"name":"appId","in":"path","required":true}],"responses":{}},"post":{"operationId":"install","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/InstallRequest"},"responses":{}},"patch":{"operationId":"patchInstallation","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/InstallRequest"},"responses":{}},"delete":{"operationId":"uninstall","parameters":[{"name":"appId","in":"path","required":true}],"responses":{}}},"/v1/app/{appId}/promote-to/{version}":{"post":{"operationId":"promoteVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}}},"/v1/app-events":{"post":{"operationId":"ingestEvent","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/app/{appId}/proxy/{proxyName}/{path}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the installed app"},{"name":"proxyName","in":"path","required":true,"description":"Name of the proxy target as defined in the app manifest"},{"name":"path","in":"path","required":true,"description":"Path to forward to the proxy target"}],"get":{"operationId":"publicProxyGet","responses":{}},"post":{"operationId":"publicProxyPost","requestBody":{"content":{"application/json":{}}},"responses":{}}}},"components":{"requestBodies":{"CreateReviewRequest":{"required":true,"content":{"application/json":{}}},"CreateLogoPresignedRequest":{"required":true,"content":{"application/json":{}}},"CreateBundlePresignedRequest":{"required":true,"content":{"application/json":{}}},"PatchConfigMetadataRequest":{"required":true,"content":{"application/json":{}}},"PatchVersionRequest":{"required":true,"content":{"application/json":{}}},"UpsertComponentRequest":{"required":true,"content":{"application/json":{}}},"CreateConfigRequest":{"required":true,"content":{"application/json":{}}},"InstallRequest":{"content":{"application/json":{}}}}}}')}},r={},t=function t(n){var p=r[n];if(void 0!==p)return p.exports;var o=r[n]={exports:{}};return e[n].call(o.exports,o,o.exports,t),o.exports}(438),n=exports;for(var p in t)n[p]=t[p];t.__esModule&&Object.defineProperty(n,"__esModule",{value:!0})})();
1
+ (()=>{"use strict";var e={330(e,r,t){var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(r,"__esModule",{value:!0});var o=n(t(466));r.default=o.default},466(e){e.exports=JSON.parse('{"openapi":"3.1.0","info":{"title":"","version":""},"servers":[{"url":"https://app.sls.epilot.io"}],"paths":{"/v1/public/app/{appId}/components/{componentId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration to install"},{"name":"componentId","in":"path","required":true,"description":"ID of the component to retrieve"}],"get":{"operationId":"getPublicFacingComponent","responses":{}}},"/v1/app-configurations":{"get":{"operationId":"listConfigurations","parameters":[{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}},"post":{"operationId":"createConfiguration","requestBody":{"$ref":"#/components/requestBodies/CreateConfigRequest"},"responses":{}}},"/v1/app-configurations/public":{"get":{"operationId":"listPublicConfigurations","parameters":[{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app-configurations/public/{appId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration to install"}],"get":{"operationId":"getPublicConfiguration","parameters":[{"name":"version","in":"query"}],"responses":{}}},"/v1/app-configurations/{appId}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration"}],"get":{"operationId":"getConfiguration","parameters":[{"name":"version","in":"query"}],"responses":{}},"patch":{"operationId":"patchMetadata","requestBody":{"$ref":"#/components/requestBodies/PatchConfigMetadataRequest"},"responses":{}},"delete":{"operationId":"deleteConfiguration","responses":{}}},"/v1/app-configurations/{appId}/events":{"post":{"operationId":"queryEvents","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/app-configurations/{appId}/bundle":{"post":{"operationId":"createBundleUploadUrl","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/CreateBundlePresignedRequest"},"responses":{}}},"/v1/app-configurations/{appId}/zip":{"post":{"operationId":"createZipUploadUrl","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"content":{"application/json":{}}},"responses":{}}},"/v1/app-configurations/{appId}/logo":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the app configuration"}],"post":{"operationId":"createLogoUploadUrl","requestBody":{"$ref":"#/components/requestBodies/CreateLogoPresignedRequest"},"responses":{}},"delete":{"operationId":"deleteLogo","responses":{}}},"/v1/app-configurations/{appId}/versions":{"get":{"operationId":"listVersions","parameters":[{"name":"appId","in":"path","required":true},{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}":{"get":{"operationId":"getVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"delete":{"operationId":"deleteVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"patch":{"operationId":"patchVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/PatchVersionRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/review":{"get":{"operationId":"getReview","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}},"post":{"operationId":"createReview","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/CreateReviewRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/components":{"post":{"operationId":"createComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/UpsertComponentRequest"},"responses":{}}},"/v1/app-configurations/{appId}/versions/{version}/components/{componentId}":{"patch":{"operationId":"patchComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true},{"name":"componentId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/UpsertComponentRequest"},"responses":{}},"delete":{"operationId":"deleteComponent","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true},{"name":"componentId","in":"path","required":true}],"responses":{}}},"/v1/app-configurations/{appId}/versions/{sourceVersion}/clone-to/{targetVersion}":{"post":{"operationId":"cloneVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"sourceVersion","in":"path","required":true},{"name":"targetVersion","in":"path","required":true}],"responses":{}}},"/v1/app":{"get":{"operationId":"listInstallations","parameters":[{"name":"componentType","in":"query"},{"name":"enabled","in":"query"},{"name":"page","in":"query"},{"name":"pageSize","in":"query"}],"responses":{}}},"/v1/app/{appId}":{"get":{"operationId":"getInstallation","parameters":[{"name":"appId","in":"path","required":true}],"responses":{}},"post":{"operationId":"install","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/InstallRequest"},"responses":{}},"patch":{"operationId":"patchInstallation","parameters":[{"name":"appId","in":"path","required":true}],"requestBody":{"$ref":"#/components/requestBodies/InstallRequest"},"responses":{}},"delete":{"operationId":"uninstall","parameters":[{"name":"appId","in":"path","required":true}],"responses":{}}},"/v1/app/{appId}/promote-to/{version}":{"post":{"operationId":"promoteVersion","parameters":[{"name":"appId","in":"path","required":true},{"name":"version","in":"path","required":true}],"responses":{}}},"/v1/app-events":{"post":{"operationId":"ingestEvent","requestBody":{"required":true,"content":{"application/json":{}}},"responses":{}}},"/v1/public/app/{appId}/proxy/{proxyName}/{path}":{"parameters":[{"name":"appId","in":"path","required":true,"description":"ID of the installed app"},{"name":"proxyName","in":"path","required":true,"description":"Name of the proxy target as defined in the app manifest"},{"name":"path","in":"path","required":true,"description":"Path to forward to the proxy target"}],"get":{"operationId":"publicProxyGet","responses":{}},"post":{"operationId":"publicProxyPost","requestBody":{"content":{"application/json":{}}},"responses":{}},"put":{"operationId":"publicProxyPut","requestBody":{"content":{"application/json":{}}},"responses":{}},"patch":{"operationId":"publicProxyPatch","requestBody":{"content":{"application/json":{}}},"responses":{}},"delete":{"operationId":"publicProxyDelete","responses":{}}}},"components":{"requestBodies":{"CreateReviewRequest":{"required":true,"content":{"application/json":{}}},"CreateLogoPresignedRequest":{"required":true,"content":{"application/json":{}}},"CreateBundlePresignedRequest":{"required":true,"content":{"application/json":{}}},"PatchConfigMetadataRequest":{"required":true,"content":{"application/json":{}}},"PatchVersionRequest":{"required":true,"content":{"application/json":{}}},"UpsertComponentRequest":{"required":true,"content":{"application/json":{}}},"CreateConfigRequest":{"required":true,"content":{"application/json":{}}},"InstallRequest":{"content":{"application/json":{}}}}}}')}},r={},t=function t(n){var o=r[n];if(void 0!==o)return o.exports;var p=r[n]={exports:{}};return e[n].call(p.exports,p,p.exports,t),p.exports}(330),n=exports;for(var o in t)n[o]=t[o];t.__esModule&&Object.defineProperty(n,"__esModule",{value:!0})})();
@@ -535,6 +535,28 @@
535
535
  }
536
536
  },
537
537
  "responses": {}
538
+ },
539
+ "put": {
540
+ "operationId": "publicProxyPut",
541
+ "requestBody": {
542
+ "content": {
543
+ "application/json": {}
544
+ }
545
+ },
546
+ "responses": {}
547
+ },
548
+ "patch": {
549
+ "operationId": "publicProxyPatch",
550
+ "requestBody": {
551
+ "content": {
552
+ "application/json": {}
553
+ }
554
+ },
555
+ "responses": {}
556
+ },
557
+ "delete": {
558
+ "operationId": "publicProxyDelete",
559
+ "responses": {}
538
560
  }
539
561
  }
540
562
  },
package/dist/openapi.d.ts CHANGED
@@ -151,9 +151,9 @@ declare namespace Components {
151
151
  */
152
152
  name: string; // ^[a-zA-Z0-9_-]+$
153
153
  /**
154
- * Base URL of the target API. Must be HTTPS.
154
+ * Base URL of the target API. Must be HTTPS. May reference component options via {{option_key}} interpolation (resolved from decrypted values), e.g. "https://{{cluster}}.example.com/api" for a per-installation host. The fully-resolved URL is validated at request time (SSRF protection).
155
155
  */
156
- target: string; // uri ^https://
156
+ target: string; // ^https://
157
157
  /**
158
158
  * Authentication strategy
159
159
  */
@@ -166,6 +166,12 @@ declare namespace Components {
166
166
  * OAuth2 token endpoint URL
167
167
  */
168
168
  token_url?: string; // uri ^https://
169
+ /**
170
+ * Additional request headers injected server-side on every proxied request. Values may reference component options via {{option_key}} interpolation (resolved from decrypted secrets), so credentials are never exposed to the client. Applied in addition to auth_type.
171
+ */
172
+ headers?: {
173
+ [name: string]: string;
174
+ };
169
175
  }
170
176
  export interface AppBridgeSurfaceConfig {
171
177
  /**
@@ -851,7 +857,7 @@ declare namespace Components {
851
857
  /**
852
858
  * Define what type of capability this is
853
859
  */
854
- type?: "tab" | "group";
860
+ type?: "tab" | "group" | "widget";
855
861
  /**
856
862
  * Which schemas are supported by the capability. If empty, all schemas are supported.
857
863
  */
@@ -1595,7 +1601,38 @@ declare namespace Components {
1595
1601
  * The portal looks up this hook implicitly per extension (one `visualizationMetadata` hook per extension) — there is no need for a data-retrieval hook to reference it explicitly.
1596
1602
  *
1597
1603
  */
1598
- PortalExtensionHookVisualizationMetadata)[];
1604
+ PortalExtensionHookVisualizationMetadata | /**
1605
+ * Hook that replaces the built-in change email functionality for portal users. When configured, the portal does not run its own change email flow. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the email change.
1606
+ * The `change_mode` controls what the portal does after the call:
1607
+ * - `asynchronous`: The third-party system takes the email change over entirely (most likely by sending the user instructions to confirm the new email address). The portal does not change the login email itself.
1608
+ * - `synchronous`: The third-party system applies the email change immediately. The portal waits for a successful (2xx) response and then also changes the portal user's login email right away, without sending a confirmation email. The user has to sign in again with the new email address afterwards.
1609
+ *
1610
+ * The expected response http status code to the call is:
1611
+ * - 2xx if the request was accepted
1612
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
1613
+ *
1614
+ */
1615
+ PortalExtensionHookChangeEmail | /**
1616
+ * Hook that replaces the built-in change password functionality for portal users. When configured, the portal does not change the user's password itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the password change (most likely by sending the user instructions to complete the process).
1617
+ * The expected response http status code to the call is:
1618
+ * - 2xx if the request was accepted
1619
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
1620
+ *
1621
+ */
1622
+ PortalExtensionHookChangePassword | /**
1623
+ * Hook that replaces the built-in delete account functionality for portal users. When configured, the portal does not delete the user itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the deletion.
1624
+ * The `deletion_mode` controls what the portal does after the call:
1625
+ * - `synchronous`: The third-party system deletes the user immediately. The portal waits for a successful (2xx) response and then also deletes the corresponding epilot Cognito user.
1626
+ * - `asynchronous`: The third-party system handles deletion out-of-band. The portal does not delete anything immediately; cleanup is expected to happen later (e.g. via the user deletion API or webhooks).
1627
+ *
1628
+ * The optional `delete_contact` additionally deletes the contact related to the portal user, once the portal user itself was deleted (`synchronous` mode only).
1629
+ *
1630
+ * The expected response http status code to the call is:
1631
+ * - 2xx if the request was accepted
1632
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
1633
+ *
1634
+ */
1635
+ PortalExtensionHookDeleteAccount)[];
1599
1636
  links?: {
1600
1637
  /**
1601
1638
  * Identifier of the link. Should not change between updates.
@@ -1625,6 +1662,159 @@ declare namespace Components {
1625
1662
  };
1626
1663
  }[];
1627
1664
  }
1665
+ /**
1666
+ * Hook that replaces the built-in change email functionality for portal users. When configured, the portal does not run its own change email flow. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the email change.
1667
+ * The `change_mode` controls what the portal does after the call:
1668
+ * - `asynchronous`: The third-party system takes the email change over entirely (most likely by sending the user instructions to confirm the new email address). The portal does not change the login email itself.
1669
+ * - `synchronous`: The third-party system applies the email change immediately. The portal waits for a successful (2xx) response and then also changes the portal user's login email right away, without sending a confirmation email. The user has to sign in again with the new email address afterwards.
1670
+ *
1671
+ * The expected response http status code to the call is:
1672
+ * - 2xx if the request was accepted
1673
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
1674
+ *
1675
+ */
1676
+ export interface PortalExtensionHookChangeEmail {
1677
+ /**
1678
+ * Identifier of the hook. Should not change between updates.
1679
+ */
1680
+ id: string; // ^[a-zA-Z0-9_-]+$
1681
+ name?: TranslatedString;
1682
+ type: "changeEmail";
1683
+ /**
1684
+ * Controls how the email change is handled once the third-party system accepted it. `asynchronous` hands the email change over entirely to the third-party system and the portal does not change the login email itself. `synchronous` waits for the third-party system to respond and then changes the portal user's login email immediately, without a confirmation email.
1685
+ *
1686
+ */
1687
+ change_mode?: "synchronous" | "asynchronous";
1688
+ /**
1689
+ * Whether the portal user must confirm their current password before the change email request is handed over to the third-party system. When true, the portal collects and verifies the current password before calling the hook. Skipped for portal users whose identity is managed by an identity provider: an SSO login has no password to confirm. When no password is confirmed and `change_mode` is `synchronous`, the re-created login gets a random password and the portal user signs in through their identity provider, or sets a new password via the email code flow.
1690
+ *
1691
+ */
1692
+ require_password_confirmation?: boolean;
1693
+ /**
1694
+ * Optional explanation shown to the user in the change email confirmation dialog.
1695
+ */
1696
+ explanation?: {
1697
+ [name: string]: string;
1698
+ /**
1699
+ * Explanation of the functionality shown to the end user.
1700
+ * example:
1701
+ * You will receive an email with instructions to confirm your new email address.
1702
+ */
1703
+ en: string;
1704
+ };
1705
+ auth?: PortalExtensionAuthBlock;
1706
+ call: {
1707
+ /**
1708
+ * HTTP method to use for the call
1709
+ */
1710
+ method?: string;
1711
+ /**
1712
+ * URL to call. Supports variable interpolation.
1713
+ */
1714
+ url: string;
1715
+ /**
1716
+ * Parameters to append to the URL. Supports variable interpolation.
1717
+ */
1718
+ params?: {
1719
+ [name: string]: string;
1720
+ };
1721
+ /**
1722
+ * Headers to use. Supports variable interpolation.
1723
+ */
1724
+ headers: {
1725
+ [name: string]: string;
1726
+ };
1727
+ /**
1728
+ * Optional JSON body to use for the call. Defaults to an object with the requested new email and portal user context, e.g. `{"new_email": "...", "old_email": "...", "portal_user_id": "..."}`. The requested new email is available as `{{Input.new_email}}` and the current account email as `{{Input.old_email}}`. Supports variable interpolation.
1729
+ */
1730
+ body?: {
1731
+ [key: string]: any;
1732
+ };
1733
+ };
1734
+ resolved?: {
1735
+ /**
1736
+ * Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).
1737
+ * If specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.
1738
+ *
1739
+ * example:
1740
+ * error.message
1741
+ */
1742
+ error_message_path?: string;
1743
+ };
1744
+ secure_proxy?: /* If set, requests are routed through the ERP Integration secure proxy. Mutually exclusive with use_static_ips. */ PortalExtensionSecureProxy;
1745
+ }
1746
+ /**
1747
+ * Hook that replaces the built-in change password functionality for portal users. When configured, the portal does not change the user's password itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the password change (most likely by sending the user instructions to complete the process).
1748
+ * The expected response http status code to the call is:
1749
+ * - 2xx if the request was accepted
1750
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
1751
+ *
1752
+ */
1753
+ export interface PortalExtensionHookChangePassword {
1754
+ /**
1755
+ * Identifier of the hook. Should not change between updates.
1756
+ */
1757
+ id: string; // ^[a-zA-Z0-9_-]+$
1758
+ name?: TranslatedString;
1759
+ type: "changePassword";
1760
+ /**
1761
+ * Whether the portal user must provide a new password. When false, the portal only asks the user to confirm (showing the configured explanation) and no new password is collected; the third-party system is expected to handle the password change. When true, the portal collects a new password and passes it to the third-party system as `{{Input.new_password}}`.
1762
+ *
1763
+ */
1764
+ require_new_password?: boolean;
1765
+ /**
1766
+ * Optional explanation shown to the user in the change password confirmation dialog.
1767
+ */
1768
+ explanation?: {
1769
+ [name: string]: string;
1770
+ /**
1771
+ * Explanation of the functionality shown to the end user.
1772
+ * example:
1773
+ * You will receive an email with instructions to reset your password.
1774
+ */
1775
+ en: string;
1776
+ };
1777
+ auth?: PortalExtensionAuthBlock;
1778
+ call: {
1779
+ /**
1780
+ * HTTP method to use for the call
1781
+ */
1782
+ method?: string;
1783
+ /**
1784
+ * URL to call. Supports variable interpolation.
1785
+ */
1786
+ url: string;
1787
+ /**
1788
+ * Parameters to append to the URL. Supports variable interpolation.
1789
+ */
1790
+ params?: {
1791
+ [name: string]: string;
1792
+ };
1793
+ /**
1794
+ * Headers to use. Supports variable interpolation.
1795
+ */
1796
+ headers: {
1797
+ [name: string]: string;
1798
+ };
1799
+ /**
1800
+ * Optional JSON body to use for the call. Defaults to an object with portal user context (and the new password as `{{Input.new_password}}` when `require_new_password` is true). Supports variable interpolation.
1801
+ */
1802
+ body?: {
1803
+ [key: string]: any;
1804
+ };
1805
+ };
1806
+ resolved?: {
1807
+ /**
1808
+ * Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).
1809
+ * If specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.
1810
+ *
1811
+ * example:
1812
+ * error.message
1813
+ */
1814
+ error_message_path?: string;
1815
+ };
1816
+ secure_proxy?: /* If set, requests are routed through the ERP Integration secure proxy. Mutually exclusive with use_static_ips. */ PortalExtensionSecureProxy;
1817
+ }
1628
1818
  /**
1629
1819
  * Hook that will allow using the specified source as data for consumption visualizations. This hook is triggered to fetch the data. Format of the request and response has to follow the following specification: TBD. The expected response to the call is:
1630
1820
  * - 200 with the time series data
@@ -1936,6 +2126,89 @@ declare namespace Components {
1936
2126
  use_static_ips?: boolean;
1937
2127
  secure_proxy?: /* If set, requests are routed through the ERP Integration secure proxy. Mutually exclusive with use_static_ips. */ PortalExtensionSecureProxy;
1938
2128
  }
2129
+ /**
2130
+ * Hook that replaces the built-in delete account functionality for portal users. When configured, the portal does not delete the user itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the deletion.
2131
+ * The `deletion_mode` controls what the portal does after the call:
2132
+ * - `synchronous`: The third-party system deletes the user immediately. The portal waits for a successful (2xx) response and then also deletes the corresponding epilot Cognito user.
2133
+ * - `asynchronous`: The third-party system handles deletion out-of-band. The portal does not delete anything immediately; cleanup is expected to happen later (e.g. via the user deletion API or webhooks).
2134
+ *
2135
+ * The optional `delete_contact` additionally deletes the contact related to the portal user, once the portal user itself was deleted (`synchronous` mode only).
2136
+ *
2137
+ * The expected response http status code to the call is:
2138
+ * - 2xx if the request was accepted
2139
+ * - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)
2140
+ *
2141
+ */
2142
+ export interface PortalExtensionHookDeleteAccount {
2143
+ /**
2144
+ * Identifier of the hook. Should not change between updates.
2145
+ */
2146
+ id: string; // ^[a-zA-Z0-9_-]+$
2147
+ name?: TranslatedString;
2148
+ type: "deleteAccount";
2149
+ /**
2150
+ * Controls how the account deletion is handled. `synchronous` waits for the third-party system to respond and then also deletes the epilot user. `asynchronous` hands the deletion over entirely to the third-party system and the portal does not delete anything immediately.
2151
+ *
2152
+ */
2153
+ deletion_mode?: "synchronous" | "asynchronous";
2154
+ /**
2155
+ * Opt-in deletion of the contact related to the portal user, applied after the portal user itself was deleted. `none` (default) leaves the contact untouched. `soft` deletes the contact, so it can still be restored from the trash. `hard` permanently purges the contact. Only applied in `synchronous` deletion mode, as `asynchronous` mode hands the cleanup over to the third-party system.
2156
+ *
2157
+ */
2158
+ delete_contact?: "none" | "soft" | "hard";
2159
+ /**
2160
+ * Optional explanation shown to the user in the delete account confirmation dialog.
2161
+ */
2162
+ explanation?: {
2163
+ [name: string]: string;
2164
+ /**
2165
+ * Explanation of the functionality shown to the end user.
2166
+ * example:
2167
+ * Your account deletion will be processed by our system. This may take a few days.
2168
+ */
2169
+ en: string;
2170
+ };
2171
+ auth?: PortalExtensionAuthBlock;
2172
+ call: {
2173
+ /**
2174
+ * HTTP method to use for the call
2175
+ */
2176
+ method?: string;
2177
+ /**
2178
+ * URL to call. Supports variable interpolation.
2179
+ */
2180
+ url: string;
2181
+ /**
2182
+ * Parameters to append to the URL. Supports variable interpolation.
2183
+ */
2184
+ params?: {
2185
+ [name: string]: string;
2186
+ };
2187
+ /**
2188
+ * Headers to use. Supports variable interpolation.
2189
+ */
2190
+ headers: {
2191
+ [name: string]: string;
2192
+ };
2193
+ /**
2194
+ * Optional JSON body to use for the call. Defaults to an object with portal user context, e.g. `{"portal_user_id": "...", "email": "..."}`. Supports variable interpolation.
2195
+ */
2196
+ body?: {
2197
+ [key: string]: any;
2198
+ };
2199
+ };
2200
+ resolved?: {
2201
+ /**
2202
+ * Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).
2203
+ * If specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.
2204
+ *
2205
+ * example:
2206
+ * error.message
2207
+ */
2208
+ error_message_path?: string;
2209
+ };
2210
+ secure_proxy?: /* If set, requests are routed through the ERP Integration secure proxy. Mutually exclusive with use_static_ips. */ PortalExtensionSecureProxy;
2211
+ }
1939
2212
  /**
1940
2213
  * Hook that checks the plausibility of meter readings before they are saved. This hook makes a POST call whenever a user is trying to save a meter reading. The expected response to the call is:
1941
2214
  * - 200:
@@ -2987,6 +3260,18 @@ declare namespace Paths {
2987
3260
  }
2988
3261
  }
2989
3262
  }
3263
+ namespace PublicProxyDelete {
3264
+ namespace Responses {
3265
+ export interface $200 {
3266
+ }
3267
+ export interface $403 {
3268
+ }
3269
+ export interface $404 {
3270
+ }
3271
+ export interface $502 {
3272
+ }
3273
+ }
3274
+ }
2990
3275
  namespace PublicProxyGet {
2991
3276
  namespace Responses {
2992
3277
  export interface $200 {
@@ -2999,6 +3284,20 @@ declare namespace Paths {
2999
3284
  }
3000
3285
  }
3001
3286
  }
3287
+ namespace PublicProxyPatch {
3288
+ export interface RequestBody {
3289
+ }
3290
+ namespace Responses {
3291
+ export interface $200 {
3292
+ }
3293
+ export interface $403 {
3294
+ }
3295
+ export interface $404 {
3296
+ }
3297
+ export interface $502 {
3298
+ }
3299
+ }
3300
+ }
3002
3301
  namespace PublicProxyPost {
3003
3302
  export interface RequestBody {
3004
3303
  }
@@ -3013,6 +3312,20 @@ declare namespace Paths {
3013
3312
  }
3014
3313
  }
3015
3314
  }
3315
+ namespace PublicProxyPut {
3316
+ export interface RequestBody {
3317
+ }
3318
+ namespace Responses {
3319
+ export interface $200 {
3320
+ }
3321
+ export interface $403 {
3322
+ }
3323
+ export interface $404 {
3324
+ }
3325
+ export interface $502 {
3326
+ }
3327
+ }
3328
+ }
3016
3329
  namespace QueryEvents {
3017
3330
  namespace Parameters {
3018
3331
  export type AppId = string;
@@ -3404,6 +3717,16 @@ export interface OperationMethods {
3404
3717
  data?: any,
3405
3718
  config?: AxiosRequestConfig
3406
3719
  ): OperationResponse<Paths.PublicProxyGet.Responses.$200>
3720
+ /**
3721
+ * publicProxyPut - publicProxyPut
3722
+ *
3723
+ * Forward a PUT request to a registered proxy target from a public-facing component
3724
+ */
3725
+ 'publicProxyPut'(
3726
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
3727
+ data?: Paths.PublicProxyPut.RequestBody,
3728
+ config?: AxiosRequestConfig
3729
+ ): OperationResponse<Paths.PublicProxyPut.Responses.$200>
3407
3730
  /**
3408
3731
  * publicProxyPost - publicProxyPost
3409
3732
  *
@@ -3414,6 +3737,26 @@ export interface OperationMethods {
3414
3737
  data?: Paths.PublicProxyPost.RequestBody,
3415
3738
  config?: AxiosRequestConfig
3416
3739
  ): OperationResponse<Paths.PublicProxyPost.Responses.$200>
3740
+ /**
3741
+ * publicProxyPatch - publicProxyPatch
3742
+ *
3743
+ * Forward a PATCH request to a registered proxy target from a public-facing component
3744
+ */
3745
+ 'publicProxyPatch'(
3746
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
3747
+ data?: Paths.PublicProxyPatch.RequestBody,
3748
+ config?: AxiosRequestConfig
3749
+ ): OperationResponse<Paths.PublicProxyPatch.Responses.$200>
3750
+ /**
3751
+ * publicProxyDelete - publicProxyDelete
3752
+ *
3753
+ * Forward a DELETE request to a registered proxy target from a public-facing component
3754
+ */
3755
+ 'publicProxyDelete'(
3756
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
3757
+ data?: any,
3758
+ config?: AxiosRequestConfig
3759
+ ): OperationResponse<Paths.PublicProxyDelete.Responses.$200>
3417
3760
  }
3418
3761
 
3419
3762
  export interface PathsDictionary {
@@ -3777,6 +4120,36 @@ export interface PathsDictionary {
3777
4120
  data?: Paths.PublicProxyPost.RequestBody,
3778
4121
  config?: AxiosRequestConfig
3779
4122
  ): OperationResponse<Paths.PublicProxyPost.Responses.$200>
4123
+ /**
4124
+ * publicProxyPut - publicProxyPut
4125
+ *
4126
+ * Forward a PUT request to a registered proxy target from a public-facing component
4127
+ */
4128
+ 'put'(
4129
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
4130
+ data?: Paths.PublicProxyPut.RequestBody,
4131
+ config?: AxiosRequestConfig
4132
+ ): OperationResponse<Paths.PublicProxyPut.Responses.$200>
4133
+ /**
4134
+ * publicProxyPatch - publicProxyPatch
4135
+ *
4136
+ * Forward a PATCH request to a registered proxy target from a public-facing component
4137
+ */
4138
+ 'patch'(
4139
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
4140
+ data?: Paths.PublicProxyPatch.RequestBody,
4141
+ config?: AxiosRequestConfig
4142
+ ): OperationResponse<Paths.PublicProxyPatch.Responses.$200>
4143
+ /**
4144
+ * publicProxyDelete - publicProxyDelete
4145
+ *
4146
+ * Forward a DELETE request to a registered proxy target from a public-facing component
4147
+ */
4148
+ 'delete'(
4149
+ parameters?: Parameters<Paths.V1PublicApp$AppIdProxy$ProxyName$Path.PathParameters> | null,
4150
+ data?: any,
4151
+ config?: AxiosRequestConfig
4152
+ ): OperationResponse<Paths.PublicProxyDelete.Responses.$200>
3780
4153
  }
3781
4154
  }
3782
4155
 
@@ -3837,10 +4210,13 @@ export type PortalBlockSurfaceConfig = Components.Schemas.PortalBlockSurfaceConf
3837
4210
  export type PortalExtensionAuthBlock = Components.Schemas.PortalExtensionAuthBlock;
3838
4211
  export type PortalExtensionComponent = Components.Schemas.PortalExtensionComponent;
3839
4212
  export type PortalExtensionConfig = Components.Schemas.PortalExtensionConfig;
4213
+ export type PortalExtensionHookChangeEmail = Components.Schemas.PortalExtensionHookChangeEmail;
4214
+ export type PortalExtensionHookChangePassword = Components.Schemas.PortalExtensionHookChangePassword;
3840
4215
  export type PortalExtensionHookConsumptionDataRetrieval = Components.Schemas.PortalExtensionHookConsumptionDataRetrieval;
3841
4216
  export type PortalExtensionHookContractIdentification = Components.Schemas.PortalExtensionHookContractIdentification;
3842
4217
  export type PortalExtensionHookCostDataRetrieval = Components.Schemas.PortalExtensionHookCostDataRetrieval;
3843
4218
  export type PortalExtensionHookDataExport = Components.Schemas.PortalExtensionHookDataExport;
4219
+ export type PortalExtensionHookDeleteAccount = Components.Schemas.PortalExtensionHookDeleteAccount;
3844
4220
  export type PortalExtensionHookMeterReadingPlausibilityCheck = Components.Schemas.PortalExtensionHookMeterReadingPlausibilityCheck;
3845
4221
  export type PortalExtensionHookPriceDataRetrieval = Components.Schemas.PortalExtensionHookPriceDataRetrieval;
3846
4222
  export type PortalExtensionHookRegistrationIdentifiersCheck = Components.Schemas.PortalExtensionHookRegistrationIdentifiersCheck;
package/dist/openapi.json CHANGED
@@ -1565,6 +1565,105 @@
1565
1565
  "description": "Bad gateway - proxy target unreachable or error"
1566
1566
  }
1567
1567
  }
1568
+ },
1569
+ "put": {
1570
+ "summary": "publicProxyPut",
1571
+ "operationId": "publicProxyPut",
1572
+ "description": "Forward a PUT request to a registered proxy target from a public-facing component",
1573
+ "tags": [
1574
+ "App Proxy"
1575
+ ],
1576
+ "security": [
1577
+ {
1578
+ "EpilotAuth": []
1579
+ }
1580
+ ],
1581
+ "requestBody": {
1582
+ "content": {
1583
+ "application/json": {
1584
+ "schema": {
1585
+ "type": "object"
1586
+ }
1587
+ }
1588
+ }
1589
+ },
1590
+ "responses": {
1591
+ "200": {
1592
+ "description": "Proxied response from the target API"
1593
+ },
1594
+ "403": {
1595
+ "description": "Forbidden - app not installed or no public component uses this proxy"
1596
+ },
1597
+ "404": {
1598
+ "description": "Proxy target not found"
1599
+ },
1600
+ "502": {
1601
+ "description": "Bad gateway - proxy target unreachable or error"
1602
+ }
1603
+ }
1604
+ },
1605
+ "patch": {
1606
+ "summary": "publicProxyPatch",
1607
+ "operationId": "publicProxyPatch",
1608
+ "description": "Forward a PATCH request to a registered proxy target from a public-facing component",
1609
+ "tags": [
1610
+ "App Proxy"
1611
+ ],
1612
+ "security": [
1613
+ {
1614
+ "EpilotAuth": []
1615
+ }
1616
+ ],
1617
+ "requestBody": {
1618
+ "content": {
1619
+ "application/json": {
1620
+ "schema": {
1621
+ "type": "object"
1622
+ }
1623
+ }
1624
+ }
1625
+ },
1626
+ "responses": {
1627
+ "200": {
1628
+ "description": "Proxied response from the target API"
1629
+ },
1630
+ "403": {
1631
+ "description": "Forbidden - app not installed or no public component uses this proxy"
1632
+ },
1633
+ "404": {
1634
+ "description": "Proxy target not found"
1635
+ },
1636
+ "502": {
1637
+ "description": "Bad gateway - proxy target unreachable or error"
1638
+ }
1639
+ }
1640
+ },
1641
+ "delete": {
1642
+ "summary": "publicProxyDelete",
1643
+ "operationId": "publicProxyDelete",
1644
+ "description": "Forward a DELETE request to a registered proxy target from a public-facing component",
1645
+ "tags": [
1646
+ "App Proxy"
1647
+ ],
1648
+ "security": [
1649
+ {
1650
+ "EpilotAuth": []
1651
+ }
1652
+ ],
1653
+ "responses": {
1654
+ "200": {
1655
+ "description": "Proxied response from the target API"
1656
+ },
1657
+ "403": {
1658
+ "description": "Forbidden - app not installed or no public component uses this proxy"
1659
+ },
1660
+ "404": {
1661
+ "description": "Proxy target not found"
1662
+ },
1663
+ "502": {
1664
+ "description": "Bad gateway - proxy target unreachable or error"
1665
+ }
1666
+ }
1568
1667
  }
1569
1668
  }
1570
1669
  },
@@ -2157,7 +2256,8 @@
2157
2256
  "type": "string",
2158
2257
  "enum": [
2159
2258
  "tab",
2160
- "group"
2259
+ "group",
2260
+ "widget"
2161
2261
  ]
2162
2262
  },
2163
2263
  "allowed_schemas": {
@@ -2651,7 +2751,10 @@
2651
2751
  "dataExport": "#/components/schemas/PortalExtensionHookDataExport",
2652
2752
  "costDataRetrieval": "#/components/schemas/PortalExtensionHookCostDataRetrieval",
2653
2753
  "meterReadingPlausibilityCheck": "#/components/schemas/PortalExtensionHookMeterReadingPlausibilityCheck",
2654
- "visualizationMetadata": "#/components/schemas/PortalExtensionHookVisualizationMetadata"
2754
+ "visualizationMetadata": "#/components/schemas/PortalExtensionHookVisualizationMetadata",
2755
+ "changeEmail": "#/components/schemas/PortalExtensionHookChangeEmail",
2756
+ "changePassword": "#/components/schemas/PortalExtensionHookChangePassword",
2757
+ "deleteAccount": "#/components/schemas/PortalExtensionHookDeleteAccount"
2655
2758
  }
2656
2759
  },
2657
2760
  "oneOf": [
@@ -2678,6 +2781,15 @@
2678
2781
  },
2679
2782
  {
2680
2783
  "$ref": "#/components/schemas/PortalExtensionHookVisualizationMetadata"
2784
+ },
2785
+ {
2786
+ "$ref": "#/components/schemas/PortalExtensionHookChangeEmail"
2787
+ },
2788
+ {
2789
+ "$ref": "#/components/schemas/PortalExtensionHookChangePassword"
2790
+ },
2791
+ {
2792
+ "$ref": "#/components/schemas/PortalExtensionHookDeleteAccount"
2681
2793
  }
2682
2794
  ]
2683
2795
  }
@@ -3571,6 +3683,344 @@
3571
3683
  ],
3572
3684
  "additionalProperties": false
3573
3685
  },
3686
+ "PortalExtensionHookChangeEmail": {
3687
+ "description": "Hook that replaces the built-in change email functionality for portal users. When configured, the portal does not run its own change email flow. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the email change.\nThe `change_mode` controls what the portal does after the call:\n - `asynchronous`: The third-party system takes the email change over entirely (most likely by sending the user instructions to confirm the new email address). The portal does not change the login email itself.\n - `synchronous`: The third-party system applies the email change immediately. The portal waits for a successful (2xx) response and then also changes the portal user's login email right away, without sending a confirmation email. The user has to sign in again with the new email address afterwards.\n\nThe expected response http status code to the call is:\n - 2xx if the request was accepted\n - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)\n",
3688
+ "type": "object",
3689
+ "properties": {
3690
+ "id": {
3691
+ "type": "string",
3692
+ "pattern": "^[a-zA-Z0-9_-]+$",
3693
+ "description": "Identifier of the hook. Should not change between updates."
3694
+ },
3695
+ "name": {
3696
+ "$ref": "#/components/schemas/TranslatedString"
3697
+ },
3698
+ "type": {
3699
+ "type": "string",
3700
+ "enum": [
3701
+ "changeEmail"
3702
+ ]
3703
+ },
3704
+ "change_mode": {
3705
+ "type": "string",
3706
+ "enum": [
3707
+ "synchronous",
3708
+ "asynchronous"
3709
+ ],
3710
+ "description": "Controls how the email change is handled once the third-party system accepted it. `asynchronous` hands the email change over entirely to the third-party system and the portal does not change the login email itself. `synchronous` waits for the third-party system to respond and then changes the portal user's login email immediately, without a confirmation email.\n",
3711
+ "default": "asynchronous"
3712
+ },
3713
+ "require_password_confirmation": {
3714
+ "type": "boolean",
3715
+ "description": "Whether the portal user must confirm their current password before the change email request is handed over to the third-party system. When true, the portal collects and verifies the current password before calling the hook. Skipped for portal users whose identity is managed by an identity provider: an SSO login has no password to confirm. When no password is confirmed and `change_mode` is `synchronous`, the re-created login gets a random password and the portal user signs in through their identity provider, or sets a new password via the email code flow.\n",
3716
+ "default": true
3717
+ },
3718
+ "explanation": {
3719
+ "type": "object",
3720
+ "properties": {
3721
+ "en": {
3722
+ "type": "string",
3723
+ "description": "Explanation of the functionality shown to the end user.",
3724
+ "example": "You will receive an email with instructions to confirm your new email address."
3725
+ }
3726
+ },
3727
+ "additionalProperties": {
3728
+ "type": "string",
3729
+ "description": "Explanation of the functionality in language denoted by ISO 3166-1 alpha-2 code."
3730
+ },
3731
+ "required": [
3732
+ "en"
3733
+ ],
3734
+ "description": "Optional explanation shown to the user in the change email confirmation dialog."
3735
+ },
3736
+ "auth": {
3737
+ "$ref": "#/components/schemas/PortalExtensionAuthBlock"
3738
+ },
3739
+ "call": {
3740
+ "type": "object",
3741
+ "properties": {
3742
+ "method": {
3743
+ "type": "string",
3744
+ "description": "HTTP method to use for the call",
3745
+ "default": "POST"
3746
+ },
3747
+ "url": {
3748
+ "type": "string",
3749
+ "description": "URL to call. Supports variable interpolation."
3750
+ },
3751
+ "params": {
3752
+ "type": "object",
3753
+ "description": "Parameters to append to the URL. Supports variable interpolation.",
3754
+ "additionalProperties": {
3755
+ "type": "string"
3756
+ },
3757
+ "default": {}
3758
+ },
3759
+ "headers": {
3760
+ "type": "object",
3761
+ "description": "Headers to use. Supports variable interpolation.",
3762
+ "additionalProperties": {
3763
+ "type": "string"
3764
+ },
3765
+ "default": {}
3766
+ },
3767
+ "body": {
3768
+ "type": "object",
3769
+ "description": "Optional JSON body to use for the call. Defaults to an object with the requested new email and portal user context, e.g. `{\"new_email\": \"...\", \"old_email\": \"...\", \"portal_user_id\": \"...\"}`. The requested new email is available as `{{Input.new_email}}` and the current account email as `{{Input.old_email}}`. Supports variable interpolation."
3770
+ }
3771
+ },
3772
+ "required": [
3773
+ "url",
3774
+ "headers"
3775
+ ],
3776
+ "additionalProperties": false
3777
+ },
3778
+ "resolved": {
3779
+ "type": "object",
3780
+ "properties": {
3781
+ "error_message_path": {
3782
+ "type": "string",
3783
+ "description": "Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).\nIf specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.\n",
3784
+ "example": "error.message"
3785
+ }
3786
+ },
3787
+ "additionalProperties": false
3788
+ },
3789
+ "secure_proxy": {
3790
+ "$ref": "#/components/schemas/PortalExtensionSecureProxy"
3791
+ }
3792
+ },
3793
+ "required": [
3794
+ "id",
3795
+ "type",
3796
+ "call"
3797
+ ],
3798
+ "additionalProperties": false
3799
+ },
3800
+ "PortalExtensionHookChangePassword": {
3801
+ "description": "Hook that replaces the built-in change password functionality for portal users. When configured, the portal does not change the user's password itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the password change (most likely by sending the user instructions to complete the process).\nThe expected response http status code to the call is:\n - 2xx if the request was accepted\n - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)\n",
3802
+ "type": "object",
3803
+ "properties": {
3804
+ "id": {
3805
+ "type": "string",
3806
+ "pattern": "^[a-zA-Z0-9_-]+$",
3807
+ "description": "Identifier of the hook. Should not change between updates."
3808
+ },
3809
+ "name": {
3810
+ "$ref": "#/components/schemas/TranslatedString"
3811
+ },
3812
+ "type": {
3813
+ "type": "string",
3814
+ "enum": [
3815
+ "changePassword"
3816
+ ]
3817
+ },
3818
+ "require_new_password": {
3819
+ "type": "boolean",
3820
+ "description": "Whether the portal user must provide a new password. When false, the portal only asks the user to confirm (showing the configured explanation) and no new password is collected; the third-party system is expected to handle the password change. When true, the portal collects a new password and passes it to the third-party system as `{{Input.new_password}}`.\n",
3821
+ "default": false
3822
+ },
3823
+ "explanation": {
3824
+ "type": "object",
3825
+ "properties": {
3826
+ "en": {
3827
+ "type": "string",
3828
+ "description": "Explanation of the functionality shown to the end user.",
3829
+ "example": "You will receive an email with instructions to reset your password."
3830
+ }
3831
+ },
3832
+ "additionalProperties": {
3833
+ "type": "string",
3834
+ "description": "Explanation of the functionality in language denoted by ISO 3166-1 alpha-2 code."
3835
+ },
3836
+ "required": [
3837
+ "en"
3838
+ ],
3839
+ "description": "Optional explanation shown to the user in the change password confirmation dialog."
3840
+ },
3841
+ "auth": {
3842
+ "$ref": "#/components/schemas/PortalExtensionAuthBlock"
3843
+ },
3844
+ "call": {
3845
+ "type": "object",
3846
+ "properties": {
3847
+ "method": {
3848
+ "type": "string",
3849
+ "description": "HTTP method to use for the call",
3850
+ "default": "POST"
3851
+ },
3852
+ "url": {
3853
+ "type": "string",
3854
+ "description": "URL to call. Supports variable interpolation."
3855
+ },
3856
+ "params": {
3857
+ "type": "object",
3858
+ "description": "Parameters to append to the URL. Supports variable interpolation.",
3859
+ "additionalProperties": {
3860
+ "type": "string"
3861
+ },
3862
+ "default": {}
3863
+ },
3864
+ "headers": {
3865
+ "type": "object",
3866
+ "description": "Headers to use. Supports variable interpolation.",
3867
+ "additionalProperties": {
3868
+ "type": "string"
3869
+ },
3870
+ "default": {}
3871
+ },
3872
+ "body": {
3873
+ "type": "object",
3874
+ "description": "Optional JSON body to use for the call. Defaults to an object with portal user context (and the new password as `{{Input.new_password}}` when `require_new_password` is true). Supports variable interpolation."
3875
+ }
3876
+ },
3877
+ "required": [
3878
+ "url",
3879
+ "headers"
3880
+ ],
3881
+ "additionalProperties": false
3882
+ },
3883
+ "resolved": {
3884
+ "type": "object",
3885
+ "properties": {
3886
+ "error_message_path": {
3887
+ "type": "string",
3888
+ "description": "Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).\nIf specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.\n",
3889
+ "example": "error.message"
3890
+ }
3891
+ },
3892
+ "additionalProperties": false
3893
+ },
3894
+ "secure_proxy": {
3895
+ "$ref": "#/components/schemas/PortalExtensionSecureProxy"
3896
+ }
3897
+ },
3898
+ "required": [
3899
+ "id",
3900
+ "type",
3901
+ "call"
3902
+ ],
3903
+ "additionalProperties": false
3904
+ },
3905
+ "PortalExtensionHookDeleteAccount": {
3906
+ "description": "Hook that replaces the built-in delete account functionality for portal users. When configured, the portal does not delete the user itself. Instead, this hook makes an HTTP call to the third-party system, which is expected to handle the deletion.\nThe `deletion_mode` controls what the portal does after the call:\n - `synchronous`: The third-party system deletes the user immediately. The portal waits for a successful (2xx) response and then also deletes the corresponding epilot Cognito user.\n - `asynchronous`: The third-party system handles deletion out-of-band. The portal does not delete anything immediately; cleanup is expected to happen later (e.g. via the user deletion API or webhooks).\n\nThe optional `delete_contact` additionally deletes the contact related to the portal user, once the portal user itself was deleted (`synchronous` mode only).\n\nThe expected response http status code to the call is:\n - 2xx if the request was accepted\n - non-2xx if the request failed (optionally with a human-readable message resolved via `resolved.error_message_path`)\n",
3907
+ "type": "object",
3908
+ "properties": {
3909
+ "id": {
3910
+ "type": "string",
3911
+ "pattern": "^[a-zA-Z0-9_-]+$",
3912
+ "description": "Identifier of the hook. Should not change between updates."
3913
+ },
3914
+ "name": {
3915
+ "$ref": "#/components/schemas/TranslatedString"
3916
+ },
3917
+ "type": {
3918
+ "type": "string",
3919
+ "enum": [
3920
+ "deleteAccount"
3921
+ ]
3922
+ },
3923
+ "deletion_mode": {
3924
+ "type": "string",
3925
+ "enum": [
3926
+ "synchronous",
3927
+ "asynchronous"
3928
+ ],
3929
+ "description": "Controls how the account deletion is handled. `synchronous` waits for the third-party system to respond and then also deletes the epilot user. `asynchronous` hands the deletion over entirely to the third-party system and the portal does not delete anything immediately.\n",
3930
+ "default": "synchronous"
3931
+ },
3932
+ "delete_contact": {
3933
+ "type": "string",
3934
+ "enum": [
3935
+ "none",
3936
+ "soft",
3937
+ "hard"
3938
+ ],
3939
+ "description": "Opt-in deletion of the contact related to the portal user, applied after the portal user itself was deleted. `none` (default) leaves the contact untouched. `soft` deletes the contact, so it can still be restored from the trash. `hard` permanently purges the contact. Only applied in `synchronous` deletion mode, as `asynchronous` mode hands the cleanup over to the third-party system.\n",
3940
+ "default": "none"
3941
+ },
3942
+ "explanation": {
3943
+ "type": "object",
3944
+ "properties": {
3945
+ "en": {
3946
+ "type": "string",
3947
+ "description": "Explanation of the functionality shown to the end user.",
3948
+ "example": "Your account deletion will be processed by our system. This may take a few days."
3949
+ }
3950
+ },
3951
+ "additionalProperties": {
3952
+ "type": "string",
3953
+ "description": "Explanation of the functionality in language denoted by ISO 3166-1 alpha-2 code."
3954
+ },
3955
+ "required": [
3956
+ "en"
3957
+ ],
3958
+ "description": "Optional explanation shown to the user in the delete account confirmation dialog."
3959
+ },
3960
+ "auth": {
3961
+ "$ref": "#/components/schemas/PortalExtensionAuthBlock"
3962
+ },
3963
+ "call": {
3964
+ "type": "object",
3965
+ "properties": {
3966
+ "method": {
3967
+ "type": "string",
3968
+ "description": "HTTP method to use for the call",
3969
+ "default": "POST"
3970
+ },
3971
+ "url": {
3972
+ "type": "string",
3973
+ "description": "URL to call. Supports variable interpolation."
3974
+ },
3975
+ "params": {
3976
+ "type": "object",
3977
+ "description": "Parameters to append to the URL. Supports variable interpolation.",
3978
+ "additionalProperties": {
3979
+ "type": "string"
3980
+ },
3981
+ "default": {}
3982
+ },
3983
+ "headers": {
3984
+ "type": "object",
3985
+ "description": "Headers to use. Supports variable interpolation.",
3986
+ "additionalProperties": {
3987
+ "type": "string"
3988
+ },
3989
+ "default": {}
3990
+ },
3991
+ "body": {
3992
+ "type": "object",
3993
+ "description": "Optional JSON body to use for the call. Defaults to an object with portal user context, e.g. `{\"portal_user_id\": \"...\", \"email\": \"...\"}`. Supports variable interpolation."
3994
+ }
3995
+ },
3996
+ "required": [
3997
+ "url",
3998
+ "headers"
3999
+ ],
4000
+ "additionalProperties": false
4001
+ },
4002
+ "resolved": {
4003
+ "type": "object",
4004
+ "properties": {
4005
+ "error_message_path": {
4006
+ "type": "string",
4007
+ "description": "Optional path to a human-readable error message in the third-party response body, used when the call fails (non-2xx status).\nIf specified and the path resolves to a string, that message is forwarded to the end user instead of a generic error.\n",
4008
+ "example": "error.message"
4009
+ }
4010
+ },
4011
+ "additionalProperties": false
4012
+ },
4013
+ "secure_proxy": {
4014
+ "$ref": "#/components/schemas/PortalExtensionSecureProxy"
4015
+ }
4016
+ },
4017
+ "required": [
4018
+ "id",
4019
+ "type",
4020
+ "call"
4021
+ ],
4022
+ "additionalProperties": false
4023
+ },
3574
4024
  "PortalExtensionSeamlessLink": {
3575
4025
  "type": "object",
3576
4026
  "properties": {
@@ -4358,8 +4808,7 @@
4358
4808
  },
4359
4809
  "target": {
4360
4810
  "type": "string",
4361
- "format": "uri",
4362
- "description": "Base URL of the target API. Must be HTTPS.",
4811
+ "description": "Base URL of the target API. Must be HTTPS. May reference component options via {{option_key}} interpolation (resolved from decrypted values), e.g. \"https://{{cluster}}.example.com/api\" for a per-installation host. The fully-resolved URL is validated at request time (SSRF protection).",
4363
4812
  "pattern": "^https://"
4364
4813
  },
4365
4814
  "auth_type": {
@@ -4381,6 +4830,13 @@
4381
4830
  "format": "uri",
4382
4831
  "description": "OAuth2 token endpoint URL",
4383
4832
  "pattern": "^https://"
4833
+ },
4834
+ "headers": {
4835
+ "type": "object",
4836
+ "description": "Additional request headers injected server-side on every proxied request. Values may reference component options via {{option_key}} interpolation (resolved from decrypted secrets), so credentials are never exposed to the client. Applied in addition to auth_type.",
4837
+ "additionalProperties": {
4838
+ "type": "string"
4839
+ }
4384
4840
  }
4385
4841
  }
4386
4842
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epilot/app-client",
3
- "version": "0.13.5",
3
+ "version": "0.13.7",
4
4
  "description": "JavaScript client library for the epilot App API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",