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

# Development

> Learn how to start the Igbo API locally

> [!TIP]
>
> If you don't want to install local dependencies on your machine, please
> navigate to the [Start with Docker](https://docs.igboapi.com/guides/docker.md) to get started.

## Setup your development

> [!NOTE]
>
> **Prerequisite** You should have installed the following dependencies:
>
> <ul>
>   <li>[Node.js version 18.10.0 or higher](https://nodejs.org/en/download/)</li>
>   <li>[MongoDB](https://www.mongodb.com/docs/v3.0/installation/)</li>
>   <li>[Firebase](https://console.firebase.google.com/)</li>
>   <li>[Java](https://www.oracle.com/java/technologies/downloads/)</li>
>   <li>[NVM](https://github.com/nvm-sh/nvm)</li>
>
>   <li>
>     [MongoDB
>     Compass](https://docs.mongodb.com/manual/administration/install-community/)
>     (Optional)
>   </li>
> </ul>

### Step 1. Clone Igbo API repo

```bash theme={null}
git clone https://github.com/nkowaokwu/igbo_api.git
```

### Step 2. Install dev dependencies

```bash theme={null}
cd igbo_api/
npm install
```

### Step 3: Build the project

```bash theme={null}
npm run build
```

### Step 4: Run the project

```bash theme={null}
npm run dev
```

> [!TIP]
>
> The Igbo API will be running at [http://localhost:8080](http://localhost:8080)

> [!TIP]
>
> The Igbo API website will be running at
> [http://localhost:3000](http://localhost:3000)

## Enable Firebase Authentication

This project uses Firebase and requires you to create your own free Firebase project.

Please follow the [Firebase Configuration Guide here](https://github.com/nkowaokwu/igbo_api/.github/FIREBASE_CONFIG.md)

### Optional: Development with Replica Sets and Redis

> [!WARNING]
>
> Running replica sets locally is machine-intensive and should only be ran for
> testing or specific-feature development purposes.

To start the dev API server while running [MongoDB Replica sets](https://docs.mongodb.com/manual/replication/) and the [Redis cache](https://redis.io/), run:

```bash theme={null}
npm run dev:full:database
```

To start a Redis server, run:

```bash theme={null}
redis-server
```

> [!NOTE]
>
> You must have [Redis](https://github.com/redis/node-redis) installed on your
> machine in order to run the server.


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