RepoVault - API Docs
Back to Dashboard

RepoVault API

REST API for managing system repositories, files, deployments, and the secure vault. All requests must be authenticated via API key.

Authentication

Include your API key in every request using one of these methods:

X-API-KEY: your_api_key_here -- or -- Authorization: Bearer your_api_key_here

Error Responses

All errors return a JSON object with an error field:

{ "error": "Description of what went wrong" }
401 - Missing API key 403 - Invalid API key 400 - Bad request / validation 404 - Resource not found 429 - Rate limit exceeded 500 - Internal server error
Repositories
GET /api/repos List all repositories Auth
Query Parameters
ParamTypeDescription
owneroptionalstringFilter by account (navaLinh, veryLinh, velyrich, Vellia-Elyvia). Omit to fetch all.
Response
{ "success": true, "data": { "navaLinh": { "repos": [ { "name": "my-repo", "full_name": "navaLinh/my-repo", "owner": "navaLinh", "private": false, "default_branch": "main", "size": 1024, "updated_at": "2024-01-15T10:30:00Z", "language": "JavaScript" } ], "count": 1 } } }
GET /api/repos/:owner/:repo Get single repository Auth
Example
GET /api/repos/navaLinh/my-project X-API-KEY: your_key
GET /api/repos/:owner/:repo/commits Get commit history Auth
Query Parameters
ParamTypeDescription
pathoptionalstringFilter commits by file path
per_pageoptionalnumberResults per page (default: 10, max: 100)
GET /api/repos/:owner/:repo/tree Get full repo file tree Auth
Query Parameters
ParamTypeDescription
refoptionalstringBranch name (default: repo default branch)
recursiveoptionalbooleanInclude all subdirectories (default: true)
Files
GET /api/files List directory contents Auth
Query Parameters
ParamTypeDescription
ownerrequiredstringSystem account username
reporequiredstringRepository name
pathoptionalstringDirectory path (default: root)
refoptionalstringBranch or commit SHA
GET /api/files/content Get file content (decoded) Auth
Query Parameters
ParamTypeDescription
ownerrequiredstringSystem account username
reporequiredstringRepository name
pathrequiredstringFile path in repository
refoptionalstringBranch or commit SHA
Response
{ "success": true, "data": { "name": "index.js", "path": "src/index.js", "sha": "abc123...", "size": 1024, "content": "// file content here...", "encoding": "utf8" } }
PUT /api/files Create or update file Auth
Request Body (JSON)
FieldTypeDescription
ownerrequiredstringSystem account username
reporequiredstringRepository name
pathrequiredstringFile path in repository
contentrequiredstringFile content (UTF-8 string)
shaoptionalstringExisting file SHA (required for updates)
messageoptionalstringCommit message (auto-generated if omitted)
branchoptionalstringTarget branch (default: repo default)
Example Request
PUT /api/files X-API-KEY: your_key Content-Type: application/json { "owner": "navaLinh", "repo": "my-project", "path": "src/index.js", "content": "console.log('hello world');", "sha": "abc123...", "message": "fix: update entry point" }
DELETE /api/files Delete a file Auth
Request Body (JSON)
FieldTypeDescription
ownerrequiredstringSystem account username
reporequiredstringRepository name
pathrequiredstringFile path to delete
sharequiredstringCurrent file SHA (from GET /api/files/content)
messageoptionalstringCommit message
branchoptionalstringTarget branch
Deployment
POST /api/deploy/zip Deploy ZIP to repository Auth
This replaces ALL repository contents with the ZIP. Rate limited to 10 deploys/hour.
Request (multipart/form-data)
FieldTypeDescription
zipfilerequiredfileZIP archive (max 100MB)
ownerrequiredstringSystem account username
reporequiredstringRepository name
branchoptionalstringTarget branch (default: repo default)
Response
{ "success": true, "deployId": "550e8400-e29b-41d4-a716-446655440000", "message": "Deployment started" }
GET /api/deploy/status/:deployId Poll deployment status Auth
Response
{ "success": true, "data": { "id": "550e8400-...", "owner": "navaLinh", "repo": "my-project", "branch": "main", "status": "success", // running | success | failed "file_count": 42, "commit_sha": "abc123def456", "steps": [ { "ts": "...", "type": "info", "message": "Validating ZIP archive..." }, { "ts": "...", "type": "success", "message": "Deployment complete!" } ] } }
GET /api/deploy/history List recent deployments (last 20) Auth
Secure Vault
GET /api/vault List vault entries Auth
Query Parameters
ParamTypeDescription
categoryoptionalstringFilter by category
searchoptionalstringSearch title or content
POST /api/vault Add vault entry Auth
Request Body
FieldTypeDescription
titlerequiredstringEntry title
contentrequiredstringSensitive content
categoryoptionalstringCategory label (default: general)
PUT /api/vault/:id Update vault entry Auth
DELETE /api/vault/:id Delete vault entry Auth
System
GET /api/system System info and health Auth
Response
{ "success": true, "data": { "name": "System Repository Manager", "version": "1.0.0", "env": "production", "uptime": 3600, "accounts": ["navaLinh", "veryLinh", "velyrich", "Vellia-Elyvia"], "timestamp": "2024-01-15T10:30:00Z" } }
GET /api/logs Get audit logs Auth
Query Parameters
ParamTypeDescription
dateoptionalstringDate in YYYY-MM-DD format (default: today)
RepoVault API v1.0.0 — All endpoints require authentication — Back to Dashboard