Skip to main content
POST
/
api
/
v1
/
projects
Create Project
curl --request POST \
  --url https://api.devkit4ai.com/api/v1/projects/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>"
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
Create a new project for your AI-powered application. Projects serve as containers for end users, API keys, and generation requests. Each developer can create multiple projects for different applications or environments.

Authentication

Requires valid JWT token with developer role.

Headers

Authorization
string
required
Bearer JWT access token obtained from login
X-User-Role
string
required
Must be set to developer
X-Developer-Key
string
required
Active developer key for authentication
Content-Type
string
required
Must be application/json

Request Body

name
string
required
Project name (3-100 characters). Should be descriptive and unique among your projects.Examples: “Production API”, “My SaaS App”, “Customer Portal”, “E-Commerce Platform”
description
string
Detailed project description (optional, max 500 characters). Describe the project’s purpose, target users, or key features.Example: “AI-powered image generation platform for e-commerce product photography”

Response

id
string
Unique UUID identifier for the newly created project
name
string
Project name as provided
description
string
Project description (null if not provided)
owner_id
string
UUID of the developer who created the project (your user ID)
is_active
boolean
Project status - always true for newly created projects
created_at
string
ISO 8601 timestamp when the project was created
updated_at
string
ISO 8601 timestamp of last update (null for new projects)

Example Request

curl -X POST https://api.vibecoding.ad/api/v1/projects/ \
  -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." \
  -H "X-User-Role: developer" \
  -H "X-Developer-Key: ak_abc123XYZ-_789def456ghi012jkl345" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "My SaaS Application",
    "description": "AI-powered content generation platform for marketing teams"
  }'

Example Response

{
  "id": "770e8400-e29b-41d4-a716-446655440002",
  "name": "My SaaS Application",
  "description": "AI-powered content generation platform for marketing teams",
  "owner_id": "550e8400-e29b-41d4-a716-446655440000",
  "is_active": true,
  "created_at": "2025-12-08T11:00:00Z",
  "updated_at": null
}

Next Steps After Creation

After creating a project, you should:
  1. Generate Project API Keys via Create API Key
  2. Configure Starter Kit with your project credentials
  3. Register End Users via Register endpoint
  4. Monitor Usage via Project Stats
(((REPLACE_THIS_WITH_IMAGE: cloud-api-project-setup-workflow.png: Step-by-step diagram showing project creation, API key generation, Starter Kit configuration, and user registration)))

Use Cases

Multi-Environment Setup

Create separate projects for each environment:
async function setupEnvironments(
  jwtToken: string,
  developerKey: string
) {
  const environments = [
    {
      name: 'Production - My SaaS App',
      description: 'Production environment for live users'
    },
    {
      name: 'Staging - My SaaS App',
      description: 'Staging environment for QA and testing'
    },
    {
      name: 'Development - My SaaS App',
      description: 'Development environment for feature testing'
    }
  ];
  
  const projects = [];
  
  for (const env of environments) {
    const response = await fetch(
      'https://api.vibecoding.ad/api/v1/projects/',
      {
        method: 'POST',
        headers: {
          'Authorization': `Bearer ${jwtToken}`,
          'X-User-Role': 'developer',
          'X-Developer-Key': developerKey,
          'Content-Type': 'application/json'
        },
        body: JSON.stringify(env)
      }
    );
    
    const project = await response.json();
    projects.push(project);
    
    console.log(`✓ Created ${env.name}: ${project.id}`);
  }
  
  return projects;
}

Multi-Product Portfolio

Manage multiple applications under one developer account:
interface ProductConfig {
  name: string;
  description: string;
  domain: string;
}

async function createProductProjects(products: ProductConfig[]) {
  const createdProjects = [];
  
  for (const product of products) {
    const response = await fetch(apiUrl, {
      method: 'POST',
      headers: {
        'Authorization': `Bearer ${jwtToken}`,
        'X-User-Role': 'developer',
        'X-Developer-Key': developerKey,
        'Content-Type': 'application/json'
      },
      body: JSON.stringify({
        name: product.name,
        description: `${product.description} - Deployed at ${product.domain}`
      })
    });
    
    const project = await response.json();
    createdProjects.push({
      ...project,
      domain: product.domain
    });
  }
  
  return createdProjects;
}

// Usage
const products = [
  {
    name: 'AI Photo Editor',
    description: 'AI-powered photo editing platform',
    domain: 'photoeditor.example.com'
  },
  {
    name: 'Content Generator',
    description: 'AI content generation tool',
    domain: 'content.example.com'
  }
];

await createProductProjects(products);

Client Project Management

Create projects for individual clients:
async function onboardNewClient(
  clientName: string,
  clientEmail: string,
  jwtToken: string,
  developerKey: string
) {
  // Step 1: Create project
  const projectResponse = await fetch(
    'https://api.vibecoding.ad/api/v1/projects/',
    {
      method: 'POST',
      headers: {
        'Authorization': `Bearer ${jwtToken}`,
        'X-User-Role': 'developer',
        'X-Developer-Key': developerKey,
        'Content-Type': 'application/json'
      },
      body: JSON.stringify({
        name: `${clientName} - Client Project`,
        description: `Dedicated project for ${clientName} (${clientEmail})`
      })
    }
  );
  
  const project = await projectResponse.json();
  
  // Step 2: Generate API key for client
  const keyResponse = await fetch(
    `https://api.vibecoding.ad/api/v1/projects/${project.id}/api-keys`,
    {
      method: 'POST',
      headers: {
        'Authorization': `Bearer ${jwtToken}`,
        'X-User-Role': 'developer',
        'X-Developer-Key': developerKey,
        'Content-Type': 'application/json'
      },
      body: JSON.stringify({
        name: `${clientName} Production Key`
      })
    }
  );
  
  const apiKey = await keyResponse.json();
  
  // Return client credentials
  return {
    clientName,
    projectId: project.id,
    projectName: project.name,
    apiKey: apiKey.key,
    setupInstructions: `
      Configure your application with:
      DEVKIT4AI_PROJECT_ID=${project.id}
      DEVKIT4AI_PROJECT_KEY=${apiKey.key}
    `
  };
}

Project Limits

Free tier developers can create up to 5 active projects. Upgrade to Cloud Starter or Cloud Premium for unlimited projects.

Tier Limits

TierMax ProjectsEnd Users per ProjectAPI Keys per Project
Free Starter51003
Cloud Starter2010,00010
Cloud PremiumUnlimitedUnlimitedUnlimited

Best Practices

Naming Conventions

Do:
  • Use descriptive names: “Production - E-Commerce Platform”
  • Include environment: “Staging - Mobile App”
  • Mention client/product: “Acme Corp - Customer Portal”
  • Keep names under 50 characters for display purposes
Don’t:
  • Use generic names: “Project 1”, “Test”, “New Project”
  • Include sensitive data: API keys, passwords, internal IDs
  • Use special characters that break URLs: #, ?, &

Organization Strategies

By Environment:
Production - My App
Staging - My App
Development - My App
By Client:
Acme Corp - Production
Widget Inc - Production
StartupXYZ - Beta
By Product:
Photo Editor Pro
Content Generator
Marketing Automation

Security Considerations

  1. Principle of Least Privilege: Create separate projects for different trust levels
  2. Environment Isolation: Never share API keys between production and development
  3. Client Separation: Each client should have their own isolated project
  4. Audit Trail: Use descriptive names and descriptions for tracking
  5. Regular Cleanup: Deactivate or delete unused projects

Error Responses

Invalid Project Name (422)

{
  "detail": [
    {
      "loc": ["body", "name"],
      "msg": "ensure this value has at least 3 characters",
      "type": "value_error.any_str.min_length"
    }
  ]
}

Description Too Long (422)

{
  "detail": [
    {
      "loc": ["body", "description"],
      "msg": "ensure this value has at most 500 characters",
      "type": "value_error.any_str.max_length"
    }
  ]
}

Project Limit Reached (403)

{
  "detail": "Maximum number of projects reached for your subscription tier. Upgrade to create more projects."
}

Unauthorized (401)

{
  "detail": "Could not validate credentials"
}

Insufficient Permissions (403)

{
  "detail": "Insufficient permissions. Developer role required."
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json
name
string
required
Required string length: 1 - 255
description
string | null
Maximum string length: 1000

Response

Successful Response

id
string<uuid>
required