diff --git a/fern/snippets/multiple-apis.mdx b/fern/snippets/multiple-apis.mdx index 2bbe1b952..93554ef3c 100644 --- a/fern/snippets/multiple-apis.mdx +++ b/fern/snippets/multiple-apis.mdx @@ -1,6 +1,8 @@ -The fern folder can house multiple API definitions. When you have multiple APIs, nest your definition files within an `apis` folder. +The fern folder can house multiple API definitions. When you have multiple APIs, nest your definition files within a top-level `apis` folder. -Each API must also have a separate `generators.yml` file that specifies the location of the API definition and configures SDK generation. +Each API must have a separate `generators.yml` file that specifies the location of the API definition and configures SDK generation. + +Below is an example of what a fern folder containing multiple APIs might look like. Your exact structure might vary depending on your organization's conventions and needs – the important part is that each API has its own `generators.yml` file. ```bash fern/ @@ -8,11 +10,11 @@ fern/ ├─ generators.yml # Optional: top-level configuration for all APIs └─ apis/ └─ first-api/ # First API - ├─ generators.yml # Required: points to API spec - └─ openapi/ - ├─ openapi.yml # API Definition file + └─ spec-folder/ # definition, openapi, asyncapi, etc. + ├─ generators.yml # Required: points to API spec and configures SDKs + └─ spec-file.yml # API Definition file └─ second-api/ # Second API - ├─ generators.yml # Required: points to API spec - └─ openapi/ - ├─ openapi.yml # API Definition file + └─ spec-folder/ # definition, openapi, asyncapi, etc. + ├─ generators.yml # Required: points to API spec and configures SDKs + └─ spec-file.yml # API Definition file ``` \ No newline at end of file