@microsoft/teams.api
Version:
<p> <a href="https://www.npmjs.com/package/@microsoft/teams.api" target="_blank"> <img src="https://img.shields.io/npm/v/@microsoft/teams.api/latest" /> </a> <a href="https://www.npmjs.com/package/@microsoft/teams.api?activeTab=code" t
101 lines (98 loc) • 2.98 kB
text/typescript
import { Attachment } from '../attachment/attachment.mjs';
import { Importance } from '../importance.mjs';
import { MessageBody } from './message-body.mjs';
import { MessageFrom } from './message-from.mjs';
import { MessageMention } from './message-mention.mjs';
import { MessageReaction } from './message-reaction.mjs';
import './message-app.mjs';
import './message-conversation.mjs';
import './message-user.mjs';
/**
*
* An interface representing MessageActionsPayload.
* Represents the individual message within a chat or channel where a message
* actions is taken.
*
*/
type Message = {
/**
* @member {string} [id] Unique id of the message.
*/
id: string;
/**
* @member {string} [replyToId] Id of the parent/root message of the thread.
*/
replyToId?: string;
/**
* @member {MessageType} [messageType] Type of message - automatically set to
* message. Possible values include: 'message'
*/
messageType?: 'message';
/**
* @member {string} [createdDateTime] Timestamp of when the message was
* created.
*/
createdDateTime?: string;
/**
* @member {string} [lastModifiedDateTime] Timestamp of when the message was
* edited or updated.
*/
lastModifiedDateTime?: string;
/**
* @member {boolean} [deleted] Indicates whether a message has been soft
* deleted.
*/
deleted?: boolean;
/**
* @member {string} [subject] Subject line of the message.
*/
subject?: string;
/**
* @member {string} [summary] Summary text of the message that could be used
* for notifications.
*/
summary?: string;
/**
* @member {Importance} [importance] The importance of the message. Possible
* values include: 'normal', 'high', 'urgent'
*/
importance?: Importance;
/**
* @member {string} [locale] Locale of the message set by the client.
*/
locale?: string;
/**
* @member {string} [linkToMessage] Link back to the message.
*/
linkToMessage?: string;
/**
* @member {MessageActionsPayloadFrom} [from] Sender of the message.
*/
from?: MessageFrom;
/**
* @member {MessageActionsPayloadBody} [body] Plaintext/HTML representation
* of the content of the message.
*/
body?: MessageBody;
/**
* @member {string} [attachmentLayout] How the attachment(s) are displayed in
* the message.
*/
attachmentLayout?: string;
/**
* @member {MessageActionsPayloadAttachment[]} [attachments] Attachments in
* the message - card, image, file, etc.
*/
attachments?: Attachment[];
/**
* @member {MessageActionsPayloadMention[]} [mentions] List of entities
* mentioned in the message.
*/
mentions?: MessageMention[];
/**
* @member {MessageActionsPayloadReaction[]} [reactions] Reactions for the
* message.
*/
reactions?: MessageReaction[];
};
export type { Message };