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

# Setup

> Connect to your Capsule CRM app for OAuth.

To setup your Capsule app in Refold for OAuth, you will need the following credentials from your [Capsule Developer account](https://developer.capsulecrm.com/clients):

* Client ID
* Client Secret
* Scopes

### Pre-requisites

1. Capsule Developer account. You can create one through GitHub [here](https://developer.capsulecrm.com).

### Required Settings

* **Mandatory Scopes**

1. read write

<Info>If you haven't already created an app in Capsule CRM, you'd need to create one.</Info>

### Creating an app in Capsule

To create a Capsule app and acquire the above mentioned credentials, please follow the steps mentioned below:

1. Log in to your [Capsule Developer account](https://developer.capsulecrm.com/clients).
2. Click on the `New Application` button in `Your Apps` section.
3. Go to your [`Apps catalog`](https://app.gocobalt.io/apps) in **Refold** > Search for `Capsule CRM` > `Settings` > `Use your credentials` > `Callback Url` > Copy it.
4. Enter the App **Name** and **Description** > Paste the Callback Url under **Redirect URL** > Provide a **Contact Email** > Choose `Web Application` as **Application Type** and click on `Save`.

<img height="200" src="https://mintcdn.com/cobalt-55/YZVVpdFwo8NtLV-a/images/Capsule/capsule_navigation.png?fit=max&auto=format&n=YZVVpdFwo8NtLV-a&q=85&s=881015e8b2045dfcfc4619837cd0b668" alt="Capsule CRM App setup" data-path="images/Capsule/capsule_navigation.png" />

5. Copy the **Client ID** and **Client Secret** displayed in the App.

<img height="200" src="https://mintcdn.com/cobalt-55/YZVVpdFwo8NtLV-a/images/Capsule/capsule_credentials.png?fit=max&auto=format&n=YZVVpdFwo8NtLV-a&q=85&s=40adeaad648d4c9a2b121aeb262171b4" alt="Getting Credentials" data-path="images/Capsule/capsule_credentials.png" />

#### Configuring credentials in Refold

App settings page lets you configure the authentication settings for an `OAuth 2.0` based application. For your customers to provide you authorization to access their data,
they would first need to install your application. This page lets you set up your application credentials.

<img height="200" src="https://mintcdn.com/cobalt-55/YZVVpdFwo8NtLV-a/images/Capsule/capsule_cobalt.png?fit=max&auto=format&n=YZVVpdFwo8NtLV-a&q=85&s=17209e8927bcc0b94051842aa816b2d6" alt="Setting up application client credentials" data-path="images/Capsule/capsule_cobalt.png" />

Provide the acquired Client ID and Client Secret under Settings of the app and save it.

#### Actions and triggers

Once the above setup is completed, you can create orchestrations of your use-cases using Capsule CRM actions and triggers. Following are the set of Capsule CRM actions and triggers
supported by Refold.

<Tabs>
  <Tab title="Actions">
    <AccordionGroup>
      <Accordion title="Entry">
        1. **Create Entry** - Create a new entry in Capsule CRM.
        2. **Update Entry** - Update an entry in Capsule CRM.
        3. **Delete Entry** - Delete an entry in Capsule CRM.
      </Accordion>

      <Accordion title="Opportunity">
        4. **Create Opportunity** - Create a new opportunity in Capsule CRM.
        5. **Update Opportunity** - Update an opportunity in Capsule CRM.
        6. **Delete Opportunity** - Delete an opportunity in Capsule CRM.
      </Accordion>

      <Accordion title="Party">
        7. **Create Party** - Create a new party in Capsule CRM.
        8. **Update Party** - Update a party in Capsule CRM.
        9. **Delete Party** - Delete a party in Capsule CRM.
      </Accordion>

      <Accordion title="Project">
        10. **Create Project** - Create a new project in Capsule CRM.
        11. **Update Project** - Update a project in Capsule CRM.
        12. **Delete Project** - Delete a project in Capsule CRM.
      </Accordion>

      <Accordion title="Organization">
        13. **Create Task** - Create a new taskn in Capsule CRM.
        14. **Update Task** - Update a task in Capsule CRM.
        15. **Delete Task** - Delete a task in Capsule CRM.
      </Accordion>

      <Accordion title="Others">
        16. **HTTP Request** - Make HTTP API calls to any Capsule CRM documented REST APIs.
      </Accordion>
    </AccordionGroup>
  </Tab>

  <Tab title="Triggers">
    There are no triggers in this application.
  </Tab>
</Tabs>
