1. Packages
  2. Dex Provider
  3. API Docs
  4. resources
  5. GitHubConnector
Dex v0.8.0 published on Thursday, Feb 19, 2026 by Kotaicode GmbH
dex logo
Dex v0.8.0 published on Thursday, Feb 19, 2026 by Kotaicode GmbH

    Manages a GitHub connector in Dex. This connector allows users to authenticate using their GitHub accounts and supports organization and team-based access control.

    Create GitHubConnector Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new GitHubConnector(name: string, args: GitHubConnectorArgs, opts?: CustomResourceOptions);
    @overload
    def GitHubConnector(resource_name: str,
                        args: GitHubConnectorArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def GitHubConnector(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        client_id: Optional[str] = None,
                        client_secret: Optional[str] = None,
                        connector_id: Optional[str] = None,
                        name: Optional[str] = None,
                        redirect_uri: Optional[str] = None,
                        host_name: Optional[str] = None,
                        load_all_groups: Optional[bool] = None,
                        orgs: Optional[Sequence[GitHubOrgArgs]] = None,
                        preferred_email_domain: Optional[str] = None,
                        root_ca: Optional[str] = None,
                        team_name_field: Optional[str] = None,
                        use_login_as_id: Optional[bool] = None)
    func NewGitHubConnector(ctx *Context, name string, args GitHubConnectorArgs, opts ...ResourceOption) (*GitHubConnector, error)
    public GitHubConnector(string name, GitHubConnectorArgs args, CustomResourceOptions? opts = null)
    public GitHubConnector(String name, GitHubConnectorArgs args)
    public GitHubConnector(String name, GitHubConnectorArgs args, CustomResourceOptions options)
    
    type: dex:resources:GitHubConnector
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args GitHubConnectorArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args GitHubConnectorArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args GitHubConnectorArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args GitHubConnectorArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args GitHubConnectorArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var gitHubConnectorResource = new Dex.Resources.GitHubConnector("gitHubConnectorResource", new()
    {
        ClientId = "string",
        ClientSecret = "string",
        ConnectorId = "string",
        Name = "string",
        RedirectUri = "string",
        HostName = "string",
        LoadAllGroups = false,
        Orgs = new[]
        {
            new Dex.Resources.Inputs.GitHubOrgArgs
            {
                Name = "string",
                Teams = new[]
                {
                    "string",
                },
            },
        },
        PreferredEmailDomain = "string",
        RootCA = "string",
        TeamNameField = "string",
        UseLoginAsID = false,
    });
    
    example, err := resources.NewGitHubConnector(ctx, "gitHubConnectorResource", &resources.GitHubConnectorArgs{
    	ClientId:      pulumi.String("string"),
    	ClientSecret:  pulumi.String("string"),
    	ConnectorId:   pulumi.String("string"),
    	Name:          pulumi.String("string"),
    	RedirectUri:   pulumi.String("string"),
    	HostName:      pulumi.String("string"),
    	LoadAllGroups: pulumi.Bool(false),
    	Orgs: resources.GitHubOrgArray{
    		&resources.GitHubOrgArgs{
    			Name: pulumi.String("string"),
    			Teams: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    		},
    	},
    	PreferredEmailDomain: pulumi.String("string"),
    	RootCA:               pulumi.String("string"),
    	TeamNameField:        pulumi.String("string"),
    	UseLoginAsID:         pulumi.Bool(false),
    })
    
    var gitHubConnectorResource = new GitHubConnector("gitHubConnectorResource", GitHubConnectorArgs.builder()
        .clientId("string")
        .clientSecret("string")
        .connectorId("string")
        .name("string")
        .redirectUri("string")
        .hostName("string")
        .loadAllGroups(false)
        .orgs(GitHubOrgArgs.builder()
            .name("string")
            .teams("string")
            .build())
        .preferredEmailDomain("string")
        .rootCA("string")
        .teamNameField("string")
        .useLoginAsID(false)
        .build());
    
    git_hub_connector_resource = dex.resources.GitHubConnector("gitHubConnectorResource",
        client_id="string",
        client_secret="string",
        connector_id="string",
        name="string",
        redirect_uri="string",
        host_name="string",
        load_all_groups=False,
        orgs=[{
            "name": "string",
            "teams": ["string"],
        }],
        preferred_email_domain="string",
        root_ca="string",
        team_name_field="string",
        use_login_as_id=False)
    
    const gitHubConnectorResource = new dex.resources.GitHubConnector("gitHubConnectorResource", {
        clientId: "string",
        clientSecret: "string",
        connectorId: "string",
        name: "string",
        redirectUri: "string",
        hostName: "string",
        loadAllGroups: false,
        orgs: [{
            name: "string",
            teams: ["string"],
        }],
        preferredEmailDomain: "string",
        rootCA: "string",
        teamNameField: "string",
        useLoginAsID: false,
    });
    
    type: dex:resources:GitHubConnector
    properties:
        clientId: string
        clientSecret: string
        connectorId: string
        hostName: string
        loadAllGroups: false
        name: string
        orgs:
            - name: string
              teams:
                - string
        preferredEmailDomain: string
        redirectUri: string
        rootCA: string
        teamNameField: string
        useLoginAsID: false
    

    GitHubConnector Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The GitHubConnector resource accepts the following input properties:

    ClientId string
    GitHub OAuth app client ID.
    ClientSecret string
    GitHub OAuth app client secret.
    ConnectorId string
    Unique identifier for the GitHub connector.
    Name string
    Human-readable name for the connector, displayed to users during login.
    RedirectUri string
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    HostName string
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    LoadAllGroups bool
    If true, load all groups (teams) the user is a member of. Defaults to false.
    Orgs List<GitHubOrg>
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    PreferredEmailDomain string
    Preferred email domain. If set, users with emails in this domain will be preferred.
    RootCA string
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    TeamNameField string
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    UseLoginAsID bool
    If true, use GitHub login username as the user ID. Defaults to false.
    ClientId string
    GitHub OAuth app client ID.
    ClientSecret string
    GitHub OAuth app client secret.
    ConnectorId string
    Unique identifier for the GitHub connector.
    Name string
    Human-readable name for the connector, displayed to users during login.
    RedirectUri string
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    HostName string
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    LoadAllGroups bool
    If true, load all groups (teams) the user is a member of. Defaults to false.
    Orgs []GitHubOrgArgs
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    PreferredEmailDomain string
    Preferred email domain. If set, users with emails in this domain will be preferred.
    RootCA string
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    TeamNameField string
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    UseLoginAsID bool
    If true, use GitHub login username as the user ID. Defaults to false.
    clientId String
    GitHub OAuth app client ID.
    clientSecret String
    GitHub OAuth app client secret.
    connectorId String
    Unique identifier for the GitHub connector.
    name String
    Human-readable name for the connector, displayed to users during login.
    redirectUri String
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    hostName String
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    loadAllGroups Boolean
    If true, load all groups (teams) the user is a member of. Defaults to false.
    orgs List<GitHubOrg>
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    preferredEmailDomain String
    Preferred email domain. If set, users with emails in this domain will be preferred.
    rootCA String
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    teamNameField String
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    useLoginAsID Boolean
    If true, use GitHub login username as the user ID. Defaults to false.
    clientId string
    GitHub OAuth app client ID.
    clientSecret string
    GitHub OAuth app client secret.
    connectorId string
    Unique identifier for the GitHub connector.
    name string
    Human-readable name for the connector, displayed to users during login.
    redirectUri string
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    hostName string
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    loadAllGroups boolean
    If true, load all groups (teams) the user is a member of. Defaults to false.
    orgs GitHubOrg[]
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    preferredEmailDomain string
    Preferred email domain. If set, users with emails in this domain will be preferred.
    rootCA string
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    teamNameField string
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    useLoginAsID boolean
    If true, use GitHub login username as the user ID. Defaults to false.
    client_id str
    GitHub OAuth app client ID.
    client_secret str
    GitHub OAuth app client secret.
    connector_id str
    Unique identifier for the GitHub connector.
    name str
    Human-readable name for the connector, displayed to users during login.
    redirect_uri str
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    host_name str
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    load_all_groups bool
    If true, load all groups (teams) the user is a member of. Defaults to false.
    orgs Sequence[GitHubOrgArgs]
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    preferred_email_domain str
    Preferred email domain. If set, users with emails in this domain will be preferred.
    root_ca str
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    team_name_field str
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    use_login_as_id bool
    If true, use GitHub login username as the user ID. Defaults to false.
    clientId String
    GitHub OAuth app client ID.
    clientSecret String
    GitHub OAuth app client secret.
    connectorId String
    Unique identifier for the GitHub connector.
    name String
    Human-readable name for the connector, displayed to users during login.
    redirectUri String
    Redirect URI registered in GitHub OAuth app. Must match Dex's callback URL.
    hostName String
    GitHub Enterprise hostname (e.g., 'github.example.com'). Leave empty for github.com.
    loadAllGroups Boolean
    If true, load all groups (teams) the user is a member of. Defaults to false.
    orgs List<Property Map>
    List of GitHub organizations with optional team restrictions. Only users in these orgs/teams will be allowed to authenticate.
    preferredEmailDomain String
    Preferred email domain. If set, users with emails in this domain will be preferred.
    rootCA String
    Root CA certificate for GitHub Enterprise (PEM format). Required if using self-signed certificates.
    teamNameField String
    Field to use for team names in group claims. Valid values: 'name', 'slug', or 'both'. Defaults to 'slug'.
    useLoginAsID Boolean
    If true, use GitHub login username as the user ID. Defaults to false.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the GitHubConnector resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Supporting Types

    GitHubOrg, GitHubOrgArgs

    Name string
    GitHub organization name.
    Teams List<string>
    List of team names within the organization. If empty, all members of the organization can authenticate.
    Name string
    GitHub organization name.
    Teams []string
    List of team names within the organization. If empty, all members of the organization can authenticate.
    name String
    GitHub organization name.
    teams List<String>
    List of team names within the organization. If empty, all members of the organization can authenticate.
    name string
    GitHub organization name.
    teams string[]
    List of team names within the organization. If empty, all members of the organization can authenticate.
    name str
    GitHub organization name.
    teams Sequence[str]
    List of team names within the organization. If empty, all members of the organization can authenticate.
    name String
    GitHub organization name.
    teams List<String>
    List of team names within the organization. If empty, all members of the organization can authenticate.

    Package Details

    Repository
    dex kotaicode/pulumi-dex
    License
    dex logo
    Dex v0.8.0 published on Thursday, Feb 19, 2026 by Kotaicode GmbH
      Meet Neo: Your AI Platform Teammate