Forward native runner credentials and publication policy#121
Merged
Conversation
This was referenced Jul 13, 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
OPENAI_API_KEYto WP Codebox; fail closed before a live OpenAI run when it is absent, while allowing explicitrun_agent: falseanddry_run: truepaths.ACCESS_TOKENsecret with the caller-scoped${{ github.token }}for same-repository target checkout and publication. The reusable job declarescontents: write,pull-requests: write, andissues: write.success_requires_prplus the bounded publication projection.EXTERNAL_PACKAGE_SOURCE_POLICYrequired and separate.Related
Secret setup
OPENAI_API_KEYin a consumer repository for liverun_agent: trueOpenAI runs. It is optional for explicit skipped and dry-run calls.EXTERNAL_PACKAGE_SOURCE_POLICYrepository secret to the documented v1 package allowlist.ACCESS_TOKENmappings. Same-repository publication uses the caller workflowGITHUB_TOKEN; callers grantcontents: write,pull-requests: write, andissues: write.Compatibility impact
ACCESS_TOKENsecret and must mapOPENAI_API_KEYfor live OpenAI execution.How to test
php tests/validate-docs-agent-bundle.php.php tests/validate-external-native-package-sources.php.54c2f9a7bc3cd1fe20055d496c83efcfb99afb41and runWP_CODEBOX_DIR=/path/to/wp-codebox php tests/validate-wp-codebox-run-agent-task-contract.php.AGENTS_API_DIR=/path/to/agents-api php tests/native-agent-import.php.php tests/repair-docs-links-smoke.php,actionlint -config-file .github/actionlint.yaml .github/workflows/*.yml, andgit diff --check.AI assistance