Repository navigation
Accept bearer tokens in TEAMWORK_API_TOKEN - #81
Merged
Merged
Conversation
A token that starts with "tkn." goes in a Bearer header, read by curl from stdin so it stays out of the process list. Other values still use basic auth. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
seanogdev
approved these changes
Nov 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
TEAMWORK_API_TOKENnow also accepts a bearer token. A value that starts withtkn.goes in anAuthorization: Bearerheader. Other values still use basic auth, so current workflows do not change.Curl reads the bearer header from stdin, so the token does not show in the runner's process list. The README links to the authentication guide, which tells how to get a token.
Evidence
The mock Teamwork API now also accepts
Bearer tkn.test-token. There are two new cases:bearer-token:INPUT_TEAMWORK_API_TOKEN=tkn.test-token→GET /tasks/1001 -> 200,POST /comments -> 201, exit 0wrong-bearer-token:INPUT_TEAMWORK_API_TOKEN=tkn.wrong-token→GET /tasks/1001 -> 401, exit 1Before: a
tkn.token goes as basic auth → 401After:
tests/run.sh→All 24 case(s) passedMerge Danger
Door: two-way
To revert, revert the commit. Nothing is stored or migrated.
Blast Radius: auth
A value that starts with
tkn.now goes as a bearer token, not with basic auth. If an API key starts withtkn., its requests will fail. This is not probable.