You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/embedded/getting-started/register-api-documentation.md
+75-64Lines changed: 75 additions & 64 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,53 +1,49 @@
1
1
---
2
-
title: Register File Storage container Type Application Permissions
2
+
title: Register file storage container type application permissions
3
3
description: Register the container type.
4
-
ms.date: 03/03/2025
4
+
ms.date: 08/11/2025
5
5
ms.localizationpriority: high
6
6
---
7
7
8
8
# Register file storage container type application permissions
9
9
10
-
In order for a SharePoint Embedded application to interact with containers in a consuming tenant, the container type must first be registered in the consuming tenant. Container type registration happens when the owning application invokes the registration API to specify what permissions can be performed against its container type. The registration API also grants access to other Guest Apps to interact with the owning application's containers. For example, a SharePoint Embedded application can grant permissions to another application--a Guest App so that the Guest App can perform backup operations against its containers.
10
+
In order for a SharePoint Embedded application to interact with containers in a consuming tenant, the container type must first be registered in the consuming tenant. Container type registration happens when the owning application invokes the registration API to specify how applications can access its container type. The registration API also grants access to other Guest Apps to interact with the owning application's containers. For example, a SharePoint Embedded application can grant permissions to another application--a Guest App so that the Guest App can perform backup operations against its containers.
11
11
12
-
Since the registration API controls the permissions that a SharePoint Embedded application can perform against the container in the consuming tenant, this call should be one of the first APIs invoked. Failure to do so results in access denied errors when invoking other APIs against the container and/or the content in the containers.
12
+
Since the [container type registration API](/graph/api/filestorage-post-containertyperegistrations) controls the access to a container type in the consuming tenant, it's the first endpoint invoked by a SharePoint Embedded application on a consuming tenant. Failure to do so results in access denied errors when invoking other APIs against containers and/or content in the containers.
13
13
14
14
There are no restrictions on how many times the registration API can be invoked. How often the registration API is invoked and when it's invoked is dependent on the SharePoint Embedded application. However, the last successful call to the registration API determines the settings used in the consuming tenant.
15
15
16
16
## Authentication and authorization requirements
17
17
18
-
For the container type's owning application to act on a consuming tenant, some pre-requisites must be completed:
18
+
For the container type's owning application to act on a consuming tenant, some prerequisites must be completed:
19
19
20
20
- the owning app must have a service principal installed on the consuming tenant; and
21
21
- the owning app must be granted admin consent to perform container type registration in the consuming tenant.
22
22
23
-
> [!NOTE]
24
-
> Only the owning application of the container type can invoke the registration API in the consuming tenant.
25
-
26
-
Both requirements can be satisfied by having a tenant administrator of the consuming tenant [grant admin consent](/entra/identity/enterprise-apps/grant-admin-consent?pivots=portal) to the container type's owning application.
23
+
You can satisfy these requirements by having the consuming tenant's Global Administrator [grant admin consent](/entra/identity/enterprise-apps/grant-admin-consent?pivots=portal) to the container type's owning application.
27
24
28
-
The container type registration API requires the `Container.Selected` app-only permission for SharePoint (see [Exceptional access patterns](../development/auth.md#exceptional-access-patterns)). You will need to use the [client credentials grant flow](/entra/identity-platform/v2-oauth2-client-creds-grant-flow) and [request a token with a certificate](/entra/identity-platform/v2-oauth2-client-creds-grant-flow#second-case-access-token-request-with-a-certificate) to use the registration API.
25
+
The [container type registration API](/graph/api/filestorage-post-containertyperegistrations) requires the `FileStorageContainerTypeReg.Selected`user-delegated or app-only permission. When the owning application calls the container type registration API on behalf of a user, the user must be assigned the [SharePoint Embedded Administrator](/entra/identity/role-based-access-control/permissions-reference#sharepoint-embedded-administrator) or the [Global Administrator](/entra/identity/role-based-access-control/permissions-reference#global-administrator) roles. When the owning application calls the container type registration API without a user context, it needs to request a token using the [client credentials grant flow](/entra/identity-platform/v2-oauth2-client-creds-grant-flow).
29
26
30
27
> [!NOTE]
31
-
> The registration API is **NOT** a Microsoft Graph API but a SharePoint API. This API will be ported to Microsoft Graph in the future.
28
+
> The container type registration API is currently in preview and subject to change.
32
29
33
30
To request admin consent from a tenant administrator in the consuming tenant, you may direct them to the [admin consent endpoint](/entra/identity-platform/v2-admin-consent). For the right endpoints on national clouds, see [Microsoft identity platform endpoints on national clouds](/entra/identity-platform/authentication-national-cloud#microsoft-entra-authentication-endpoints):
You may configure the admin consent endpoint to fit your needs, including handling errors and successful grants. For more information, see [Admin consent URI](/entra/identity-platform/v2-admin-consent).
40
37
41
-
42
38
## Container type Permissions
43
39
44
40
The registration API determines what permissions a SharePoint Embedded application can perform against containers and content in containers for the specified container type.
| None | Has no permissions to any containers or content of this container type. |
49
-
| ReadContent | Can read content of containers of this container type.|
50
-
| WriteContent | Can write content to containers for this container type. This permission can't be granted without the ReadContent permission. |
45
+
| ReadContent | Can read the content of containers of this container type. |
46
+
| WriteContent | Can write content to containers for this container type. This can't be granted without the ReadContent permission. |
51
47
| Create | Can create containers of this container type. |
52
48
| Delete | Can delete containers of this container type. |
53
49
| Read | Can read the metadata of containers of this container type. |
@@ -57,53 +53,28 @@ The registration API determines what permissions a SharePoint Embedded applicati
57
53
| UpdatePermissions | Can update (change roles of) existing memberships in the container for containers of this container type. |
58
54
| DeletePermissions | Can delete other members (but not self) from the container for containers of this container type. |
59
55
| DeleteOwnPermissions | Can remove own membership from the container for containers of this container type. |
60
-
| ManagePermissions | Can add, remove (including self) or update members in the container roles for containers of this container type. |
56
+
| ManagePermissions | Can add, remove (including self), or update members in the container roles for containers of this container type. |
57
+
| ManageContent | Can manage the content of the container |
61
58
| Full | Has all permissions for containers of this container type. |
62
59
63
-
## HTTP request
64
-
65
-
```http
66
-
PUT {RootSiteUrl}/_api/v2.1/storageContainerTypes/{containerTypeId}/applicationPermissions
67
-
```
68
-
69
-
> [!NOTE]
70
-
> This is NOT a Graph API
71
-
>
72
-
> `{RootSiteURL}` is the SharePoint URL of the consuming tenant. For example, https://contoso.sharepoint.com.
73
-
74
-
### Request body
75
-
76
-
In the request body, supply a JSON representation of the container type permissions for the SharePoint Embedded applications.
77
-
78
-
### Response
79
-
80
-
If successful, this method returns a `200 OK` response code and the container type permissions configured for the SharePoint Embedded applications in the response body.
| 403 | Provided authentication credentials are valid but insufficient to perform the requested operation. Examples: the calling app isn't the owning app of the container type. |
87
-
| 404 | Container type doesn't exist. |
88
-
89
60
## Examples
90
61
91
62
### Register the container type in a consuming tenant with permissions only for the Owning App
92
63
93
-
Register the container type in the consuming tenant and grant full permissions to the Owning Application (AppId 71392b2f-1765-406e-86af-5907d9bdb2ab) for Delegated and AppOnly calls.
64
+
Register the container type `de988700-d700-020e-0a00-0831f3042f00`in the consuming tenant and grant `full` permissions to the owning application `71392b2f-1765-406e-86af-5907d9bdb2ab` for delegated and app-only calls.
94
65
95
66
#### Request
96
67
97
-
```json
98
-
PUT {RootSiteUrl}/_api/v2.1/storageContainerTypes/{containerTypeId}/applicationPermissions
68
+
```http
69
+
PUT https://graph.microsoft.com/beta/storage/fileStorage/containerTypeRegistrations/de988700-d700-020e-0a00-0831f3042f00
### Register the container type in a consuming tenant with permissions for a Guest App
130
121
131
-
Register the container type in the consuming tenant and grant full permissions to the Owning Application (AppId 71392b2f-1765-406e-86af-5907d9bdb2ab) for Delegated and AppOnly calls. In addition, grant a Guest App (AppId 89ea5c94-7736-4e25-95ad-3fa95f62b6) read and write permissions only for Delegated calls.
122
+
Register the container type `de988700-d700-020e-0a00-0831f3042f00`in the consuming tenant and grant full permissions to the owning application `71392b2f-1765-406e-86af-5907d9bdb2ab` for delegated and app-only calls. In addition, grant a guest app `89ea5c94-7736-4e25-95ad-3fa95f62b6` both `read` and `write` permissions only for delegated calls.
132
123
133
124
#### Request
134
125
135
-
```json
136
-
PUT /storagecontainerTypes/{containerTypeId}/applicationPermissions
126
+
```http
127
+
PUT https://graph.microsoft.com/beta/storage/fileStorage/containerTypeRegistrations/de988700-d700-020e-0a00-0831f3042f00
0 commit comments