Config is used for authentication for Git operations.
| 55 | |
| 56 | // Config is used for authentication for Git operations. |
| 57 | type Config struct { |
| 58 | promoauth.InstrumentedOAuth2Config |
| 59 | // ID is a unique identifier for the authenticator. |
| 60 | ID string |
| 61 | // Type is the type of provider. |
| 62 | Type string |
| 63 | |
| 64 | ClientID string |
| 65 | ClientSecret string |
| 66 | // DeviceAuth is set if the provider uses the device flow. |
| 67 | DeviceAuth *DeviceAuth |
| 68 | // DisplayName is the name of the provider to display to the user. |
| 69 | DisplayName string |
| 70 | // DisplayIcon is the path to an image that will be displayed to the user. |
| 71 | DisplayIcon string |
| 72 | |
| 73 | // ExtraTokenKeys is a list of extra properties to |
| 74 | // store in the database returned from the token endpoint. |
| 75 | // |
| 76 | // e.g. Slack returns `authed_user` in the token which is |
| 77 | // a payload that contains information about the authenticated |
| 78 | // user. |
| 79 | ExtraTokenKeys []string |
| 80 | |
| 81 | // NoRefresh stops Coder from using the refresh token |
| 82 | // to renew the access token. |
| 83 | // |
| 84 | // Some organizations have security policies that require |
| 85 | // re-authentication for every token. |
| 86 | NoRefresh bool |
| 87 | // ValidateURL ensures an access token is valid before |
| 88 | // returning it to the user. If omitted, tokens will |
| 89 | // not be validated before being returned. |
| 90 | ValidateURL string |
| 91 | |
| 92 | RevokeURL string |
| 93 | RevokeTimeout time.Duration |
| 94 | |
| 95 | // Regex is a Regexp matched against URLs for |
| 96 | // a Git clone. e.g. "Username for 'https://github.com':" |
| 97 | // The regex would be `github\.com`.. |
| 98 | Regex *regexp.Regexp |
| 99 | // APIBaseURL is the base URL for provider REST API calls |
| 100 | // (e.g., "https://api.github.com" for GitHub). Derived from |
| 101 | // defaults when not explicitly configured. |
| 102 | APIBaseURL string |
| 103 | // AppInstallURL is for GitHub App's (and hopefully others eventually) |
| 104 | // to provide a link to install the app. There's installation |
| 105 | // of the application, and user authentication. It's possible |
| 106 | // for the user to authenticate but the application to not. |
| 107 | AppInstallURL string |
| 108 | // AppInstallationsURL is an API endpoint that returns a list of |
| 109 | // installations for the user. This is used for GitHub Apps. |
| 110 | AppInstallationsURL string |
| 111 | // Deprecated: Injected MCP in AI Bridge is deprecated and will be removed in a future release. |
| 112 | // |
| 113 | // MCPURL is the endpoint that clients must use to communicate with the associated |
| 114 | // MCP server. |
nothing calls this directly
no outgoing calls
no test coverage detected