Microsoft 365 Teams.team.Functions API
The teams.team.Functions API from Microsoft 365 — 1 operation(s) for teams.team.functions.
The teams.team.Functions API from Microsoft 365 — 1 operation(s) for teams.team.functions.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/microsoft-365:microsoft-365-teams-team-functions-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Teams.team.Functions API
version: v1.0
servers:
- url: https://graph.microsoft.com/v1.0/
description: Core
security:
- azureaadv2: []
tags:
- name: teams.team.Functions
paths:
/teams/microsoft.graph.getAllMessages():
get:
tags:
- teams.team.Functions
summary: Invoke function getAllMessages
operationId: team_getAllMessage
parameters:
- name: model
in: query
description: The payment model for the API
style: form
explode: false
schema:
type: string
- $ref: '#/components/parameters/top'
- $ref: '#/components/parameters/skip'
- $ref: '#/components/parameters/search'
- $ref: '#/components/parameters/filter'
- $ref: '#/components/parameters/count'
- name: $select
in: query
description: Select properties to be returned
style: form
explode: false
schema:
uniqueItems: true
type: array
items:
type: string
- name: $orderby
in: query
description: Order items by property values
style: form
explode: false
schema:
uniqueItems: true
type: array
items:
type: string
- name: $expand
in: query
description: Expand related entities
style: form
explode: false
schema:
uniqueItems: true
type: array
items:
type: string
responses:
2XX:
description: Success
content:
application/json:
schema:
title: Collection of chatMessage
type: object
properties:
value:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessage'
'@odata.nextLink':
type:
- string
- 'null'
additionalProperties:
type: object
default:
$ref: '#/components/responses/error'
x-ms-docs-operation-type: function
x-ms-pageable:
nextLinkName: '@odata.nextLink'
operationName: listMore
components:
schemas:
microsoft.graph.chatMessageFromIdentitySet:
allOf:
- $ref: '#/components/schemas/microsoft.graph.identitySet'
- title: chatMessageFromIdentitySet
type: object
additionalProperties:
type: object
microsoft.graph.eventMessageDetail:
title: eventMessageDetail
type: object
additionalProperties:
type: object
microsoft.graph.identitySet:
title: identitySet
type: object
properties:
application:
$ref: '#/components/schemas/microsoft.graph.identity'
device:
$ref: '#/components/schemas/microsoft.graph.identity'
user:
$ref: '#/components/schemas/microsoft.graph.identity'
additionalProperties:
type: object
microsoft.graph.chatMessageImportance:
title: chatMessageImportance
enum:
- normal
- high
- urgent
- unknownFutureValue
type: string
microsoft.graph.channelIdentity:
title: channelIdentity
type: object
properties:
channelId:
type:
- string
- 'null'
description: The identity of the channel in which the message was posted.
teamId:
type:
- string
- 'null'
description: The identity of the team in which the message was posted.
additionalProperties:
type: object
microsoft.graph.chatMessageMentionedIdentitySet:
allOf:
- $ref: '#/components/schemas/microsoft.graph.identitySet'
- title: chatMessageMentionedIdentitySet
type: object
properties:
conversation:
$ref: '#/components/schemas/microsoft.graph.teamworkConversationIdentity'
additionalProperties:
type: object
microsoft.graph.chatMessageHistoryItem:
title: chatMessageHistoryItem
type: object
properties:
actions:
$ref: '#/components/schemas/microsoft.graph.chatMessageActions'
modifiedDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
description: The date and time when the message was modified.
format: date-time
reaction:
$ref: '#/components/schemas/microsoft.graph.chatMessageReaction'
additionalProperties:
type: object
microsoft.graph.chatMessage:
allOf:
- $ref: '#/components/schemas/microsoft.graph.entity'
- title: chatMessage
type: object
properties:
attachments:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessageAttachment'
description: References to attached objects like files, tabs, meetings etc.
body:
$ref: '#/components/schemas/microsoft.graph.itemBody'
channelIdentity:
$ref: '#/components/schemas/microsoft.graph.channelIdentity'
chatId:
type:
- string
- 'null'
description: If the message was sent in a chat, represents the identity of the chat.
createdDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type:
- string
- 'null'
description: Timestamp of when the chat message was created.
format: date-time
deletedDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type:
- string
- 'null'
description: Read-only. Timestamp at which the chat message was deleted, or null if not deleted.
format: date-time
etag:
type:
- string
- 'null'
description: Read-only. Version number of the chat message.
eventDetail:
$ref: '#/components/schemas/microsoft.graph.eventMessageDetail'
from:
$ref: '#/components/schemas/microsoft.graph.chatMessageFromIdentitySet'
importance:
$ref: '#/components/schemas/microsoft.graph.chatMessageImportance'
lastEditedDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type:
- string
- 'null'
description: Read-only. Timestamp when edits to the chat message were made. Triggers an 'Edited' flag in the Teams UI. If no edits are made the value is null.
format: date-time
lastModifiedDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type:
- string
- 'null'
description: Read-only. Timestamp when the chat message is created (initial setting) or modified, including when a reaction is added or removed.
format: date-time
locale:
type: string
description: Locale of the chat message set by the client. Always set to en-us.
mentions:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessageMention'
description: 'List of entities mentioned in the chat message. Supported entities are: user, bot, team, channel, chat, and tag.'
messageHistory:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessageHistoryItem'
description: List of activity history of a message item, including modification time and actions, such as reactionAdded, reactionRemoved, or reaction changes, on the message.
messageType:
$ref: '#/components/schemas/microsoft.graph.chatMessageType'
policyViolation:
$ref: '#/components/schemas/microsoft.graph.chatMessagePolicyViolation'
reactions:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessageReaction'
description: Reactions for this chat message (for example, Like).
replyToId:
type:
- string
- 'null'
description: Read-only. ID of the parent chat message or root chat message of the thread. (Only applies to chat messages in channels, not chats.)
subject:
type:
- string
- 'null'
description: The subject of the chat message, in plaintext.
summary:
type:
- string
- 'null'
description: Summary text of the chat message that could be used for push notifications and summary views or fall back views. Only applies to channel chat messages, not chat messages in a chat.
webUrl:
type:
- string
- 'null'
description: Read-only. Link to the message in Microsoft Teams.
hostedContents:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessageHostedContent'
description: Content in a message hosted by Microsoft Teams - for example, images or code snippets.
x-ms-navigationProperty: true
replies:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.chatMessage'
description: Replies for a specified message. Supports $expand for channel messages.
x-ms-navigationProperty: true
additionalProperties:
type: object
microsoft.graph.teamworkHostedContent:
allOf:
- $ref: '#/components/schemas/microsoft.graph.entity'
- title: teamworkHostedContent
type: object
properties:
contentBytes:
type:
- string
- 'null'
description: Write only. Bytes for the hosted content (such as images).
format: base64url
contentType:
type:
- string
- 'null'
description: Write only. Content type. such as image/png, image/jpg.
additionalProperties:
type: object
microsoft.graph.identity:
title: identity
type: object
properties:
displayName:
type:
- string
- 'null'
description: The display name of the identity.For drive items, the display name might not always be available or up to date. For example, if a user changes their display name the API might show the new value in a future response, but the items associated with the user don't show up as changed when using delta.
id:
type:
- string
- 'null'
description: Unique identifier for the identity or actor. For example, in the access reviews decisions API, this property might record the id of the principal, that is, the group, user, or application that's subject to review.
additionalProperties:
type: object
microsoft.graph.chatMessageType:
title: chatMessageType
enum:
- message
- chatEvent
- typing
- unknownFutureValue
- systemEventMessage
type: string
microsoft.graph.itemBody:
title: itemBody
type: object
properties:
content:
type:
- string
- 'null'
description: The content of the item.
contentType:
$ref: '#/components/schemas/microsoft.graph.bodyType'
additionalProperties:
type: object
microsoft.graph.chatMessagePolicyViolation:
title: chatMessagePolicyViolation
type: object
properties:
dlpAction:
$ref: '#/components/schemas/microsoft.graph.chatMessagePolicyViolationDlpActionTypes'
justificationText:
type:
- string
- 'null'
description: Justification text provided by the sender of the message when overriding a policy violation.
policyTip:
$ref: '#/components/schemas/microsoft.graph.chatMessagePolicyViolationPolicyTip'
userAction:
$ref: '#/components/schemas/microsoft.graph.chatMessagePolicyViolationUserActionTypes'
verdictDetails:
$ref: '#/components/schemas/microsoft.graph.chatMessagePolicyViolationVerdictDetailsTypes'
additionalProperties:
type: object
microsoft.graph.chatMessageHostedContent:
allOf:
- $ref: '#/components/schemas/microsoft.graph.teamworkHostedContent'
- title: chatMessageHostedContent
type: object
additionalProperties:
type: object
microsoft.graph.ODataErrors.MainError:
required:
- code
- message
type: object
properties:
code:
type: string
message:
type: string
x-ms-primary-error-message: true
target:
type:
- string
- 'null'
details:
type: array
items:
$ref: '#/components/schemas/microsoft.graph.ODataErrors.ErrorDetails'
innerError:
$ref: '#/components/schemas/microsoft.graph.ODataErrors.InnerError'
additionalProperties:
type: object
microsoft.graph.ODataErrors.ODataError:
required:
- error
type: object
properties:
error:
$ref: '#/components/schemas/microsoft.graph.ODataErrors.MainError'
additionalProperties:
type: object
microsoft.graph.chatMessageReactionIdentitySet:
allOf:
- $ref: '#/components/schemas/microsoft.graph.identitySet'
- title: chatMessageReactionIdentitySet
type: object
additionalProperties:
type: object
microsoft.graph.teamworkConversationIdentityType:
title: teamworkConversationIdentityType
enum:
- team
- channel
- chat
- unknownFutureValue
type: string
microsoft.graph.ODataErrors.ErrorDetails:
required:
- code
- message
type: object
properties:
code:
type: string
message:
type: string
target:
type:
- string
- 'null'
additionalProperties:
type: object
microsoft.graph.teamworkConversationIdentity:
allOf:
- $ref: '#/components/schemas/microsoft.graph.identity'
- title: teamworkConversationIdentity
type: object
properties:
conversationIdentityType:
$ref: '#/components/schemas/microsoft.graph.teamworkConversationIdentityType'
additionalProperties:
type: object
microsoft.graph.ODataErrors.InnerError:
type: object
additionalProperties:
type: object
description: The structure of this object is service-specific
microsoft.graph.chatMessagePolicyViolationPolicyTip:
title: chatMessagePolicyViolationPolicyTip
type: object
properties:
complianceUrl:
type:
- string
- 'null'
description: The URL a user can visit to read about the data loss prevention policies for the organization. (ie, policies about what users shouldn't say in chats)
generalText:
type:
- string
- 'null'
description: Explanatory text shown to the sender of the message.
matchedConditionDescriptions:
type: array
items:
type:
- string
- 'null'
description: The list of improper data in the message that was detected by the data loss prevention app. Each DLP app defines its own conditions, examples include 'Credit Card Number' and 'Social Security Number'.
additionalProperties:
type: object
microsoft.graph.chatMessagePolicyViolationUserActionTypes:
title: chatMessagePolicyViolationUserActionTypes
enum:
- none
- override
- reportFalsePositive
type: string
x-ms-enum-flags:
isFlags: true
microsoft.graph.chatMessageReaction:
title: chatMessageReaction
type: object
properties:
createdDateTime:
pattern: ^[0-9]{4,}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9]([.][0-9]{1,12})?(Z|[+-][0-9][0-9]:[0-9][0-9])$
type: string
description: The timestamp type represents date and time information using ISO 8601 format and is always in UTC. For example, midnight UTC on Jan 1, 2014 is 2014-01-01T00:00:00Z.
format: date-time
displayName:
type:
- string
- 'null'
description: The name of the reaction.
reactionContentUrl:
type:
- string
- 'null'
description: The hosted content URL for the custom reaction type.
reactionType:
type: string
description: The reaction type. Supported values include Unicode characters, custom, and some backward-compatible reaction types, such as like, angry, sad, laugh, heart, and surprised.
user:
$ref: '#/components/schemas/microsoft.graph.chatMessageReactionIdentitySet'
additionalProperties:
type: object
microsoft.graph.chatMessageMention:
title: chatMessageMention
type: object
properties:
id:
maximum: 2147483647
minimum: -2147483648
type:
- number
- 'null'
description: Index of an entity being mentioned in the specified chatMessage. Matches the {index} value in the corresponding <at id='{index}'> tag in the message body.
format: int32
mentioned:
$ref: '#/components/schemas/microsoft.graph.chatMessageMentionedIdentitySet'
mentionText:
type:
- string
- 'null'
description: String used to represent the mention. For example, a user's display name, a team name.
additionalProperties:
type: object
microsoft.graph.chatMessagePolicyViolationDlpActionTypes:
title: chatMessagePolicyViolationDlpActionTypes
enum:
- none
- notifySender
- blockAccess
- blockAccessExternal
type: string
x-ms-enum-flags:
isFlags: true
microsoft.graph.bodyType:
title: bodyType
enum:
- text
- html
type: string
microsoft.graph.chatMessagePolicyViolationVerdictDetailsTypes:
title: chatMessagePolicyViolationVerdictDetailsTypes
enum:
- none
- allowFalsePositiveOverride
- allowOverrideWithoutJustification
- allowOverrideWithJustification
type: string
x-ms-enum-flags:
isFlags: true
microsoft.graph.chatMessageActions:
title: chatMessageActions
enum:
- reactionAdded
- reactionRemoved
- actionUndefined
- unknownFutureValue
type: string
x-ms-enum-flags:
isFlags: true
microsoft.graph.entity:
title: entity
type: object
properties:
id:
type: string
description: The unique identifier for an entity. Read-only.
additionalProperties:
type: object
microsoft.graph.chatMessageAttachment:
title: chatMessageAttachment
type: object
properties:
content:
type:
- string
- 'null'
description: The content of the attachment. If the attachment is a rich card, set the property to the rich card object. This property and contentUrl are mutually exclusive.
contentType:
type:
- string
- 'null'
description: 'The media type of the content attachment. The possible values are: reference: The attachment is a link to another file. Populate the contentURL with the link to the object.forwardedMessageReference: The attachment is a reference to a forwarded message. Populate the content with the original message context.Any contentType that is supported by the Bot Framework''s Attachment object.application/vnd.microsoft.card.codesnippet: A code snippet. application/vnd.microsoft.card.announcement: An announcement header.'
contentUrl:
type:
- string
- 'null'
description: The URL for the content of the attachment.
id:
type:
- string
- 'null'
description: Read-only. The unique ID of the attachment.
name:
type:
- string
- 'null'
description: The name of the attachment.
teamsAppId:
type:
- string
- 'null'
description: The ID of the Teams app that is associated with the attachment. The property is used to attribute a Teams message card to the specified app.
thumbnailUrl:
type:
- string
- 'null'
description: The URL to a thumbnail image that the channel can use if it supports using an alternative, smaller form of content or contentUrl. For example, if you set contentType to application/word and set contentUrl to the location of the Word document, you might include a thumbnail image that represents the document. The channel could display the thumbnail image instead of the document. When the user selects the image, the channel would open the document.
additionalProperties:
type: object
parameters:
top:
name: $top
in: query
description: Show only the first n items
style: form
explode: false
schema:
minimum: 0
type: integer
example: 50
search:
name: $search
in: query
description: Search items by search phrases
style: form
explode: false
schema:
type: string
skip:
name: $skip
in: query
description: Skip the first n items
style: form
explode: false
schema:
minimum: 0
type: integer
filter:
name: $filter
in: query
description: Filter items by property values
style: form
explode: false
schema:
type: string
count:
name: $count
in: query
description: Include count of items
style: form
explode: false
schema:
type: boolean
responses:
error:
description: error
content:
application/json:
schema:
$ref: '#/components/schemas/microsoft.graph.ODataErrors.ODataError'
securitySchemes:
azureaadv2:
type: oauth2
flows:
authorizationCode:
authorizationUrl: https://login.microsoftonline.com/common/oauth2/v2.0/authorize
tokenUrl: https://login.microsoftonline.com/common/oauth2/v2.0/token
scopes: {}