CodeRifts for GitLab — Coming Soon
Native GitLab integration is on our roadmap — automatic merge request comments with breaking change detection, risk scoring, and policy enforcement. In the meantime, the CodeRifts REST API works in any GitLab CI pipeline today.
Use CodeRifts in GitLab CI Today
While native GitLab integration is in development, you can use the REST API in your .gitlab-ci.yml to get the same analysis on every merge request.
# .gitlab-ci.yml
stages:
- test
api-contract-check:
stage: test
image: curlimages/curl:latest
variables:
CODERIFTS_API_KEY: $CODERIFTS_API_KEY
script:
- |
RESULT=$(curl -sf -X POST \
https://app.coderifts.com/api/diff \
-H "Authorization: Bearer $CODERIFTS_API_KEY" \
-H "Content-Type: application/json" \
-d "{
\"base\": \"$CI_MERGE_REQUEST_TARGET_BRANCH_NAME:api/openapi.yaml\",
\"head\": \"api/openapi.yaml\"
}")
echo "$RESULT" | python3 -m json.tool
# Fail if breaking changes detected
BREAKING=$(echo "$RESULT" | python3 -c \
"import sys,json; print(json.load(sys.stdin).get('summary',{}).get('breaking',0))")
if [ "$BREAKING" -gt 0 ]; then
echo "ERROR: $BREAKING breaking change(s) detected"
exit 1
fi
rules:
- if: $CI_MERGE_REQUEST_IID
changes:
- "api/**/*.yaml"
- "api/**/*.json"
Set CODERIFTS_API_KEY in GitLab CI/CD variables. Get a free API key →
What Native GitLab Integration Will Include
The same features you get with the GitHub App — but native to GitLab.
MR Comments
Automatic merge request comments with breaking changes, risk score, and policy violations.
Zero Config
Auto-detect OpenAPI specs. No .gitlab-ci.yml changes needed.
Pipeline Status
Block merges when breaking changes are detected via pipeline status checks.
Self-Hosted Support
Support for GitLab self-hosted instances on Enterprise plans.
Get notified when GitLab support launches.
We'll send one email when it's ready. No spam.
Don't wait — protect your APIs today.
The REST API works in any CI pipeline. Get your free API key and start catching breaking changes in GitLab CI right now.