Skip to content
Ketan Kamble
Ketan Kamble
Modern Workplace Architect

Read-only Intune & Entra tooling, in the open, and what the portal is doing underneath.

MD-102 SC-300 Speaker · WNUG Finland

Entra's preview lets local AI agents call APIs as the signed-in user

Entra local agents calling APIs as the signed-in user, in preview, where consent to the agent's scopes decides which ones it can use

Microsoft Entra Agent ID has a preview flow for AI agents that run on a user's own device. The agent signs the user in and then calls a protected API with that user's delegated permissions. There's no SLA, and Microsoft doesn't recommend it for production workloads.

Whoever can approve the agent's scopes decides which ones it can use on a user's behalf. Consent settings should come first, then the pilot.

How this was tested Written from Microsoft's announcements and documentation. I haven't reproduced it in my lab.

How the flow works

  1. The user signs in through a browser.
  2. The agent asks for the delegated scopes the API needs. A scope is one named permission, such as User.Read.
  3. A user or admin has to consent before the agent can use a scope.
  4. MSAL, Microsoft's sign-in library, gets an access token for the user and caches it.
  5. The API decides whether to allow the call based on the user, the agent's client ID and the scopes in the token.

Each API needs its own token. A token issued for Microsoft Graph can't be used with another API.

Local agents are public clients and only get delegated access. They can't use client credentials to get app-only tokens. The docs give no general availability date, and the preview notice links to the Universal License Terms for Online Services.

Who this lands on

Entra admins get this first, because they own consent, app permissions and agent identities. Developers building agents for user devices will care too, and so will API owners, who decide which delegated permissions their API offers. If you're on the endpoint side and want to know which local AI tools users already run, my read-only local AI agent inventory lists them by device and user. My Ignite 2026 GA vs preview roundup covers a related preview too, Agent ID for discovered local agents. Microsoft MCP Server for IT Admins, which is generally available, also works only with delegated permissions, and I covered what to check before piloting it.

Pilot checklist

  1. Find out in your user consent settings which permissions users can approve for themselves, and decide which ones should need an admin.
  2. Use single-instance mode. A blueprint is the Entra object an agent identity is created from, and public-client agents on endpoint devices have to use single-instance mode. You can't change the mode after the blueprint is created. Single-instance provisioning and single-instance authentication both have to be enabled for the tenant, and single-instance blueprints don't support inheritable permissions.
  3. Keep credentials off the blueprint for this flow. A local agent can't securely store a client secret or certificate, and Microsoft says not to add those or a federated identity credential.
  4. Check the requested scopes against the task. Microsoft's advice is to request only the delegated scopes the operation needs.
  5. Set up an approval path. If consent needs an administrator's approval, the admin needs the client ID, the target API and the requested scopes.
  6. Give support the error guide. For a 401, check that the token was requested for this API and that the API's validation settings match its registration. For a 403, check delegated consent and the user's access to the resource.

Every installation uses the same client ID. Installing the agent on another device doesn't create another agent identity, and Microsoft says not to create one per device.

CIMD clients show up somewhere else

Client ID Metadata Documents (CIMD) are a separate preview, where the client ID is a public HTTPS address for the client's metadata document. Entra represents a CIMD client as an agent identity in each tenant where it's approved, with a read-only blueprint. It isn't clear from the docs whether that blueprint appears in the blueprint list, so don't count on the check below to find CIMD clients. In the admin center, they're under Entra ID > Agents > Agent identities with the Has Client ID Metadata Document filter.

The default posture lets users add CIMD clients and grant a limited set of scopes, such as openid and Microsoft Graph User.Read. Other permissions need admin approval. The strict posture has an admin add every client. I'd settle on a posture before the pilot starts.

Which single-instance blueprints carry credentials

For each single-instance blueprint, the script counts its client secrets and certificates. It asks for the credential properties with $select, and if one doesn't come back it shows unknown instead of 0. Selecting keyCredentials is throttled at 150 requests per minute per tenant. Check federated identity credentials and granted consent separately, because the script doesn't look at them.

It uses Graph beta, because isSingleInstance is only on the beta resource, and needs AgentIdentityBlueprint.Read.All. If you don't own the blueprints, you also need a supported Entra role. For non-owners listing them in delegated calls, Microsoft names Agent ID Administrator as the least privileged role, and that role can manage everything about agents in the tenant, lifecycle included. Nothing in the script writes.

# Lists single-instance agent identity blueprints and their credential counts.
Connect-MgGraph -Scopes 'AgentIdentityBlueprint.Read.All' -NoWelcome

$select = 'id,appId,displayName,isDisabled,isSingleInstance,passwordCredentials,keyCredentials'
$uri = "https://graph.microsoft.com/beta/applications/microsoft.graph.agentIdentityBlueprint?`$select=$select"
$blueprints = while ($uri) {
    $page = Invoke-MgGraphRequest -Method GET -Uri $uri
    $page.value
    $uri  = $page.'@odata.nextLink'
}

function Get-CredCount($value) {
    if ($null -eq $value) { 'unknown' } else { @($value).Count }
}

$blueprints |
    Where-Object { $_.isSingleInstance -eq $true } |
    ForEach-Object {
        [pscustomobject]@{
            Name         = $_.displayName
            ClientId     = $_.appId
            Disabled     = $_.isDisabled
            Secrets      = Get-CredCount $_.passwordCredentials
            Certificates = Get-CredCount $_.keyCredentials
        }
    } | Format-Table -AutoSize

A single-instance blueprint isn't always a local agent, since hosted confidential clients can use that mode too. Confirm each result with its owner before you treat a secret as a problem.

Questions people ask

Can a local AI agent call Microsoft Graph as the signed-in user? Yes, in preview. The agent asks for delegated scopes, a user or admin consents, and MSAL gets a token for that user.

Can a local agent use app-only permissions? Only delegated access. Local agents are public clients and can't use client credentials to get app-only tokens.

Is calling APIs from a local agent generally available? It's still a preview in Microsoft Entra Agent ID, without an SLA, and Microsoft doesn't recommend it for production workloads.

Should a local agent's blueprint have a client secret? Not for this flow. Microsoft says not to add a client secret, certificate or federated identity credential, because a local agent can't securely store a secret or certificate.

Does each device get its own agent identity? Every installation shares the same client ID. Installing the agent on another device doesn't create another agent identity.

Sources


I wrote this from Microsoft's preview docs on 4 December 2026 and haven't run the flow in production. Try the script in a test tenant before anything else. Independent content, not affiliated with, sponsored by, or endorsed by Microsoft. Microsoft, Microsoft Entra and Microsoft Graph are trademarks of the Microsoft group of companies.

← More from the blog