> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pinkfish.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# microsoft-active-directory-service-principals

> Active Directory Service Principals — manage enterprise applications, app role assignments, and OAuth permission grants

**Server path:** `/microsoft-active-directory-service-principals` | **Type:** Application | **PCID required:** Yes

## Tools

| Tool                                                                                                                                                                | Description                                              |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------- |
| [`microsoft_active_directory_service_principals_get_principal`](#microsoft_active_directory_service_principals_get_principal)                                       | Get a service principal by ID                            |
| [`microsoft_active_directory_service_principals_list_service_principals`](#microsoft_active_directory_service_principals_list_service_principals)                   | List service principals                                  |
| [`microsoft_active_directory_service_principals_list_sp_app_role_assigned_to`](#microsoft_active_directory_service_principals_list_sp_app_role_assigned_to)         | List app role assignments granted on a service principal |
| [`microsoft_active_directory_service_principals_list_sp_app_role_assignments`](#microsoft_active_directory_service_principals_list_sp_app_role_assignments)         | List app role assignments granted to a service principal |
| [`microsoft_active_directory_service_principals_list_sp_oauth2_permission_grants`](#microsoft_active_directory_service_principals_list_sp_oauth2_permission_grants) | List delegated permission grants for a service principal |

***

## microsoft\_active\_directory\_service\_principals\_get\_principal

Get a service principal by ID

**Parameters:**

| Parameter | Type   | Required | Default | Description                                  |
| --------- | ------ | -------- | ------- | -------------------------------------------- |
| `sp_id`   | string | Yes      | —       | Service principal ID (GUID)                  |
| `$select` | string | No       | —       | Comma-separated list of properties to return |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "sp_id": {
        "type": "string",
        "description": "Service principal ID (GUID)"
      },
      "$select": {
        "type": "string",
        "description": "Comma-separated list of properties to return"
      }
    },
    "required": [
      "PCID",
      "sp_id"
    ]
  }
  ```
</Expandable>

***

## microsoft\_active\_directory\_service\_principals\_list\_service\_principals

List service principals

**Parameters:**

| Parameter | Type    | Required | Default | Description                                  |
| --------- | ------- | -------- | ------- | -------------------------------------------- |
| `$filter` | string  | No       | —       | OData filter expression                      |
| `$select` | string  | No       | —       | Comma-separated list of properties to return |
| `$top`    | integer | No       | —       | Number of results to return                  |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "$filter": {
        "type": "string",
        "description": "OData filter expression"
      },
      "$select": {
        "type": "string",
        "description": "Comma-separated list of properties to return"
      },
      "$top": {
        "type": "integer",
        "description": "Number of results to return"
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## microsoft\_active\_directory\_service\_principals\_list\_sp\_app\_role\_assigned\_to

List app role assignments granted on a service principal

**Parameters:**

| Parameter | Type   | Required | Default | Description |
| --------- | ------ | -------- | ------- | ----------- |
| `sp_id`   | string | Yes      | —       | Sp Id       |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "sp_id": {
        "type": "string",
        "description": "Sp Id"
      }
    },
    "required": [
      "PCID",
      "sp_id"
    ]
  }
  ```
</Expandable>

***

## microsoft\_active\_directory\_service\_principals\_list\_sp\_app\_role\_assignments

List app role assignments granted to a service principal

**Parameters:**

| Parameter | Type   | Required | Default | Description |
| --------- | ------ | -------- | ------- | ----------- |
| `sp_id`   | string | Yes      | —       | Sp Id       |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "sp_id": {
        "type": "string",
        "description": "Sp Id"
      }
    },
    "required": [
      "PCID",
      "sp_id"
    ]
  }
  ```
</Expandable>

***

## microsoft\_active\_directory\_service\_principals\_list\_sp\_oauth2\_permission\_grants

List delegated permission grants for a service principal

**Parameters:**

| Parameter | Type   | Required | Default | Description |
| --------- | ------ | -------- | ------- | ----------- |
| `sp_id`   | string | Yes      | —       | Sp Id       |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "sp_id": {
        "type": "string",
        "description": "Sp Id"
      }
    },
    "required": [
      "PCID",
      "sp_id"
    ]
  }
  ```
</Expandable>
