Background
Lens exposes GET /price/:assetA/:assetB, GET /status, GET /pools, and a GraphQL endpoint. Developers integrating Lens need to know the exact request format, the x402 payment header format, and the response schema. An OpenAPI spec makes this discoverable and enables auto-generated clients.
What to build
Author or generate an OpenAPI 3.0 spec covering all Lens REST endpoints, including the x402 payment header requirement.
Key files
src/routes/ — all route handlers
openapi.yaml — create at repo root
README.md — link to spec
Suggested execution
git checkout -b docs/openapi-spec
- Document
GET /price/{assetA}/{assetB} — include x402 header in security scheme, describe all response fields
- Document
GET /status, GET /pools
- Add a custom
x402 security scheme describing the X-PAYMENT header format
- Validate with
npx @redocly/cli lint openapi.yaml
Example commit message:
docs: add OpenAPI 3.0 spec for all Lens REST endpoints including x402 auth
Acceptance criteria
Drips Wave · Complexity: Medium · 150 points
Comment below to request assignment. PR must include Closes #[this issue].
Background
Lens exposes
GET /price/:assetA/:assetB,GET /status,GET /pools, and a GraphQL endpoint. Developers integrating Lens need to know the exact request format, the x402 payment header format, and the response schema. An OpenAPI spec makes this discoverable and enables auto-generated clients.What to build
Author or generate an OpenAPI 3.0 spec covering all Lens REST endpoints, including the x402 payment header requirement.
Key files
src/routes/— all route handlersopenapi.yaml— create at repo rootREADME.md— link to specSuggested execution
GET /price/{assetA}/{assetB}— include x402 header in security scheme, describe all response fieldsGET /status,GET /poolsx402security scheme describing theX-PAYMENTheader formatnpx @redocly/cli lint openapi.yamlExample commit message:
docs: add OpenAPI 3.0 spec for all Lens REST endpoints including x402 authAcceptance criteria