Adding custom code
This page covers how to add custom logic, methods, and dependencies to your Ruby SDK.
Before getting started, read about how Fern SDKs use custom code and learn about the
.fernignore file.Adding custom logic
To get started adding custom code:
Adding custom SDK methods
Fern also allows you to add custom methods to the SDK itself (e.g.
client.my_method() ) by inheriting the Fern generated client and then
extending it.
Update generators.yml configuration
Name your Fern-generated client something like BaseClient to reflect that this client will be extended.
generators.yml
Adding custom dependencies
Pro and Enterprise feature
This feature is available only for the Pro and Enterprise plans. To get started, reach out to support@buildwithfern.com.
To add gems that your custom code requires, update your generators.yml.
generators.yml