-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
dev-mondoshawan edited this page Apr 16, 2026
·
1 revision
**Referenced Files in This Document**
- [backend/package.json](https://github.com/RunTimeAdmin/AgentID/blob/main/backend/package.json)
- [frontend/package.json](https://github.com/RunTimeAdmin/AgentID/blob/main/frontend/package.json)
- [backend/src/models/migrate.js](https://github.com/RunTimeAdmin/AgentID/blob/main/backend/src/models/migrate.js)
- [backend/src/config/index.js](https://github.com/RunTimeAdmin/AgentID/blob/main/backend/src/config/index.js)
- [agentid_build_plan.md](https://github.com/RunTimeAdmin/AgentID/blob/main/agentid_build_plan.md)
- Introduction
- Prerequisites
- Installation
- Configuration
- Running the Application
- Verification
- Next Steps
This guide will help you get AgentID up and running on your local machine for development and testing purposes.
Before you begin, ensure you have the following installed:
- Node.js 18.x or higher (Download)
- PostgreSQL 14.x or higher (Download)
- Redis 7.x or higher (Download)
- Git (Download)
git clone https://github.com/RunTimeAdmin/AgentID.git
cd AgentIDcd backend
npm installcd ../frontend
npm installCreate a PostgreSQL database:
createdb agentid
Or using psql:
psql -U postgres -c "CREATE DATABASE agentid;"Copy the example environment file:
cd backend
cp .env.example .envEdit .env with your configuration:
PORT=3002 NODE_ENV=development DATABASE_URL=postgresql://user:password@localhost:5432/agentid REDIS_URL=redis://localhost:6379 BAGS_API_KEY=your_bags_api_key_here SAID_GATEWAY_URL=https://said-gateway.example.com AGENTID_BASE_URL=http://localhost:3002 CORS_ORIGIN=http://localhost:5173 BADGE_CACHE_TTL=60 CHALLENGE_EXPIRY_SECONDS=300
cd frontend
cp .env.example .envEdit .env:
VITE_API_BASE_URL=http://localhost:3002/api
Run the database migrations to create the required tables:
cd backend
npm run migrateThis will create:
-
agent_identitiestable -
agent_verificationstable -
agent_flagstable - Required indexes
cd backend
npm run devThe backend API will be available at http://localhost:3002
In a new terminal:
cd frontend
npm run devThe frontend will be available at http://localhost:5173
Ensure Redis is running:
redis-server
curl http://localhost:3002/health
Expected response:
{"status":"ok"}Register a test agent:
curl -X POST http://localhost:3002/api/register \ -H "Content-Type: application/json" \ -d '{ "pubkey": "test_pubkey_88_chars_long_here", "name": "Test Agent", "signature": "test_signature", "message": "test_message", "nonce": "test_nonce" }'
Open your browser and navigate to http://localhost:5173
You should see the AgentID registry interface.
Now that you have AgentID running:
- Read the Developer Guide - Learn about the architecture and how to extend the system
- Review the API Reference - Understand the available endpoints
- Check the Security Implementation - Learn about authentication and security
- Explore the Widget Guide - Learn how to embed trust badges
- Verify PostgreSQL is running
- Check DATABASE_URL format
- Ensure database exists
- Verify Redis is running on the configured port
- Check REDIS_URL format
- Ensure CORS_ORIGIN matches your frontend URL
- Check that the frontend VITE_API_BASE_URL is correct
- Change PORT in backend .env
- Change the dev server port in frontend vite.config.js