import { Account } from './models/account.js';
import { MentionEntity } from './models/entity/mention-entity.js';
import { InputHint } from './models/input-hint.js';
import { TextFormat } from './models/text-format.js';
import { Attachment } from './models/attachment/attachment.js';
import { CardAttachmentType, CardAttachmentTypes } from './models/attachment/card-attachment.js';
import { AttachmentLayout } from './models/attachment/attachment-layout.js';
import { SuggestedActions } from './models/suggested-actions.js';
import { Importance } from './models/importance.js';
import { DeliveryMode } from './models/delivery-mode.js';
import { IActivity, Activity } from './activities/activity.js';
import { ITypingActivity } from './activities/typing.js';
import { IMessageUpdateActivity } from './activities/message/message-update.js';

/**
 * any activity type that has a `text` property
 */
type TextActivity = IMessageActivity | IMessageUpdateActivity | ITypingActivity;
type StripMentionsTextOptions = {
    /**
     * the account to remove mentions for
     * by default, all at-mentions listed in `entities` are removed.
     */
    accountId?: string;
    /**
     * when `true`, the inner text of the tag
     * will not be removed
     * Eg. input: Hello <at>my-bot</at>! How are you?
     *     output: Hello my-bot! How are you?
     */
    tagOnly?: boolean;
};
/**
 * remove "\<at>...\</at>" text from an activity
 * @param activity the activity
 */
declare function stripMentionsText<TActivity extends TextActivity>(activity: TActivity, { accountId, tagOnly }?: StripMentionsTextOptions): TActivity['text'];

interface IMessageActivity extends IActivity<'message'> {
    /**
     * The text content of the message.
     */
    text: string;
    /**
     * The text to speak.
     */
    speak?: string;
    /**
     * Indicates whether your bot is accepting,
     * expecting, or ignoring user input after the message is delivered to the client. Possible
     * values include: 'acceptingInput', 'ignoringInput', 'expectingInput'
     */
    inputHint?: InputHint;
    /**
     * The text to display if the channel cannot render cards.
     */
    summary?: string;
    /**
     * Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'
     */
    textFormat?: TextFormat;
    /**
     * The layout hint for multiple attachments. Default: list. Possible values include: 'list',
     * 'carousel'
     */
    attachmentLayout?: AttachmentLayout;
    /**
     * Attachments
     */
    attachments?: Attachment[];
    /**
     * The suggested actions for the activity.
     */
    suggestedActions?: SuggestedActions;
    /**
     * The importance of the activity. Possible values include: 'low', 'normal', 'high'
     */
    importance?: Importance;
    /**
     * A delivery hint to signal to the recipient alternate delivery paths for the activity.
     * The default delivery mode is "default". Possible values include: 'normal', 'notification'
     */
    deliveryMode?: DeliveryMode;
    /**
     * The time at which the activity should be considered to be "expired" and should not be
     * presented to the recipient.
     */
    expiration?: Date;
    /**
     * A value that is associated with the activity.
     */
    value?: any;
    /**
     * remove "\<at>...\</at>" text from an activity
     */
    stripMentionsText(options?: StripMentionsTextOptions): IMessageActivity;
    /**
     * is the recipient account mentioned
     */
    isRecipientMentioned(): boolean;
    /**
     * get a mention by the account id if exists
     */
    getAccountMention(accountId: string): MentionEntity | undefined;
}
declare class MessageActivity extends Activity<'message'> implements IMessageActivity {
    /**
     * The text content of the message.
     */
    text: string;
    /**
     * The text to speak.
     */
    speak?: string;
    /**
     * Indicates whether your bot is accepting,
     * expecting, or ignoring user input after the message is delivered to the client. Possible
     * values include: 'acceptingInput', 'ignoringInput', 'expectingInput'
     */
    inputHint?: InputHint;
    /**
     * The text to display if the channel cannot render cards.
     */
    summary?: string;
    /**
     * Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'
     */
    textFormat?: TextFormat;
    /**
     * The layout hint for multiple attachments. Default: list. Possible values include: 'list',
     * 'carousel'
     */
    attachmentLayout?: AttachmentLayout;
    /**
     * Attachments
     */
    attachments?: Attachment[];
    /**
     * The suggested actions for the activity.
     */
    suggestedActions?: SuggestedActions;
    /**
     * The importance of the activity. Possible values include: 'low', 'normal', 'high'
     */
    importance?: Importance;
    /**
     * A delivery hint to signal to the recipient alternate delivery paths for the activity.
     * The default delivery mode is "default". Possible values include: 'normal', 'notification'
     */
    deliveryMode?: DeliveryMode;
    /**
     * The time at which the activity should be considered to be "expired" and should not be
     * presented to the recipient.
     */
    expiration?: Date;
    /**
     * A value that is associated with the activity.
     */
    value?: any;
    constructor(text?: string, value?: Omit<Partial<IMessageActivity>, 'type'>);
    /**
     * initialize from interface
     */
    static from(activity: IMessageActivity): MessageActivity;
    /**
     * convert to interface
     */
    toInterface(): IMessageActivity;
    /**
     * copy to a new instance
     */
    clone(options?: Omit<Partial<IMessageActivity>, 'type'>): MessageActivity;
    /**
     * The text content of the message.
     */
    withText(value: string): this;
    /**
     * The text to speak.
     */
    withSpeak(value: string): this;
    /**
     * Indicates whether your bot is accepting,
     * expecting, or ignoring user input after the message is delivered to the client. Possible
     * values include: 'acceptingInput', 'ignoringInput', 'expectingInput'
     */
    withInputHint(value: InputHint): this;
    /**
     * The text to display if the channel cannot render cards.
     */
    withSummary(value: string): this;
    /**
     * Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'
     */
    withTextFormat(value: TextFormat): this;
    /**
     * The layout hint for multiple attachments. Default: list. Possible values include: 'list',
     * 'carousel'
     */
    withAttachmentLayout(value: AttachmentLayout): this;
    /**
     * The suggested actions for the activity.
     */
    withSuggestedActions(value: SuggestedActions): this;
    /**
     * The importance of the activity. Possible values include: 'low', 'normal', 'high'
     */
    withImportance(value: Importance): this;
    /**
     * A delivery hint to signal to the recipient alternate delivery paths for the activity.
     * The default delivery mode is "default". Possible values include: 'normal', 'notification'
     */
    withDeliveryMode(value: DeliveryMode): this;
    /**
     * The time at which the activity should be considered to be "expired" and should not be
     * presented to the recipient.
     */
    withExpiration(value: Date): this;
    /**
     * Append text
     */
    addText(text: string): this;
    /**
     * Attachments
     */
    addAttachments(...value: Attachment[]): this;
    /**
     * `@mention` an account
     * @param account the account to mention
     * @param options options to customize the mention
     */
    addMention(account: Account, options?: AddMentionOptions): this;
    /**
     * Add a card attachment
     */
    addCard<T extends CardAttachmentType>(type: T, content: CardAttachmentTypes[T]['content']): this;
    /**
     * remove "\<at>...\</at>" text from an activity
     */
    stripMentionsText(options?: StripMentionsTextOptions): this;
    /**
     * is the recipient account mentioned
     */
    isRecipientMentioned(): boolean;
    /**
     * get a mention by the account id if exists
     */
    getAccountMention(accountId: string): MentionEntity | undefined;
    /**
     * Add stream info, making
     * this a final stream message
     */
    addStreamFinal(): this;
    /**
     * Set the recipient of this message, optionally marking it as a targeted (ephemeral) message.
     * Targeted messages are only visible to the specified recipient in a shared conversation.
     * @param account - The recipient account
     * @param isTargeted - If true, marks this as a targeted message visible only to the recipient
     * @returns this instance for chaining
     *
     * @experimental This API is in preview and may change in the future.
     * Diagnostic: ExperimentalTeamsTargeted
     */
    withRecipient(account: Account, isTargeted?: boolean): this;
}
/**
 * options for adding a mention
 * to an activity
 */
type AddMentionOptions = {
    /**
     * if `true`, append the mention `text` to the `activity.text`
     * @default true
     */
    readonly addText?: boolean;
    /**
     * the `text` to use for the mention
     *
     * @default `account.name`
     * @remark
     * this text should not include `<at>` or `</at>`
     */
    readonly text?: string;
};

export { type AddMentionOptions as A, type IMessageActivity as I, MessageActivity as M, type StripMentionsTextOptions as S, stripMentionsText as s };
