Installation

This guide covers setting up a DataBridge server. If you just want to use an existing DataBridge server, see our Quick Start Guide instead.

Starting the Server

1. Clone the Repository

git clone https://github.com/databridge-org/databridge-core.git

2. Setup Python Environment

Python 3.12 is supported, but other versions may work:

cd databridge-core
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate

3. Install Dependencies

pip install -r requirements.txt

4. Configure Environment

Copy the example environment file and create your own .env:

cp .env.example .env

Then edit the .env file with your settings:

# MongoDB URI
MONGODB_URI=your_mongodb_connection_string

# API Keys
OPENAI_API_KEY=your_openai_key
UNSTRUCTURED_API_KEY=your_unstructured_key

# AWS Credentials
AWS_ACCESS_KEY=your_aws_access_key
AWS_SECRET_ACCESS_KEY=your_aws_secret_key

# Auth secret
JWT_SECRET_KEY=your_jwt_secret

5. Run Quick Setup

python quick_setup.py

This script will automatically:

  • Configure your MongoDB database and indexes

  • Set up your S3 bucket

  • Create the required vector index

6. Generate Local Auth Token

python generate_local_uri.py

Save the output URI - you'll need it to connect to your local server.

7. Start the Server

python start_server.py

The server will start at http://localhost:8000 by default. Visit http://localhost:8000/docs for the complete OpenAPI documentation.

Configuration Details

MongoDB Setup

  1. You need a MongoDB Atlas cluster with Vector Search enabled

  2. Create a database named as per your DATABRIDGE_DB setting

  3. The server will automatically create required collections and indexes

AWS S3 Setup

  1. Create an S3 bucket for document storage

  2. Create an IAM user with permissions for this bucket

  3. Use the access keys in your .env file

API Keys

  • OpenAI API key: Required for embeddings generation

  • Unstructured API key: Required for document parsing

Next Steps

Last updated