> For the complete documentation index, see [llms.txt](https://karini-ai.gitbook.io/karini-ai-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://karini-ai.gitbook.io/karini-ai-documentation/recipes/knowledgebase-recipe/connector-credential-setup.md).

# Connector Credential Setup

This section outlines the steps required to create credentials for connectors. Follow the instructions below to generate, configure, and manage credentials for connectors.

### Sharepoint Credential Setup

**1. Register an Application in Azure Active Directory**

1. **Go to Azure Porta**l:
   * Navigate to the **Azure Portal** (<https://portal.azure.com/>).
   * **Register New Application:**
     1. In the Azure Active Directory pane, select **App registrations**.
     2. Click on **New registration** to create a new application.
     3. Provide a name for your application (e.g., "SharePointAPIApp").
     4. Set the **Supported account types** to "Accounts in this organizational directory only" (this is the default option for most cases).
     5. Optionally, you can add a **Redirect URI** (though this is not necessary for the purpose of this integration).
     6. Click **Register**.
2. &#x20;**Obtain the Tenant ID**
   * After registering your application, you'll be taken to the **Overview** page of your newly registered app.
   * Here, you'll find the **Tenant ID** listed under the **Directory** (**tenant**) **ID** section. This is the unique identifier for your Azure AD tenant.
3. **Get the Client ID**

   On the same **Overview** page, you’ll also see the **Application** (**client**) ID. This is the unique identifier for your application in Azure AD. Copy this value; it will be used as your **Client ID**.
4. **Generate the Client Secret**
   * In the left sidebar of the app's page, click on **Certificates & secrets** under **Manage**.
   * Under the **Client secrets** section, click **New client secret**.
   * Add a description (e.g., "SharePoint API Secret") and set an expiration period for the secret (choose from 1 year, 2 years, or never).
   * Click **Add** and your **Client Secret** will be generated.
   * Copy the **Client Secret** immediately, as it will not be visible again after you leave the page.
5. **Grant Permissions to Access SharePoint**

   * In the left sidebar of the application page, select **API permissions** under **Manage**.
   * Click **Add permission**.
   * Choose **Microsoft Graph**  (depending on the permissions you require).
   * Select **Delegated permissions** and **Application permission**s based on your needs (most likely, Application permissions) as shown below.
   * For accessing SharePoint data, add permissions like:

   <figure><img src="/files/XSxOGvo5hMLH3s6aYjgi" alt=""><figcaption></figcaption></figure>

   * Click **Add permissions**.
   * For some **permissions**, you will need to click on **Grant admin consent** f**or \[your organization]** to allow these permissions to take effect (this access is only for Global admin).
6. &#x20;**Use the Credentials in Your Application**

   Once you have the following credentials:

   * **Client ID:**&#x46;rom the Azure AD application registration.
   * **Client Secret**:Generated in the "Certificates & Secrets" section.
   * **Tenant ID:**&#x46;rom the Azure AD app's Overview page.

   You enter these credentials on your [organization’s ](/karini-ai-documentation/organization.md)configuration page and utilize them within your integration setup to authenticate and securely establish a connection with the SharePoint API.<br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://karini-ai.gitbook.io/karini-ai-documentation/recipes/knowledgebase-recipe/connector-credential-setup.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
