Documentation
Agents and automation

Set up Review Router from an AI coding session

An agent declares the connection. One person signs in to lock the exact plan. GitHub and Slack credentials never pass through the agent.

Fastest path: GitHub Action

Add this workflow to the repository that you want to route. The Action uses GitHub Actions OIDC to prove where it ran, creates an inert setup session, masks the machine token, and puts the human authorization link in the job summary. The link contains no claim secret and is bound to the GitHub actor who started the workflow, so it remains safe in a public repository.

name: Set up Review Router

on:
  workflow_dispatch:

permissions:
  contents: read
  id-token: write

jobs:
  setup:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v7
      - uses: Patrax/review-router-setup@v1
        with:
          slack-channel: pull-requests
          preset: repo-watch
          reviewer-mentions: all

OIDC proves the workflow repository. It does not authorize GitHub App installation, Slack OAuth, or a Review Router route.

Optional config as code

Commit .tenpace/review-router.yml so coding agents and teammates can discover the intended route. Explicit Action inputs override the file.

version: 1
route:
  slack-channel: pull-requests
  preset: repo-watch
  reviewer-mentions: all

Direct REST API

Any LLM, CLI, or automation can create a rate-limited proposal. Use an idempotency key for one logical request.

curl --request POST https://api.tenpace.com/v1/review-router/setup-sessions \
  --header 'Content-Type: application/json' \
  --header 'Idempotency-Key: your-stable-request-key' \
  --data '{
    "source": "cli",
    "intent": {
      "repository": "OWNER/REPOSITORY",
      "slackChannel": "pull-requests",
      "preset": "repo_watch",
      "reviewerMentions": "all"
    }
  }'

The creation response contains three values:

  • setupUrl — send this to the human. For direct API, CLI, and MCP sessions, its claim secret is in the URL fragment, so it is not included in HTTP requests or ordinary server logs. GitHub Action links instead contain no secret and are bound to the OIDC actor.
  • agentToken — a secret used to monitor, edit the proposal before claim, apply the locked plan, and request the real delivery test.
  • id — the public setup-session identifier.

Every status response includes a structured plan, humanAction, connection readiness, and result. Apply and test operations are idempotent.

The authorization boundary

  1. A machine creates a proposed intent with no provider authority.
  2. A Tenpace user signs in and claims the short-lived browser link. Action links additionally require the GitHub account that started the workflow. Claiming atomically locks the current intent version.
  3. After claim, the machine token cannot edit. The person who claimed the setup can edit it; saving creates and locks the new version in the same action.
  4. GitHub and Slack OAuth happen in the human browser; tokens are encrypted server-side.
  5. Tenpace creates a missing public Slack channel when authorized, reconciles the route, and posts one real verification message. Private channels require an app invite.

MCP tools

Connect an MCP client to https://api.tenpace.com/mcp. The facade exposes the same domain service and security boundary as REST:

  • start_review_router_setup
  • get_review_router_setup_status
  • preview_review_router_setup
  • apply_review_router_setup
  • send_review_router_test

Machine-readable discovery

No single AI-discovery convention is universal. The same contract is published as linked HTML, Markdown, OpenAPI, llms files, Action metadata, a README, and AGENTS.md so retrieval does not depend on one crawler convention.