coder/Coder Agents Chat
Run Coder agents from any GitHub workflow. Triage issues, review PRs, or follow up on an existing chat.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Activelast commit Jun 4, 2026
- License
- None
Pinned Snippet
uses: coder/agents-chat-action@b3fc81d7dae5006dd124e98ef6fada1a36cdd86e # v0.3.0tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| chat-prompt | Prompt to send to the agents chat. Templated by the workflow before being passed in. | yes | — |
| coder-token | Coder session token used to authenticate with the Coder API. | yes | — |
| coder-url | Coder deployment URL. | yes | — |
| github-url | GitHub issue or pull request URL to link the chat to. Used for the issue/PR comment and as the human-readable association in the chat label. | yes | — |
| github-token | GitHub token used to post and update issue comments. | yes | — |
| coder-organization | Coder organization name. Looked up by name to resolve the organization UUID for chat creation. Recommended when the Coder user belongs to more than one organization, since the fallback choice is non-deterministic. | no | — |
| workspace-id | Existing workspace ID to pin the chat to. If unset, Agents auto-provisions a workspace. | no | — |
| model-config-id | Model configuration ID to use for the chat. | no | — |
| existing-chat-id | Existing chat ID to send a follow-up message to instead of creating a new chat. Mutually exclusive with force-new-chat. | no | — |
| comment-on-issue | Whether to comment on the GitHub issue or pull request with the chat URL and status. | no | true |
| wait | Wait mode. 'none' (default) returns immediately after creating the chat or sending the message. 'complete' polls every 5 seconds until the chat reaches a terminal status (waiting, completed, error) or wait-timeout-seconds elapses. | no | none |
| wait-timeout-seconds | Maximum seconds to wait when wait=complete before failing with a timeout. | no | 600 |
| idempotency-key | Optional sharding key to narrow the default reuse scope. By default the action reuses the most recent non-archived chat scoped to `gh-target` and the workflow name (when `GITHUB_WORKFLOW` is set). All chats are owned by the `coder-token` holder, so the scope does not include a per-actor component. Set this to maintain multiple parallel chats on the same target/workflow (for example, one per matrix dimension). Pass the `github.actor` context value to maintain one chat per triggering user. | no | — |
| force-new-chat | Always create a new chat instead of reusing the most recent matching chat. Mutually exclusive with existing-chat-id. | no | false |
Outputs
| name | description |
|---|---|
| coder-username | The Coder username the `coder-token` belongs to (always the chat owner; the chats API has no owner override). |
| chat-id | The chat ID. |
| chat-url | The URL to view the chat in Coder. |
| chat-created | Whether the chat was newly created (true) or a message was sent to an existing chat (false). |
| chat-status | Current chat status (waiting, pending, running, paused, completed, error). |
| chat-title | The chat title. |
| workspace-id | The workspace ID the chat is running in (auto-provisioned or provided). |
| pull-request-url | URL of the pull request or branch page when the chat has tracked changes. |
| pull-request-state | Pull request state (open, closed, merged) when available. |
| pull-request-title | Title of the pull request when available. |
| pull-request-number | Pull request number when available. |
| diff-additions | Number of lines added in tracked changes. |
| diff-deletions | Number of lines deleted in tracked changes. |
| diff-changed-files | Number of files changed in tracked changes. |
| head-branch | Head branch name when available. |
| base-branch | Base branch name when available. |
| chat-error-kind | Machine-readable error kind when the chat fails (one of `spend_exceeded`, `org_not_found`, `api_error`, `timeout`). |
| chat-error-message | Human-readable error message when the chat fails. |