Kiwi

Kiwi for CircleCI

Report check results from CircleCI to a run's Verify step with a checker key.

  • Posts named check results over HTTP with a checker key. The key can report only the checks you choose in one project.
  • Checks reserved for CI accept results only from a checker key.
  • Records each result against the candidate under review. A pass counts toward Verify; a fail means the run needs rework.
  • Records a retried report once.
  • Kiwi does not start pipelines or read their logs. It records the results your pipeline sends.

Set up

Store your checker key as a project environment variable named KIWI_CHECKER_KEY and add report-kiwi-check.sh from the setup guide to your repository.

This .circleci/config.yml runs your tests, then reports the tests-pass check as pass or fail:

version: 2.1

parameters:
  kiwi_run_id:
    type: string
    default: ""

jobs:
  test:
    docker:
      - image: cimg/node:22.23
    environment:
      KIWI_RUN_ID: << pipeline.parameters.kiwi_run_id >>
    steps:
      - checkout
      - run: sudo apt-get update && sudo apt-get install -y uuid-runtime
      - run: npm ci && npm test
      - run:
          when: on_fail
          command: ./report-kiwi-check.sh tests-pass fail "$CIRCLE_BUILD_URL"
      - run:
          when: on_success
          command: ./report-kiwi-check.sh tests-pass pass "$CIRCLE_BUILD_URL"

workflows:
  kiwi:
    when: << pipeline.parameters.kiwi_run_id >>
    jobs:
      - test

Trigger a pipeline with the kiwi_run_id parameter set to the Kiwi run ID.

Replace tests-pass with the check ID from your plan.