- api.devkit4ai.com — Primary production server
- api.vibecoding.ad — Alternative production server
What It Provides
Authentication Services
- User registration: Create new user accounts with email and password
- Login/logout: Secure authentication with JWT tokens
- Token refresh: Automatic token renewal for continuous sessions
- Email verification: Verify user email addresses
- Password reset: Secure password recovery flow
- Session management: Handle user sessions across devices
Project Management
- Project CRUD: Create, read, update, and delete projects
- API key generation: Create project-scoped authentication keys
- Key management: List, revoke, and track API key usage
- Project isolation: Multi-tenant architecture ensures data separation
AI Generation
- Image generation: Create AI images using Replicate models
- Status tracking: Monitor generation progress and completion
- History management: Access past generations for authenticated users
- Public sharing: Toggle image visibility for sharing
- Anonymous generation: Support for unauthenticated generation flows
Health & Monitoring
- Health checks: Verify API availability and status
- Database status: Check backend database connectivity
- Storage status: Verify file storage availability
- Detailed diagnostics: Get comprehensive system information
How Authentication Works
JWT Token Flow
1
User logs in
Starter Kit sends email/password to
/api/v1/auth/login2
API validates credentials
Cloud API checks credentials and generates tokens
3
Tokens returned
Access token (30 min) and refresh token (7 days) sent to client
4
Tokens stored
Starter Kit stores tokens in httpOnly cookies for security
5
Authenticated requests
Subsequent requests include JWT token automatically
Required Headers
All API requests from your Starter Kit include these authentication headers:- X-User-Role: Identifies the user type (end_user for Starter Kit users)
- X-Developer-Key: Your developer credential from Cloud Admin
- X-Project-ID: Your project’s unique identifier (UUID format)
- X-API-Key: Your project’s API key
- Authorization: JWT token for authenticated user requests
Role-Based Access
Different user types have different access levels to API endpoints:| Endpoint Group | Operator | Developer | End User |
|---|---|---|---|
| Health Check | ✅ | ✅ | ✅ |
| Authentication | ✅ | ✅ | ✅ |
| Project Management | ✅ | ✅ Own projects | ❌ |
| AI Generation | ✅ | ✅ | ✅ Project-scoped |
API Endpoints
The Cloud API is organized into logical groups:Health Check Endpoints
GET /health- Quick health statusGET /api/v1/health- Comprehensive health checkGET /api/v1/health/database- Database connectivityGET /api/v1/health/storage- File storage statusGET /api/v1/health/redis- Cache status (if configured)
Authentication Endpoints
POST /api/v1/auth/register- Create new userPOST /api/v1/auth/login- Authenticate userGET /api/v1/auth/me- Get current user infoPOST /api/v1/auth/refresh- Refresh access tokenPOST /api/v1/auth/verify-email- Verify email addressPOST /api/v1/auth/request-verification- Request verification email
Project Endpoints
GET /api/v1/projects- List user’s projectsPOST /api/v1/projects- Create new projectGET /api/v1/projects/{id}- Get project detailsDELETE /api/v1/projects/{id}- Delete projectPOST /api/v1/projects/{id}/api-keys- Generate API keyGET /api/v1/projects/{id}/api-keys- List project keysDELETE /api/v1/projects/{id}/api-keys/{key_id}- Revoke key
Generation Endpoints
POST /api/v1/generation/generate-v2- Create AI generationGET /api/v1/generation/{id}/status- Check generation statusGET /api/v1/generation- List user’s generationsPATCH /api/v1/generation/{id}/public- Toggle visibilityDELETE /api/v1/generation/{id}- Delete generationGET /api/v1/generation/public- List public generations
Integration with Starter Kit
The Starter Kit is pre-configured to work with the Cloud API:- Environment variables set the API URL and credentials
- Deployment mode validates configuration on startup
- Server actions in
app/actions.tscall API endpoints - Authentication context manages user state from API responses
- Headers automatically included in all requests
Rate Limits & Quotas
Rate limits and quotas depend on your plan. Contact support for details about upgrading or custom limits.

