Testing ralph-starter Integrations
This guide walks you through testing ralph-starter features and setting up integrations.
Configuring API Keys
You have two options for storing API keys:
Option 1: Environment Variables (Recommended)
Set environment variables in your shell profile (~/.bashrc, ~/.zshrc) or a .env file:
export LINEAR_API_KEY=lin_api_xxxxx
export NOTION_API_KEY=secret_xxxxx
export GITHUB_TOKEN=ghp_xxxxx
Option 2: Config Command
ralph-starter config set linear.apiKey your_api_key
Environment variables take precedence over the config file. This is useful for CI/CD or when you want different keys per project.
Quick Start Testing (No API Keys)
You can test many features without any API keys:
1. Test the Interactive Wizard
ralph-starter
This launches the wizard - follow the prompts to describe a project and see the AI refinement flow.
2. Test Idea Mode
ralph-starter ideas
Choose a discovery method and see AI-generated project ideas.
3. Test with Public URLs
Fetch specs from any public markdown or HTML page:
# Public GitHub raw file
ralph-starter run --from https://raw.githubusercontent.com/rubenmarcus/ralph-starter/main/README.md
# Public gist
ralph-starter run --from https://gist.githubusercontent.com/user/id/raw/spec.md
# Any public webpage
ralph-starter run --from https://example.com/docs/feature-spec
4. Test with Local Files
# Create a simple spec
echo "Build a counter app with React that increments and decrements" > test-spec.md
# Run with local file
ralph-starter run --from ./test-spec.md
5. Test with PDF Files
# If you have a PDF spec
ralph-starter run --from ./requirements.pdf
GitHub Integration (No API Key Usually Needed)
GitHub uses the gh CLI, which doesn't require a separate API key if you're logged in.
Setup
# Install GitHub CLI (if not installed)
# macOS
brew install gh
# Linux
sudo apt install gh
# Windows
winget install GitHub.cli
Authenticate
gh auth login
# Follow prompts to authenticate via browser
Test Connection
ralph-starter source test github
Test Fetching Issues
# Preview issues from any public repo
ralph-starter source preview github --project rubenmarcus/ralph-starter --limit 5
# Run with a public repo
ralph-starter run --from github --project rubenmarcus/ralph-starter --label "enhancement"
Alternative: Personal Access Token
If you prefer not to use gh:
- Go to GitHub Settings > Developer settings > Personal access tokens
- Click "Generate new token (classic)"
- Select scopes:
repo(or justpublic_repofor public repos) - Copy the token
ralph-starter config set github.token ghp_xxxxxxxxxxxx
ralph-starter source test github
Linear Integration
Get Your API Key
- Go to linear.app/settings/api
- Click "Create key" under "Personal API keys"
- Name it "ralph-starter"
- Copy the key (starts with
lin_api_)
Configure
ralph-starter config set linear.apiKey lin_api_xxxxxxxxxxxx
Test Connection
ralph-starter source test linear
Test Fetching Issues
# Preview issues
ralph-starter source preview linear --limit 5
# Filter by label
ralph-starter source preview linear --label "bug" --limit 3
# Filter by project
ralph-starter source preview linear --project "My Project"
Create a Test Issue
In Linear:
- Create a new issue with detailed description
- Add a label like "ralph-test"
ralph-starter run --from linear --label "ralph-test"
Notion Integration
Notion requires a few more steps because you need to create an integration and share pages with it.
1. Create an Integration
- Go to notion.so/my-integrations
- Click "New integration"
- Fill in:
- Name: "ralph-starter"
- Associated workspace: Select your workspace
- Capabilities: Read content, Read user information
- Click "Submit"
- Copy the "Internal Integration Secret" (starts with
secret_)
2. Configure ralph-starter
ralph-starter config set notion.token secret_xxxxxxxxxxxx
3. Share Pages with the Integration
This step is required! Notion integrations can only access pages explicitly shared with them.
- Open the Notion page or database you want to use
- Click the "..." menu in the top right
- Click "Add connections"
- Search for "ralph-starter" and select it
- Click "Confirm"
Test Connection
ralph-starter source test notion
Test Fetching Pages
# Preview pages from a database
ralph-starter source preview notion --project "My Database Name" --limit 5
Create a Test Page
- Create a new page in a database shared with ralph-starter
- Add content like:
Build a simple blog with Next.js
Features:
- List blog posts
- View single post
- Markdown support - Fetch it:
ralph-starter run --from notion --project "Your Database Name" --limit 1
Verifying Your Setup
Check All Sources
# List available sources
ralph-starter source list
# Test each configured source
ralph-starter source test github
ralph-starter source test linear
ralph-starter source test notion
View Current Config
ralph-starter config list
Check Specific Config
ralph-starter config get linear
ralph-starter config get notion
ralph-starter config get github
Troubleshooting
"Source test failed"
- Verify your API key is correct
- Check the key hasn't expired
- Ensure you have the right permissions
# Re-enter the API key
ralph-starter config set linear.apiKey <new-key>
"No items found"
- For Linear: Make sure you have issues matching your filter
- For Notion: Ensure the page/database is shared with your integration
- For GitHub: Check the repo exists and you have access
"Authentication failed" for Notion
Notion is strict about sharing. Make sure:
- The integration exists in your workspace
- You've clicked "Add connections" on the specific page/database
- You've refreshed the page after adding the connection
Config file location
All credentials are stored in:
~/.ralph-starter/sources.json
You can manually edit this file if needed.
Security Notes
- API keys are stored locally in
~/.ralph-starter/sources.json - Never commit this file to version control
- Use read-only tokens when possible
- Revoke unused tokens periodically
Removing Credentials
# Remove a specific key
ralph-starter config delete linear.apiKey
# Remove all config for a source
ralph-starter config delete linear
Testing the Full Workflow
Once integrations are set up, test the full workflow:
# 1. Initialize a new project
mkdir test-project && cd test-project
git init
# 2. Fetch a spec from your favorite source
ralph-starter run --from linear --label "ralph-test" --commit
# 3. Watch the magic happen!
Or use the wizard:
ralph-starter
# Follow prompts...