Ellipse Gradient for Header

Microsoft Teams Integration Guide

Integrate Microsoft Teams with enterprise systems through Microsoft Graph REST APIs, selected change notifications, and Microsoft 365 file resources.

Microsoft Teams integration options at a glance

Microsoft Teams integrations are primarily built on Microsoft Graph REST APIs, which provide access to teams, channels, members, chats, messages, meetings, users, and related Microsoft 365 resources. Selected resources support Graph change notifications through HTTPS endpoints, while JSON batching can reduce request overhead. Teams files are accessed through SharePoint or OneDrive APIs, and selected resources may support delta queries for incremental synchronization. Microsoft Entra ID provides OAuth 2.0 delegated or application authentication. Martini can consume these APIs, receive supported notifications through an API endpoint, orchestrate workflows, map payloads, and apply retries, validation, and business rules.

Integration pointSupported by Microsoft Teams?Common use casesHow Martini supports it
Microsoft Graph REST APIsYesManage and retrieve teams, channels, members, chats, messages, online meetings, users, and related Microsoft 365 resources. Use v1.0 for generally available production capabilities where possible.Martini can consume Microsoft Graph HTTPS endpoints from workflows, map JSON request and response data, apply business rules, and expose APIs for downstream consumers.
Webhooks / outbound callbacksLimitedMicrosoft Graph change notifications can notify subscribers about selected chat messages, channel messages, chats, memberships, and other supported resources. Coverage is resource-specific rather than universal.Martini can expose an HTTPS API endpoint, validate subscription requests and notifications, retrieve the current resource, and process lifecycle or renewal events.
Bulk / async / batch APIsLimitedMicrosoft Graph JSON batching combines multiple Graph requests in one HTTP request and can reduce network overhead, but individual permissions, throttling, and service constraints still apply.Martini workflows can construct and consume batch requests where appropriate and handle individual subrequest results, retries, and partial failures.
File / attachment APIsYesTeams files are commonly stored in SharePoint or OneDrive and can be accessed through Microsoft Graph. Messages may also reference hosted content or files.Martini can follow file references, call SharePoint or OneDrive Graph resources, transform metadata or content, and deliver it to an external repository or process.
Delta and incremental synchronizationLimitedDelta queries support incremental synchronization for selected Microsoft Graph resources. Support and token behavior vary by Teams resource.Martini can persist delta links, process additions and deletions, handle expired tokens, and initiate a full resynchronization when required.
AuthenticationYesMicrosoft Graph uses Microsoft Entra ID OAuth 2.0 access tokens with delegated or application permissions, administrator consent, and resource-specific restrictions where applicable.Martini can use secure environment configuration and secrets management for OAuth credentials and tokens, keeping them out of workflow payloads and logs.
SDKsYesMicrosoft Graph SDKs are available for several programming languages, but they are optional because the underlying REST APIs are the primary integration contract.Martini can consume the HTTPS REST APIs directly and use custom JVM-compatible logic when API-specific processing requires it.
Database accessNoMicrosoft Teams does not expose a direct relational database interface for application integration.Martini should use Microsoft Graph, SharePoint or OneDrive APIs, change notifications, and supported Teams application interfaces instead of direct database access.

How Microsoft Teams exposes data and business events

Microsoft Graph REST APIs

Microsoft Graph is the primary integration surface for Microsoft Teams. Its REST resources cover teams, channels, members, chats, messages, online meetings, users, files, and related Microsoft 365 data. Production integrations should prefer v1.0 resources when they provide the required capability, while beta resources should be isolated and treated as change-prone.

Martini implementation pattern

Martini implementation pattern: a workflow authenticates with Microsoft Entra ID, calls the required Graph endpoint, follows pagination or related-resource links, maps the JSON response into a canonical model, applies business rules, and writes to or calls the target system. Martini can also expose a controlled API façade over the resulting process.

Implementation sequence

Obtain an access token with the required Microsoft Graph permissions
Call the selected Microsoft Graph REST resource
Follow pagination and related SharePoint or OneDrive references
Map the response into the canonical integration model
Apply validation, routing, and business rules
Write the result to the target system and record correlation data

Microsoft Graph change notifications

Microsoft Graph supports change-notification subscriptions for selected Teams and Microsoft 365 resources. Notifications may contain identifiers rather than complete resource state, and subscriptions have expiration, validation, permission, and lifecycle requirements.

Martini implementation pattern

Martini implementation pattern: expose a Martini API endpoint as the notification URL, return the validation token as required, validate incoming notifications, retrieve the changed resource from Graph, and process the current state. A scheduled workflow can renew subscriptions and recover from lifecycle failures.

Implementation sequence

Create or maintain a Microsoft Graph subscription for the supported resource
Receive the validation request or change notification at the Martini API endpoint
Return the validation token when Graph validates the endpoint
Validate the notification and identify the changed resource
Retrieve the current resource from Microsoft Graph
Process the resource with duplicate detection and business rules

Microsoft Graph JSON batching

Microsoft Graph JSON batching allows multiple requests to be submitted in a single HTTP request. It can reduce network overhead but does not remove individual permission checks, throttling, request limits, or partial-failure handling.

Martini implementation pattern

Martini implementation pattern: assemble independent Graph requests in a workflow, submit the batch, inspect each subresponse, route successful and failed operations separately, and retry only eligible transient failures rather than replaying the entire batch indiscriminately.

Implementation sequence

Collect independent Graph operations for the workflow run
Build a JSON batch with stable request identifiers
Submit the batch to Microsoft Graph
Inspect each subresponse and classify failures
Retry eligible transient subrequests with bounded backoff
Persist successful results and exception details

Microsoft Graph files and attachments

Teams files are commonly stored in SharePoint or OneDrive, while messages can contain hosted content or file references. File processing therefore crosses Teams, SharePoint, OneDrive, and Microsoft Graph resource boundaries.

Martini implementation pattern

Martini implementation pattern: identify the referenced drive, site, item, or hosted content resource, retrieve permitted metadata or content, transform it for the target system, and preserve the source identifiers and permissions context. Message processing and file retrieval should be treated as related but separate operations.

Implementation sequence

Receive or retrieve the Teams message or file reference
Resolve the associated SharePoint or OneDrive resource
Retrieve permitted metadata, hosted content, or file content
Map content and identifiers to the target model
Write the file or metadata to the destination
Record source references and handle permission or retrieval failures

Microsoft Graph delta synchronization

Delta queries can support incremental synchronization for selected Graph resources, but coverage is not uniform across Teams objects. Delta links, deleted objects, token expiration, and full-resynchronization paths must be treated as synchronization state.

Martini implementation pattern

Martini implementation pattern: store the current delta link securely, call the delta endpoint on a schedule or after a notification, process additions and deletions, and replace the stored link only after successful downstream handling. When the token expires or coverage is insufficient, the workflow starts a controlled full synchronization.

Implementation sequence

Select a Teams resource with confirmed delta-query support
Load the stored delta link or begin an initial synchronization
Retrieve each page of changes from Microsoft Graph
Apply additions, updates, and deletions to the target
Persist the returned delta link after successful processing
Start a controlled full resynchronization when the token expires

Common Microsoft Teams integration patterns

Pattern 1: Send ServiceNow incidents to Teams

When to use this pattern

Use this pattern when operations teams need timely incident creation, assignment, escalation, or resolution notifications in a Teams channel. It is appropriate for event-driven delivery or scheduled reconciliation where the source does not provide a reliable event.

Integration direction
ServiceNow
Martini
Microsoft Teams
Example Mapping
Microsoft Teams FieldCanonical FieldTarget Field
numberincidentNumbermessage.subject
short_descriptionsummarymessage.body
priorityseveritychannel.routingKey
sys_idsourceIdmessage.correlationKey
Martini implementation pattern

Martini receives a ServiceNow event or retrieves changed incidents, enriches the payload with assignment and severity data, selects a Teams team and channel using business rules, and calls Microsoft Graph to create the message. The workflow stores the ServiceNow identifier and destination message correlation, uses bounded retries for Graph throttling, and routes permanent failures to exception handling.

Martini capabilities used
  • workflows
  • API consumption
  • data mapping
  • business rules
  • error handling
  • scheduled synchronization

Pattern 2: Publish Salesforce opportunity changes to Teams

When to use this pattern

Use this pattern when sales and account teams need collaboration updates without opening Salesforce for every change. It supports stage changes, ownership changes, and selected customer activity notifications.

Integration direction
Salesforce
Martini
Microsoft Teams
Example Mapping
Microsoft Teams FieldCanonical FieldTarget Field
IdopportunityIdmessage.correlationKey
NameopportunityNamemessage.body.title
StageNamestagemessage.body.stage
Amountvaluemessage.body.amount
Martini implementation pattern

Martini consumes or polls Salesforce changes, applies thresholds and account-to-channel routing, maps approved fields into a Teams message, and calls Microsoft Graph. Correlation keys prevent duplicate posts, while failed deliveries are retried or sent to an exception path without losing the source change.

Martini capabilities used
  • workflows
  • API consumption
  • data mapping
  • business rules
  • error handling
  • reusable integration logic

Pattern 3: Route Jira issue updates to project channels

When to use this pattern

Use this pattern when development and delivery teams need issue, sprint, release, or blocker updates in the Teams channels associated with Jira projects.

Integration direction
Jira
Martini
Microsoft Teams
Example Mapping
Microsoft Teams FieldCanonical FieldTarget Field
keyissueKeymessage.subject
fields.summarysummarymessage.body
fields.priority.nameprioritychannel.routingKey
fields.status.namestatusmessage.body.status
Martini implementation pattern

Martini receives Jira webhook-style events or runs a scheduled poll, normalizes issue data, routes by project, component, sprint, or priority, and formats a concise Graph channel message. It records the Jira issue key and event identity for idempotency and applies retry rules for transient Graph failures.

Martini capabilities used
  • API consumption
  • workflows
  • data mapping
  • conditional routing
  • business rules
  • error handling

Pattern 4: Archive selected Teams messages and files

When to use this pattern

Use this pattern when an organization must preserve selected channel messages, chat messages, hosted content, or referenced files in an archive or records platform.

Integration direction
Microsoft Teams
Martini
Enterprise archive
Example Mapping
Microsoft Teams FieldCanonical FieldTarget Field
idmessageIdarchive.sourceMessageId
createdDateTimecreatedAtarchive.createdAt
fromauthorarchive.author
hostedContentscontentReferencesarchive.attachments
Martini implementation pattern

A Martini API receives a supported Graph change notification, validates it, retrieves the current message, follows SharePoint or OneDrive references where permitted, and maps message metadata and content to the archive. Duplicate notifications are suppressed using message and subscription identifiers, while expired subscriptions and retrieval errors are handled through renewal and retry workflows.

Martini capabilities used
  • API exposure
  • webhook handling
  • API consumption
  • data mapping
  • scheduled workflows
  • error handling

Applications commonly integrated with Microsoft Teams

Microsoft Teams commonly participates in collaboration, service management, sales, development, support, HR, content, and analytics workflows. The following applications can be integrated with Teams through their APIs, events, files, or Microsoft Graph resources, with Martini coordinating authentication, routing, transformation, and error handling.

Application Scenario Direction Martini Pattern
ServiceNow Send incident, change, request, and approval notifications to Teams channels and provide links back to operational workflows. ServiceNow → Martini → Microsoft Teams Consume ServiceNow events or scheduled results, map incident and change fields into Microsoft Graph channel-message requests, route by severity or assignment group, and use the ServiceNow identifier to prevent duplicate posts.
Salesforce Notify sales and account teams about opportunity stages, ownership changes, and important customer activity. Salesforce → Martini → Microsoft Teams Receive or retrieve Salesforce changes, enrich the payload with account and owner data, select the target team or channel using business rules, and call Microsoft Graph with bounded retries and correlation tracking.
Jira Surface issue creation, priority changes, sprint updates, and release blockers in project collaboration channels. Jira → Martini → Microsoft Teams Consume Jira webhook notifications or poll for updates, transform issue and sprint fields into Teams message content, route by project or priority, and optionally expose an API for controlled Jira updates.
Zendesk Deliver support ticket assignments, escalations, and SLA notifications to authorized Teams channels. Zendesk → Martini → Microsoft Teams Receive Zendesk events or query ticket changes, apply routing and data-minimization rules, format the ticket summary for Teams, and record the ticket ID and message correlation key for idempotency.
Workday Share selected HR workflow notifications or approvals with authorized Teams users while limiting sensitive employee data. Workday → Martini → Microsoft Teams Retrieve approved Workday events or workflow results, validate recipient and data classification rules, map only permitted fields to a Teams message or link, and retain audit metadata without exposing unnecessary HR content.
SharePoint Access files associated with Teams channels and synchronize selected document metadata or content with external systems. Microsoft Teams → Martini → SharePoint Process a Teams or Graph notification, resolve the associated SharePoint site, drive, and item, retrieve permitted metadata or content, and map it to the downstream repository with duplicate detection.
OneDrive Retrieve or synchronize files referenced in Teams chats and personal collaboration contexts. Microsoft Teams → Martini → OneDrive Follow Graph file references from message or chat payloads, authenticate against the relevant OneDrive resource, transform metadata and content as required, and handle permission failures separately from transient API errors.
Power BI Share report links, alerts, or selected analytical notifications in Teams channels. Power BI → Martini → Microsoft Teams Receive or retrieve Power BI notification data, apply audience and routing rules, create a concise Teams message containing approved report links, and log the source event for traceability.

How to build a Microsoft Teams integration in Martini

Objective

Establish Microsoft Graph access using Microsoft Entra ID and the minimum delegated or application permissions required for the selected Teams resources.

Instructions in Martini

  • Configure the Graph base URL and API version appropriate to the use case
  • Select delegated or application-only OAuth 2.0 access
  • Store client credentials and secrets in secure Martini environment configuration
  • Obtain administrator or resource-specific consent where required

Objective

Select an event-driven or scheduled trigger based on the resource coverage and reliability required by the integration.

Instructions in Martini

  • Use a Martini API endpoint for supported Graph change notifications
  • Use a scheduler for reconciliation, subscription renewal, or resources without notification coverage
  • Use delta queries where the target Graph resource supports them
  • Define a full-resynchronization path for expired or invalid synchronization state

Objective

Receive the notification or source event and retrieve authoritative resource state from Microsoft Graph rather than assuming the notification contains a complete payload.

Instructions in Martini

  • Validate Graph subscription requests and incoming notifications
  • Call the relevant Graph resource after identifying the changed object
  • Follow @odata.nextLink for paginated collections
  • Resolve SharePoint or OneDrive references for Teams files

Objective

Coordinate source processing, Graph calls, target writes, routing, and state management in a maintainable Martini workflow.

Instructions in Martini

  • Separate notification intake from follow-up retrieval where appropriate
  • Use reusable workflow logic for authentication, correlation, and resource retrieval
  • Route messages by team, channel, severity, project, or permission-aware business rules
  • Persist delta links, subscription state, and external correlation identifiers

Objective

Convert Teams and Microsoft Graph payloads into a canonical model or target-specific request while accounting for rich content and related resources.

Instructions in Martini

  • Map teams, channels, chats, messages, members, meetings, and file references explicitly
  • Normalize HTML, mentions, links, hosted content, and timestamps for the target
  • Apply validation before writing data downstream
  • Use custom logic only where standard mapping and transformation are insufficient

Objective

Enforce routing, privacy, retention, permission, and idempotency rules before performing downstream actions.

Instructions in Martini

  • Restrict message and file content to approved recipients and destinations
  • Use stable team, channel, chat, message, subscription, or source identifiers for duplicate detection
  • Prefer v1.0 Graph resources for production when they meet requirements
  • Classify permission failures separately from transient service failures

Common Microsoft Teams data objects used in integrations

ObjectTypical UseCommon target systemsMartini handling
TeamsRepresent collaboration workspaces containing channels, members, tabs, apps, and settings.ServiceNow, Salesforce, Jira, SharePoint, enterprise archivesMartini retrieves or updates Teams through Microsoft Graph, maps identifiers and membership data, and applies permission-aware routing and error handling.
ChannelsOrganize team collaboration and provide destinations for operational, project, and notification messages.ServiceNow, Salesforce, Jira, Zendesk, records platformsMartini resolves team and channel identifiers, applies routing rules, constructs Graph message payloads, and tracks posted message correlations.
Chat messagesRepresent messages in one-to-one, group, or meeting-related chats, including content and references.Enterprise archives, compliance platforms, SharePoint, analytics storesMartini processes notifications or retrieved messages, normalizes HTML and metadata, follows hosted-content or file references, and prevents duplicate archival.
ChatsRepresent one-to-one, group, or meeting-related conversations and their participants.Enterprise archives, customer systems, compliance platformsMartini retrieves supported chat data through Graph, validates permissions and retention rules, and maps participants and message relationships to the target model.
Team membersRepresent users, guests, or other directory principals associated with a team.Identity directories, HR systems, access governance platformsMartini synchronizes supported membership data, maps Microsoft Entra identifiers, and applies least-privilege and privacy rules before writing downstream.
Online meetingsRepresent scheduled or ad hoc Teams meetings and associated meeting resources.Calendars, service platforms, archives, workflow systemsMartini calls supported Graph meeting resources, maps meeting metadata and links, and handles resource-specific permission and notification limitations.

Authentication and security considerations

Microsoft Entra ID and Microsoft Graph permissions

Microsoft Teams integrations use Microsoft Graph access tokens issued by Microsoft Entra ID. Martini workflows may use delegated OAuth 2.0 access for user-context operations or application permissions for supported application-only operations.

  • Request only the Graph permissions required for the selected teams, channels, messages, chats, files, users, or meetings.
  • Plan for administrator consent and resource-specific consent where required.
  • Keep client credentials, tokens, and subscription data in secure Martini environment configuration or secrets-management facilities.
  • Do not log access tokens or unnecessary message and file content.

Cross-service authorization

Teams files commonly reside in SharePoint or OneDrive, so an integration may require permissions across multiple Microsoft 365 resources. Validate the storage location and permission context before retrieving content.

Operational considerations for Microsoft Teams integrations

Throttling, pagination, and retries

Microsoft Graph applies throttling and collection responses may contain an @odata.nextLink reference. Workflows should follow pagination, honor Retry-After when supplied, and use bounded exponential backoff for transient failures.

  • Inspect individual results when using JSON batching because subrequests can fail independently.
  • Use stable identifiers such as message, chat, channel, team, subscription, and source IDs for idempotency.
  • Persist delta links only after successful downstream processing and support token expiration or full resynchronization.
  • Renew Graph subscriptions before expiration and handle validation and lifecycle notifications.
  • Test rich message content, mentions, hosted content, file references, permissions, and both v1.0 and any required beta resources separately.

Schema and service boundaries

Teams integrations can cross Microsoft Graph, SharePoint, OneDrive, Exchange, Microsoft Entra ID, and Microsoft 365 groups. Isolate Graph-specific mappings and prefer stable v1.0 contracts for production integrations.

Why use Martini instead of scripts or point-to-point integrations?

Orchestration beyond a single script

Martini separates notification intake, resource retrieval, transformation, business rules, target writes, and exception handling into maintainable workflows. This is useful when a Teams process spans Microsoft Graph, SharePoint, OneDrive, and other enterprise applications.

  • Expose reusable APIs and receive supported Graph change notifications.
  • Coordinate real-time, scheduled, batch, and reconciliation workflows.
  • Apply consistent mappings, validation, routing, idempotency, and retry policies.
  • Keep authentication and secrets outside workflow payloads.
  • Monitor processing and preserve correlation information for troubleshooting without creating tightly coupled point-to-point scripts.

Frequently asked questions

How can Microsoft Teams be integrated with enterprise systems?

Microsoft Teams is integrated primarily through Microsoft Graph REST APIs. Graph provides access to teams, channels, members, chats, messages, online meetings, users, and related SharePoint or OneDrive resources. Selected resources support change notifications, while scheduled synchronization, JSON batching, and delta queries can support other integration scenarios.

Can Martini integrate with Microsoft Teams?

Yes. Martini can consume Microsoft Graph REST APIs, authenticate through Microsoft Entra ID, expose an API endpoint for supported Graph change notifications, retrieve related SharePoint or OneDrive resources, and orchestrate mappings, business rules, retries, and downstream writes.

Do I need a connector to integrate Microsoft Teams with Martini?

No. A dedicated Microsoft Teams connector is not required. Martini can use Microsoft Graph REST APIs, supported Graph change notifications, SharePoint and OneDrive file APIs, and Microsoft Entra ID authentication to implement the integration.

Is there any extra Lonti cost to integrate Microsoft Teams with Martini?

Lonti does not charge an additional per-connector or per-vendor fee to integrate Microsoft Teams. The integration is subject to the provisioned capacity of the Martini environment. Separate costs may apply from Microsoft, Azure, Microsoft 365, cloud infrastructure, or other third-party systems depending on licensing, usage, and deployment model.

Which Microsoft Teams integration methods should be used?

Microsoft Graph REST APIs are the primary method. Use v1.0 resources for production where possible, selected change notifications for supported event scenarios, delta queries for supported incremental resources, JSON batching when appropriate, and SharePoint or OneDrive APIs for Teams files. Graph SDKs are optional because Martini can consume the REST APIs directly.

Are Microsoft Teams webhooks or events available?

Microsoft Graph change notifications are available for selected resources and operations, but they are not a universal event stream for every Teams action. Subscriptions have expiration, validation, permission, and lifecycle requirements, so integrations should combine notifications with follow-up Graph reads, scheduled reconciliation, or delta synchronization where needed.

How does synchronization and data mapping work?

Martini can retrieve paginated Graph collections, process supported delta queries, store synchronization links, and map Teams objects into canonical or target-specific models. Workflows can normalize message content, follow file references into SharePoint or OneDrive, apply routing and privacy rules, and write results to downstream systems.

Can Martini expose an API façade for Microsoft Teams processes?

Yes. Martini can expose a controlled REST API that accepts requests from enterprise applications, applies authorization and business rules, and orchestrates Microsoft Graph calls. This can provide a stable internal contract while isolating consumers from Graph-specific permissions, payloads, throttling, and API-version changes.