Installation & Setup
Install the monday_ruby gem and configure your development environment.
Requirements
- Ruby 2.7 or higher
- A monday.com account
- A monday.com API token
Check your Ruby version:
ruby -v
Install the Gem
gem install monday_ruby
Then run bundle install if using Bundler, or verify with gem list monday_ruby.
Get Your API Token
- Log in to your monday.com account
- Click your profile picture in the top-right corner
- Select Administration
- Go to the Connections section
- Select Personal API token in the sidebar
- Copy your token
Configure the Client
Option 1: Environment Variables (Recommended)
Create a .env file in your project root:
MONDAY_TOKEN=your_token_here
Load it in your application:
require "monday_ruby"
require "dotenv/load"
Monday.configure do |config|
config.token = ENV["MONDAY_TOKEN"]
end
Install the dotenv gem:
gem install dotenv
Or add to your Gemfile:
gem 'dotenv'
Option 2: Direct Configuration
Configure globally:
require "monday_ruby"
Monday.configure do |config|
config.token = "your_token_here"
end
Security
Never commit API tokens to version control. Always use environment variables or secure credential storage.
Option 3: Per-Client Configuration
Pass token when creating the client:
client = Monday::Client.new(token: "your_token_here")
Verify Setup
Test your configuration:
require "monday_ruby"
Monday.configure do |config|
config.token = ENV["MONDAY_TOKEN"]
end
client = Monday::Client.new
response = client.boards
if response.success?
puts "Connected successfully!"
puts "Found #{response.body.dig('data', 'boards').length} boards"
else
puts "Connection failed: #{response.code}"
end
Run this script. If you see “Connected successfully!”, you’re ready to go.
Configuration Options
Advanced configuration options
API Version
Specify the monday.com API version:
Monday.configure do |config|
config.token = ENV["MONDAY_TOKEN"]
config.version = "2024-10"
end
Default version: 2024-01
API Host
Override the API endpoint (rarely needed):
Monday.configure do |config|
config.token = ENV["MONDAY_TOKEN"]
config.host = "https://api.monday.com/v2"
end
Edit this page
Last updated
Was this page helpful?
Thanks for your feedback!