Skip to content

Use --key/BENCHER_API_KEY instead of deprecated --token#7

Merged
epompeii merged 1 commit into
mainfrom
api-token-to-key
Jun 16, 2026
Merged

Use --key/BENCHER_API_KEY instead of deprecated --token#7
epompeii merged 1 commit into
mainfrom
api-token-to-key

Conversation

@epompeii

Copy link
Copy Markdown
Member

Summary

Bencher deprecated user API tokens in favor of API keys (bencherdev/bencher#897), which is now deployed and released. This updates the example workflows to match the released convention.

  • Swap --token '${{ secrets.BENCHER_API_TOKEN }}'--key '${{ secrets.BENCHER_API_KEY }}' in all 5 authenticating workflows (bencher run / bencher archive):
    • base_benchmarks.yml
    • fork_pr_benchmarks_closed.yml
    • fork_pr_benchmarks_track.yml
    • pr_benchmarks.yml
    • pr_benchmarks_closed.yml
  • Restore the missing line-continuation backslash on the --branch "$GITHUB_HEAD_REF" line in pr_benchmarks.yml so the command matches the canonical docs (pre-existing bug, not part of #897).

Verified the exact flag/secret convention against both the #897 diff and the live docs at https://bencher.dev/docs/how-to/github-actions/.

Action required after merge

The secret name changed, so the workflows now reference secrets.BENCHER_API_KEY. Add a BENCHER_API_KEY repository secret (a project API key bencher_run_* is sufficient, since each workflow sets --project example). The old BENCHER_API_TOKEN secret can then be removed.

🤖 Generated with Claude Code

Bencher deprecated user API tokens in favor of API keys
(bencherdev/bencher#897). Update all authenticating workflows to pass
the credential via the --key option and the BENCHER_API_KEY secret.

Also restore the missing line-continuation backslash on the --branch
line in pr_benchmarks.yml so the bencher run command matches the
canonical docs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

🐰 Bencher Report

Branchapi-token-to-key
Testbedubuntu-latest
Click to view all benchmark results
BenchmarkLatencyBenchmark Result
nanoseconds (ns)
(Result Δ%)
Upper Boundary
nanoseconds (ns)
(Limit %)
bencher::mock_0📈 view plot
🚷 view threshold
3.14 ns
(-38.92%)Baseline: 5.15 ns
11.38 ns
(27.63%)
bencher::mock_1📈 view plot
🚷 view threshold
10.86 ns
(-30.35%)Baseline: 15.59 ns
22.18 ns
(48.95%)
bencher::mock_2📈 view plot
🚷 view threshold
20.21 ns
(-16.39%)Baseline: 24.17 ns
30.79 ns
(65.64%)
bencher::mock_3📈 view plot
🚷 view threshold
36.23 ns
(+5.02%)Baseline: 34.49 ns
42.17 ns
(85.91%)
bencher::mock_4📈 view plot
🚷 view threshold
44.51 ns
(-0.08%)Baseline: 44.54 ns
50.99 ns
(87.30%)
🐰 View full continuous benchmarking report in Bencher

@github-actions

Copy link
Copy Markdown

🐰 Bencher Report

Branchfork/api-token-to-key
Testbedubuntu-latest
Click to view all benchmark results
BenchmarkLatencyBenchmark Result
nanoseconds (ns)
(Result Δ%)
Upper Boundary
nanoseconds (ns)
(Limit %)
bencher::mock_0📈 view plot
🚷 view threshold
1.00 ns
(-80.57%)Baseline: 5.15 ns
11.38 ns
(8.79%)
🐰 View full continuous benchmarking report in Bencher

@epompeii epompeii merged commit 6ff8ccd into main Jun 16, 2026
2 checks passed
@epompeii epompeii self-assigned this Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant