Items marked preview in this article are currently in preview. This preview is provided without a service-level agreement, and Microsoft doesn’t recommend it for production workloads. Certain features might not be supported or might have constrained capabilities. For more information, see Supplemental Terms of Use for Microsoft Azure Previews.
Prerequisites
Before you begin, ensure you have:-
The commercial requirement for the connection you use:
- An active Microsoft Foundry project with a deployed model.
-
Azure RBAC roles:
- Foundry User role on the Foundry project for the developer identity, the agent’s runtime identity, and any user identity involved in OAuth flows.
- Foundry Project Manager role on the Foundry project for creating a Foundry connection to the Work IQ endpoint.
-
A Microsoft Entra Global Administrator who can complete the one-time tenant setup by provisioning the Work IQ service principal and granting admin consent for
WorkIQAgent.Ask. Activate this role just in time through Microsoft Entra Privileged Identity Management (PIM), and deactivate it after setup. Day-to-day Work IQ users don’t need this role. - Foundry Toolkit: Install Visual Studio Code and Foundry Toolkit for Visual Studio Code.
-
JavaScript development: Use Node.js 22 or later and install
@azure/ai-projects2.4.0 or later with@azure/identity.
A2A-Version: 1.0 to use v1 method names. Omitting the header defaults to v0.3. Include location metadata for time-sensitive requests, and use delegated user authentication.
Follow the setup dependency map
Use this map to separate the agent-use flow from dependencies that an administrator completes once for the organization.
Complete the agent-use flow first when your organization already has a connection. Use the one-time tenant setup only when an administrator needs to create the first connection.
Usage support
How it works
- Your agent dispatches a tool call — When the agent model identifies a task that requires Microsoft 365 data, it emits a tool call to the
work_iq_previewtool. - Foundry routes the request to Work IQ via A2A — Foundry uses the Agent-to-Agent (A2A) protocol to forward the natural-language query to Work IQ as a peer agent. Authentication uses On-Behalf-Of (OBO) so the request runs in the context of the signed-in user.
- Work IQ retrieves and reasons over M365 data — Work IQ queries the user’s emails, meetings, files, chats, and other Microsoft 365 signals. It applies semantic understanding to synthesize a response grounded in the user’s actual work context, honoring Microsoft 365 permissions and sensitivity labels throughout.
- The result is returned to your agent — Work IQ returns the synthesized response to Foundry via A2A. Your agent incorporates it into its reply to the user.
Connect to Work IQ
Add the Work IQ tool to your agent
Add Work IQ to a toolbox with the Azure Developer CLI
Use the Azure Developer CLI to create the Work IQ A2A project connection, and then reference it from a minimal toolbox YAML.This article uses the Work IQ A2A endpoint
https://workiq.svc.cloud.microsoft/a2a/. The previous toolbox catalog used https://agent365.svc.cloud.microsoft/agents/agents/workiq for its azd workflow. Verify the endpoint if your Work IQ connection uses a different A2A or MCP target.Use Work IQ with a hosted agent
After you creatework-iq-toolbox, follow Use a toolbox with a hosted agent to connect it to Agent Framework, run it locally, and deploy it to Foundry Agent Service. The hosted integration preserves the per-request context that Work IQ needs to act on behalf of each signed-in user.
For end-to-end implementations, use the maintained Python Teams activity sample or .NET Teams activity sample.
Authentication and security
Work IQ uses Microsoft Entra ID delegated authentication. All requests run in the context of the signed-in user. Application-only (app-only) authentication isn’t supported. Microsoft 365 permissions are enforced automatically — Work IQ agents can never access data that the signed-in user isn’t already permitted to see. Only Bring your own Entra app (On-Behalf-Of authentication) is supported for Work IQ connections. This authentication method gives your Entra admin explicit control over which applications can retrieve Microsoft 365 data through Work IQ. The admin reviews and grants theWorkIQAgent.Ask permission specifically for your registered app.
Set up your Microsoft Entra app (one-time, per organization)
A Microsoft Entra admin must complete the following one-time tenant operation before you can create a Work IQ connection in Foundry. For steps that require the Global Administrator role, use Microsoft Entra PIM to activate the role just in time, and deactivate it when setup is complete. Day-to-day Work IQ users don’t need this role.Provision the Work IQ service principal (one-time)
Before you create the app registration, a Global Administrator must provision the Work IQ service principal as part of this one-time tenant operation. If you skip this step, the Work IQ option won’t appear when you search API permissions. Follow Step 1: Create the Work IQ service principal in the Work IQ API quickstart. A 201 Created response from Graph Explorer confirms success. A conflict error means the principal already exists — continue to the next step.Create the app registration
- Go to the Microsoft Entra admin center. In the left navigation, select Entra ID > App registrations.
- Select New registration. Give the app a descriptive name and set Supported account types to Accounts in this organizational directory only. Select Register.
- Copy the Application (client) ID. You need this value when creating the Foundry connection.
-
Select API permissions > Add a permission > APIs my organization uses. Search for Work IQ (application ID
fdcc1f02-fc51-4226-8753-f668596af7f7), select Delegated permissions, select WorkIQAgent.Ask, then select Add permissions. - Select Grant admin consent for [your tenant]. Review the confirmation dialog and select Yes.
Granting tenant-wide admin consent is a one-time tenant operation that requires the Global Administrator role in Microsoft Entra ID. Activate the role just in time through Microsoft Entra PIM, and deactivate it after granting consent. Day-to-day Work IQ users don’t need this role. If you don’t have this role, ask your organization’s Global Administrator to complete this step.
- Select Certificates & secrets > New client secret. Add a description and expiration. Select Add, and then immediately copy the secret Value - it’s only shown once. Store the secret in Azure Key Vault or another approved secret store. Never commit the secret to source control or print or log it. Rotate the secret before it expires.
- Copy your Directory (tenant) ID from the Microsoft Entra ID overview page.
Fill in the Foundry connection values
In Microsoft Foundry, open your project and go to Settings > Connections > New connection > Work IQ. Fill in the following fields:
Replace
{tenant-id} with your Directory (tenant) ID from step 7. Select Save to create the connection.

You can’t edit connection fields after creation. If you enter incorrect values, delete the connection and create a new one.
Create the connection with the Azure Developer CLI
Set the Foundry project endpoint and your app registration values. Keep the client secret in your shell or secret store, and don’t put it in source control.Add the redirect URI to your app registration
After Foundry creates the connection, it displays an OAuth redirect URL. Add this URL to your app registration:- In the Microsoft Entra admin center, go to Entra ID > App registrations and select your app.
- Select Authentication > Add a platform > Web.
- Under Redirect URIs, paste the OAuth redirect URL from Foundry.
- Select Configure.
Create the connection with the REST API
As an alternative to the Foundry portal, use the Azure Resource Manager API to create the Work IQ connection programmatically. Step 1: Acquire a tokenproperties.oauthRedirectUrl field — use that value as the redirect URI in your Entra app registration (see Add the redirect URI to your app registration).
Data governance and compliance
Work IQ and Foundry are Microsoft services with distinct service and data-processing boundaries. When a Foundry agent calls Work IQ, request data goes beyond the Foundry service boundary and might be processed outside the Azure compliance boundary. Work IQ authenticates requests on behalf of the signed-in user and enforces that user’s existing Microsoft 365 permissions and applicable policies. The Microsoft Entra tenant establishes the authorization context; it doesn’t, by itself, guarantee where data is processed or stored. For this Agent-to-Agent (A2A) integration, Work IQ returns a synthesized response that can contain information grounded in the user’s Microsoft 365 content. Foundry can further process or store that response according to the agent and project configuration. The complete workflow can involve Work IQ, Copilot, and Foundry processing. Review the applicable service terms, data-handling policies, regional configuration, and certification coverage for every service in the request path. End-to-end processing also depends on the Copilot billing configuration and Foundry project region. Don’t infer end-to-end residency or compliance coverage solely from the user’s tenant or the location of the original Microsoft 365 content. Direct traffic between Azure and Microsoft services is expected to use the Microsoft global network, as described in Global routing and interconnection. Work IQ uses the public HTTPS endpointhttps://workiq.svc.cloud.microsoft. Authentication and supported file operations can also require outbound HTTPS access to additional endpoints. A public endpoint can still be reached over the Microsoft global network and doesn’t necessarily mean that traffic traverses the public internet. Review and allow the destinations required by your Work IQ scenario.
When the Foundry project is configured for bring-your-own virtual network (BYO VNet) outbound integration, Work IQ tool calls route through the project’s single-tenant data proxy. This platform-managed networking component is dedicated to the project and handles outbound tool connectivity, allowing customer-defined network controls to govern that traffic. For more information about the data proxy and request path, see Deep dive into Foundry Agent Service networking. For the available inbound and outbound configurations, see Networking options for Foundry Agent Service.
A private endpoint for Foundry provides private inbound access to Foundry. It doesn’t configure outbound VNet integration or make the outbound connection to Work IQ private. Work IQ remains a public HTTPS destination in this configuration. Routing through the data proxy doesn’t establish private ingress to Work IQ or change the service terms and data-handling requirements applicable to Work IQ processing.
Data residency
Microsoft 365 retrieval follows your tenant’s permissions and residency configuration. End-to-end processing also depends on your Copilot billing configuration and Foundry project region. For details, see Microsoft Copilot privacy and data handling policies.Privacy and data handling
Review the Microsoft Copilot privacy and data handling policies and the Foundry data handling requirements that apply to your deployment. Confirm the complete request path with your privacy and compliance teams.Access control and permissions
Design the connection so retrieval uses the signed-in user’s Microsoft 365 permissions. Test permission trimming with representative users and restricted content before deployment:- Role-based access control, sensitivity labels, and information barriers defined in Microsoft 365 are respected.
Compliance review
Use your organization’s Microsoft compliance resources to confirm which certifications and controls apply to the complete Work IQ and Foundry deployment.Admin management
As an Entra admin, you control which applications in your tenant can access Work IQ data on behalf of users. The following sections describe the key controls available to you.Grant or revoke admin consent
Admin consent forWorkIQAgent.Ask is required before any user in your organization can authenticate through the app. You can manage consent at any time:
- Grant consent: In the Microsoft Entra admin center, go to Entra ID > App registrations > select the app > API permissions. Select Grant admin consent for [your tenant].
- Revoke consent: On the same API permissions page, select the
WorkIQAgent.Askpermission and select Revoke admin consent. Existing tokens remain valid until they expire; no new tokens can be issued after revocation.