import { BaseContext } from '../../types';
import { AppIdentifier, Context, ContextMetadata, Intent } from '@finos/fdc3';
/**
 * EventInfo returned by FDC3 Message events
 */
export type Fdc3MessageInfo = Fdc3MessageSentInfo | Fdc3MessageReceivedInfo;
/**
 * Event Info for FDC3 Sent Message Event
 */
export interface Fdc3MessageSentInfo extends BaseContext {
    /**
     * Direction - always 'sent'
     */
    direction: 'sent';
    /**
     * Event Type: `RaiseIntent`, `RaiseIntentForContext, `BroadcastMessage`
     */
    eventType: 'RaiseIntent' | 'RaiseIntentForContext' | 'BroadcastMessage';
    /**
     * FDC3 Intent which caused Event to fire (if type is `RaiseIntent`)
     */
    intent?: Intent;
    /**
     * Full FDC3 Context for object related to the Event
     */
    context: Context;
    /**
     * Target application for the message
     */
    app?: AppIdentifier;
}
/**
 * Event Info for FDC3 Received Message Event
 */
export interface Fdc3MessageReceivedInfo extends BaseContext {
    /**
     * Direction - always 'received'
     */
    direction: 'received';
    /**
     * EventType: `IntentRaised`, `ContextBroadcast`
     */
    eventType: 'IntentRaised' | 'ContextBroadcast';
    /**
     * FDC3 Intent which caused Event to fire (if type is `IntentRaised`)
     */
    intent?: Intent;
    /**
     * Full FDC3 Context for object related to the Event
     */
    context: Context;
    /**
     * Metadata associated with the FDC3 Context
     */
    metadata?: ContextMetadata;
}
