Skip to content

Conversation

@local-fern-autopilot
Copy link
Contributor

Upgrading from 3.4.0 to 3.31.1 - Changelog

    3.31.1
  • fix: Fix generator to not generate CONTRIBUTING.md file if config.whitelabel is true.

  • 3.31.0

  • feat: Add generateSubpackageExports configuration option to enable direct imports of subpackage clients.
    This allows JavaScript bundlers to tree-shake and include only the imported subpackage code, resulting in much smaller bundle sizes.

    Example:

    import { BarClient } from '@acme/sdk/foo/bar';
    
    const client = new BarClient({...});

    To enable this feature, add the following configuration to your generators.yml file:

    # In generators.yml
    groups:
      generators:
        - name: fernapi/fern-typescript-sdk
          config:
            generateSubpackageExports: true
  • 3.30.0

  • feat: Add offsetSemantics flag, which changes how the step attribute in x-fern-pagination is interpreted.
    When offsetSemantics is item-index (the default), offset is understood as an item index that increases by the number of entities fetched.
    When offsetSemantics is page-index, offset is understood as a page index that increases by 1 each time.

  • 3.29.2

  • fix: Improve SDK generation performance.

  • 3.29.1

  • fix: When generating hasNextPage, use Math.Floor to ensure an integer comparison against the number of entities.

  • 50 additional updates, see more

    3.29.0

  • feat: Add parameterNaming configuration option to control how parameter names are generated in the SDK.
    The available options are:

    • originalName: Use the original name from the OpenAPI spec.
    • wireValue: Use the wire value from the OpenAPI spec, falling back to the original name if not present.
    • camelCase: Convert the name to camelCase.
    • snakeCase: Convert the name to snake_case.
    • default: Use the default naming strategy.
  • 3.28.12

  • fix: Include more files and folders in .npmignore:

    • .mock
    • .fern
    • dist
    • scripts
    • jest.config.*
    • vitest.config.*
  • fix: Only generate .npmignore when useLegacyExports: true.
    When useLegacyExports: false, we generate a package.json with "files" field which makes .npmignore redundant.

  • 3.28.11

  • fix: Do not generate a snippet-templates.json file in the generated TypeScript SDK.

  • 3.28.10

  • fix: Set Accept header for JSON (application/json), text (text/plain), and other (*/*) response types.
    This ensures that the Accept header is set consistently across runtimes.
    Unlike all other runtimes, Cloudflare Workers and Vercel Edge Runtime do not set a default Accept header in their fetch implementations.

  • 3.28.9

  • fix: Fix Error._visit to pass the correct type (core.Fetcher.Error) to the _other callback.

  • 3.28.8

  • fix: Clean up imports for requestWithRetries.test.ts.

  • 3.28.7

  • fix: Fix circular type alias errors (TS2456) in undiscriminated unions containing self-recursive Record types where the value is a union of itself with null and/or undefined.

  • 3.28.6

  • fix: Fix circular type alias errors (TS2456) in undiscriminated unions containing self-recursive Record types.

  • 3.28.5

  • fix: Fix issue where logs were logged even when the respective log level was disabled.

  • chore: Add tests for logging and the fetcher's redaction functionality.

  • chore: Improve unit test performance and refactor code to reduce duplication.

  • 3.28.4

  • fix: Fix a compilation error when a websocket channel has no send or receive messages.

  • 3.28.3

  • fix: Fix local GitHub generation to match remote generation.

  • 3.28.2

  • fix: Fix inconsistent path parameter casing in the WebSocket connect options.
    The casing now follows the same rules as other HTTP path parameters:

    • retainOriginalCasing: true: use the original casing from the OpenAPI spec, regardless of the noSerdeLayer setting.
    • noSerdeLayer: true: use the original casing from the OpenAPI spec.
    • noSerdeLayer: false: use camelCase for path parameters.
  • 3.28.1

  • fix: Always use vitest.config.mts for consistency across all generated SDKs. This ensures Vitest v3 can load the config as ESM in both CommonJS and ESM packages.

  • 3.28.0

  • feat: Added Generation Metadata file to output.

  • 3.27.0

  • feat: Add support for variables in wire tests.

  • 3.26.0

  • feat: Include "dependencies": {} in package.json when generating a TypeScript SDK without dependencies.

  • 3.25.0

  • feat: Add support for logging to the generated SDK.
    Users can configure the logger by passing in a logging object to the client options.

    import { FooClient, logging } from "foo";
    
    const client = new FooClient({
        logging: {
           level: logging.LogLevel.Info, // LogLevel.Info is the default
           logger: new logging.ConsoleLogger(), // ConsoleLogger is the default
           silent: false, // true is the default, set to false to enable logging
        }
    });

    The logging object can have the following properties:

    • level: The log level to use. Defaults to logging.LogLevel.Info.
    • logger: The logger to use. Defaults to logging.ConsoleLogger.
    • silent: Whether to silence the logger. Defaults to true.

    The level property can be one of the following values:

    • logging.LogLevel.Debug
    • logging.LogLevel.Info
    • logging.LogLevel.Warn
    • logging.LogLevel.Error

    To provide a custom logger, users can pass in a custom logger implementation that implements the logging.ILogger interface.

  • 3.24.0

  • feat: Add support for forward-compatible enums.
    To enable forward-compatible enums, add the following configuration to your generators.yml file:

    # In generators.yml
    groups:
      generators:
        - name: fernapi/fern-typescript-sdk
          config:
            enableForwardCompatibleEnums: true
  • 3.23.0

  • feat: Add support for bytes download responses.

  • 3.22.0

  • feat: Add support for oxfmt as the formatter.
    This is a beta feature and not officially supported yet.

  • 3.21.0

  • feat: Add support for oxlint as the linter.
    This is a beta feature and not officially supported yet.

  • 3.20.0

  • feat: Implement base and extend properties in discriminated union examples.

  • 3.19.1

  • fix: mergeHeaders() and mergeOnlyDefinedHeaders() are now case-insensitive.

  • 3.19.0

  • feat: Add support for application/x-www-form-urlencoded request bodies.

  • 3.18.0

  • feat: Users can now pass in a custom fetch function to the client options.

  • 3.17.1

  • fix: hasNextPage() now factors in offset.step if provided for offset-based pagination
    such that hasNextPage now returns false if the returned page was not as large as requested.

  • 3.17.0

  • feat: Add Page to the top-level exports.ts files, which allows for import { Page } from '...'; to work.
    Remove Pageable, and use only core.Page for pagination everywhere.

  • 3.16.0

  • feat: Generate a CONTRIBUTING.md file.

  • 3.15.0

  • feat: Export types for ReconnectingWebSocket, ReconnectingWebSocket.Event, ReconnectingWebSocket.CloseEvent, and ReconnectingWebSocket.ErrorEvent.

  • 3.14.0

  • feat: Expose the underlying response on the Page type.

  • 3.13.0

  • feat: Improve pnpm and yarn caching in generator Docker images.

  • 3.12.3

  • fix: Fix .github/workflows/ci.yml file when using OIDC for npm publishing.

  • 3.12.2

  • fix: Add streaming tests; fix custom message terminators in streams; fix multi-byte character handling across chunk breaks in streams.

  • 3.12.1

  • chore: Update Biome to 2.3.1

  • 3.12.0

  • feat: Add support for publishing to npmjs.org using OIDC from GitHub Actions.

    To use OIDC for publishing to npmjs.org, you need to follow two steps:

    1. Follow the instructions in "Step 1: Add a trusted publisher on npmjs.com".

    2. Set the output.token field to OIDC in generators.yml to enable this feature:

      # In generators.yml
      groups:
        ts-sdk:
          generators:
            - name: fernapi/fern-typescript-sdk
              output:
                location: npm
                package-name: your-package-name
                token: OIDC # previously this would be set to something like ${NPM_TOKEN}
              ...

      This will take care of "Step 2: Configure your CI/CD workflow".

    For local generation, you'll need Fern CLI version 0.94.0 or later.

  • feat: Update GitHub Actions setup-node action to v4 in the generated CI workflow.

  • 3.11.1

  • fix: Generate streaming response section in README.md for streaming response endpoints.

  • 3.11.0

  • feat: Add linter and formatter configuration options to configure code linters and formatters for the generated SDK.

    • linter:
      • biome: Use Biome as the code linter. This is the default.
      • none: Do not include a code linter.
    • formatter:
      • biome: Use Biome as the code formatter. This is the default.
      • prettier: Use Prettier as the code formatter.

    For consistency, the package.json scripts will always include the following scripts:

    • lint: Run the configured linter.
    • lint:fix: Run the configured linter with auto-fix.
    • format: Run the configured formatter.
    • format:check: Run the configured formatter in check mode.
    • check: Run both the linter and formatter in check mode.
    • check:fix: Run both the linter and formatter with auto-fix.
      When the linter is set to none, lint and lint:fix scripts will echo a message indicating that no linter is configured.
  • 3.10.0

  • feat: Generate file upload section in README.md for multipart-form file uploads.

  • 3.9.3

  • fix: Fix a compilation error when a path parameter is nullable or optional.

  • 3.9.2

  • fix: Match the logic in wire test generation where the static example generation omits the request parameter for empty objects when optional.
    This fixes some wire tests that were failing due to mismatched request bodies.

  • fix: Return undefined when passing in undefined to toJson when useBigInt is enabled.

  • 3.9.1

  • fix: Improve the performance of JSON serialization and parsing when useBigInt is enabled.

  • 3.9.0

  • feat: Add support for the Uploadable.FromPath and Uploadable.WithMetadata types to upload files with metadata to multipart-form endpoints.

    Users can configure metadata when uploading a file to a multipart-form upload endpoint using the Uploadable.WithMetadata type:

    import { createReadStream } from "fs";
    
    await client.upload({
        file: {
          data: createReadStream("path/to/file"),
          filename: "my-file",
          contentType: "audio/mpeg",
        },
        otherField: "other value",
    });

    The filename, contentType, and contentLength properties are optional.

    Alternatively, users can use the Uploadable.FromPath type to upload directly from a file path:

    await client.upload({
        file: {
            path: "path/to/file",
            filename: "my-file",
            contentType: "audio/mpeg",
        },
        otherField: "other value",
    });

    The metadata is used to set the Content-Type and Content-Disposition headers. If not provided, the client will attempt to determine them automatically.

    
    </li>
    	
    <strong><code>3.8.0</code></strong>
    <li>
    
    <code>feat:</code> Use Biome for formatting instead of Prettier, and also use Biome to check (fix) the generated code.
    
    </li>
    	
    <strong><code>3.7.3</code></strong>
    <li>
    
    <code>fix:</code> Fix default request parameter value unwrapping for `nullable<>`.
    
    </li>
    	
    <strong><code>3.7.2</code></strong>
    <li>
    
    <code>fix:</code> Include `extra-properties` (aka. `additionalProperties`) when generating examples for objects and inlined request bodies.
    
    </li>
    
    <li>
    
    <code>fix:</code> Allow arbitrary properties in inlined request bodies when `extra-properties` (aka. `additionalProperties`) is set to true.
    
    </li>
    	
    <strong><code>3.7.1</code></strong>
    <li>
    
    <code>fix:</code> Filter out `undefined` from lists, maps, sets, and object properties when generating examples.
    
    </li>
    
    <li>
    
    <code>fix:</code> Restore missing test scripts in package.json when using `useLegacyExports: true`.
    
    </li>
    	
    <strong><code>3.7.0</code></strong>
    <li>
    
    <code>feat:</code> Generate a `BaseClientOptions`, `BaseRequestOptions`, and `BaseIdempotentRequestOptions` interface and extend from these in the generated client `Options`, `RequestOptions`, and `IdempotentRequestOptions` interfaces.
    This reduces a large amount of duplicate code in the generated SDK.
    
    </li>
    	
    <strong><code>3.6.1</code></strong>
    <li>
    
    <code>fix:</code> Add missing test scripts when `bundle: true`.
    
    </li>
    	
    <strong><code>3.6.0</code></strong>
    <li>
    
    <code>feat:</code> Allow for configuring `timeoutMs` and `maxRetries` request options at the client-level as well as the request level.
    
    </li>
    	
    <strong><code>3.5.0</code></strong>
    <li>
    
    <code>feat:</code> Enable `verbatimModuleSyntax` in _tsconfig.esm.json_ to increase TypeScript performance for the ESM build (not CJS).
    You may need to update your custom TypeScript code to comply with this setting.
    
    </li>
    </details></ul>
    </dd>
    </dl>
    

local-fern-autopilot bot and others added 12 commits November 12, 2025 17:36
…23)

Co-authored-by: local-fern-autopilot[bot] <243617323+local-fern-autopilot[bot]@users.noreply.github.com>
…30)

Co-authored-by: development-fern-autopilot[bot] <239652995+development-fern-autopilot[bot]@users.noreply.github.com>
)

Co-authored-by: development-fern-autopilot[bot] <239652995+development-fern-autopilot[bot]@users.noreply.github.com>
)

Co-authored-by: development-fern-autopilot[bot] <239652995+development-fern-autopilot[bot]@users.noreply.github.com>
)

Co-authored-by: development-fern-autopilot[bot] <239652995+development-fern-autopilot[bot]@users.noreply.github.com>
)

Co-authored-by: development-fern-autopilot[bot] <239652995+development-fern-autopilot[bot]@users.noreply.github.com>
Co-authored-by: fern-bot[bot] <2280197+fern-bot[bot]@users.noreply.github.com>
@github-actions
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants