Reporter Actions
How RunWatch reporter actions integrate with your CI/CD pipelines to collect and report metrics
Overview
RunWatch provides official reporter actions for GitHub Actions and GitLab CI/CD. These actions automatically collect pipeline and job-level metrics from your CI/CD runs and send them to RunWatch for analysis and visualization.
The reporters use a push model - they collect metrics at the end of your pipeline and send them to RunWatch's ingestion API. This approach minimizes API usage, ensures fast data ingestion, and allows platform-specific aggregation before sending to the backend.
GitHub Actions Reporter
The GitHub Actions reporter is a GitHub Action that collects workflow and job metrics from your GitHub Actions workflows and reports them to RunWatch.
Two Modes:
- Inline Mode: Runs as the final step in your workflow. Simple setup, but cannot report on cancelled workflows.
- External Mode: Runs in a separate workflow triggered when your main workflow completes. Can report on all workflow states including cancelled runs.
Quick Start: Add the action as a final job in your workflow with if: always() to ensure it runs even if previous jobs fail.
GitLab CI/CD Reporter
The GitLab CI/CD reporter is a GitLab CI/CD component that collects pipeline and job metrics from your GitLab pipelines and reports them to RunWatch.
Two Modes:
- Inline Mode: Runs as the final job in your pipeline. Simple setup, but cannot report on cancelled pipelines.
- External Mode: Runs in a separate pipeline triggered when your main pipeline completes. Can report on all pipeline states including cancelled runs.
Quick Start: Include the component in your pipeline and add a report job with when: always to ensure it runs even if previous jobs fail.
Metrics Collected
Both reporters collect comprehensive metrics at the pipeline/workflow and job levels:
Pipeline/Workflow Level:
- Repository name and provider
- Pipeline/workflow ID and name
- Run ID and attempt number
- Status (success, failure, cancelled, etc.)
- Duration and compute time
- Start and completion timestamps
- Trigger source (push, pull request, manual, etc.)
- Branch name
- Triggering actor/user
Job Level:
- Job name and ID
- Job URL (direct link to job logs)
- Status (success, failure, cancelled, etc.)
- Duration in seconds
- Start and completion timestamps
Setup Requirements
1. Get Your API Key
Create an access key in the RunWatch dashboard under Access Keys. This key authenticates your CI/CD pipelines with RunWatch.
2. Add Secret/Variable
- GitHub: Add
RUNWATCH_API_KEYas a repository secret in Settings → Secrets and variables → Actions - GitLab: Add
RUNWATCH_API_KEYas a CI/CD variable in Settings → CI/CD → Variables
3. Add Reporter to Pipeline
Follow the setup instructions in the respective repository README files linked above. Both reporters support inline and external modes for different use cases.
Custom Integration
If you're using a CI/CD platform that doesn't have an official reporter, or you want to send custom metrics, you can use the Ingest API directly. The API accepts the same JSON schema that the reporters send, allowing you to build custom integrations for any CI/CD platform.