Ruby Quickstart
You will learn the following:
- Install
clerk-sdk-ruby
- Configuration
- Instantiate a
Clerk::SDK
instance
Learn how to use Clerk to quickly and easily add secure authentication and user management to your Ruby app. If you would like to use a framework, refer to the integrations.
The Clerk Ruby SDK provides a range of backend utilities to simplify user authentication and management in your application.
- Add the following code to your application's
Gemfile
. - Run the following command to install the SDK:
The configuration object provides a flexible way to configure the SDK. When a configuration value is not explicitly provided, it will fall back to checking the corresponding environment variable. You must provide your Clerk Secret Key, which can be retrieved from the API keys page in the Clerk Dashboard.
The following example shows how to set up your configuration object:
For more information, see Faraday's documentation.
Instantiate a Clerk::SDK
instance
All available methods are listed in the Ruby HTTP Client documentation. The Ruby HTTP Client is a generated wrapper around the Backend API that provides a more Ruby-friendly interface.
To access available methods, you must instantiate a Clerk::SDK
instance.
Ruby SDK Reference
Learn more about the Ruby SDK.
Deploy to Production
Learn how to deploy your Clerk app to production.
Feedback
Last updated on