diff --git a/clients/customer-portal-client/package.json b/clients/customer-portal-client/package.json index fa05d455..d78abe83 100644 --- a/clients/customer-portal-client/package.json +++ b/clients/customer-portal-client/package.json @@ -1,6 +1,6 @@ { "name": "@epilot/customer-portal-client", - "version": "0.43.0", + "version": "0.44.0", "description": "API Client for epilot portal API", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/clients/customer-portal-client/src/openapi.d.ts b/clients/customer-portal-client/src/openapi.d.ts index 63202e80..b3f6a7cb 100644 --- a/clients/customer-portal-client/src/openapi.d.ts +++ b/clients/customer-portal-client/src/openapi.d.ts @@ -1463,6 +1463,10 @@ declare namespace Components { * Configures which 360 events generate an in-app notification for the portal user. Each enabled trigger renders the referenced notification template and creates a notification addressed to the portal user. Admin/builder-only — never exposed via the public portal config. */ notification_triggers?: NotificationTriggerConfig[]; + /** + * Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it. + */ + engagement_center_enabled?: boolean; } export interface CommonConfigAttributesV3 { /** @@ -3293,7 +3297,27 @@ declare namespace Components { templates?: { [name: string]: string; }; - templates_ref?: /* Reference to admin-authored portal configuration (a page block or a global search configuration item) from which the API derives Handlebars templates server-side. This replaces client-supplied template strings so portal users can never submit arbitrary templates for resolution. When both a reference and raw `templates` are provided, the reference wins and the raw templates are ignored. */ TemplatesRef; + /** + * Reference to admin-authored portal configuration (a page block or a global search configuration item) from which the API derives Handlebars templates server-side. This replaces client-supplied template strings so portal users can never submit arbitrary templates for resolution. When both a reference and raw `templates` are provided, the reference wins and the raw templates are ignored. + */ + templates_ref?: { + /** + * ID of the portal page to derive templates from. When given without `block_id`, templates are derived from every block of the page and returned resolved as a nested map keyed by block id (the entity detail page contract). + */ + page_id?: string; + /** + * ID of a block within the page. Templates are derived from the block's content according to its block type (e.g. meter_selector, meter_reading, entity_list). + */ + block_id?: string; + /** + * For blocks carrying a per-schema configuration array (entity_list), the id of the configuration item to derive templates from. Requires `page_id` and `block_id`. + */ + config_id?: string; + /** + * ID of the portal's `global_search` configuration item to derive search result templates and the group title template from. Mutually exclusive with `page_id`. + */ + global_search_config_id?: string; + }; } export interface EntityTemplates { /** @@ -6613,6 +6637,10 @@ declare namespace Components { * Configures which 360 events generate an in-app notification for the portal user. Each enabled trigger renders the referenced notification template and creates a notification addressed to the portal user. Admin/builder-only — never exposed via the public portal config. */ notification_triggers?: NotificationTriggerConfig[]; + /** + * Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it. + */ + engagement_center_enabled?: boolean; /** * ID of the organization * example: @@ -8106,11 +8134,14 @@ declare namespace Components { */ code: string; /** - * The redirect uri + * The redirect uri used in the authorization request. Optional: when omitted it is + * resolved server-side from the provider's configured `redirect_uri`, falling back to + * the portal's own callback route (`https:///sso`). + * * example: - * https://customer-portal.com/login + * https://customer-portal.com/sso */ - redirect_uri: string; + redirect_uri?: string; /** * The client id * example: @@ -9014,6 +9045,10 @@ declare namespace Components { * Configures which 360 events generate an in-app notification for the portal user. Each enabled trigger renders the referenced notification template and creates a notification addressed to the portal user. Admin/builder-only — never exposed via the public portal config. */ notification_triggers?: NotificationTriggerConfig[]; + /** + * Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it. + */ + engagement_center_enabled?: boolean; } export interface UpsertPortalConfigV3 { /** @@ -9667,7 +9702,7 @@ declare namespace Components { /** * Intervals supported for the current context. If omitted, all intervals are assumed supported. */ - intervals?: ("PT15M" | "PT1H" | "P1D" | "P1M")[]; + intervals?: ("PT15M" | "PT1H" | "P1D" | "P1M" | "P1Y")[]; data_range?: /* Earliest / latest timestamps for which data is available in the current context. */ VisualizationDataRange; } export interface VisualizationTypeOption { @@ -11358,7 +11393,7 @@ declare namespace Paths { export type ExtensionId = string; export type From = string; // date-time export type HookId = string; - export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M"; + export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M" | "P1Y"; export type MeterId = string; export type To = string; // date-time } @@ -11715,7 +11750,7 @@ declare namespace Paths { export type ExtensionId = string; export type From = string; // date-time export type HookId = string; - export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M"; + export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M" | "P1Y"; export type MeterId = string; export type To = string; // date-time } @@ -13561,6 +13596,10 @@ declare namespace Paths { * Configures which 360 events generate an in-app notification for the portal user. Each enabled trigger renders the referenced notification template and creates a notification addressed to the portal user. Admin/builder-only — never exposed via the public portal config. */ notification_triggers?: Components.Schemas.NotificationTriggerConfig[]; + /** + * Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it. + */ + engagement_center_enabled?: boolean; /** * ID of the organization * example: @@ -14183,6 +14222,10 @@ declare namespace Paths { * Configures which 360 events generate an in-app notification for the portal user. Each enabled trigger renders the referenced notification template and creates a notification addressed to the portal user. Admin/builder-only — never exposed via the public portal config. */ notification_triggers?: Components.Schemas.NotificationTriggerConfig[]; + /** + * Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it. + */ + engagement_center_enabled?: boolean; /** * ID of the organization * example: @@ -14583,7 +14626,7 @@ declare namespace Paths { export type ExtensionId = string; export type From = string; // date-time export type HookId = string; - export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M"; + export type Interval = "PT15M" | "PT1H" | "P1D" | "P1M" | "P1Y"; export type MeterId = string; export type To = string; // date-time } diff --git a/clients/customer-portal-client/src/openapi.json b/clients/customer-portal-client/src/openapi.json index 99149a27..b4b46ae1 100644 --- a/clients/customer-portal-client/src/openapi.json +++ b/clients/customer-portal-client/src/openapi.json @@ -961,7 +961,8 @@ "PT15M", "PT1H", "P1D", - "P1M" + "P1M", + "P1Y" ] }, "required": true, @@ -1299,7 +1300,8 @@ "PT15M", "PT1H", "P1D", - "P1M" + "P1M", + "P1Y" ] }, "required": true, @@ -1473,7 +1475,8 @@ "PT15M", "PT1H", "P1D", - "P1M" + "P1M", + "P1Y" ] }, "required": true, @@ -13042,6 +13045,10 @@ "items": { "$ref": "#/components/schemas/NotificationTriggerConfig" } + }, + "engagement_center_enabled": { + "type": "boolean", + "description": "Master toggle for the portal's engagement center (in-app notifications including the notification triggers above). Off when absent — portal users only see the engagement center and receive trigger notifications after an admin enables it." } } }, @@ -13947,7 +13954,26 @@ } }, "templates_ref": { - "$ref": "#/components/schemas/TemplatesRef" + "type": "object", + "description": "Reference to admin-authored portal configuration (a page block or a global search configuration item) from which the API derives Handlebars templates server-side. This replaces client-supplied template strings so portal users can never submit arbitrary templates for resolution. When both a reference and raw `templates` are provided, the reference wins and the raw templates are ignored.", + "properties": { + "page_id": { + "type": "string", + "description": "ID of the portal page to derive templates from. When given without `block_id`, templates are derived from every block of the page and returned resolved as a nested map keyed by block id (the entity detail page contract)." + }, + "block_id": { + "type": "string", + "description": "ID of a block within the page. Templates are derived from the block's content according to its block type (e.g. meter_selector, meter_reading, entity_list)." + }, + "config_id": { + "type": "string", + "description": "For blocks carrying a per-schema configuration array (entity_list), the id of the configuration item to derive templates from. Requires `page_id` and `block_id`." + }, + "global_search_config_id": { + "type": "string", + "description": "ID of the portal's `global_search` configuration item to derive search result templates and the group title template from. Mutually exclusive with `page_id`." + } + } } } }, @@ -16578,7 +16604,8 @@ "PT15M", "PT1H", "P1D", - "P1M" + "P1M", + "P1Y" ] } }, @@ -18683,7 +18710,6 @@ "token_endpoint", "grant_type", "code", - "redirect_uri", "client_id", "code_verifier" ], @@ -18709,8 +18735,8 @@ }, "redirect_uri": { "type": "string", - "description": "The redirect uri", - "example": "https://customer-portal.com/login" + "description": "The redirect uri used in the authorization request. Optional: when omitted it is\nresolved server-side from the provider's configured `redirect_uri`, falling back to\nthe portal's own callback route (`https:///sso`).\n", + "example": "https://customer-portal.com/sso" }, "client_id": { "type": "string",