GitHub v6.8.0 published on Thursday, Oct 23, 2025 by Pulumi
github.getOrganizationRepositoryRoles
Lookup all custom repository roles in an organization.
Note: Custom organization repository roles are currently only available in GitHub Enterprise Cloud.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as github from "@pulumi/github";
const example = github.getOrganizationRepositoryRoles({});
import pulumi
import pulumi_github as github
example = github.get_organization_repository_roles()
package main
import (
"github.com/pulumi/pulumi-github/sdk/v6/go/github"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := github.GetOrganizationRepositoryRoles(ctx, map[string]interface{}{}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Github = Pulumi.Github;
return await Deployment.RunAsync(() =>
{
var example = Github.GetOrganizationRepositoryRoles.Invoke();
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.github.GithubFunctions;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var example = GithubFunctions.getOrganizationRepositoryRoles(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference);
}
}
variables:
example:
fn::invoke:
function: github:getOrganizationRepositoryRoles
arguments: {}
Nested Schema for roles
Read-Only
role_id(Number) The ID of the organization repository role.name(String) The name of the organization repository role.description(String) The description of the organization repository role.base_role(String) The system role from which this role inherits permissions.permissions(Set of String) The permissions included in this role.
Using getOrganizationRepositoryRoles
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getOrganizationRepositoryRoles(opts?: InvokeOptions): Promise<GetOrganizationRepositoryRolesResult>
function getOrganizationRepositoryRolesOutput(opts?: InvokeOptions): Output<GetOrganizationRepositoryRolesResult>def get_organization_repository_roles(opts: Optional[InvokeOptions] = None) -> GetOrganizationRepositoryRolesResult
def get_organization_repository_roles_output(opts: Optional[InvokeOptions] = None) -> Output[GetOrganizationRepositoryRolesResult]func GetOrganizationRepositoryRoles(ctx *Context, opts ...InvokeOption) (*GetOrganizationRepositoryRolesResult, error)
func GetOrganizationRepositoryRolesOutput(ctx *Context, opts ...InvokeOption) GetOrganizationRepositoryRolesResultOutput> Note: This function is named GetOrganizationRepositoryRoles in the Go SDK.
public static class GetOrganizationRepositoryRoles
{
public static Task<GetOrganizationRepositoryRolesResult> InvokeAsync(InvokeOptions? opts = null)
public static Output<GetOrganizationRepositoryRolesResult> Invoke(InvokeOptions? opts = null)
}public static CompletableFuture<GetOrganizationRepositoryRolesResult> getOrganizationRepositoryRoles(InvokeOptions options)
public static Output<GetOrganizationRepositoryRolesResult> getOrganizationRepositoryRoles(InvokeOptions options)
fn::invoke:
function: github:index/getOrganizationRepositoryRoles:getOrganizationRepositoryRoles
arguments:
# arguments dictionarygetOrganizationRepositoryRoles Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Roles
List<Get
Organization Repository Roles Role> - (Set of Object, see schema) Available organization repository roles.
- Id string
- The provider-assigned unique ID for this managed resource.
- Roles
[]Get
Organization Repository Roles Role - (Set of Object, see schema) Available organization repository roles.
- id String
- The provider-assigned unique ID for this managed resource.
- roles
List<Get
Organization Repository Roles Role> - (Set of Object, see schema) Available organization repository roles.
- id string
- The provider-assigned unique ID for this managed resource.
- roles
Get
Organization Repository Roles Role[] - (Set of Object, see schema) Available organization repository roles.
- id str
- The provider-assigned unique ID for this managed resource.
- roles
Sequence[Get
Organization Repository Roles Role] - (Set of Object, see schema) Available organization repository roles.
- id String
- The provider-assigned unique ID for this managed resource.
- roles List<Property Map>
- (Set of Object, see schema) Available organization repository roles.
Supporting Types
GetOrganizationRepositoryRolesRole
- Base
Role string - The system role from which this role inherits permissions.
- Description string
- The description of the organization repository role.
- Name string
- The name of the organization repository role.
- Permissions List<string>
- The permissions included in this role.
- Role
Id int - The ID of the organization repository role.
- Base
Role string - The system role from which this role inherits permissions.
- Description string
- The description of the organization repository role.
- Name string
- The name of the organization repository role.
- Permissions []string
- The permissions included in this role.
- Role
Id int - The ID of the organization repository role.
- base
Role String - The system role from which this role inherits permissions.
- description String
- The description of the organization repository role.
- name String
- The name of the organization repository role.
- permissions List<String>
- The permissions included in this role.
- role
Id Integer - The ID of the organization repository role.
- base
Role string - The system role from which this role inherits permissions.
- description string
- The description of the organization repository role.
- name string
- The name of the organization repository role.
- permissions string[]
- The permissions included in this role.
- role
Id number - The ID of the organization repository role.
- base_
role str - The system role from which this role inherits permissions.
- description str
- The description of the organization repository role.
- name str
- The name of the organization repository role.
- permissions Sequence[str]
- The permissions included in this role.
- role_
id int - The ID of the organization repository role.
- base
Role String - The system role from which this role inherits permissions.
- description String
- The description of the organization repository role.
- name String
- The name of the organization repository role.
- permissions List<String>
- The permissions included in this role.
- role
Id Number - The ID of the organization repository role.
Package Details
- Repository
- GitHub pulumi/pulumi-github
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
githubTerraform Provider.
