Settings

Manage API keys, webhooks, CI/CD integration, and account preferences.

Select Project

Choose a project to view or manage its credentials.

Select a project above to manage its API key and webhooks.

GitHub Actions

Add this step to your workflow YAML to run a code review on every push.

- name: Checkout code
  uses: actions/checkout@v4

- name: Sanchan Code Review
  run: |
    curl -s -X POST https://codereview.sanchaninfo.com/ci/review \
      -H "x-api-key: ${{ secrets.SANCHAN_API_KEY }}" \
      -H "Content-Type: application/json" \
      -d '{
        "gitUrl": "${{ github.event.repository.html_url }}",
        "branch": "${{ github.ref_name }}",
        "commit": "${{ github.sha }}"
      }' | tee /tmp/sanchan-result.json
    cat /tmp/sanchan-result.json
Add SANCHAN_API_KEY to your repository secrets under Settings → Secrets and variables → Actions.

GitLab CI/CD

Add this job to your .gitlab-ci.yml.

sanchan-review:
  stage: test
  image: curlimages/curl:latest
  script:
    - |
      curl -s -X POST https://codereview.sanchaninfo.com/ci/review \
        -H "x-api-key: $SANCHAN_API_KEY" \
        -H "Content-Type: application/json" \
        -d "{
          \"gitUrl\": \"$CI_PROJECT_URL\",
          \"branch\": \"$CI_COMMIT_REF_NAME\",
          \"commit\": \"$CI_COMMIT_SHA\"
        }" | tee sanchan-result.json
    - cat sanchan-result.json
  artifacts:
    paths:
      - sanchan-result.json
    expire_in: 7 days
Set SANCHAN_API_KEY as a CI/CD variable in Settings → CI/CD → Variables.

Suppressing Issues

Suppress a specific line from being flagged in future reviews.

1

Add a suppression comment on the line above the issue

// sanchan-ignore
const password = process.env.DB_PASS;
2

Suppress with a reason (recommended)

// sanchan-ignore: intentional use of eval for template rendering
eval(templateString);
Suppressed lines are tracked and visible in the review report with an Ignored badge. They still count toward your total line count but are excluded from scoring.

Quality Gate

Automatically fail a CI build when code quality falls below your threshold.

The /ci/review endpoint returns a JSON response with a passed boolean and a score number (0–100). Exit with a non-zero code to fail the pipeline:
#!/bin/bash
RESULT=$(curl -s -X POST https://codereview.sanchaninfo.com/ci/review \
  -H "x-api-key: $SANCHAN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"gitUrl":"'"$REPO_URL"'"}')

SCORE=$(echo "$RESULT" | python3 -c "import sys,json; print(json.load(sys.stdin)['score'])")
PASSED=$(echo "$RESULT" | python3 -c "import sys,json; print(json.load(sys.stdin)['passed'])")

echo "Sanchan score: $SCORE"

if [ "$PASSED" != "True" ]; then
  echo "Quality gate FAILED (score: $SCORE, minimum: 70)"
  exit 1
fi
echo "Quality gate PASSED"
The default passing threshold is 70 / 100. Contact your admin to adjust the threshold per-project.

Account Information

Your identity is managed by your administrator. Contact them to update your name or email.

Name
Email
Role
Projects

Change Password

Choose a strong password with at least 8 characters, one uppercase letter, and one number.