Skip to main content

How to Set Up Microsoft Copilot Studio

Connect AuditSwarm to Microsoft Copilot Studio for enterprise AI assistance.

Prerequisites

  • Microsoft Copilot Studio access
  • AuditSwarm account with admin permissions

Quick Setup (5 Steps)

Step 1: Open MCP Configuration

In Copilot Studio, click "Add a Model Context Protocol server (Preview)"

Step 2: Enter Server Details

FieldValue
Server nameauditswarm-mcp
Server descriptionaudit management system
Server URLhttps://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/mcp

Step 3: Select Authentication

  • Authentication: OAuth 2.0
  • Type: Dynamic discovery

Step 4: Create Connection

Click "Create" to save the MCP server configuration.

Step 5: Complete OAuth Login

You'll be redirected to AuditSwarm to authorize the connection. Sign in with your AuditSwarm account.


Critical Configuration Notes

Server URL Requirements

MUST use Cloud Run URL:

https://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/mcp

MUST include /mcp suffix - this is the JSON-RPC endpoint.

DO NOT use:

  • Custom domain URLs (browser access only)
  • URLs without /mcp suffix

OAuth Configuration

  • No client ID or secret required
  • Uses Dynamic Client Registration with PKCE
  • OAuth endpoints auto-discovered from /.well-known/oauth-authorization-server

Available Endpoints

EndpointURLPurpose
MCP Endpointhttps://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/mcpFor Copilot connections
Health Checkhttps://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/mcp/healthTest connectivity
OpenAPI Spechttps://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/openapi.jsonAPI documentation
OAuth Metadatahttps://demo.auditswarm.com/.well-known/oauth-authorization-serverAuth discovery

Troubleshooting

Error: "Invalid token"

Cause: MCP server is missing NEXTAUTH_SECRET environment variable.

Solution (for admins):

gcloud run services update auditswarms-mcp \
--region=us-central1 \
--update-secrets=NEXTAUTH_SECRET=nextauth-secret:latest

Error: "Connector request failed"

Cause: Missing /mcp suffix in server URL.

Solution: Use the full URL with /mcp:

https://auditswarms-mcp-wf4a3tv3ka-uc.a.run.app/mcp

Error: "Authentication failed"

Cause: OAuth flow failed or token expired.

Solution:

  1. Remove the existing MCP server connection
  2. Re-add with the correct URL
  3. Complete OAuth login again

Testing the Connection

After setup, test the connection:

  1. In Copilot Studio, open the MCP server settings
  2. Click "Test" or ask the copilot to list audits
  3. Verify you see audit data from AuditSwarm

Available Tools

Once connected, your copilot has access to:

ToolDescription
suggest_changeCreate, update, delete entities (via suggestions)
query_dataQuery audits, risks, controls, workflows
get_current_contextGet user's current page context
helpGet workflow guidance

See MCP Tools Reference for complete documentation.


Next Steps