MCPcopy
hub / github.com/cli/cli / getCallbackURI

Function getCallbackURI

internal/authflow/flow.go:108–116  ·  view source on GitHub ↗
(oauthHost string)

Source from the content-addressed store, hash-verified

106}
107
108func getCallbackURI(oauthHost string) string {
109 callbackURI := "http://127.0.0.1/callback"
110 if ghauth.IsEnterprise(oauthHost) {
111 // the OAuth app on Enterprise hosts is still registered with a legacy callback URL
112 // see https://github.com/cli/cli/pull/222, https://github.com/cli/cli/pull/650
113 callbackURI = "http://localhost/"
114 }
115 return callbackURI
116}
117
118type cfg struct {
119 token string

Callers 2

AuthFlowFunction · 0.85
Test_getCallbackURIFunction · 0.85

Calls

no outgoing calls

Tested by 1

Test_getCallbackURIFunction · 0.68