Edit

Share via


Create agentIdentityBlueprint

Namespace: microsoft.graph

Create a new agent identity blueprint object.

Permissions

Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.

Permission type Least privileged permission Higher privileged permissions
Delegated (work or school account) AgentIdentityBlueprint.Create AgentIdentityBlueprint.ReadWrite.All
Delegated (personal Microsoft account) Not supported. Not supported.
Application AgentIdentityBlueprint.Create AgentIdentityBlueprint.ReadWrite.All

Important

For delegated access using work or school accounts, the admin must be assigned a supported Microsoft Entra role. This operation supports the following built-in roles, which provide only the least privilege necessary:

  • Agent ID Administrator.
  • Agent ID Developer - Create agent identity blueprints and blueprint principals. The principal with this role is assigned ownership of the blueprint or blueprint principal they create and can perform write operations on the resources they own.

Known issue: If the client is granted either the Directory.AccessAsUser.All or Directory.ReadWrite.All permission, the client's permissions to create, update, and delete Agent IDs are ignored, which can cause requests to fail with 403 Forbidden error. To resolve this issue, remove these permissions from the client, request new access tokens, and retry the request.

HTTP request

POST /applications/microsoft.graph.agentIdentityBlueprint

Request headers

Name Description
Authorization Bearer {token}. Required. Learn more about authentication and authorization.
Content-Type application/json. Required.

Request body

In the request body, supply a JSON representation of agent identity blueprint object. You must specify the displayName property and sponsors relationship.

Response

If successful, this method returns 201 Created response code and an agent identity blueprint object in the response body.

Examples

Request

The following example shows a request.

POST https://graph.microsoft.com/v1.0/applications/microsoft.graph.agentIdentityBlueprint
Content-type: application/json

{
  "displayName": "Display name",
  "sponsors@odata.bind": [
    "https://graph.microsoft.com/v1.0/users/e64405d7-f156-4ce1-b1f5-b0d801c367f3"
   ]
}

Response

The following example shows the response.

Note: The response object shown here might be shortened for readability.

HTTP/1.1 201 Created
Content-type: application/json

{
    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#applications/microsoft.graph.agentIdentityBlueprint/$entity",
    "id": "03ef14b0-ca33-4840-8f4f-d6e91916010e",
    "appId": "00001111-aaaa-2222-bbbb-3333cccc4444",
    "identifierUris": [],
    "createdDateTime": "2019-09-17T19:10:35.2742618Z",
    "displayName": "Display name",
    "publisherDomain": "contoso.com",
    "requiredResourceAccess": [],
    "signInAudience": "AzureADMyOrg"
}