mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-26 17:26:23 +02:00
feat: added google based connectors docs
This commit is contained in:
parent
761fa9162b
commit
1b4ec2daa7
4 changed files with 203 additions and 59 deletions
|
|
@ -3,32 +3,81 @@ title: Gmail
|
||||||
description: Connect your Gmail to SurfSense
|
description: Connect your Gmail to SurfSense
|
||||||
---
|
---
|
||||||
|
|
||||||
|
# Gmail OAuth Integration Setup Guide
|
||||||
|
|
||||||
|
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Gmail account.
|
||||||
|
|
||||||
|
## Step 1: Access the Google Cloud Console
|
||||||
|
|
||||||
|
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||||
|
2. Select an existing project or create a new one
|
||||||
|
|
||||||
|
## Step 2: Enable Required APIs
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Library**
|
||||||
|
2. Search for and enable the following APIs:
|
||||||
|
- **People API** (required for Google OAuth)
|
||||||
|
- **Gmail API** (required for Gmail connector)
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 3: Configure OAuth Consent Screen
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **OAuth consent screen**
|
||||||
|
2. Select **External** user type (or Internal if using Google Workspace)
|
||||||
|
3. Fill in the required information:
|
||||||
|
- **App name**: `SurfSense`
|
||||||
|
- **User support email**: Your email address
|
||||||
|
- **Developer contact information**: Your email address
|
||||||
|
4. Click **Save and Continue**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Add Scopes
|
||||||
|
|
||||||
|
1. Click **Add or Remove Scopes**
|
||||||
|
2. Add the following scopes:
|
||||||
|
- `https://www.googleapis.com/auth/gmail.readonly` - Read Gmail messages
|
||||||
|
- `https://www.googleapis.com/auth/userinfo.email` - View user email address
|
||||||
|
3. Click **Update** and then **Save and Continue**
|
||||||
|
|
||||||
|
## Step 4: Create OAuth Client ID
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Credentials**
|
||||||
|
2. Click **Create Credentials** > **OAuth client ID**
|
||||||
|
3. Select **Web application** as the application type
|
||||||
|
4. Enter **Name**: `SurfSense`
|
||||||
|
5. Under **Authorized redirect URIs**, add:
|
||||||
|
```
|
||||||
|
http://localhost:8000/api/v1/auth/google/gmail/connector/callback
|
||||||
|
```
|
||||||
|
6. Click **Create**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 5: Get OAuth Credentials
|
||||||
|
|
||||||
|
1. After creating the OAuth client, you'll see a dialog with your credentials
|
||||||
|
2. Copy your **Client ID** and **Client Secret**
|
||||||
|
|
||||||
|
> ⚠️ Never share your client secret publicly or include it in code repositories.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Running SurfSense with Gmail Connector
|
||||||
|
|
||||||
|
Add the Google OAuth environment variables to your Docker run command:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker run -d -p 3000:3000 -p 8000:8000 \
|
||||||
|
-v surfsense-data:/data \
|
||||||
# Gmail Connector
|
# Gmail Connector
|
||||||
|
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||||
Index your Gmail emails and make them searchable.
|
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||||
|
-e GOOGLE_GMAIL_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/gmail/connector/callback \
|
||||||
## Prerequisites
|
--name surfsense \
|
||||||
|
--restart unless-stopped \
|
||||||
- A Google account
|
ghcr.io/modsetter/surfsense:latest
|
||||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
```
|
||||||
- Gmail API enabled in Google Cloud Console
|
|
||||||
|
|
||||||
## Setup
|
|
||||||
|
|
||||||
1. Navigate to your Search Space settings
|
|
||||||
2. Click on **Add Connector**
|
|
||||||
3. Select **Gmail** from the list
|
|
||||||
4. Authorize SurfSense to access your Gmail
|
|
||||||
5. Configure which labels/folders to index
|
|
||||||
|
|
||||||
## What Gets Indexed
|
|
||||||
|
|
||||||
- Email content
|
|
||||||
- Email attachments
|
|
||||||
- Thread conversations
|
|
||||||
- Labels and categories
|
|
||||||
|
|
||||||
## Sync Frequency
|
|
||||||
|
|
||||||
The Gmail connector supports scheduled syncing to keep your emails indexed.
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,32 +3,80 @@ title: Google Calendar
|
||||||
description: Connect your Google Calendar to SurfSense
|
description: Connect your Google Calendar to SurfSense
|
||||||
---
|
---
|
||||||
|
|
||||||
|
# Google Calendar OAuth Integration Setup Guide
|
||||||
|
|
||||||
|
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Google Calendar.
|
||||||
|
|
||||||
|
## Step 1: Access the Google Cloud Console
|
||||||
|
|
||||||
|
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||||
|
2. Select an existing project or create a new one
|
||||||
|
|
||||||
|
## Step 2: Enable Required APIs
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Library**
|
||||||
|
2. Search for and enable the following APIs:
|
||||||
|
- **People API** (required for Google OAuth)
|
||||||
|
- **Google Calendar API** (required for Calendar connector)
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 3: Configure OAuth Consent Screen
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **OAuth consent screen**
|
||||||
|
2. Select **External** user type (or Internal if using Google Workspace)
|
||||||
|
3. Fill in the required information:
|
||||||
|
- **App name**: `SurfSense`
|
||||||
|
- **User support email**: Your email address
|
||||||
|
- **Developer contact information**: Your email address
|
||||||
|
4. Click **Save and Continue**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Add Scopes
|
||||||
|
|
||||||
|
1. Click **Add or Remove Scopes**
|
||||||
|
2. Add the following scope:
|
||||||
|
- `https://www.googleapis.com/auth/calendar.readonly` - Read Google Calendar events
|
||||||
|
3. Click **Update** and then **Save and Continue**
|
||||||
|
|
||||||
|
## Step 4: Create OAuth Client ID
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Credentials**
|
||||||
|
2. Click **Create Credentials** > **OAuth client ID**
|
||||||
|
3. Select **Web application** as the application type
|
||||||
|
4. Enter **Name**: `SurfSense`
|
||||||
|
5. Under **Authorized redirect URIs**, add:
|
||||||
|
```
|
||||||
|
http://localhost:8000/api/v1/auth/google/calendar/connector/callback
|
||||||
|
```
|
||||||
|
6. Click **Create**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 5: Get OAuth Credentials
|
||||||
|
|
||||||
|
1. After creating the OAuth client, you'll see a dialog with your credentials
|
||||||
|
2. Copy your **Client ID** and **Client Secret**
|
||||||
|
|
||||||
|
> ⚠️ Never share your client secret publicly or include it in code repositories.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Running SurfSense with Google Calendar Connector
|
||||||
|
|
||||||
|
Add the Google OAuth environment variables to your Docker run command:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker run -d -p 3000:3000 -p 8000:8000 \
|
||||||
|
-v surfsense-data:/data \
|
||||||
# Google Calendar Connector
|
# Google Calendar Connector
|
||||||
|
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||||
Index your Google Calendar events and make them searchable.
|
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||||
|
-e GOOGLE_CALENDAR_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/calendar/connector/callback \
|
||||||
## Prerequisites
|
--name surfsense \
|
||||||
|
--restart unless-stopped \
|
||||||
- A Google account
|
ghcr.io/modsetter/surfsense:latest
|
||||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
```
|
||||||
- Google Calendar API enabled in Google Cloud Console
|
|
||||||
|
|
||||||
## Setup
|
|
||||||
|
|
||||||
1. Navigate to your Search Space settings
|
|
||||||
2. Click on **Add Connector**
|
|
||||||
3. Select **Google Calendar** from the list
|
|
||||||
4. Authorize SurfSense to access your Google Calendar
|
|
||||||
5. Select which calendars to index
|
|
||||||
|
|
||||||
## What Gets Indexed
|
|
||||||
|
|
||||||
- Event titles and descriptions
|
|
||||||
- Event attendees
|
|
||||||
- Meeting notes
|
|
||||||
- Recurring events
|
|
||||||
|
|
||||||
## Sync Frequency
|
|
||||||
|
|
||||||
The Google Calendar connector supports scheduled syncing to keep your events indexed.
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,32 +3,81 @@ title: Google Drive
|
||||||
description: Connect your Google Drive to SurfSense
|
description: Connect your Google Drive to SurfSense
|
||||||
---
|
---
|
||||||
|
|
||||||
|
# Google Drive OAuth Integration Setup Guide
|
||||||
|
|
||||||
|
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Google Drive.
|
||||||
|
|
||||||
|
## Step 1: Access the Google Cloud Console
|
||||||
|
|
||||||
|
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||||
|
2. Select an existing project or create a new one
|
||||||
|
|
||||||
|
## Step 2: Enable Required APIs
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Library**
|
||||||
|
2. Search for and enable the following APIs:
|
||||||
|
- **People API** (required for Google OAuth)
|
||||||
|
- **Google Drive API** (required for Drive connector)
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 3: Configure OAuth Consent Screen
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **OAuth consent screen**
|
||||||
|
2. Select **External** user type (or Internal if using Google Workspace)
|
||||||
|
3. Fill in the required information:
|
||||||
|
- **App name**: `SurfSense`
|
||||||
|
- **User support email**: Your email address
|
||||||
|
- **Developer contact information**: Your email address
|
||||||
|
4. Click **Save and Continue**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Add Scopes
|
||||||
|
|
||||||
|
1. Click **Add or Remove Scopes**
|
||||||
|
2. Add the following scopes:
|
||||||
|
- `https://www.googleapis.com/auth/drive.readonly` - Read-only access to Google Drive
|
||||||
|
- `https://www.googleapis.com/auth/userinfo.email` - View user email address
|
||||||
|
3. Click **Update** and then **Save and Continue**
|
||||||
|
|
||||||
|
## Step 4: Create OAuth Client ID
|
||||||
|
|
||||||
|
1. Go to **APIs & Services** > **Credentials**
|
||||||
|
2. Click **Create Credentials** > **OAuth client ID**
|
||||||
|
3. Select **Web application** as the application type
|
||||||
|
4. Enter **Name**: `SurfSense`
|
||||||
|
5. Under **Authorized redirect URIs**, add:
|
||||||
|
```
|
||||||
|
http://localhost:8000/api/v1/auth/google/drive/connector/callback
|
||||||
|
```
|
||||||
|
6. Click **Create**
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
## Step 5: Get OAuth Credentials
|
||||||
|
|
||||||
|
1. After creating the OAuth client, you'll see a dialog with your credentials
|
||||||
|
2. Copy your **Client ID** and **Client Secret**
|
||||||
|
|
||||||
|
> ⚠️ Never share your client secret publicly or include it in code repositories.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Running SurfSense with Google Drive Connector
|
||||||
|
|
||||||
|
Add the Google OAuth environment variables to your Docker run command:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker run -d -p 3000:3000 -p 8000:8000 \
|
||||||
|
-v surfsense-data:/data \
|
||||||
# Google Drive Connector
|
# Google Drive Connector
|
||||||
|
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||||
Index your Google Drive files, documents, and shared content.
|
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||||
|
-e GOOGLE_DRIVE_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/drive/connector/callback \
|
||||||
## Prerequisites
|
--name surfsense \
|
||||||
|
--restart unless-stopped \
|
||||||
- A Google account
|
ghcr.io/modsetter/surfsense:latest
|
||||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
```
|
||||||
|
|
||||||
## Setup
|
|
||||||
|
|
||||||
1. Navigate to your Search Space settings
|
|
||||||
2. Click on **Add Connector**
|
|
||||||
3. Select **Google Drive** from the list
|
|
||||||
4. Authorize SurfSense to access your Google Drive
|
|
||||||
5. Select the folders you want to index
|
|
||||||
|
|
||||||
## What Gets Indexed
|
|
||||||
|
|
||||||
- Google Docs
|
|
||||||
- Google Sheets
|
|
||||||
- Google Slides
|
|
||||||
- PDFs and other documents
|
|
||||||
- Shared files
|
|
||||||
|
|
||||||
## Sync Frequency
|
|
||||||
|
|
||||||
The Google Drive connector supports scheduled syncing to keep your content up to date.
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,8 +15,6 @@ To set up Google OAuth:
|
||||||
1. Login to your [Google Developer Console](https://console.cloud.google.com/)
|
1. Login to your [Google Developer Console](https://console.cloud.google.com/)
|
||||||
2. Enable the required APIs:
|
2. Enable the required APIs:
|
||||||
- **People API** (required for basic Google OAuth)
|
- **People API** (required for basic Google OAuth)
|
||||||
- **Gmail API** (required if you want to use the Gmail connector)
|
|
||||||
- **Google Calendar API** (required if you want to use the Google Calendar connector)
|
|
||||||

|

|
||||||
3. Set up OAuth consent screen.
|
3. Set up OAuth consent screen.
|
||||||

|

|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue