Skip to content

Latest commit

 

History

History

fastify

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

README.md

@easydocs/fastify

EasyDocs plugin for Fastify. Generate accurate OpenAPI 3.0 specs from your API's real traffic — local-first and self-hostable, with an offline mode (Ollama) where nothing leaves your machine.

Install

npm install @easydocs/fastify

Usage

import Fastify from 'fastify'
import { easydocs } from '@easydocs/fastify'

const app = Fastify()
await app.register(easydocs)

// Your routes — nothing changes here
app.get('/users', async () => ({ users: [] }))

await app.listen({ port: 3000 })

Configuration

await app.register(easydocs, {
  ai: {
    provider: 'openai',
    model: 'gpt-4o',
  },
  capture: {
    ignoreRoutes: ['/health'],
  },
})

View your docs

npm install -D @easydocs/dashboard
npx @easydocs/cli dashboard

# Or export to a file
npx @easydocs/cli export > openapi.json

See @easydocs/core for the full configuration reference.