SharePoint/OneDrive

Connect SharePoint and OneDrive directly in MeinGPT — via Microsoft sign-in, no Azure app of your own

Set up in MeinGPT

Open Settings → Data sources, click Add data source, and choose SharePoint/OneDrive.

No separate Azure app registration is needed. MeinGPT connects through its own, already-registered multi-tenant Azure app (the same "MeinGPT Enterprise Application" used by the Microsoft 365 Connector) — you do not configure a client_id, client_secret, or refresh token manually.

Sign in with Microsoft

MeinGPT opens a popup window and redirects to login.microsoftonline.com; sign in with a work, school, or university account.

Confirm permissions

The requested scopes are Sites.Read.All, User.Read, and offline_access. If your organization requires admin consent for new applications, an administrator needs to grant it once — see Troubleshooting below.

Choose a site, or a drive and folder

Once signed in, MeinGPT shows the available SharePoint sites; select an entire site, or a specific drive and folder.

Attention

The list of available sites is based on Microsoft's search index (Microsoft Graph /sites?search=*), not a complete enumeration of every site you have access to in Microsoft 365. Team sites Microsoft hasn't yet indexed — even with correct permissions and correct search-visibility settings — may not appear in this list, even though you can access them directly in SharePoint. If a site you should be able to access is missing, use the sharepoint_site mode below, which connects the site directly by its URL.

SharePoint/OneDrive runs as a Cloud data source; it needs no Outpost of your own, and this source type is not available for on-premise Outpost deployments.

Internal configuration structure

The field table below describes the data source's internal configuration structure. As a customer you don't fill in these fields yourself — they're populated automatically when you connect through the Microsoft sign-in above.

FieldRequiredDescription
client_id–Application client ID (default: the MeinGPT Enterprise Application)
client_secret–Application client secret
refresh_token✅OAuth refresh token
drive_id✅OneDrive ID
drive_type✅Drive type (personal, business, documentLibrary)
tenant_id–Optional custom tenant
base_path–Optional folder path

Synchronization

  • MeinGPT uses the OAuth refresh token to access OneDrive/SharePoint content.
  • Sync runs pull files from the selected drive scope and ingest incrementally.
  • If tokens rotate, runtime refresh updates are applied automatically during operation.

SharePoint Site Sync (By URL)

Alongside the drive-scoped onedrive type above, there is a second SharePoint mode that syncs one specific SharePoint site, selected directly by URL rather than through the drive picker in step 3 above: sharepoint_site. This mode also works when a site doesn't show up in the sites list, since sharepoint_site resolves the site directly by URL instead of relying on Microsoft's search index.

FieldRequiredDescription
site_url✅SharePoint URL, e.g. https://company.sharepoint.com, or a specific site such as https://company.sharepoint.com/sites/sales
site_id✅Microsoft Graph site ID of the selected SharePoint site
refresh_token✅OAuth refresh token
client_id✅Azure AD application client ID
client_secret✅Azure AD application client secret
base_path–Optional folder path

MeinGPT sets this mode up together with you.

Troubleshooting

"Could not verify account" after signing in with Microsoft

This message appears when the OAuth popup does not return a valid authorization code to MeinGPT after sign-in. The most common causes:

  • Missing admin consent: If your organization doesn't let users consent to apps themselves, a Global or Application Administrator needs to grant one-time consent. The most reliable way is for that person to connect this data source, or specifically the SharePoint connector under Microsoft 365, in MeinGPT themselves and check "Consent on behalf of your organization" on the Microsoft permission screen before approving. Consent granted through a different Microsoft connector, such as Outlook or Teams, does not cover this data source's Sites.Read.All permission. Without that consent, Microsoft shows an error inside the popup ("Admin approval required," often with the code "AADSTS65001") instead of completing sign-in - if you close the popup at that point, MeinGPT treats it as a cancelled sign-in and shows "Could not verify account."
  • Popup blocked or closed early: Check that your browser allows popups for MeinGPT, and don't close the Microsoft window before it redirects back to MeinGPT.
  • Personal Microsoft account used: Only work, school, or university accounts are supported.

Do not use the "Grant admin consent" button in the Entra admin center for this. It only grants the base permissions fixed in the MeinGPT app registration and replaces the organization-wide consent, so permissions already granted, such as Sites.Read.All for this data source or the Microsoft 365 Connector permissions, disappear afterward.

Was this page helpful?