Edit

Share via


Items - Associate Identity (beta)

Associates the default identity with an item.

Note

This API is part of a Beta release and is provided for evaluation and development purposes only. It may change based on feedback and is not recommended for production use. When calling this API, callers must specify true as the value for the query parameter beta.

This API supports long running operations (LRO).

This API is supported for a number of item types, find the supported item types and information about their definition structure in Item management overview.

Permissions

The caller must have read and write permissions for the item.

Required Delegated Scopes

For item APIs use these scope types:

  • Generic scope: Item.ReadWrite.All
  • Specific scope: itemType.ReadWrite.All (for example: Notebook.ReadWrite.All)

for more information about scopes, see: scopes article.

Microsoft Entra supported identities

This API supports the Microsoft identities listed in this section.

Identity Support
User Yes
Service principal and Managed identities When the item type in the call is supported. Check the corresponding API for the item type you're calling, to see if your call is supported.

Interface

POST https://api.fabric.microsoft.com/v1/workspaces/{workspaceId}/items/{itemId}/identities/default/assign?beta={beta}

URI Parameters

Name In Required Type Description
itemId
path True

string (uuid)

The item ID.

workspaceId
path True

string (uuid)

The workspace ID.

beta
query True

boolean

This required parameter must be set to true to access this API, which is currently in beta.

Request Body

Name Required Type Description
assignmentType True

IdentityAssignmentEntityType

The type of subject that makes an associaste identity request.

Responses

Name Type Description
200 OK

UpdateItemIdentityResponse

Request completed successfully.

202 Accepted

Request accepted, identity association is in progress.

Headers

  • Location: string
  • Retry-After: integer
429 Too Many Requests

ErrorResponse

The service rate limit was exceeded. The server returns a Retry-After header indicating, in seconds, how long the client must wait before sending additional requests.

Headers

Retry-After: integer

Other Status Codes

ErrorResponse

Common error codes:

  • ItemNotFound - The requested item was not found.

  • InvalidRequest - Invalid association request.

Examples

Associate identity example

Sample request

POST https://api.fabric.microsoft.com/v1/workspaces/cfafbeb1-8037-4d0c-896e-a46fb27ff229/items/5b218778-e7a5-4d73-8187-f10824047715/identities/default/assign?beta=True

{
  "assignmentType": "Caller"
}

Sample response

{
  "assignmentStatus": [
    {
      "itemId": "eab1679a-8cab-40d6-9ba6-5c2a07a7ce81",
      "status": "Succeeded"
    },
    {
      "itemId": "8eedb1b0-3af8-4b17-8e7e-663e61e12211",
      "parentItemId": "eab1679a-8cab-40d6-9ba6-5c2a07a7ce81",
      "status": "Succeeded"
    },
    {
      "itemId": "83b128a3-f58f-4eee-ab0b-e7e25a748f54",
      "parentItemId": "eab1679a-8cab-40d6-9ba6-5c2a07a7ce81",
      "status": "Failed",
      "errorInfo": {
        "errorCode": "AssignmentFailed",
        "message": "The assignment operation failed due to insufficient permissions."
      }
    }
  ]
}
Location: https://api.fabric.microsoft.com/v1/operations/427f6c34-b64e-4ee4-8ea5-b533c0e203ef
x-ms-operation-id: 427f6c34-b64e-4ee4-8ea5-b533c0e203ef
Retry-After: 30

Definitions

Name Description
ErrorRelatedResource

The error related resource details object.

ErrorResponse

The error response.

ErrorResponseDetails

The error response details.

IdentityAssignmentEntityType

The type of subject that makes an associaste identity request.

IdentityAssignmentStatusType

The status of the identity assignment. Additional status may be added over time.

ItemAssignmentStatus

The status of an identity assignment to an item.

UpdateItemIdentityRequest

Associate identity request payload.

UpdateItemIdentityResponse

Associate identity response.

ErrorRelatedResource

The error related resource details object.

Name Type Description
resourceId

string

The resource ID that's involved in the error.

resourceType

string

The type of the resource that's involved in the error.

ErrorResponse

The error response.

Name Type Description
errorCode

string

A specific identifier that provides information about an error condition, allowing for standardized communication between our service and its users.

message

string

A human readable representation of the error.

moreDetails

ErrorResponseDetails[]

List of additional error details.

relatedResource

ErrorRelatedResource

The error related resource details.

requestId

string (uuid)

ID of the request associated with the error.

ErrorResponseDetails

The error response details.

Name Type Description
errorCode

string

A specific identifier that provides information about an error condition, allowing for standardized communication between our service and its users.

message

string

A human readable representation of the error.

relatedResource

ErrorRelatedResource

The error related resource details.

IdentityAssignmentEntityType

The type of subject that makes an associaste identity request.

Value Description
Caller

User or service principal who makes the associate identity request.

IdentityAssignmentStatusType

The status of the identity assignment. Additional status may be added over time.

Value Description
Succeeded

The identity is successfully assigned to the item.

Failed

The identity assignment failed.

ItemAssignmentStatus

The status of an identity assignment to an item.

Name Type Description
errorInfo

ErrorResponseDetails

The error information if the identity assignment failed.

itemId

string (uuid)

The ID of the item.

parentItemId

string (uuid)

The ID of the parent item.

status

IdentityAssignmentStatusType

The status of the identity assignment. Additional status may be added over time.

UpdateItemIdentityRequest

Associate identity request payload.

Name Type Description
assignmentType

IdentityAssignmentEntityType

The type of subject that makes an associaste identity request.

UpdateItemIdentityResponse

Associate identity response.

Name Type Description
assignmentStatus

ItemAssignmentStatus[]

The identity assigned to the item after update.