From 31914154c03966020364cc213496e33f62cb2cc4 Mon Sep 17 00:00:00 2001 From: "promptless[bot]" <179508745+promptless[bot]@users.noreply.github.com> Date: Tue, 16 Sep 2025 17:23:20 +0000 Subject: [PATCH 1/3] Documentation updates from Promptless --- .../products/sdks/snippets/readme-options.mdx | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/fern/products/sdks/snippets/readme-options.mdx b/fern/products/sdks/snippets/readme-options.mdx index 73c967cbe..c69c1950a 100644 --- a/fern/products/sdks/snippets/readme-options.mdx +++ b/fern/products/sdks/snippets/readme-options.mdx @@ -10,6 +10,27 @@ readme: method: "POST" path: "/users" stream: false + customSections: + - title: "Usage" + language: "JAVA" + content: | + Add the following dependency to your project: + + ```xml + + {{ group }} + {{ artifact }} + {{ version }} + + ``` + - title: "Getting Started" + language: "PYTHON" + content: | + Install the SDK using pip: + + ```bash + pip install {{ package }}=={{ version }} + ``` features: authentication: - method: "POST" @@ -46,6 +67,29 @@ readme: Specifies which endpoint's code snippet to showcase as the primary example in the README. + + Each item in the array defines a custom section with specific language, title, and content. + The sections are added to the generated README file for the specified language. + + + The title of the custom section. + + + The language for which this section should be added. Use the values: + - 'JAVA' + - 'PYTHON' + - 'TYPESCRIPT' + - 'NODE' + - 'C_SHARP' + - 'GO' + - 'PHP' + - 'RUBY' + + + The Markdown content of the custom section. You can use template variables like `{{ group }}`, `{{ artifact }}`, and `{{ version }}` within the Markdown content. + + + Organizes endpoints into named feature sections within the README. Each feature creates a dedicated section with example code snippets for the specified endpoints. From 269b83c7463faa21e610a18b49726c83936a5de1 Mon Sep 17 00:00:00 2001 From: Devin Logan Date: Tue, 16 Sep 2025 15:43:36 -0400 Subject: [PATCH 2/3] make clarifying edits --- .../products/sdks/snippets/readme-options.mdx | 74 +++++++++---------- 1 file changed, 33 insertions(+), 41 deletions(-) diff --git a/fern/products/sdks/snippets/readme-options.mdx b/fern/products/sdks/snippets/readme-options.mdx index c69c1950a..a53cda0a0 100644 --- a/fern/products/sdks/snippets/readme-options.mdx +++ b/fern/products/sdks/snippets/readme-options.mdx @@ -11,26 +11,18 @@ readme: path: "/users" stream: false customSections: - - title: "Usage" - language: "JAVA" + - title: "Custom Section" + language: "java" content: | - Add the following dependency to your project: - - ```xml - - {{ group }} - {{ artifact }} - {{ version }} - - ``` - - title: "Getting Started" - language: "PYTHON" + This is a custom section. Latest package info is {{ group }}:{{ artifact }}:{{ version }}. + - title: "Custom Section" + language: "typescript" content: | - Install the SDK using pip: - - ```bash - pip install {{ package }}=={{ version }} - ``` + Custom section for {{ packageName }} + - title: "Another Custom Section" + language: "typescript" + content: | + A second custom section for {{ packageName }} features: authentication: - method: "POST" @@ -67,29 +59,6 @@ readme: Specifies which endpoint's code snippet to showcase as the primary example in the README. - - Each item in the array defines a custom section with specific language, title, and content. - The sections are added to the generated README file for the specified language. - - - The title of the custom section. - - - The language for which this section should be added. Use the values: - - 'JAVA' - - 'PYTHON' - - 'TYPESCRIPT' - - 'NODE' - - 'C_SHARP' - - 'GO' - - 'PHP' - - 'RUBY' - - - The Markdown content of the custom section. You can use template variables like `{{ group }}`, `{{ artifact }}`, and `{{ version }}` within the Markdown content. - - - Organizes endpoints into named feature sections within the README. Each feature creates a dedicated section with example code snippets for the specified endpoints. @@ -108,4 +77,27 @@ Specifies which endpoint's code snippet to showcase as the primary example in th Whether the endpoint is a streaming endpoint. Defaults to `false`. + + +### Custom sections + +Define a custom section in the generated README for a specific SDK. + + + The title of the custom section as it will appear in the README. + + + The target SDK language for this section. The custom section will only appear in README files generated for the specified language. + + + The Markdown content of the custom section. You can use template variables to dynamically insert package names and SDK version numbers. + + | Language | Variable | Description | + |----------|----------|-------------| + | Java | `{{ group }}` | Maven groupId from `coordinate` field | + | Java | `{{ artifact }}` | Maven artifactId from `coordinate` field | + | Java | `{{ version }}` | SDK version | + | TypeScript | `{{ packageName }}` | Name of your package, as specified in the `package-name` field | + | TypeScript | `{{ version }}` | SDK version | + \ No newline at end of file From 773210764736eb9fadccece5869ed37270aac1eb Mon Sep 17 00:00:00 2001 From: Devin Logan Date: Tue, 23 Sep 2025 13:58:57 -0400 Subject: [PATCH 3/3] add rest of languages --- .../cli-changelog/2025-09-22.mdx | 2 +- .../products/sdks/snippets/readme-options.mdx | 32 +++++++++++-------- 2 files changed, 20 insertions(+), 14 deletions(-) diff --git a/fern/products/cli-api-reference/cli-changelog/2025-09-22.mdx b/fern/products/cli-api-reference/cli-changelog/2025-09-22.mdx index 614e22d32..57a099503 100644 --- a/fern/products/cli-api-reference/cli-changelog/2025-09-22.mdx +++ b/fern/products/cli-api-reference/cli-changelog/2025-09-22.mdx @@ -7,7 +7,7 @@ ## 0.78.4 -**`(fix):`** Collapse any combination of optional and nullable to optional>. +**`(fix):`** Collapse any combination of optional and nullable to `optional>`. ## 0.78.3 **`(chore):`** Support IR v59 in the Rust SDK generator. diff --git a/fern/products/sdks/snippets/readme-options.mdx b/fern/products/sdks/snippets/readme-options.mdx index a53cda0a0..f40e1c05c 100644 --- a/fern/products/sdks/snippets/readme-options.mdx +++ b/fern/products/sdks/snippets/readme-options.mdx @@ -55,10 +55,6 @@ readme: Sections to disable in the README. Supported values: `"contributing"`. - - Specifies which endpoint's code snippet to showcase as the primary example in the README. - - Organizes endpoints into named feature sections within the README. Each feature creates a dedicated section with example code snippets for the specified endpoints. @@ -83,21 +79,31 @@ Specifies which endpoint's code snippet to showcase as the primary example in th Define a custom section in the generated README for a specific SDK. - + The title of the custom section as it will appear in the README. - + The target SDK language for this section. The custom section will only appear in README files generated for the specified language. - - The Markdown content of the custom section. You can use template variables to dynamically insert package names and SDK version numbers. + + The Markdown content of the custom section. You can use template variables in the format `{{ variable }}` that will be dynamically replaced with values specific to each SDK language when the README is generated. + + Available template variables by language: | Language | Variable | Description | |----------|----------|-------------| - | Java | `{{ group }}` | Maven groupId from `coordinate` field | - | Java | `{{ artifact }}` | Maven artifactId from `coordinate` field | - | Java | `{{ version }}` | SDK version | - | TypeScript | `{{ packageName }}` | Name of your package, as specified in the `package-name` field | - | TypeScript | `{{ version }}` | SDK version | + | TypeScript | `packageName` | Name of your package, as specified in the [`package-name` field](/sdks/generators/typescript/configuration#package-name) | + | Python | `packageName` | Name of your package, as specified in the [`package-name` field](/sdks/generators/python/configuration#package-name) | + | Go | `owner` | The owner of your Go module | + | Go | `repo` | The [repository](/sdks/generators/go/publishing#configure-output-location) where your Go module is published | + | Go | `version` | SDK version | + | Java | `group` | Maven `groupId` [from `coordinate` field](/sdks/generators/java/publishing#configure-maven-coordinate) | + | Java | `artifact` | Maven `artifactId` [from `coordinate` field](/sdks/generators/java/publishing#configure-maven-coordinate) | + | Java | `version` | SDK version | + | C#/.NET | `packageName` | Name of your package, as specified in the [`package-name` field](/sdks/generators/csharp/configuration#package-name) | + | PHP | `packageName` | Name of your package, as specified in the [`package-name` field](/sdks/generators/php/configuration#package-name) | + | Ruby | `packageName` | Name of your package, as specified in the [`package-name` field](/sdks/generators/ruby/configuration#package-name) | + | Swift | `gitUrl` | The [URL](/sdks/generators/swift/publishing#verify-package-availability) where your Swift package is published. For example, `https://github.com/fern-api/basic-swift-sdk` | + | Swift | `minVersion` | SDK version | \ No newline at end of file