Repositories

Repositories are synced from your GitHub account and are the unit everything else hangs off: deployments target a repository id, and monitoring is grouped per repository. These endpoints list them, force a fresh sync, and run stack analysis without deploying.

GET/api/v1/reposBearer token

Lists the authenticated user's synced repositories as a JSON array, most recently updated first.

FieldTypeDescription
idstringRepository id (cuid) — use this for deployments and analysis.
namestringRepository name.
fullNamestringowner/name as on GitHub.
isPrivatebooleanWhether the repo is private on GitHub.
defaultBranchstringBranch that gets analyzed and deployed.
updatedAtstringISO timestamp of the last update.
languagestring | nullPrimary language reported by GitHub.
descriptionstring | nullGitHub repository description.
urlstringThe repository's GitHub page.
request
curl https://www.deplo.in/api/v1/repos \
  -H "Authorization: Bearer $DEPLO_TOKEN"
response · 200
[
  {
    "id": "cm5xb2c3d0002njk8p4q5r6s7",
    "name": "acme-shop",
    "fullName": "adalovelace/acme-shop",
    "isPrivate": true,
    "defaultBranch": "main",
    "updatedAt": "2026-08-06T18:22:41.000Z",
    "language": "TypeScript",
    "description": "Full-stack storefront (Next.js + Express)",
    "url": "https://github.com/adalovelace/acme-shop"
  }
]
POST/api/v1/repos/syncBearer token

Forces a fresh repository sync from GitHub, bypassing the cache, and returns how many repositories are now synced. Use this when a newly created repo has not appeared yet. No request body.

request
curl -X POST https://www.deplo.in/api/v1/repos/sync \
  -H "Authorization: Bearer $DEPLO_TOKEN"
response · 200
{
  "synced": 42
}

Runs stack analysis on the repository's default branch and returns the detected stack, rich per-component analysis, and the environment variables the code actually reads. Purely read-only — no deployment is created. Returns 403 if the repo belongs to another user, 404 if it does not exist.

FieldTypeDescription
stack.frontendstring | nullDetected frontend framework (e.g. NEXTJS, REACT_VITE).
stack.backendstring | nullDetected backend framework (e.g. EXPRESS, FASTIFY).
stack.frontendPathstring | nullPath of the frontend within the repo.
stack.backendPathstring | nullPath of the backend within the repo.
stack.buildCommandstring | nullBuild command resolved from the repo's own scripts.
stack.packageManagerstring | nullnpm, pnpm, yarn, or bun.
analysisobjectRich detection detail: repo structure, primaryLanguage, overallConfidence (0–1), needsAiFallback, and a components array with per-component framework, confidence, and deploy strategy.
envVars[]arrayDetected variables: key, value (default or empty), isRequired, and source (where it was found).
defaultBranchstringThe branch that was analyzed.
request
curl https://www.deplo.in/api/v1/repos/cm5xb2c3d0002njk8p4q5r6s7/analyze \
  -H "Authorization: Bearer $DEPLO_TOKEN"
response · 200
{
  "stack": {
    "frontend": "NEXTJS",
    "backend": "EXPRESS",
    "frontendPath": "client",
    "backendPath": "server",
    "buildCommand": "npm run build",
    "packageManager": "npm"
  },
  "analysis": {
    "structure": "frontend-backend",
    "primaryLanguage": "typescript",
    "overallConfidence": 0.92,
    "needsAiFallback": false,
    "components": [
      {
        "path": "client",
        "role": "frontend",
        "framework": "nextjs",
        "language": "typescript",
        "confidence": 0.95,
        "deployable": true,
        "provider": "vercel",
        "buildCommand": "npm run build",
        "outputDirectory": ".next",
        "startCommand": null
      },
      {
        "path": "server",
        "role": "backend",
        "framework": "express",
        "language": "typescript",
        "confidence": 0.89,
        "deployable": true,
        "provider": "render",
        "buildCommand": "npm run build",
        "outputDirectory": null,
        "startCommand": "npm run start"
      }
    ]
  },
  "envVars": [
    { "key": "DATABASE_URL", "value": "", "isRequired": true, "source": "code" },
    { "key": "STRIPE_SECRET_KEY", "value": "", "isRequired": true, "source": "code" },
    { "key": "NEXT_PUBLIC_API_URL", "value": "", "isRequired": false, "source": "dotenv-example" }
  ],
  "defaultBranch": "main"
}
Tip
Analysis runs automatically when you start a deployment — call this endpoint only when you want to preview the detected stack and env vars first, e.g. to build a configure step like the dashboard's. See the environment variables guide for how source and isRequired are derived.