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

# 3.3 Run Locally

Run these commands from the existing repository. The backend directory is `backend/`, and its Python package retains the `refundflow` name.

## 1. Set up the backend

```bash theme={null}
cd backend
python3.11 -m venv .venv
source .venv/bin/activate
python -m pip install --pre -e '.[dev]'
cp .env.example .env
uvicorn api.main:app --reload --port 8000
```

Use a separate terminal to check `http://localhost:8000/health/live`, `/health/ready`, `/docs`, and `/openapi.json`. The API can start without cloud credentials, but claim processing needs the services configured in `backend/.env`.

## 2. Start Durable Functions when testing workflow processing

Configure `backend/local.settings.json` from `backend/local.settings.example.json`. From `backend/`, run:

```bash theme={null}
func start --port 7071
```

## 3. Run the frontend

In another terminal:

```bash theme={null}
cd frontend
pnpm install --frozen-lockfile
pnpm dev
```

Open `http://localhost:3000`. Follow the frontend README for the required `NEXT_PUBLIC_` Microsoft Entra settings. The frontend is still under active development, so some full workflow screens may not be available.

In `APP_ENV=local`, a request without a bearer token receives a synthetic identity with Customer, Reviewer, and Admin roles. Do not use local mode in a deployed environment. Keep `.env` and `local.settings.json` out of version control.


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