Updating Dittofeed’s API docs requires running Dittofeed’s API server locally, and copying the OpenAPI / Swagger spec to the docs package.

1

Start API Server

Start the API server by running the following command:

yarn workspace api dev
2

Sync Open API

In a separate terminal, run the following command to copy the OpenAPI / Swagger spec to the docs package:

curl "http://localhost:3001/documentation/json" | jq "." > packages/docs/open-api.json

Note this command assumes you have jq installed, which formats the JSON output from the API server.

4

Add new endpoints to docs (optional)

Run the following command to add new endpoints to the docs:

npx @mintlify/scraping@latest openapi-file packages/docs/open-api.json --outDir packages/docs/api-reference/auto

Then add the new endpoints to the mint.json file.

mint.json
{
  "group": "API Reference",
  "pages": [
    "api-reference/auto/content/get-apiadmincontenttemplates",
    ...
  ]
}

4

Run Docs

Run Dittofeed’s docs in local machine:

cd into docs directory

cd packages/docs

Run the mintlify dev server.

mintlify dev