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

# SharePoint

> Give your workflows access to the SharePoint sites and files of your tenant.

The SharePoint integration lets your workflows find a site, list the files of a site, and read a file. A workflow also writes a file back to SharePoint.

This is the shortest installation of the five. It is one sign-in, and nothing else. The one decision you make is the account.

## Before you start

You need two things:

* The **admin** role in the Current workspace.
* A Microsoft account that opens every SharePoint site your workflows use.

<Warning>
  The connection stops when the account loses its access. Sign in with an account that stays, for example a service account of your organization. If you sign in with your own account and you then leave the team, every workflow that reads SharePoint stops.
</Warning>

<Note>
  SharePoint and Microsoft Teams are two separate connections, and one gives no access to the other. Both sign in to Microsoft, so the sign-in page looks the same. Connect each one that you need.
</Note>

## Install

<Steps>
  <Step title="Open the Integrations page">
    In the portal, go to **Settings** > **Integrations**.
  </Step>

  <Step title="Connect SharePoint">
    Find the **SharePoint** row. Click **Connect**.
  </Step>

  <Step title="Sign in to Microsoft">
    Sign in with the account that holds the site access. Read the permission list and give your consent.

    If your tenant asks for an approval of a new application, Microsoft sends the request to a Microsoft administrator. The connection completes after that person gives the consent.
  </Step>

  <Step title="Confirm the connection">
    The browser comes back to the **Integrations** page.

    <Check>
      The **SharePoint** row shows the green **Connected** badge.
    </Check>

    Click the chevron at the end of the row. The details give the account, the user, and the tenant ID. Confirm that the account is the one you planned to use.
  </Step>
</Steps>

## What Current asks for

| Permission            | Why Current needs it                                     |
| --------------------- | -------------------------------------------------------- |
| `offline_access`      | Keep the connection without a new sign-in each day.      |
| `User.Read`           | Read the name of the account and identify your tenant.   |
| `Sites.Read.All`      | Find the sites of your tenant.                           |
| `Files.ReadWrite.All` | Read a file, and write a file that a workflow publishes. |

The name `Sites.Read.All` looks broad, and the account limits it. Current asks for these permissions for the signed-in account only. An account that opens three sites gives a connection that sees three sites.

<Note>
  A connection from an earlier version of Current holds read-only file access, and it writes no file. The badge stays green, because such a connection still authenticates. Click **Reconnect** on the **SharePoint** row to grant the write permission. See [Repair a connection](/connect#repair-a-connection).
</Note>

## Verify the installation

Open a workflow that reads SharePoint and click **Run now**. Read the run history in the action drawer.

<Check>
  A run that lists a site confirms the connection.
</Check>

If the run reports that it finds no site, the signed-in account has no access to that site. Give the account access in SharePoint, or connect again with another account.

## Remove the integration

Go to **Settings** > **Integrations**. Click **Disconnect** on the **SharePoint** row, then confirm.

A disconnection removes the token from Current. It cancels nothing at Microsoft. To remove the access at Microsoft as well, a Microsoft administrator removes the application from the enterprise applications of your tenant.

## Questions you may have

<AccordionGroup>
  <Accordion title="Which sites does Current see?">
    The sites that the signed-in account opens. Current adds no access.

    To give Current a new site, give the account access to that site in SharePoint. The connection reads it immediately, and you connect nothing again.
  </Accordion>

  <Accordion title="Do I connect SharePoint if I already connected Microsoft Teams?">
    Yes. The two connections are separate. A Teams connection gives no file access and no site access.
  </Accordion>

  <Accordion title="Does Current change our files?">
    Current reads files. It writes a file only when one of your workflows publishes one. It deletes no file.
  </Accordion>
</AccordionGroup>
