Microsoft Graph servicePrincipals.directoryObject API

The servicePrincipals.directoryObject API from Microsoft Graph — 64 operation(s) for serviceprincipals.directoryobject.

Operations 66

GET /servicePrincipals/{servicePrincipal-id}/memberOf Microsoft Graph List servicePrincipal memberOf #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id} Microsoft Graph Get memberOf from servicePrincipals #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.administrativeUnit Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.administrativeUnit #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.directoryRole Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.directoryRole #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.group Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.group #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.administrativeUnit Microsoft Graph Get the items of type microsoft.graph.administrativeUnit in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.administrativeUnit/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.directoryRole Microsoft Graph Get the items of type microsoft.graph.directoryRole in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.directoryRole/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.group Microsoft Graph Get the items of type microsoft.graph.group in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/memberOf/graph.group/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects Microsoft Graph servicePrincipal: List createdObjects #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects/{directoryObject-id} Microsoft Graph Get createdObjects from servicePrincipals #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects/{directoryObject-id}/graph.servicePrincipal Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.servicePrincipal #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects/graph.servicePrincipal Microsoft Graph Get the items of type microsoft.graph.servicePrincipal in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/createdObjects/graph.servicePrincipal/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects Microsoft Graph servicePrincipals: List ownedObjects #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id} Microsoft Graph Get ownedObjects from servicePrincipals #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id}/graph.application Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.application #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id}/graph.appRoleAssignment Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.appRoleAssignment #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id}/graph.endpoint Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.endpoint #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id}/graph.group Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.group #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/{directoryObject-id}/graph.servicePrincipal Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.servicePrincipal #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.application Microsoft Graph Get the items of type microsoft.graph.application in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.application/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.appRoleAssignment Microsoft Graph Get the items of type microsoft.graph.appRoleAssignment in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.appRoleAssignment/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.endpoint Microsoft Graph Get the items of type microsoft.graph.endpoint in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.endpoint/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.group Microsoft Graph Get the items of type microsoft.graph.group in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.group/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.servicePrincipal Microsoft Graph Get the items of type microsoft.graph.servicePrincipal in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/ownedObjects/graph.servicePrincipal/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/owners Microsoft Graph Get owners from servicePrincipals #
DELETE /servicePrincipals/{servicePrincipal-id}/owners/{directoryObject-id}/$ref Microsoft Graph Remove service principal owner #
GET /servicePrincipals/{servicePrincipal-id}/owners/{directoryObject-id}/graph.appRoleAssignment Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.appRoleAssignment #
GET /servicePrincipals/{servicePrincipal-id}/owners/{directoryObject-id}/graph.endpoint Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.endpoint #
GET /servicePrincipals/{servicePrincipal-id}/owners/{directoryObject-id}/graph.servicePrincipal Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.servicePrincipal #
GET /servicePrincipals/{servicePrincipal-id}/owners/{directoryObject-id}/graph.user Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.user #
GET /servicePrincipals/{servicePrincipal-id}/owners/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/owners/$ref Microsoft Graph Get ref of owners from servicePrincipals #
POST /servicePrincipals/{servicePrincipal-id}/owners/$ref Microsoft Graph servicePrincipal: Add owner #
DELETE /servicePrincipals/{servicePrincipal-id}/owners/$ref Microsoft Graph Remove service principal owner #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.appRoleAssignment Microsoft Graph Get the items of type microsoft.graph.appRoleAssignment in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.appRoleAssignment/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.endpoint Microsoft Graph Get the items of type microsoft.graph.endpoint in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.endpoint/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.servicePrincipal Microsoft Graph Get the items of type microsoft.graph.servicePrincipal in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.servicePrincipal/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.user Microsoft Graph Get the items of type microsoft.graph.user in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/owners/graph.user/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf Microsoft Graph List servicePrincipal transitive memberOf #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/{directoryObject-id} Microsoft Graph Get transitiveMemberOf from servicePrincipals #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/{directoryObject-id}/graph.administrativeUnit Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.administrativeUnit #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/{directoryObject-id}/graph.directoryRole Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.directoryRole #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/{directoryObject-id}/graph.group Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.group #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.administrativeUnit Microsoft Graph Get the items of type microsoft.graph.administrativeUnit in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.administrativeUnit/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.directoryRole Microsoft Graph Get the items of type microsoft.graph.directoryRole in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.directoryRole/$count Microsoft Graph Get the number of the resource #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.group Microsoft Graph Get the items of type microsoft.graph.group in the microsoft.graph.directoryObject collection #
GET /servicePrincipals/{servicePrincipal-id}/transitiveMemberOf/graph.group/$count Microsoft Graph Get the number of the resource #

Documentation

📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/admin?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/agreementacceptance?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/agreement?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/teamsapp?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/application?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/applicationtemplate?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/azure-ad-auditlog-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/authenticationmethodconfiguration?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/authenticationmethodspolicy?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/certificatebasedauthconfiguration?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/chat?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/communications-api-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/complianceapioverview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/externalconnectors-externalconnection?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/contact?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/contract?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/copilot-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/datapolicyoperation?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/intune-apps-conceptual?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/intune-device-conceptual?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/device?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/directory?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/domaindnsrecord?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/domain?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/drive?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/education-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/employee-experience-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/externalconnectors-external?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/filter-query-parameter
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/excel?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/grouplifecyclepolicy?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/groups-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/groupsetting?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/groupsettingtemplate?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/identitycontainer?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/informationprotection?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/invitation?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/users?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/oauth2permissiongrant?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/organization?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/resourcespecificpermissiongrant?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/place?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/planner-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/policy-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/print?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/privacy?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/report?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/rolemanagement?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/schemaextension?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/scopedrolemembership?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/search-api-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/security-api-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/serviceprincipal?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/shares?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/sharepoint?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/solutions-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/filestorage?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/subscribedsku?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/subscription?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/teams-api-overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/teamwork?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/tenantrelationship?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/auth/auth-concepts
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/workplace?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/overview?view=graph-rest-1.0
📖
Documentation
https://learn.microsoft.com/en-us/graph/api/resources/sitepage?view=graph-rest-1.0

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/microsoft-graph-serviceprincipals-directoryobject-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

microsoft-graph-serviceprincipals-directoryobject-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Microsoft Graph Admin Admin.admin Service Principals.directory Object API
  description: 'Microsoft Graph API for managing administrative resources in Microsoft Entra ID.

    This API enables administrators to manage Microsoft Edge browser settings, Internet Explorer mode configurations,

    site lists, shared browser sites, Microsoft 365 Apps installation options, people insights, service announcements,

    SharePoint settings, Copilot administration, directory administrative units, and admin consent policies.'
  version: 1.0.0
  contact:
    name: Microsoft Graph API Support
    url: https://developer.microsoft.com/graph
servers:
- url: https://graph.microsoft.com/v1.0
  description: Microsoft Graph API v1.0 endpoint
tags:
- name: servicePrincipals.directoryObject
paths:
  /servicePrincipals/{servicePrincipal-id}/memberOf:
    description: Provides operations to manage the memberOf property of the microsoft.graph.servicePrincipal entity.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph List servicePrincipal memberOf
      description: Get the groups and directory roles that this servicePrincipal is a direct member of. This operation is not transitive.
      externalDocs:
        description: Find more info here
        url: https://learn.microsoft.com/graph/api/serviceprincipal-list-memberof?view=graph-rest-1.0
      operationId: servicePrincipals.ListMemberOf
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.directoryObjectCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
      x-ms-docs-operation-type: operation
  /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}:
    description: Provides operations to manage the memberOf property of the microsoft.graph.servicePrincipal entity.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get memberOf from servicePrincipals
      description: 'Roles that this service principal is a member of. HTTP Methods: GET Read-only. Nullable. Supports $expand.'
      operationId: servicePrincipals.GetMemberOf
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Retrieved navigation property
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.directoryObject'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-docs-operation-type: operation
  /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.administrativeUnit:
    description: Casts the previous resource to administrativeUnit.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.administrativeUnit
      operationId: servicePrincipals.GetMemberOf.AsAdministrativeUnit
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Entity result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.administrativeUnit'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.directoryRole:
    description: Casts the previous resource to directoryRole.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.directoryRole
      operationId: servicePrincipals.GetMemberOf.AsDirectoryRole
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Entity result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.directoryRole'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/{directoryObject-id}/graph.group:
    description: Casts the previous resource to group.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.group
      operationId: servicePrincipals.GetMemberOf.AsGroup
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Entity result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.group'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/$count:
    description: Provides operations to count the resources in the collection.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the number of the resource
      operationId: servicePrincipals.memberOf.GetCount-be11
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      responses:
        2XX:
          $ref: '#/components/responses/ODataCountResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.administrativeUnit:
    description: Casts the previous resource to administrativeUnit.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the items of type microsoft.graph.administrativeUnit in the microsoft.graph.directoryObject collection
      operationId: servicePrincipals.ListMemberOf.AsAdministrativeUnit
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.administrativeUnitCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.administrativeUnit/$count:
    description: Provides operations to count the resources in the collection.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the number of the resource
      operationId: servicePrincipals.MemberOf.GetCount.AsAdministrativeUnit-472e
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      responses:
        2XX:
          $ref: '#/components/responses/ODataCountResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.directoryRole:
    description: Casts the previous resource to directoryRole.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the items of type microsoft.graph.directoryRole in the microsoft.graph.directoryObject collection
      operationId: servicePrincipals.ListMemberOf.AsDirectoryRole
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.directoryRoleCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.directoryRole/$count:
    description: Provides operations to count the resources in the collection.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the number of the resource
      operationId: servicePrincipals.MemberOf.GetCount.AsDirectoryRole-fa4e
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      responses:
        2XX:
          $ref: '#/components/responses/ODataCountResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.group:
    description: Casts the previous resource to group.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the items of type microsoft.graph.group in the microsoft.graph.directoryObject collection
      operationId: servicePrincipals.ListMemberOf.AsGroup
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.groupCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
  /servicePrincipals/{servicePrincipal-id}/memberOf/graph.group/$count:
    description: Provides operations to count the resources in the collection.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the number of the resource
      operationId: servicePrincipals.MemberOf.GetCount.AsGroup-96d9
      parameters:
      - name: ConsistencyLevel
        in: header
        description: 'Indicates the requested consistency level. Documentation URL: https://docs.microsoft.com/graph/aad-advanced-queries'
        schema:
          type: string
        examples:
          example-1:
            description: $search and $count queries require the client to set the ConsistencyLevel HTTP header to 'eventual'.
            value: eventual
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      responses:
        2XX:
          $ref: '#/components/responses/ODataCountResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/createdObjects:
    description: Provides operations to manage the createdObjects property of the microsoft.graph.servicePrincipal entity.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: 'Microsoft Graph servicePrincipal: List createdObjects'
      description: Retrieve a list of directoryobject objects.
      externalDocs:
        description: Find more info here
        url: https://learn.microsoft.com/graph/api/serviceprincipal-list-createdobjects?view=graph-rest-1.0
      operationId: servicePrincipals.ListCreatedObjects
      parameters:
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.directoryObjectCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
      x-ms-docs-operation-type: operation
  /servicePrincipals/{servicePrincipal-id}/createdObjects/{directoryObject-id}:
    description: Provides operations to manage the createdObjects property of the microsoft.graph.servicePrincipal entity.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get createdObjects from servicePrincipals
      description: Directory objects created by this service principal. Read-only. Nullable.
      operationId: servicePrincipals.GetCreatedObjects
      parameters:
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Retrieved navigation property
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.directoryObject'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-docs-operation-type: operation
  /servicePrincipals/{servicePrincipal-id}/createdObjects/{directoryObject-id}/graph.servicePrincipal:
    description: Casts the previous resource to servicePrincipal.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    - name: directoryObject-id
      in: path
      description: The unique identifier of directoryObject
      required: true
      schema:
        type: string
      x-ms-docs-key-type: directoryObject
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the item of type microsoft.graph.directoryObject as microsoft.graph.servicePrincipal
      operationId: servicePrincipals.GetCreatedObjects.AsServicePrincipal
      parameters:
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          description: Entity result.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/microsoft.graph.servicePrincipal'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/createdObjects/$count:
    description: Provides operations to count the resources in the collection.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the number of the resource
      operationId: servicePrincipals.createdObjects.GetCount-0714
      parameters:
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      responses:
        2XX:
          $ref: '#/components/responses/ODataCountResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
  /servicePrincipals/{servicePrincipal-id}/createdObjects/graph.servicePrincipal:
    description: Casts the previous resource to servicePrincipal.
    parameters:
    - name: servicePrincipal-id
      in: path
      description: The unique identifier of servicePrincipal
      required: true
      schema:
        type: string
      x-ms-docs-key-type: servicePrincipal
    get:
      tags:
      - servicePrincipals.directoryObject
      summary: Microsoft Graph Get the items of type microsoft.graph.servicePrincipal in the microsoft.graph.directoryObject collection
      operationId: servicePrincipals.ListCreatedObjects.AsServicePrincipal
      parameters:
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      - $ref: '#/components/parameters/search'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/count'
      - name: $orderby
        in: query
        description: Order items by property values
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $select
        in: query
        description: Select properties to be returned
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      - name: $expand
        in: query
        description: Expand related entities
        style: form
        explode: false
        schema:
          uniqueItems: true
          type: array
          items:
            type: string
      responses:
        2XX:
          $ref: '#/components/responses/microsoft.graph.servicePrincipalCollectionResponse'
        4XX:
          $ref: '#/components/responses/error'
        5XX:
          $ref: '#/components/responses/error'
      x-ms-pageable:
        nextLinkName: '@odata.nextLink'
        operationName: listMore
  /servicePrincipals/{servicePrincipal-id}/createdObj

# --- truncated at 32 KB (1249 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/microsoft-graph/refs/heads/main/openapi/microsoft-graph-serviceprincipals-directoryobject-api-openapi.yml