newdrive/api/openapi.yaml
Elijah 077cf7601a
Some checks failed
CI / Backend (push) Failing after 4s
CI / Frontend (push) Successful in 11s
CI / Contracts and repository policy (push) Failing after 5s
CI / Container (push) Has been skipped
Initial phase 1 baseline implementation
2026-07-16 19:14:01 -07:00

98 lines
2.5 KiB
YAML

openapi: 3.1.0
info:
title: Drive v2 API
version: 0.0.0
description: >-
Contract-first API for Drive v2. The current Phase 1 persistence foundation
exposes only setup status and health operations; product endpoints are added
with their implementation.
servers:
- url: /
paths:
/api/v1/setup/status:
get:
security: []
operationId: getSetupStatus
summary: Report whether the owner account has been initialized
responses:
"200":
description: Current setup state
content:
application/json:
schema:
$ref: "#/components/schemas/SetupStatus"
"503":
description: Setup state cannot be read because a required dependency is unavailable
content:
application/problem+json:
schema:
$ref: "#/components/schemas/Problem"
/health/live:
get:
security: []
operationId: getLiveness
summary: Report process liveness
responses:
"200":
description: Process is live
content:
application/json:
schema:
$ref: "#/components/schemas/HealthStatus"
/health/ready:
get:
security: []
operationId: getReadiness
summary: Report dependency readiness
responses:
"200":
description: Process is ready
content:
application/json:
schema:
$ref: "#/components/schemas/HealthStatus"
"503":
description: A required dependency is unavailable
content:
application/problem+json:
schema:
$ref: "#/components/schemas/Problem"
components:
schemas:
SetupStatus:
type: object
required: [initialized, phase, version]
properties:
initialized:
type: boolean
phase:
type: string
version:
type: string
HealthStatus:
type: object
required: [status]
properties:
status:
type: string
enum: [live, ready]
Problem:
type: object
required: [type, title, status, code]
properties:
type:
type: string
format: uri-reference
title:
type: string
status:
type: integer
minimum: 100
maximum: 599
detail:
type: string
instance:
type: string
format: uri-reference
code:
type: string