import { ContextAny, InteropBroadcast, InteropRaiseIntent, ResolverResolution, PrivateChannelEventSubscriptionType } from "../../../../clients/Interop/types";
import { ActionId } from "../../../../common/redux/types";
import { AppIdentifier, ContextElement } from "@finos/fdc3";
/**
 * This type is used internally by the broadcast action. It can
 * handle either an intent or a context.
 *
 * It supports necessary internal features that are not possible
 * through the desktop agent.
 */
export type InteropBroadcastInternal = {
    type: "broadcast" | "raiseIntent";
    payload: {
        context?: ContextAny;
        intent?: string;
    };
    meta: {
        uuid: string;
        channel?: string;
        to?: string;
        noSelectConnect?: boolean;
        setSenderContext?: boolean;
        pendingActionId?: ActionId;
        autoBroadcast?: boolean;
        targetSubscriberId?: string;
    };
};
export type LimitOptionType = {
    contextType?: string;
    intentType?: string;
};
export type LinkerChannelConfig = {
    name: string;
    color: string;
    border?: string;
    label?: string;
}[];
export type InteropLinkChannels = {
    type: "linker/linkChannels";
    payload: {
        channels: string[];
    };
    meta: {
        windowName: string;
    };
};
export type InteropUnlinkChannels = {
    type: "linker/unlinkChannels";
    payload: {
        channels?: string[];
    };
    meta: {
        windowName: string;
    };
};
export type InteropLinkerSetActiveWindow = {
    type: "linker/setActiveWindow";
    payload: {
        windowName: string;
        showWindowAtMouse?: boolean;
    };
};
export type LinkerInitializeWindow = {
    channels?: string[];
    connectIdChannel?: string;
    modifiedConnectIdChannel?: string;
    windowName: string;
};
export type OpenAppResult = {
    actionId: ActionId;
    error?: string | null;
    windowName?: string;
    pendingMessage: InteropBroadcastInternal | null;
    rememberChoice?: boolean;
    originatingAppWindow?: string;
    bridgeAppIdentifier?: AppIdentifier;
};
export type UIResolutionResult = {
    actionId: ActionId;
    resolverResolution: ResolverResolution;
    pendingMessage: InteropRaiseIntent | InteropBroadcast;
};
export type DelayResetResults = {
    senderUuid: string;
    newTimerId: ReturnType<typeof setTimeout>;
};
export type PersistedData = {
    persistedData?: Record<string, ContextAny>;
    windowName: string;
};
export type InteropBridgingBroadcast = {
    type: "bridging/interopBridgeBroadcast";
    payload: {
        channelName: string;
        channelType: string;
        channelDisplayMetaData?: {
            name: string;
            color: string;
            glyph: string;
        };
        context?: ContextAny;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingFindIntent = {
    type: "bridging/interopToBridgeFindIntent";
    payload: {
        actionId: ActionId;
        intent?: string;
        context?: ContextElement;
        resultType?: string;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingGetAppMetadata = {
    type: "bridging/interopToBridgeGetAppMetadata";
    payload: {
        actionId: ActionId;
        appIdentifier: AppIdentifier;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingFindInstances = {
    type: "bridging/interopToBridgeFindInstances";
    payload: {
        actionId: ActionId;
        appIdentifier: AppIdentifier;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingOpen = {
    type: "bridging/interopToBridgeOpen";
    payload: {
        appIdentifier: AppIdentifier;
        context?: ContextElement;
        actionId: ActionId;
        originatingAppWindow?: string;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingRaiseIntent = {
    type: "bridging/interopToBridgeRaiseIntent";
    payload: {
        requestId: string;
        appIdentifier: AppIdentifier;
        context: ContextElement;
        intent: string;
        actionId: ActionId;
        originatingAppWindow?: string;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
export type InteropBridgingPrivateChannelEvent = {
    type: "bridging/interopToBridgePrivateChannelEvent";
    payload: {
        subscribeType: PrivateChannelEventSubscriptionType;
        channel: string;
        context?: string;
    };
    meta: {
        sourceAppId: string;
        sourceInstanceId: string;
    };
};
//# sourceMappingURL=types.d.ts.map