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

# Credential Setup

> Configure access to model providers and external services by adding API credentials to your environment.

> [!WARNING]
>
> **OpenAI API Key Required:** Weam AI requires OpenAI API access for core functionality including RAG processing, document analysis, and web scraping. The application will not work properly without an OpenAI API key.

## Model Providers

Add credentials for the models you want to use. **At minimum, configure one provider** to enable basic functionality.

**OpenAI is mandatory** for Weam AI to function properly. Add credentials for additional models you want to use.

> [tab] OpenAI (Required)
>
> **Get Your API Key:**
>
> 1. Visit [platform.openai.com](https://platform.openai.com)
> 2. Sign up or log in to your account
> 3. Navigate to the **API Keys** section
> 4. Create a new secret key
> 5. Copy the key (you won't see it again)
>
> **Add to Environment:**
>
> ```env theme={null}
> Weam AI_OPEN_AI_KEY=sk-your-openai-api-key-here
> OPEN_AI_MODAL=gpt-4
> OPEN_AI_API_URL=https://api.openai.com
> ```
>
> > [card] [Detailed OpenAI Setup Guide](https://opensource.weam.ai/docs/extended-reading/openai-api)
> >
> > Step-by-step OpenAI API key generation

> [tab] Anthropic (Claude)
>
> **Get Your API Key:**
>
> 1. Visit [console.anthropic.com](https://console.anthropic.com)
> 2. Sign up or log in
> 3. Go to the **API Keys** section
> 4. Create a new key
> 5. Copy and save the key securely
>
> **Add to Environment:**
>
> ```env theme={null}
> Weam AI_ANTHROPIC_API_KEY=sk-ant-your-anthropic-key-here
> ANTHROPIC_AI_API_URL=https://api.anthropic.com
> ```
>
> > [card] [Detailed Anthropic Setup Guide](https://opensource.weam.ai/docs/extended-reading/anthropic-api)
> >
> > Step-by-step Anthropic API key generation

> [tab] Google AI (Gemini)
>
> **Get Your API Key:**
>
> 1. Visit [makersuite.google.com](https://makersuite.google.com)
> 2. Sign in with a Google account
> 3. Create an API key
> 4. Copy the generated key
>
> **Add to Environment:**
>
> ```env theme={null}
> Weam AI_GEMINI_KEY=your-google-ai-api-key-here
> GEMINI_API_URL=https://generativelanguage.googleapis.com
> ```
>
> > [card] [Detailed Google AI Setup Guide](https://opensource.weam.ai/docs/extended-reading/gemini-api)
> >
> > Step-by-step Google AI API key generation

> [tab] Additional Providers
>
> ### HuggingFace
>
> **Get Token:**
>
> 1. Visit [huggingface.co](https://huggingface.co)
> 2. Go to Settings → Access Tokens
> 3. Create a new token
>
> ```env theme={null}
> HUGGING_FACE_AUTH_TOKEN=hf_your-huggingface-token-here
> ```
>
> ### OpenRouter (Multiple Models)
>
> **Get API Key:**
>
> 1. Visit [openrouter.ai](https://openrouter.ai)
> 2. Sign up and go to Keys section
> 3. Create a new API key
>
> ```env theme={null}
> Weam AI_OPEN_ROUTER_KEY=sk-or-your-openrouter-key-here
> ```
>
> ### DeepSeek
>
> ```env theme={null}
> Weam AI_DEEPSEEK_KEY=sk-your-deepseek-key-here
> ```
>
> > [card] [HuggingFace Guide](https://opensource.weam.ai/docs/extended-reading/hugging-face-api)
>
> > [card] [OpenRouter Guide](https://opensource.weam.ai/docs/extended-reading/openrouter-api)

## External Integrations (Optional)

> [tab] Slack
>
> **Setup OAuth Integration:**
>
> 1. Visit [api.slack.com/apps](https://api.slack.com/apps)
> 2. Create a new app
> 3. Configure OAuth settings
> 4. Get Client ID and Secret
>
> ```env theme={null}
> SLACK_CLIENT_ID=your-slack-client-id
> SLACK_CLIENT_SECRET=your-slack-client-secret
> NEXT_PUBLIC_SLACK_CLIENT_ID=your-slack-client-id
> NEXT_PUBLIC_SLACK_CLIENT_SECRET=your-slack-client-secret
> ```
>
> > [card] [Detailed Slack Setup](https://opensource.weam.ai/docs/connections/slack.md)
> >
> > Complete Slack integration guide

> [tab] GitHub
>
> **Setup OAuth Integration:**
>
> 1. Visit [github.com/settings/developers](https://github.com/settings/developers)
> 2. Create a new OAuth app
> 3. Configure redirect URLs
> 4. Get Client ID and Secret
>
> ```env theme={null}
> GITHUB_CLIENT_ID=your-github-client-id
> GITHUB_CLIENT_SECRET=your-github-client-secret
> GITHUB_REDIRECT_URI=https://your-domain.com/api/auth/github/callback
> ```
>
> > [card] [Detailed GitHub Setup](https://opensource.weam.ai/docs/connections/github.md)
> >
> > Complete GitHub integration guide

> [tab] Google Workspace
>
> **Setup OAuth Integration:**
>
> 1. Visit [console.cloud.google.com](https://console.cloud.google.com)
> 2. Create project and enable APIs
> 3. Configure OAuth consent screen
> 4. Create credentials
>
> ```env theme={null}
> GOOGLE_CLIENT_ID=your-google-client-id.googleusercontent.com
> GOOGLE_CLIENT_SECRET=your-google-client-secret
> ```
>
> > [card] [Detailed Google Setup](https://opensource.weam.ai/docs/connections/google/google-apps.md)
> >
> > Complete Google Workspace integration guide

## Service Configuration

### Email Service (Optional)

> [accordion] Configure SMTP for Notifications
>
> For user notifications and account management:
>
> ```env theme={null}
> EMAIL_PROVIDER=SMTP
> SMTP_SERVER=smtp.gmail.com
> SMTP_PORT=587
> SMTP_USER=your-email@domain.com
> SMTP_PASSWORD=your-app-specific-password
> SUPPORT_EMAIL=support@yourdomain.com
> ```
>
> **Gmail App Password Setup:**
>
> 1. Enable 2FA on your Google account
> 2. Go to [App Passwords](https://support.google.com/accounts/answer/185833)
> 3. Generate an app password for Weam AI
> 4. Use the generated password in `SMTP_PASSWORD`

### SEO Tools (Optional)

> [accordion] DataForSEO Integration
>
> For SEO agent functionality:
>
> ```env theme={null}
> SEO_USER_ID=your-seo-tool-email
> SEO_PASSWORD=your-seo-tool-password
> ```
>
> **Setup:**
>
> 1. Visit [DataForSEO](https://dataforseo.com/)
> 2. Create account
> 3. Go to Dashboard → API Credentials
> 4. Get your credentials

## Minimum Configuration

For basic functionality, you only need:

* **One model provider** (OpenAI recommended)
* **Database credentials** (usually auto-configured)
* **Security keys for JWT tokens** (auto-generated)

Additional providers and integrations can be added later without downtime.

## Generate Security Keys

> [accordion] Generate Required Security Keys
>
> If you need to generate security keys for JWT and encryption:
>
> **Using OpenSSL (Recommended):**
>
> ```bash theme={null}
> # Generate all required keys
> openssl rand -hex 64  # For JWT_SECRET
> openssl rand -hex 64  # For JWT_REFRESH_SECRET
> openssl rand -hex 16  # For SECURITY_KEY
> openssl rand -hex 32  # For CSRF_TOKEN_SECRET
> ```
>
> **Using Node.js:**
>
> ```bash theme={null}
> node -e "console.log('JWT_SECRET =', require('crypto').randomBytes(64).toString('hex'))"
> node -e "console.log('JWT_REFRESH_SECRET =', require('crypto').randomBytes(64).toString('hex'))"
> node -e "console.log('SECURITY_KEY =', require('crypto').randomBytes(16).toString('hex'))"
> node -e "console.log('CSRF_TOKEN_SECRET =', require('crypto').randomBytes(32).toString('hex'))"
> ```
>
> **Online Generators:**
>
> * [RandomKeyGen](https://randomkeygen.com)
> * [Random.org](https://www.random.org/strings/)

## Next Steps

> [card] [Launch & Verify](https://opensource.weam.ai/docs/setup/after-setup-complete/launch-verify.md)
>
> Start services and test your configuration


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.