Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
710:cms_sharepoint_online_new [2024/04/15 08:20] – [API Permissions] Policnik, Florian | 710:cms_sharepoint_online_new [2024/07/17 07:54] (current) – removed Policnik, Florian | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | [[: | ||
- | ====== !!! DRAFT !!! ====== | ||
- | ====== Sharepoint Online ====== | ||
- | |||
- | You are able to connect Stages with SharePoint Online. A typical URL to SharePoint Online looks like '' | ||
- | |||
- | ===== Example Configuration ===== | ||
- | |||
- | <code xml> | ||
- | < | ||
- | <!-- Global Properties --> | ||
- | < | ||
- | <!-- Host Properties --> | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | </ | ||
- | |||
- | |||
- | </ | ||
- | |||
- | ===== Host Properties ===== | ||
- | |||
- | These configuration properties affect the behavior of one SharePoint Online server. | ||
- | |||
- | *** ** '' | ||
- | Properties marked with ** * ** are required for the adapter to work. | ||
- | |||
- | **# ** '' | ||
- | Properties marked with ** # ** are required but can also be set in the //File Management// | ||
- | |||
- | '' | ||
- | Properties marked with are required, but there is a default value. This values can be overridden by configuring it in the config.xml. | ||
- | |||
- | > client.id ** * ** | ||
- | |||
- | * Description: | ||
- | * Links: [[https:// | ||
- | |||
- | > client.secret ** * ** | ||
- | |||
- | * Description: | ||
- | * Links: [[https:// | ||
- | |||
- | > tenant.id ** * ** | ||
- | |||
- | * Description: | ||
- | * Links: [[https:// | ||
- | |||
- | > loginserver | ||
- | |||
- | * Default Value: < | ||
- | * Description: | ||
- | * Links: [[https:// | ||
- | |||
- | > state.attribute.name | ||
- | |||
- | * Description: | ||
- | |||
- | > document.content.type.name | ||
- | |||
- | * Default Value: Document | ||
- | * Description: | ||
- | * Since Stages 7.5.6.2, 7.6.2.4 and 7.7.0.0 it is possible to define multiple content types. Separate them with a #. For example: | ||
- | <code xml> | ||
- | < | ||
- | </ | ||
- | |||
- | > link.content.type.name | ||
- | |||
- | * Default Value: Link to a document | ||
- | * Description: | ||
- | * Known Issue: Typo in Default Value. Has to be Link to a **D**ocument | ||
- | * Since Stages 7.5.6.2, 7.6.2.4 and 7.7.0.0 it is possible to define multiple link types. Separate them with a #. For example: | ||
- | <code xml> | ||
- | < | ||
- | </ | ||
- | |||
- | > use.system.account.for.download | ||
- | |||
- | * Default Value: false | ||
- | * Description: | ||
- | |||
- | > sites.selected.scope (since Stages XXX) | ||
- | |||
- | * Default Value: false | ||
- | * Description: | ||
- | |||
- | ===== Azure Portal ===== | ||
- | |||
- | The integration uses [[https:// | ||
- | |||
- | ==== Authentication ==== | ||
- | |||
- | Every application registered at the Microsoft azure portal can register **Redirect URIs** | ||
- | |||
- | [[https:// | ||
- | |||
- | For the authentication process to work, you have to add the following redirect for **Web** | ||
- | |||
- | https://< | ||
- | |||
- | </ | ||
- | |||
- | * Microsoft only accepts __https__ | ||
- | * Stages-hostname: | ||
- | |||
- | === Example === | ||
- | |||
- | If the link to your Stages looks like this | ||
- | |||
- | < | ||
- | https:// | ||
- | |||
- | </ | ||
- | |||
- | then your redirect URI is | ||
- | |||
- | < | ||
- | https:// | ||
- | |||
- | </ | ||
- | |||
- | |||
- | ==== API Permissions ==== | ||
- | |||
- | In addition to the Redirect URIs, the application needs [[https:// | ||
- | |||
- | === Default option: delegated permission Sites.ReadWrite.All === | ||
- | |||
- | On this option Stages act in behalf of the user. The permissions are all of the type [[https:// | ||
- | |||
- | * offline_access (Microsoft Graph, type delegated) | ||
- | * User.Read (Microsoft Graph, type delegated) | ||
- | * Sites.ReadWrite.All (Microsoft Graph, type delegated) | ||
- | |||
- | In some cases an **admin consent is required**. This can be done by a Global Administrator, | ||
- | |||
- | The picture below shows, how this should look like: | ||
- | |||
- | [[https:// | ||
- | |||
- | |||
- | === Recommended option: application and delegated permission Sites.Selected (Since Stages XXX) === | ||
- | |||
- | To active this option the setting '' | ||
- | |||
- | <code xml> | ||
- | < | ||
- | </ | ||
- | |||
- | On this option Stages acts with Azure [[https:// | ||
- | |||
- | * offline_access (Microsoft Graph, type delegated) | ||
- | * User.Read (Microsoft Graph, type delegated) | ||
- | * Sites.Selected (Microsoft Graph, type delegated) | ||
- | * Sites.Selected (Microsoft Graph, type application) | ||
- | |||
- | For this option an **admin consent is required**. This can be done by a Global Administrator, | ||
- | |||
- | In addition for the '' | ||
- | |||
- | == PowerShell == | ||
- | |||
- | Please refer [[https:// | ||
- | |||
- | <code powershell> | ||
- | Grant-PnPAzureADAppSitePermission -AppId " | ||
- | </ | ||
- | |||
- | |||
- | == GraphAPI == | ||
- | |||
- | Please refer [[https:// | ||
- | |||
- | First the ID of the SharePoint site have to be found out. | ||
- | |||
- | |||
- | |||
- | |||
- | * Method: '' | ||
- | * URL: ''< | ||
- | * In the URL replace '' | ||
- | * e.g.: ''< | ||
- | * Payload / body: | ||
- | |||
- | <code javascript> | ||
- | { | ||
- | " | ||
- | " | ||
- | ], | ||
- | " | ||
- | { | ||
- | " | ||
- | " | ||
- | " | ||
- | } | ||
- | } | ||
- | ] | ||
- | } | ||
- | </ | ||
- | |||
- | |||
- | ==== Certificates & secrets ==== | ||
- | |||
- | It is required to generate a client secret for Stages. It's recommended to choose expire never or a long duration. If the secret expires it must be changed in Stages and all users have to re-authenticate. | ||
- | |||
- | |||
- | [[https:// | ||
- | |||
- | ===== Repository Configuration ===== | ||
- | |||
- | Access to SharePoint Online projects can be configured in Stages processes via “Management > File Management > Repositories”. [[https:// | ||
- | |||
- | If you go to the document library with your browser you will get a URL like this. We will use it in this example.< | ||
- | |||
- | https:// | ||
- | |||
- | </ | ||
- | |||
- | > Name: The name of this SharePoint Online configuration. This name will be used by Stages to refer to this repository configuration (e.g. in repository plan) | ||
- | |||
- | > Host: This selection field contains an entry for each cms-host section in the Stages configuration file (config.xml). You can select the host for this repository configuration. | ||
- | |||
- | > Site: Define a site parameter for this repository configuration. The site is the path to the location, where your document libraries are located on the SharePoint server. The site is one piece for the complete connection string to the SharePoint server. | ||
- | |||
- | This overwrites the **path** | ||
- | |||
- | Example: | ||
- | |||
- | * **config.xml**: | ||
- | * Value in **Site**: // | ||
- | * Resulting **URL**: //< | ||
- | * The path from the config.xml gets overwritten by the value from Repository Path. | ||
- | |||
- | > Document Library: Defines the name of the document library. The document library is one piece for the complete connection string to the SharePoint server. If your document library contains a space it must be replaced by **%20** | ||
- | |||
- | > Root Folder: Defines a root folder **inside** | ||
- | |||
- | > Default Lifecycle Select a lifecycle from the process metamodel as default for files from this repository. | ||
- | |||
- | ===== Known Limitations ===== | ||
- | |||
- | ==== Behavior of Lock/Unlock ==== | ||
- | |||
- | Currently, the graph API only supports checkin/ | ||
- | |||
- | ==== Initial commit ==== | ||
- | |||
- | Creates two versions (one for the creation of a new file/ second for updating the properties) | ||
- | |||
- | ==== Set State ==== | ||
- | |||
- | After setting the state of a Sharepoint Online document, the assignment to the Stages user gets lost. The modifier will be the Sharepoint Online user instead of the Stages user. | ||
- | |||
- | ==== Major / Minor Version ==== | ||
- | |||
- | The Graph API, wich is used by the SharePoint Online Adapter, does currently not support setting major/minor versions when uploading a file. | ||
- | |||
- | ==== Action before authentication ==== | ||
- | |||
- | If the current user is not authenticated yet and performs an action, the authentication dialog will be opened. After the authentication the user has to performs the action again. | ||
- | |||
- | |||
- | ===== Troubleshooting ===== | ||
- | |||
- | ==== Error AADSTS50011: | ||
- | |||
- | Check the Redirect URI in Azure Portal | ||
- | |||
- | ==== Unknown certificates ==== | ||
- | |||
- | At the moment this public CAs are required: | ||
- | |||
- | * DigiCert Global Root CA | ||
- | * valid until 10 Nov 2031 00:00:00 GMT | ||
- | * SHA1: A8: | ||
- | * SHA256: 43: | ||
- | * DigiCert Assured ID Root G2 | ||
- | * Valid unitl: 15 Jan 2038 12:00:00 GMT | ||
- | * SHA1: A1: | ||
- | * SHA256: 7D: | ||
- | * Microsoft RSA Root Certificate Authority 2017 | ||
- | * Valid until Fri, 18 Jul 2042 23:00:23 GMT | ||
- | * SHA1: 73: | ||
- | * DigiCert Global Root G2 | ||
- | * Valid until Fri, 15 Jan 2038 12:00:00 GMT | ||
- | * SHA1: DF: | ||
- | * SHA256: CB: | ||
- | |||
- | |||
- | [[https:// | ||
- | |||
- | [[https:// |