Core Endpoints•8 min read
Projects & Workspaces API
Create, retrieve, update, and manage engineering application projects and workspaces using Kavach REST APIs.
Projects Endpoints Summary
The Projects API allows security and DevOps engineers to manage workspaces, configure repository bindings, and set compliance blueprints programmatically.
Endpoints Reference (5)
GET/api/v1/projects
Permission: PROJECT_READList all projects in your organization
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| limit | query | integer | No | Number of records to return (1-500, default: 100) |
| offset | query | integer | No | Offset for pagination (default: 0) |
Request Example (cURL)
curl -X GET "http://localhost:8000/api/v1/projects?limit=10" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Accept: application/json"Response (200 List of projects successfully retrieved)
[
{
"id": "7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4",
"name": "Payments Service",
"description": "Core PCI-DSS compliant credit card processing API",
"repository_url": "https://github.com/org/payments-service",
"default_branch": "main",
"created_at": "2026-10-15T09:20:00Z",
"finding_count": 3
}
]POST/api/v1/projects
Permission: PROJECT_WRITECreate and persist a new project
Request Example (cURL)
curl -X POST "http://localhost:8000/api/v1/projects" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "Auth Microservice", "repository_url": "https://github.com/org/auth-service"}'Response (201 Project created successfully in PostgreSQL)
{
"id": "b3f18a22-98e1-45bc-8a9d-123456789abc",
"name": "Auth Microservice",
"status": "ACTIVE",
"created_at": "2026-11-17T00:20:00Z"
}GET/api/v1/projects/{project_id}
Permission: PROJECT_READRetrieve project details by ID
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| project_id | path | UUID | Yes | Unique identifier of the project |
Request Example (cURL)
curl -X GET "http://localhost:8000/api/v1/projects/7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4" \
-H "Authorization: Bearer YOUR_API_TOKEN"Response (200 Project details retrieved)
{
"id": "7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4",
"name": "Payments Service",
"status": "ACTIVE",
"finding_count": 3
}PATCH/api/v1/projects/{project_id}
Permission: PROJECT_WRITEUpdate project configuration
Request Example (cURL)
curl -X PATCH "http://localhost:8000/api/v1/projects/7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"description": "Updated project description"}'Response (200 Project updated)
{
"id": "7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4",
"updated_at": "2026-11-17T00:25:00Z"
}DELETE/api/v1/projects/{project_id}
Permission: PROJECT_DELETEDelete project and related data
Request Example (cURL)
curl -X DELETE "http://localhost:8000/api/v1/projects/7f8b91a2-3c4d-5e6f-a7b8-c9d0e1f2a3b4" \
-H "Authorization: Bearer YOUR_API_TOKEN"Response (204 Project deleted successfully)
HTTP 204 No Content