Integration

Local Integration

Integrate Raiken with your local development workflow using the bridge server for seamless file system access and test management.

Bridge Server Architecture

How Raiken connects your web interface with your local file system

Raiken uses a local bridge server to connect the web interface with your project files. This allows you to generate tests in the browser and save them directly to your project.

Web Interface

localhost:3001

Bridge Server

File system access

Your Project

Local files

Prerequisites

Before setting up local integration

Before you start: Complete the CLI Setup guide to install and configure Raiken.

This guide assumes you have Raiken CLI installed and your OpenRouter API key configured.

Development Workflow

How to integrate Raiken into your daily development process

Typical Workflow

  1. Start your application development server
  2. Run raiken start in your project directory
  3. Develop features in your preferred editor
  4. Generate tests using Raiken's web interface
  5. Tests are automatically saved to your project
  6. Run tests using npx playwright test or your preferred test runner

File System Access

  • Read project structure
  • Save generated tests
  • Update existing tests
  • Read configuration files

Real-time Features

  • Live test execution
  • File change detection
  • Project auto-discovery
  • Test result streaming

File Management

How Raiken manages test files in your project

Default File Structure

Raiken creates and organizes test files based on your project structure:

your-project/
├── tests/
│ ├── auth/
│ │ ├── login.spec.ts
│ │ └── registration.spec.ts
│ ├── components/
│ │ ├── header.spec.ts
│ │ └── footer.spec.ts
│ └── e2e/
│ └── user-journey.spec.ts
├── generated-tests/
│ └── # AI-generated tests
└── raiken.config.js

File Operations

✅ Supported Operations
  • • Create new test files
  • • Update existing tests
  • • Organize tests by feature
  • • Auto-generate file names
  • • Backup existing files
🔒 Safety Features
  • • Never overwrites without confirmation
  • • Creates backups before changes
  • • Validates file permissions
  • • Respects .gitignore patterns
  • • Atomic file operations

Security & Permissions

Understanding security implications and file access permissions

Local Access Only

The bridge server only accepts connections from localhost (127.0.0.1) and cannot be accessed from external networks.

Security Features

  • Localhost-only binding
  • Project directory sandboxing
  • File operation validation
  • No external network access

Required Permissions

  • Read project files
  • Write to test directories
  • Execute test commands
  • Create configuration files

Advanced Integration Features

Powerful features for enhanced development workflow

Hot Reload Integration

Raiken can detect when your application restarts and automatically reconnect.

# Auto-reconnect on app restart
raiken start --watch

CI/CD Integration

Run generated tests in your CI/CD pipeline using standard test runners.

# Run tests in CI
npx playwright test

Multi-Project Support

Switch between different projects without restarting the bridge server.

cd /path/to/other/project && raiken start

Test Execution

Execute tests directly from the web interface with real-time results.

npx playwright test --headed --debug

Troubleshooting

Common issues and solutions for local integration

Bridge Server Won't Start

  • • Check if port 3001 is already in use
  • • Ensure you have write permissions in the project directory
  • • Try running with admin/sudo privileges if needed
  • • Check for firewall or antivirus blocking the connection

File Permissions Issues

  • • Ensure the test directory is writable
  • • Check if files are locked by other processes
  • • Verify you have permission to create new files

Application Not Detected

  • • Ensure your app is running on the expected port
  • • Check if the app URL is accessible from localhost
  • • Manually specify the app port: raiken start --app-port 3000

Next Steps

Ready to start using Raiken with your local development workflow?