How to integrate Microsoft Defender MCP with Atomic Agent

Connect Atomic Agent to Microsoft Defender MCP. List high-severity microsoft defender incidents, submit a microsoft defender threat sample, and more using natural language, with authentication handled for you.

Microsoft Defender logoMicrosoft Defender
Oauth2S2s Oauth2

Microsoft Defender is Microsoft's cloud security service for detecting and investigating cyber threats. It provides unified visibility into alerts, incidents, devices, vulnerabilities, and threat intelligence.

89 Tools

Introduction

Atomic Agent is an open-source AI agent that runs on your machine and supports local models through llama.cpp. Connect it to 1,700+ apps through Composio, including Microsoft Defender.

This guide uses Atomic Agent's built-in Composio integration. You need Atomic Agent v0.5.6 or later, your own Composio API key, and a Microsoft Defender account. See the Atomic Agent documentation for installation instructions.

For exact tool slugs and parameter tables, see the tool catalog in the Composio docs.

Also integrate Microsoft Defender with

How Atomic Agent connects to Microsoft Defender

Atomic Agent connects to Composio's Tool Router over Streamable HTTP MCP. It discovers the tools needed for your request, and Composio handles account authentication.

Execution and account-connection tools follow Atomic Agent's configured approval policy. Review any approval prompt before allowing an action on your connected account.

Connect Microsoft Defender to Atomic Agent

  1. Sign up or sign in to the Composio dashboard. Copy your API key.
  2. In Atomic Agent, open the Integrations tab and select Composio. Select API key, press e, paste the key, and press Enter. The tools become available immediately, without a restart.
  3. Ask Atomic Agent to do something in Microsoft Defender. It searches Composio for the right tool.
  4. On first use, open the sign-in link returned in the chat. Connect your Microsoft Defender account, then return to Atomic Agent to continue.

Headless setup

Add the following line to ~/.atomic-agent/.env, replacing YOUR_COMPOSIO_API_KEY with your key. Start Atomic Agent after saving the file.

bash
COMPOSIO_API_KEY=YOUR_COMPOSIO_API_KEY

What is the Microsoft Defender MCP server, and what's possible with it?

The Microsoft Defender MCP server is an implementation of the Model Context Protocol that connects your AI agent and assistants like Claude, Cursor, etc directly to your Microsoft Defender account. It provides structured and secure access to security alerts and incidents, threat intelligence, secure scores, attack simulations, and threat submissions, so your agent can investigate alerts, add analyst comments, review threat data, assess security posture, and manage simulation campaigns on your behalf.

  • Alert and incident investigation: Have your agent retrieve Microsoft Defender alerts and incidents, then add comments to document analyst findings.
  • Threat intelligence research: Direct your agent to inspect hosts, reputations, WHOIS records, ports, cookies, trackers, subdomains, vulnerabilities, threat articles, and passive DNS records.
  • Security posture review: Let the agent retrieve secure scores and control profiles to help you understand your organization’s security posture.
  • Attack simulation management: Instruct your agent to create, retrieve, track, and delete attack simulations, inspect their payloads and pages, and review simulation report overviews.
  • Threat submission administration: Have your agent retrieve threat submissions and create, review, or delete email submission policies.

Use Microsoft Defender from Atomic Agent

With your account connected, ask Atomic Agent to work with Microsoft Defender in natural language. You can connect more apps through the same Composio integration as you need them.

Visit the Atomic Agent website or inspect the Atomic Agent source code.

Troubleshooting

Why is my API key rejected?

Copy the key directly from the Composio dashboard. Atomic Agent requires ASCII characters because it sends the key in an HTTP header. Remove any extra characters introduced when copying.

Why are Composio tools unavailable after saving a key?

Check that you use Atomic Agent v0.5.6 or later and that Composio is enabled in your configuration. A "composio": { "enabled": false } setting disables the integration while keeping the saved key on disk.

Does Composio have a free plan?

The Hobby plan includes 100,000 tool calls per month. Composio-managed OAuth apps have a lower included allowance. See Composio pricing for the current limits that apply to your connection.

TOOLS

Supported Tools

Every Microsoft Defender action and event your agent gets out of the box.

Add Alert Comment

Append a comment to a Microsoft Defender security alert.

Add Incident Comment

Append an analyst comment to a Microsoft Defender incident; comments cannot be removed by this action.

Create Email Submission Policy

Create an email threat-submission policy with the supplied settings.

Create Simulation

Create an attack simulation using payload, login-page, and landing-page resource IDs; acceptance is asynchronous.

Delete Email Submission Policy

Delete an email threat-submission policy by its Microsoft Graph identifier.

Delete Simulation

Delete an attack simulation campaign.

Get Alert

Retrieve the documented properties of a Microsoft Defender security alert.

Get Article Indicator

Read a Microsoft Defender Threat Intelligence article indicator.

Get Email Submission Policy

Get one email threat-submission policy by its Microsoft Graph identifier.

Get Host Component

Read a web component observed on a threat-intelligence host.

Get Host Cookie

Read a cookie observed on a Microsoft Defender Threat Intelligence host.

Get Host Pair

Read a parent-child host relationship observed by Microsoft Defender Threat Intelligence.

Get Host Port

Read a port observed on a Microsoft Defender Threat Intelligence host.

Get Host Reputation

Get the reputation properties and relationships for a threat-intelligence host.

Get Host Tracker

Read an internet tracker observed on a Microsoft Defender Threat Intelligence host.

Get Host WHOIS

Get the WHOIS record associated with a threat-intelligence host.

Get Incident

Retrieve a Microsoft Defender incident by its identifier.

Get Intelligence Profile

Get a Microsoft Defender threat-intelligence profile by identifier.

Get Intelligence Profile Indicator

Get a Microsoft Defender intelligence profile indicator by identifier.

Get Landing Page

Get a landing page associated with an attack simulation campaign.

Get Login Page

Get a login page associated with an attack simulation campaign.

Get Passive DNS Record

Get a Microsoft Defender passive DNS record by identifier.

Get Payload

Get an attack simulation campaign payload.

Get Payload Detail

Get detailed content for an attack simulation campaign payload.

Get Secure Score

Retrieve a Microsoft secure score by its provider-generated identifier.

Get Secure Score Control Profile

Retrieve a Microsoft secure score control profile by its identifier.

Get Simulation

Get an attack simulation campaign.

Get Simulation Automation

Get an attack simulation automation.

Get Simulation Landing Page

Get the landing page associated with an attack simulation campaign.

Get Simulation Login Page

Get the login page associated with an attack simulation campaign.

Get Simulation Operation

Get an attack simulation operation to track a long-running request.

Get Simulation Payload

Get the payload associated with an attack simulation campaign.

Get Simulation Report Overview

Get an overview of an attack simulation and training campaign.

Get Subdomain

Get a Microsoft Defender threat-intelligence subdomain by identifier.

Get Threat Article

Read a Microsoft Defender Threat Intelligence article by ID.

Get Threat Host

Read a hostname or IP address detected by Microsoft Defender Threat Intelligence.

Get Threat Submission

Get one email, file, or URL threat submission by its Microsoft Graph identifier.

Get Training

Get an attack simulation training resource.

Get Training Language Detail

Get localized language details for an attack simulation training.

Get Vulnerability

Get a Microsoft Defender threat-intelligence vulnerability by identifier.

Get Vulnerability Component

Get a component associated with a Microsoft Defender vulnerability.

Get WHOIS History Record

Get a Microsoft Defender WHOIS history record by identifier.

Get WHOIS Record

Get a Microsoft Defender WHOIS record by identifier.

List Alerts

Get a page of Microsoft Defender security alerts and their properties.

List Article Indicators

List indicators of threat or compromise associated with a threat article.

List Attack Simulation Repeat Offenders

Get one page of tenant users who yielded to attacks more than once in attack simulation campaigns.

List Email Submission Policies

Get the email threat-submission policies and their current settings.

List End User Notifications

Get one page of attack simulation end-user notification templates.

List Host Components

List web components observed on a Microsoft Defender Threat Intelligence host.

List Host Cookies

List cookies observed on a Microsoft Defender Threat Intelligence host.

List Host Pairs

List all, child, or parent host-pair relationships for a threat-intelligence host.

List Host Passive DNS

List passive-DNS records associated with a Microsoft Defender Threat Intelligence host.

List Host Ports

Get one page of ports associated with a Microsoft Defender threat-intelligence host.

List Host Reverse Passive DNS

Get one page of passive DNS records that resolve to the specified host.

List Host Subdomains

Get one page of subdomain resources associated with a threat-intelligence host.

List Host Trackers

Get one page of trackers associated with a threat-intelligence host.

List Host WHOIS History

Get one page of historical WHOIS records associated with a host.

List Incidents

Get one page of Microsoft Defender incidents and an opaque continuation cursor.

List Intelligence Profile Indicators

Get one page of indicators associated with a Microsoft Defender intelligence profile.

List Intelligence Profiles

Get one page of Microsoft Defender threat-intelligence profiles.

List Landing Pages

Get one page of landing pages for attack simulation campaigns.

List Login Pages

Get one page of login pages for attack simulation campaigns.

List Payloads

Get one page of payloads for attack simulation campaigns.

List Secure Score Control Profiles

Return one page of Microsoft secure score control profiles and an opaque continuation cursor.

List Secure Scores

Return one page of daily Microsoft secure scores and an opaque continuation cursor.

List Simulation Automation Runs

Get one page of runs for an attack simulation automation.

List Simulation Automations

Get one page of attack simulation automations.

List Simulations

Get one page of attack simulation campaigns.

List Simulation User Coverage

Get one page of attack simulation coverage records for tenant users.

List Simulation Users

List users and their recorded actions in an attack simulation campaign.

List Threat Articles

List Microsoft Defender Threat Intelligence articles one page at a time.

List Threat Submissions

List one page of email, file, or URL threat submissions visible to the connected account.

List Trainings

Get one page of attack simulation training resources.

List Training User Coverage

Get one page of training coverage records for tenant users in attack simulation campaigns.

List Vulnerability Components

Get one page of components associated with a Microsoft Defender vulnerability.

List WHOIS Record History

Get one page of historical records for a Microsoft Defender WHOIS record.

List WHOIS Records

Get one page of WHOIS records from Microsoft Defender threat intelligence.

Merge Incidents

Merge at least two Microsoft Defender incidents into one incident.

Move Alerts

Move one or more Microsoft Defender alerts to a new or existing incident.

Review Email Threat Submission

Record the administrator's review category for an email threat submission.

Run Hunting Query

Run a Kusto Query Language query against Microsoft Defender advanced-hunting data for the requested time span or workspace.

Submit Email Threat

Submit email content or a Microsoft Graph message URL for security analysis; this starts an external review workflow and cannot be undone here.

Submit File Threat

Submit base64 file content for security analysis; this starts an external review workflow and cannot be undone here.

Submit URL Threat

Submit a URL for security analysis; this starts an external review workflow and cannot be undone here.

Update Alert

Update one or more mutable properties of a Microsoft Defender security alert.

Update Email Submission Policy

Update one or more settings on an email threat-submission policy.

Update Incident

Update one or more editable properties of a Microsoft Defender incident.

Update Secure Score Control Profile

Update tenant state, assignment, comments, and required vendor information for a Microsoft secure score control profile.

Update Simulation

Update a draft attack simulation, optionally binding a payload by resource ID; acceptance does not mean completion.

FAQ

Frequently asked questions

Start with Microsoft Defender.It takes 30 seconds.

Managed auth, hosted MCP servers, and every Microsoft Defender tool your agent needs.Free to start.

Start building