Babarkhan01/Docloom — API Reference
Structural facts below were extracted from the source at branch main with a TypeScript AST parser; descriptions are AI-written from those facts only.
Endpoints (4)
| Method | Path | Description |
|---|---|---|
| GET | /api/auth/github/callback | Handles the GitHub OAuth redirect by exchanging the authorization code server-side, upserting the user, and issuing a signed session cookie. |
| GET | /api/auth/github | Initiates the GitHub App OAuth authorization code flow to obtain a user-to-server token. |
| POST | /api/repos/[id]/generate | Starts a documentation generation run for the specified repo owned by the caller, enforcing the free-plan daily generation cap. |
| GET | /api/repos/available | Returns the repositories accessible to the user via the GitHub App that are not yet connected, using a read-only user-to-server token. |
Reference
/api/auth/github/callback
GET /api/auth/github/callback
Handles the GitHub OAuth redirect by exchanging the authorization code server-side, upserting the user, and issuing a signed session cookie.
Details
- Source:
src/app/api/auth/github/callback/route.ts - Route context: none
- Reads the request: yes
- Returns a Response: yes
- Exports:
dynamic,GET
/api/auth/github
GET /api/auth/github
Initiates the GitHub App OAuth authorization code flow to obtain a user-to-server token.
Details
- Source:
src/app/api/auth/github/route.ts - Route context: none
- Reads the request: yes
- Returns a Response: yes
- Exports:
dynamic,GET
/api/repos/[id]/generate
POST /api/repos/[id]/generate
Starts a documentation generation run for the specified repo owned by the caller, enforcing the free-plan daily generation cap.
Details
- Source:
src/app/api/repos/[id]/generate/route.ts - Dynamic segments:
[id] - Route context:
params:Promise<{ id: string }>
- Reads the request: no
- Returns a Response: yes
- Exports:
dynamic,POST
/api/repos/available
GET /api/repos/available
Returns the repositories accessible to the user via the GitHub App that are not yet connected, using a read-only user-to-server token.
Details
- Source:
src/app/api/repos/available/route.ts - Route context: none
- Reads the request: no
- Returns a Response: yes
- Exports:
dynamic,GET