MCPcopy Create free account
hub / github.com/github/gh-aw / GetRequiredSecretNames

Method GetRequiredSecretNames

pkg/workflow/pi_engine.go:171–178  ·  view source on GitHub ↗

GetRequiredSecretNames returns the list of secrets required by the Pi engine. When the model uses provider/model format the provider-specific secret is required (e.g. ANTHROPIC_API_KEY for "anthropic/..."); otherwise Pi routes through the Copilot LLM gateway and reuses COPILOT_GITHUB_TOKEN.

(workflowData *WorkflowData)

Source from the content-addressed store, hash-verified

169// (e.g. ANTHROPIC_API_KEY for "anthropic/..."); otherwise Pi routes through the
170// Copilot LLM gateway and reuses COPILOT_GITHUB_TOKEN.
171func (e *PiEngine) GetRequiredSecretNames(workflowData *WorkflowData) []string {
172 piLog.Print("Collecting required secrets for Pi engine")
173 backend := resolvePiBackend(workflowData)
174 profile := getUniversalLLMBackendProfile(backend, hasCopilotRequestsWritePermission(workflowData))
175 secrets := append([]string{}, profile.coreSecretNames...)
176 secrets = append(secrets, collectCommonMCPSecrets(workflowData)...)
177 return secrets
178}
179
180// GetSupportedEnvVarKeys returns the engine.env variable names that the Pi engine
181// supports as defined in the AWF specification. Pi is a multi-provider engine so all

Calls 5

resolvePiBackendFunction · 0.85
collectCommonMCPSecretsFunction · 0.85
PrintMethod · 0.80