Query
AI-generatedSummary
Execute a prompt query using the GitHub Copilot CLI, optionally authenticating with a GitHub token, and receive the command output and related metadata.
Inputs
- Authentication Method — Select whether to use a GitHub token (GH_TOKEN/GITHUB_TOKEN) credential for authentication instead of the local Copilot CLI authentication.
- Prompt (required) — Specify the query or task for the GitHub Copilot CLI as a string prompt. This will be executed with the command: copilot -p "your prompt".
- Tool Approval — Control which tools Copilot can use without manual confirmation, choosing from predefined modes (allow all, shell only, write only, manual, or custom). Manual is default for safety.
- Options — Additional execution options including selecting the AI model (e.g., gpt-4o, claude-3.5-sonnet) and maximum command execution timeout in seconds (default 60).
- Allowed Tools — Specify custom tool approval flags (space-separated) when Tool Approval is set to Custom.
Output shape
a list of JSON items, each containing the inputs (operation, prompt, model, toolApproval, authMethod) plus GitHub Copilot CLI version info, the CLI's output string, any stderr output (optional), and a timestamp
The operation runs the copilot CLI command with specified settings and returns the CLI output. Errors such as missing CLI installation, authentication issues, or command failures are thrown unless 'Continue On Fail' is enabled, in which case error messages are returned as output data items. Authentication can be via local CLI or GitHub token credential. The prompt is mandatory; other inputs are optional with sensible defaults.