import { EnvironmentModuleEntryPoint, EnvironmentModuleEntryPointType } from '../../manifest/environment-modules'; import { RpcBaseData } from '../rpc-base'; /** * RPC extension request name and version. */ export declare class RpcSmeExtensionRequestKey { static command: string; static version: string; } /** * RPC extension response name and version. */ export declare class RpcSmeExtensionResponseKey { static command: string; static version: string; } /** * Rpc Version spec data. */ export interface VersionSpecData { /** * The minimum version. */ minVersion: string; /** * Whether or not minimum is inclusive. */ isMinInclusive: boolean; /** * The maximum version. */ maxVersion: string; /** * Whether or not the maximum is inclusive. */ isMaxInclusive: boolean; } /** * Rpc extension data. */ export interface SmeExtensionData { /** * The extension id. */ id: string; /** * The version of the extension. */ version: string; /** * The authors of the extension. */ authors: string[]; /** * The owners of the extension. */ owners: string[]; /** * The title of the extension. */ title: string; /** * Summary of the extension. */ summary: string; /** * The description of the extension. */ description: string; /** * Release notes. */ releaseNotes: string; /** * Icon of the extension. */ iconUrl: string; /** * The published date. */ published: Date; /** * Whether or not this is the latest extension. */ isLatestVersion: boolean; /** * Tags of the extension. */ tags: string[]; /** * Status of the extension. */ status: string; /** * Display title. */ displayTitle: string; /** * Flat owner list. */ flatOwnerList: string; /** * Flat author list. */ flatAuthorList: string; /** * Installed version. */ installedVersion: string; /** * All available versions. */ availableVersions: string[]; /** * Project url. */ projectUrl: string; /** * License url. */ licenseUrl: string; /** * Copyright information. */ copyright: string; /** * Package source. */ packageSource: string; /** * Display status. */ displayStatus: string; /** * Compatible gateway versions. */ compatibleGatewayVersions: VersionSpecData; /** * Whether or not the extension is compatible with the gateway. */ isCompatibleWithGateway: boolean; /** * Available extension status. */ availableExtensionStatus?: number; /** * Update label. */ updateLabel?: string; /** * Icon path. */ icon?: string; /** * Manifest object. */ manifest?: any; /** * Pre-processed icon coming from an extension catalog. */ icon_catalog?: string; /** * icon display classes for sme-icons */ iconClasses?: string[]; } /** * Request payload for getting extension data, includes a flagging indicating whether or not extension data is available */ export interface SmeExtensionPayload { /** * Status indicating whether extensions are loaded (if false, update status cannot be determined) */ extensionsLoaded: boolean; /** * All extensions */ extensions: SmeExtensionData[]; } /** * SME extensions status set. */ export interface SmeExtensions { /** * available extensions */ availableExtensions: SmeExtensionData[]; /** * installed extensions */ installedExtensions: SmeExtensionData[]; /** * Extensions with invalid metadata (e.g. a version that could not be parsed) */ invalidExtensions?: SmeExtensionData[]; } /** * The condition to search to further narrowing done. */ export interface SmeExtensionSearchCondition { /** * The solution ID. */ targetSolutionId: string; /** * The communication target names. */ targetNames: string[]; /** * The connections. */ targetConnections: { /** * The identity of connection. */ id: string; /** * The type of connection. */ type: string; /** * The name of connection. */ name: string; }[]; /** * Validate with the requirements on manifest. */ validationRequired: boolean; /** * Search feed even a module was installed already. * (optional and default is false.) */ searchFeedForUpgradable?: boolean; } /** * The extension search options. */ export interface SmeExtensionSearchOptions { /** * The type of extension to search for. Currently only snap-in is supported. */ extensionTypes: EnvironmentModuleEntryPointType[]; /** * The condition of extension to search. */ condition: SmeExtensionSearchCondition; /** * The flag indicating if query should be retried. Default uses cache. */ retry?: boolean; } /** * Extended Entry point information that includes package information. */ export interface SmeExtensionEntryPoint extends EnvironmentModuleEntryPoint { /** * The package information from the feed. */ extensionData?: SmeExtensionData; } /** * Defines the result for extension find responses */ export interface SmeExtensionFindResult { /** * Indicates if an extension instance was found */ found: boolean; /** * Indicates if an extension package is installed when 'found' property is true. */ installed?: boolean; /** * Indicates if an extension live package is upgradable when 'found' and 'installed' properties are true. */ upgradable?: boolean; /** * The entry points found matching query */ entryPoints?: SmeExtensionEntryPoint[]; /** * The entry points found upgradable from live feed. */ entryPointsUpgradeable?: SmeExtensionEntryPoint[]; } /** * Defines the search result. */ export interface SmeExtensionEntries { /** * The entry points. */ entryPoints: SmeExtensionEntryPoint[]; /** * The entry points found upgradable from live feed. */ entryPointsUpgradeable?: SmeExtensionEntryPoint[]; /** * The state of validation. */ conditionValidated: boolean; /** * The installed state. */ installed: boolean; /** * The upgradable statue. */ upgradable: boolean; } /** * The extension update status. */ export interface ExtensionUpdateStatus { /** * Status indicating whether extensions are loaded (if false, update status cannot be determined) */ extensionsLoaded: boolean; /** * Status if extension update available. */ isExtensionUpdateAvailable: boolean; /** * Status if user is administrator of the gateway. */ isUserAdmin: boolean; } /** * The RPC SME extension request packet. */ export interface RpcSmeExtensionRequest extends RpcBaseData { /** * Request specific Id to track completion. */ requestId: string; /** * The request type. */ requestType: RpcSmeExtensionRequestType; /** * The extension configuration if any. */ extensionConfiguration?: RpcSmeExtensionConfiguration; /** * The extension entry points find options if any. */ extensionSearchOptions?: SmeExtensionSearchOptions; } /** * The PRC SME extension update status. */ export interface RpcSmeExtensionUpdateStatus { /** * Request specific Id to track completion. */ requestId: string; /** * The update status. */ status: ExtensionUpdateStatus; /** * Error if any */ error?: string; } /** * The RPC SME extension request type. */ export declare enum RpcSmeExtensionRequestType { /** * request is for available extensions */ Available = "available", /** * request is for installed extensions */ Installed = "installed", /** * request is for all extensions */ All = "all", /** * request is to install an extension */ InstallExtension = "installExtension", /** * request is for update status of extensions. */ UpdateStatus = "updateStatus", /** * request for searching entry points with search options. */ SearchEntryPoints = "searchEntryPoints" } /** * Sme Extension operation/action RPC message result. */ export interface RpcSmeExtensionRequestResult { /** * Request specific Id to track completion. */ requestId: string; /** * Sme Extensions */ extensions: SmeExtensions; /** * Sme Extension entry points find result. */ findResult?: SmeExtensionFindResult; /** * Error if any */ error?: string; } /** * The RPC SME extension configuration to install. */ export interface RpcSmeExtensionConfiguration { /** * name of the extension to install. */ extensionName: string; /** * version of the extension to install. * if none is specified, the latest will be installed. */ extensionVersion?: string; /** * The location of feed from which to install the extension. */ packageFeed?: string; }