Skip to content
- Formats — Swagger 2.0, OpenAPI 3.0 and 3.1, JSON or YAML. A 2.0 document is converted to 3.0 first (
definitions, in: body / formData, consumes / produces, x-nullable, collectionFormat); the 3.1 spellings (type: [x, "null"], const) are folded into their 3.0 equivalents. Local $refs that point outside components are inlined.
- Where from — a file, a folder of files (one per service) or a URL, or a map
{ service: fileOrUrl }.
- Protected URLs —
headers (--headers "Authorization: Bearer …", OPENAPI_FORGE_HEADERS).
- TLS —
tls: { ca: "internal-ca.pem" } (--ca) trusts a private CA in addition to the public ones; tls: { insecure: true } (--insecure) skips verification (local development only, never in CI). NODE_EXTRA_CA_CERTS works too, and a TLS failure names these options.
- Gaps — what a document leaves out never breaks the output: that spot is typed
unknown, and the run lists every one of them with the operation and the part (response, request body, parameter x, schema Y) so it can be fixed at the source. --verbose lists all of them.