Skip to main content

Prerequisites

1

Get Your API Key

Navigate to your Coval dashboard and generate an API key from Settings.
2

Add GitHub Secret

  1. Go to your repository Settings > Secrets and variables > Actions
  2. Click New repository secret
  3. Name: COVAL_API_KEY
  4. Value: Your Coval API key
3

Gather Required IDs

You’ll need the following identifiers:
  • Agent ID (22 chars): Found in Agents page → Select agent → Copy ID
  • Persona ID (22 chars): Found in Personas page → Select persona → Copy ID
  • Test Set ID (8 chars): Found in Test Sets page → Select test set → Copy ID
  • Metric IDs (22 chars each, optional): Found in Metrics page → Click metric → Copy ID

Quick Start

Automatic PR Checks

Create .github/workflows/coval-eval.yml:

Manual Workflow Dispatch

Create .github/workflows/manual-eval.yml:
To trigger:
  1. Navigate to Actions tab
  2. Select Manual Evaluation
  3. Click Run workflow
  4. Enter your IDs and click Run workflow

Advanced Configuration

Custom Metrics and Options

Using Outputs

Configuration Reference

Inputs

Outputs

Environment Variables

API Details

The action uses the Coval v1 Runs API:

Launch Run

Endpoint: POST https://api.coval.dev/v1/runs Request:
Response:

Monitor Run

Endpoint: GET https://api.coval.dev/v1/runs/{run_id} Response:

Run Statuses

Examples

Environment-Based Testing

Parallel Persona Testing

Scheduled Regression Testing

Troubleshooting

Invalid API Key

Solution: Verify COVAL_API_KEY is set correctly in GitHub Secrets.

Invalid Agent ID

Solution: Confirm the agent ID is 22 characters and exists in your organization.

Validation Errors

Solution: Ensure all parameters meet the constraints listed in the Configuration Reference.

Timeout

Solution: Increase max_wait_time for larger test sets or check the Coval dashboard for run status.

Invalid JSON

Resources