Notatka
Dostęp do tej strony wymaga autoryzacji. Może spróbować zalogować się lub zmienić katalogi.
Dostęp do tej strony wymaga autoryzacji. Możesz spróbować zmienić katalogi.
Namespace: microsoft.graph
Important
APIs under the /beta version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported. To determine whether an API is available in v1.0, use the Version selector.
Delete an objectConnection to clear the cached linkage record for an object in a synchronizationJob.
The service clears the corresponding connector data store cache entry so the object is re-evaluated during a later synchronization cycle. This operation clears the linkage record; it doesn't delete the source or target directory object.
This API is available in the following national cloud deployments.
| Global service | US Government L4 | US Government L5 (DOD) | China operated by 21Vianet |
|---|---|---|---|
| ✅ | ❌ | ❌ | ❌ |
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 permissions | Higher privileged permissions |
|---|---|---|
| Delegated (work or school account) | SynchronizationMetadata.ReadWrite.All | Not available. |
| Delegated (personal Microsoft account) | Not supported. | Not supported. |
| Application | SynchronizationMetadata.ReadWrite.OwnedBy | SynchronizationMetadata.ReadWrite.All |
The SynchronizationMetadata.ReadWrite.OwnedBy application permission restricts access to synchronization jobs associated with service principals owned by the calling application.
HTTP request
DELETE /servicePrincipals/{servicePrincipal-id}/synchronization/jobs/{synchronizationJob-id}/objectConnections/{objectId}
Replace {objectId} with the exact source or target identifier for the object in this synchronization job. For example, use the Microsoft Entra object ID for the Microsoft Entra side of a connection, or the Workday worker's WID for the Workday source. The service searches for a source identifier first, then a target identifier. Preserve the identifier's original format.
Request headers
| Name | Description |
|---|---|
| Authorization | Bearer {token}. Required. Learn more about authentication and authorization. |
Request body
Don't supply a request body for this method.
Response
If successful, this method returns a 204 No Content response code.
Errors
| HTTP status | Condition |
|---|---|
401 Unauthorized |
The caller is unauthenticated, lacks the delegated scope, or fails delegated authorization checks. |
403 Forbidden |
The required application permission is missing, or the caller can't access the requested synchronization job. |
404 Not Found |
The synchronization job or object connection doesn't exist. |
429 Too Many Requests |
The request is throttled. |
Examples
Request
The following example uses the source user's Microsoft Entra object ID as {objectId}.
DELETE https://graph.microsoft.com/beta/servicePrincipals/{servicePrincipal-id}/synchronization/jobs/{synchronizationJob-id}/objectConnections/9d47c4a5-0d5a-4c0e-91b6-6f6c9c6e4c77
Response
The following example shows the response.
HTTP/1.1 204 No Content