github_actions_artifactgithub_actions_repository_runnergithub_actions_repository_secretgithub_actions_repository_workflow_rungithub_audit_loggithub_branchgithub_branch_protectiongithub_commitgithub_community_profilegithub_gistgithub_gitignoregithub_issuegithub_licensegithub_my_gistgithub_my_issuegithub_my_organizationgithub_my_repositorygithub_my_stargithub_my_teamgithub_organizationgithub_organization_membergithub_pull_requestgithub_rate_limitgithub_releasegithub_repositorygithub_search_codegithub_search_commitgithub_search_issuegithub_search_labelgithub_search_pull_requestgithub_search_repositorygithub_search_topicgithub_search_usergithub_stargazergithub_taggithub_teamgithub_team_membergithub_team_repositorygithub_traffic_view_dailygithub_traffic_view_weeklygithub_usergithub_workflow
Table: github_team_repository
A repository contains all of your project's files and each file's revision history.
The github_team_repository
table can be used to query information about repositories that a team has access to. You must specify the organization and team slug in the where or join clause (where organization= AND slug=
, join github_team_repository on organization= AND slug=
).
To list all your repositories use the github_my_repository
table instead. To get information about any repository, use the github_repository
table instead.
Examples
List a specific team's repositories
select organization, slug as team_slug, name, permissions, language, forks_count, stargazers_count, subscribers_count, descriptionfrom github_team_repositorywhere organization = 'my_org' and slug = 'my-team';
List visible teams and repositories they have admin permissions to
select t.organization as organization, t.name as team_name, t.slug as team_slug, t.privacy as team_privacy, t.description as team_description, tr.name as repo_name, tr.permissions as team_repo_permissions, tr.fork as repo_is_fork, tr.private as repo_is_private, tr.archived as repo_is_archived, tr.language as repo_primary_languagefrom github_team as t, github_team_repository AS trwhere t.organization = tr.organization and t.slug = tr.slug and permissions ? 'admin';
.inspect github_team_repository
GitHub Repositories that a given team is associated with. GitHub Repositories contain all of your project's files and each file's revision history.
Name | Type | Description |
---|---|---|
_ctx | jsonb | Steampipe context in JSON form, e.g. connection_name. |
allow_merge_commit | boolean | If true, the repository allows merge commits. |
allow_rebase_merge | boolean | If true, the repository allows rebase merges. |
allow_squash_merge | boolean | If true, the repository allows squash merges. |
archived | boolean | If true, the repository is archived and read-only. |
clone_url | text | URL that can be provided to git clone to clone the repository via HTTPS. |
code_of_conduct_key | text | Unique key for code of conduct for the repository. |
code_of_conduct_name | text | Name of the Code of Conduct for the repository. |
code_of_conduct_url | text | URL of the Code of Conduct for the repository. |
collaborator_logins | jsonb | An array of logins for users (inside and outside collaborators) who have access to the repository. |
collaborators | jsonb | An array of users (teams and outside collaborators) who have access to the repository, including their permissions. |
created_at | timestamp with time zone | The timestamp when the repository was created. |
default_branch | text | The name of the deafult branch. The default branch is the base branch for pull requests and code commits. |
delete_branch_on_merge | boolean | If enabled, branches are automatically deleted whe a PR is merged. |
description | text | The repository description. |
disabled | boolean | If true, the repository is disabled. |
fork | boolean | If true, this repository is a fork of another repository. |
forks_count | bigint | The number of repositories that have forked this repository. |
full_name | text | The full name of the repository, including the owner and repo name. |
git_url | text | The git url to clone this repo via the git protocol. |
has_downloads | boolean | If true, the GitHub Downloads feature is enabled on the repository. |
has_issues | boolean | If true, the GitHub Issues feature is enabled on the repository. |
has_pages | boolean | If true, the GitHub Pages feature is enabled on the repository. |
has_projects | boolean | If true, the GitHub Projects feature is enabled on the repository. |
has_wiki | boolean | If true, the GitHub Wiki feature is enabled on the repository. |
homepage | text | The URL of a page describing the project. |
hooks | jsonb | The API Hooks URL. |
html_url | text | The URL of the repo. |
id | bigint | The unique ID number of the repository. |
is_template | boolean | If true, the repository is a template repository. |
language | text | The repository language (JavaScript, Go, etc) |
license_key | text | The key of the license associated with the repository. |
license_name | text | The name of the license associated with the repository. |
license_node_id | text | The node id of the license associated with the repository. |
license_spdx_id | text | The Software Package Data Exchange (SPDX) id of the license associated with the repository. |
license_url | text | The url of the license associated with the repository. |
name | text | The name of the repository. |
network_count | bigint | The number of member repositories in the network. |
node_id | text | The Node ID of the repository. |
open_issues_count | bigint | The number of open issues for the repository. |
organization | text | The organization the team is associated with. |
outside_collaborator_logins | jsonb | An array of logins for outside collaborators who have access to the repository. |
outside_collaborators | jsonb | An array of outside collaborators who have access to the repository, including their permissions. |
owner_id | bigint | The user id (number) of the repository owner. |
owner_login | text | The user login name of the repository owner. |
owner_type | text | The type of the repository owner (User or Organization). |
permissions | jsonb | The team's permissions for a repository. |
private | boolean | If true, the repo is private, otherwise it is public. |
pushed_at | timestamp with time zone | Timestamp of the last push to the repository. |
size | bigint | The size of the whole repository (including history), in kilobytes. |
slug | text | The team slug name. |
ssh_url | text | The url to clone this repo via ssh. |
stargazers_count | bigint | The number of users who have 'starred' the repository. |
subscribers_count | bigint | The number of users who have subscribed to the repository. |
template_repository | text | The template repository used to create this resource. |
topics | jsonb | The topics (similar to tags or labels) associated with the repository. |
updated_at | timestamp with time zone | Timestamp when the repository was last updated. |
url | text | The url to clone this repo via https. |
visibility | text | The visibility of the repository (public or private) |
watchers_count | bigint | The number of users who have watched the repository. |