An engineering team is designing how an agent should share state across a GitHub Actions workflow, Copilot CLI session, and Copilot cloud agent context. Match each state-sharing mechanism to the best use. Which mapping is correct?
1. $GITHUB_OUTPUT
2. actions/upload-artifact
3. env at job level
4. MCP server tool access
A. Share variables with steps in the same job
B. Persist files for later jobs in the run
C. Create step outputs for later workflow references
D. Let Copilot use configured external tools
E. Store branch protection decisions permanently
F. Approve all agent tool calls manuallyChoose an answer
Tap an option to check your answer.
Correct answer: 1-C, 2-B, 3-A, 4-D.
Why this is the answer
The correct mapping is 1-C, 2-B, 3-A, 4-D. 1. $GITHUBOUTPUT (1) is used to create step outputs for later workflow references (C). This mechanism allows a step to set variables that can be consumed by subsequent steps or jobs within the same workflow. 2. actions/upload-artifact (2) is designed to persist files for later jobs in the run (B). Artifacts are used to store data generated during a workflow run, making it available for download or use by other jobs, even in different runs. 3. env at the job level (3) is used to share variables with steps in the same job (A). Environment variables defined at the job level are accessible to all steps within that specific job. 4. MCP server tool access (4) allows Copilot to use configured external tools (D). The Copilot CLI and cloud agents can integrate with external tools and services, and this access mechanism enables that interaction. Incorrect options are wrong because they misattribute the primary function of each state-sharing mechanism. For example, $GITHUBOUTPUT is not for persisting files across jobs, nor is env for creating workflow-wide references.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed