mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-25 08:46:22 +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
|
||||
---
|
||||
|
||||
# Gmail Connector
|
||||
# Gmail OAuth Integration Setup Guide
|
||||
|
||||
Index your Gmail emails and make them searchable.
|
||||
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Gmail account.
|
||||
|
||||
## Prerequisites
|
||||
## Step 1: Access the Google Cloud Console
|
||||
|
||||
- A Google account
|
||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
||||
- Gmail API enabled in Google Cloud Console
|
||||
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||
2. Select an existing project or create a new one
|
||||
|
||||
## Setup
|
||||
## Step 2: Enable Required APIs
|
||||
|
||||
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
|
||||
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)
|
||||
|
||||
## What Gets Indexed
|
||||

|
||||
|
||||
- Email content
|
||||
- Email attachments
|
||||
- Thread conversations
|
||||
- Labels and categories
|
||||
## Step 3: Configure OAuth Consent Screen
|
||||
|
||||
## Sync Frequency
|
||||
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**
|
||||
|
||||
The Gmail connector supports scheduled syncing to keep your emails indexed.
|
||||

|
||||
|
||||
### 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
|
||||
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||
-e GOOGLE_GMAIL_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/gmail/connector/callback \
|
||||
--name surfsense \
|
||||
--restart unless-stopped \
|
||||
ghcr.io/modsetter/surfsense:latest
|
||||
```
|
||||
|
|
|
|||
|
|
@ -3,32 +3,80 @@ title: Google Calendar
|
|||
description: Connect your Google Calendar to SurfSense
|
||||
---
|
||||
|
||||
# Google Calendar Connector
|
||||
# Google Calendar OAuth Integration Setup Guide
|
||||
|
||||
Index your Google Calendar events and make them searchable.
|
||||
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Google Calendar.
|
||||
|
||||
## Prerequisites
|
||||
## Step 1: Access the Google Cloud Console
|
||||
|
||||
- A Google account
|
||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
||||
- Google Calendar API enabled in Google Cloud Console
|
||||
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||
2. Select an existing project or create a new one
|
||||
|
||||
## Setup
|
||||
## Step 2: Enable Required APIs
|
||||
|
||||
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
|
||||
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)
|
||||
|
||||
## What Gets Indexed
|
||||

|
||||
|
||||
- Event titles and descriptions
|
||||
- Event attendees
|
||||
- Meeting notes
|
||||
- Recurring events
|
||||
## Step 3: Configure OAuth Consent Screen
|
||||
|
||||
## Sync Frequency
|
||||
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**
|
||||
|
||||
The Google Calendar connector supports scheduled syncing to keep your events indexed.
|
||||

|
||||
|
||||
### 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
|
||||
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||
-e GOOGLE_CALENDAR_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/calendar/connector/callback \
|
||||
--name surfsense \
|
||||
--restart unless-stopped \
|
||||
ghcr.io/modsetter/surfsense:latest
|
||||
```
|
||||
|
|
|
|||
|
|
@ -3,32 +3,81 @@ title: Google Drive
|
|||
description: Connect your Google Drive to SurfSense
|
||||
---
|
||||
|
||||
# Google Drive Connector
|
||||
# Google Drive OAuth Integration Setup Guide
|
||||
|
||||
Index your Google Drive files, documents, and shared content.
|
||||
This guide walks you through setting up a Google OAuth 2.0 integration for SurfSense to connect your Google Drive.
|
||||
|
||||
## Prerequisites
|
||||
## Step 1: Access the Google Cloud Console
|
||||
|
||||
- A Google account
|
||||
- Google OAuth configured in SurfSense (see [Prerequisites](/docs))
|
||||
1. Navigate to [Google Cloud Console](https://console.cloud.google.com/)
|
||||
2. Select an existing project or create a new one
|
||||
|
||||
## Setup
|
||||
## Step 2: Enable Required APIs
|
||||
|
||||
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
|
||||
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)
|
||||
|
||||
## What Gets Indexed
|
||||

|
||||
|
||||
- Google Docs
|
||||
- Google Sheets
|
||||
- Google Slides
|
||||
- PDFs and other documents
|
||||
- Shared files
|
||||
## Step 3: Configure OAuth Consent Screen
|
||||
|
||||
## Sync Frequency
|
||||
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**
|
||||
|
||||
The Google Drive connector supports scheduled syncing to keep your content up to date.
|
||||

|
||||
|
||||
### 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
|
||||
-e GOOGLE_OAUTH_CLIENT_ID=your_google_client_id \
|
||||
-e GOOGLE_OAUTH_CLIENT_SECRET=your_google_client_secret \
|
||||
-e GOOGLE_DRIVE_REDIRECT_URI=http://localhost:8000/api/v1/auth/google/drive/connector/callback \
|
||||
--name surfsense \
|
||||
--restart unless-stopped \
|
||||
ghcr.io/modsetter/surfsense:latest
|
||||
```
|
||||
|
|
|
|||
|
|
@ -15,8 +15,6 @@ To set up Google OAuth:
|
|||
1. Login to your [Google Developer Console](https://console.cloud.google.com/)
|
||||
2. Enable the required APIs:
|
||||
- **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.
|
||||

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