View Source GitHub.Repos (GitHub REST API Client v0.0.7)

Provides API endpoints related to repos

Link to this section Summary

Functions

Check if a user is a repository collaborator

Check if vulnerability alerts are enabled for a repository

Create an autolink reference for a repository

Create a custom deployment protection rule on an environment

Create a repository dispatch event

Create a repository for the authenticated user

Create an organization repository

Create an organization repository ruleset

Create a tag protection state for a repository

Create a repository webhook

Delete a repository

Delete an autolink reference from a repository

Delete an organization repository ruleset

Delete a GitHub Pages site

Delete a tag protection state for a repository

Disable Git LFS for a repository

Download a repository archive (tar)

Download a repository archive (zip)

Enable Git LFS for a repository

Generate release notes content for a release

Get a repository

Get all deployment protection rules for an environment

Get all repository topics

Get an autolink reference of a repository

Get repository clones

Get the weekly commit activity

Get the combined status for a specific reference

Get the last year of commit activity

Get all contributor commit activity

Get an organization repository ruleset

Get all organization repository rulesets

Get a GitHub Pages site

Get a DNS health check for GitHub Pages

Get the hourly commit count for each day

Get a repository README

Get a repository README for a directory

Get all repository rulesets

Get a webhook configuration for a repository

List all autolinks of a repository

List repository collaborators

List commit comments for a repository

List commit statuses for a reference

List repository contributors

List custom deployment rule integrations available for an environment

List repositories for the authenticated user

List organization repositories

List repositories for a user

List repository invitations

List repository invitations for the authenticated user

List repository languages

List public repositories

List tag protection states for a repository

List repository tags

List repository teams

List deliveries for a repository webhook

List repository webhooks

Sync a fork branch with the upstream repository

Request a GitHub Pages build

Test the push repository webhook

Update information about a GitHub Pages site

Update an organization repository ruleset

Update a webhook configuration for a repository

Link to this section Functions

Link to this function

accept_invitation_for_authenticated_user(invitation_id, opts \\ [])

View Source
@spec accept_invitation_for_authenticated_user(
  integer(),
  keyword()
) :: :ok | {:error, GitHub.Error.t()}

Accept a repository invitation

resources

Resources

Link to this function

add_app_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec add_app_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.App.t()]} | {:error, GitHub.Error.t()}

Add app access restrictions

resources

Resources

Link to this function

add_collaborator(owner, repo, username, body, opts \\ [])

View Source
@spec add_collaborator(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.Invitation.t()} | {:error, GitHub.Error.t()}

Add a repository collaborator

resources

Resources

Link to this function

add_status_check_contexts(owner, repo, branch, body, opts \\ [])

View Source
@spec add_status_check_contexts(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) ::
  {:ok, [String.t()]} | {:error, GitHub.Error.t()}

Add status check contexts

resources

Resources

Link to this function

add_team_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec add_team_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.Team.t()]} | {:error, GitHub.Error.t()}

Add team access restrictions

resources

Resources

Link to this function

add_user_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec add_user_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.User.simple()]} | {:error, GitHub.Error.t()}

Add user access restrictions

resources

Resources

Link to this function

check_collaborator(owner, repo, username, opts \\ [])

View Source
@spec check_collaborator(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Check if a user is a repository collaborator

resources

Resources

Link to this function

check_vulnerability_alerts(owner, repo, opts \\ [])

View Source
@spec check_vulnerability_alerts(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Check if vulnerability alerts are enabled for a repository

resources

Resources

Link to this function

codeowners_errors(owner, repo, opts \\ [])

View Source
@spec codeowners_errors(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.CodeownersErrors.t()} | {:error, GitHub.Error.t()}

List CODEOWNERS errors

options

Options

  • ref (String.t()): A branch, tag or commit name used to determine which version of the CODEOWNERS file to use. Default: the repository's default branch (e.g. main)

resources

Resources

Link to this function

compare_commits(owner, repo, basehead, opts \\ [])

View Source
@spec compare_commits(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Commit.Comparison.t()} | {:error, GitHub.Error.t()}

Compare two commits

options

Options

  • page (integer): Page number of the results to fetch.
  • per_page (integer): The number of results per page (max 100).

resources

Resources

Link to this function

create_autolink(owner, repo, body, opts \\ [])

View Source
@spec create_autolink(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Autolink.t()} | {:error, GitHub.Error.t()}

Create an autolink reference for a repository

resources

Resources

Link to this function

create_commit_comment(owner, repo, commit_sha, body, opts \\ [])

View Source
@spec create_commit_comment(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Commit.Comment.t()} | {:error, GitHub.Error.t()}

Create a commit comment

resources

Resources

Link to this function

create_commit_signature_protection(owner, repo, branch, opts \\ [])

View Source
@spec create_commit_signature_protection(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, GitHub.ProtectedBranch.AdminEnforced.t()} | {:error, GitHub.Error.t()}

Create commit signature protection

resources

Resources

Link to this function

create_commit_status(owner, repo, sha, body, opts \\ [])

View Source
@spec create_commit_status(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Status.t()} | {:error, GitHub.Error.t()}

Create a commit status

resources

Resources

Link to this function

create_deploy_key(owner, repo, body, opts \\ [])

View Source
@spec create_deploy_key(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.DeployKey.t()} | {:error, GitHub.Error.t()}

Create a deploy key

resources

Resources

Link to this function

create_deployment(owner, repo, body, opts \\ [])

View Source
@spec create_deployment(String.t(), String.t(), map(), keyword()) ::
  {:ok, map() | GitHub.Deployment.t()} | {:error, GitHub.Error.t()}

Create a deployment

resources

Resources

Link to this function

create_deployment_branch_policy(owner, repo, environment_name, body, opts \\ [])

View Source
@spec create_deployment_branch_policy(
  String.t(),
  String.t(),
  String.t(),
  GitHub.Deployment.BranchPolicyNamePattern.t(),
  keyword()
) :: {:ok, GitHub.Deployment.BranchPolicy.t()} | {:error, GitHub.Error.t()}

Create a deployment branch policy

resources

Resources

Link to this function

create_deployment_protection_rule(owner, repo, environment_name, body, opts \\ [])

View Source
@spec create_deployment_protection_rule(
  String.t(),
  String.t(),
  String.t(),
  map(),
  keyword()
) ::
  {:ok, GitHub.Deployment.ProtectionRule.t()} | {:error, GitHub.Error.t()}

Create a custom deployment protection rule on an environment

resources

Resources

Link to this function

create_deployment_status(owner, repo, deployment_id, body, opts \\ [])

View Source
@spec create_deployment_status(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Deployment.Status.t()} | {:error, GitHub.Error.t()}

Create a deployment status

resources

Resources

Link to this function

create_dispatch_event(owner, repo, body, opts \\ [])

View Source
@spec create_dispatch_event(String.t(), String.t(), map(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Create a repository dispatch event

resources

Resources

Link to this function

create_for_authenticated_user(body, opts \\ [])

View Source
@spec create_for_authenticated_user(
  map(),
  keyword()
) :: {:ok, GitHub.Repository.t()} | {:error, GitHub.Error.t()}

Create a repository for the authenticated user

resources

Resources

Link to this function

create_fork(owner, repo, body, opts \\ [])

View Source
@spec create_fork(String.t(), String.t(), map() | nil, keyword()) ::
  {:ok, GitHub.Repository.full()} | {:error, GitHub.Error.t()}

Create a fork

resources

Resources

Link to this function

create_in_org(org, body, opts \\ [])

View Source
@spec create_in_org(String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.t()} | {:error, GitHub.Error.t()}

Create an organization repository

resources

Resources

Link to this function

create_or_update_environment(owner, repo, environment_name, body, opts \\ [])

View Source
@spec create_or_update_environment(
  String.t(),
  String.t(),
  String.t(),
  map() | nil,
  keyword()
) ::
  {:ok, GitHub.Environment.t()} | {:error, GitHub.Error.t()}

Create or update an environment

resources

Resources

Link to this function

create_or_update_file_contents(owner, repo, path, body, opts \\ [])

View Source
@spec create_or_update_file_contents(
  String.t(),
  String.t(),
  String.t(),
  map(),
  keyword()
) ::
  {:ok, GitHub.FileCommit.t()} | {:error, GitHub.Error.t()}

Create or update file contents

resources

Resources

Link to this function

create_org_ruleset(org, body, opts \\ [])

View Source
@spec create_org_ruleset(String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Create an organization repository ruleset

resources

Resources

Link to this function

create_pages_deployment(owner, repo, body, opts \\ [])

View Source
@spec create_pages_deployment(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Pages.Deployment.t()} | {:error, GitHub.Error.t()}

Create a GitHub Pages deployment

resources

Resources

Link to this function

create_pages_site(owner, repo, body, opts \\ [])

View Source
@spec create_pages_site(String.t(), String.t(), map() | nil, keyword()) ::
  {:ok, GitHub.Page.t()} | {:error, GitHub.Error.t()}

Create a GitHub Pages site

resources

Resources

Link to this function

create_release(owner, repo, body, opts \\ [])

View Source
@spec create_release(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Release.t()} | {:error, GitHub.Error.t()}

Create a release

resources

Resources

Link to this function

create_repo_ruleset(owner, repo, body, opts \\ [])

View Source
@spec create_repo_ruleset(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Create a repository ruleset

resources

Resources

Link to this function

create_tag_protection(owner, repo, body, opts \\ [])

View Source
@spec create_tag_protection(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.TagProtection.t()} | {:error, GitHub.Error.t()}

Create a tag protection state for a repository

resources

Resources

Link to this function

create_using_template(template_owner, template_repo, body, opts \\ [])

View Source
@spec create_using_template(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.t()} | {:error, GitHub.Error.t()}

Create a repository using a template

resources

Resources

Link to this function

create_webhook(owner, repo, body, opts \\ [])

View Source
@spec create_webhook(String.t(), String.t(), map() | nil, keyword()) ::
  {:ok, GitHub.Hook.t()} | {:error, GitHub.Error.t()}

Create a repository webhook

resources

Resources

Link to this function

decline_invitation_for_authenticated_user(invitation_id, opts \\ [])

View Source
@spec decline_invitation_for_authenticated_user(
  integer(),
  keyword()
) :: :ok | {:error, GitHub.Error.t()}

Decline a repository invitation

resources

Resources

Link to this function

delete(owner, repo, opts \\ [])

View Source
@spec delete(String.t(), String.t(), keyword()) :: :ok | {:error, GitHub.Error.t()}

Delete a repository

resources

Resources

Link to this function

delete_access_restrictions(owner, repo, branch, opts \\ [])

View Source
@spec delete_access_restrictions(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete access restrictions

resources

Resources

Link to this function

delete_admin_branch_protection(owner, repo, branch, opts \\ [])

View Source
@spec delete_admin_branch_protection(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete admin branch protection

resources

Resources

Link to this function

delete_an_environment(owner, repo, environment_name, opts \\ [])

View Source
@spec delete_an_environment(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete an environment

resources

Resources

Link to this function

delete_autolink(owner, repo, autolink_id, opts \\ [])

View Source
@spec delete_autolink(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete an autolink reference from a repository

resources

Resources

Link to this function

delete_branch_protection(owner, repo, branch, opts \\ [])

View Source
@spec delete_branch_protection(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete branch protection

resources

Resources

Link to this function

delete_commit_comment(owner, repo, comment_id, opts \\ [])

View Source
@spec delete_commit_comment(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a commit comment

resources

Resources

Link to this function

delete_commit_signature_protection(owner, repo, branch, opts \\ [])

View Source
@spec delete_commit_signature_protection(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  :ok | {:error, GitHub.Error.t()}

Delete commit signature protection

resources

Resources

Link to this function

delete_deploy_key(owner, repo, key_id, opts \\ [])

View Source
@spec delete_deploy_key(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a deploy key

resources

Resources

Link to this function

delete_deployment(owner, repo, deployment_id, opts \\ [])

View Source
@spec delete_deployment(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a deployment

resources

Resources

Link to this function

delete_deployment_branch_policy(owner, repo, environment_name, branch_policy_id, opts \\ [])

View Source
@spec delete_deployment_branch_policy(
  String.t(),
  String.t(),
  String.t(),
  integer(),
  keyword()
) ::
  :ok | {:error, GitHub.Error.t()}

Delete a deployment branch policy

resources

Resources

Link to this function

delete_file(owner, repo, path, body, opts \\ [])

View Source
@spec delete_file(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.FileCommit.t()} | {:error, GitHub.Error.t()}

Delete a file

resources

Resources

Link to this function

delete_invitation(owner, repo, invitation_id, opts \\ [])

View Source
@spec delete_invitation(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a repository invitation

resources

Resources

Link to this function

delete_org_ruleset(org, ruleset_id, opts \\ [])

View Source
@spec delete_org_ruleset(String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete an organization repository ruleset

resources

Resources

Link to this function

delete_pages_site(owner, repo, opts \\ [])

View Source
@spec delete_pages_site(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a GitHub Pages site

resources

Resources

Link to this function

delete_pull_request_review_protection(owner, repo, branch, opts \\ [])

View Source
@spec delete_pull_request_review_protection(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  :ok | {:error, GitHub.Error.t()}

Delete pull request review protection

resources

Resources

Link to this function

delete_release(owner, repo, release_id, opts \\ [])

View Source
@spec delete_release(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a release

resources

Resources

Link to this function

delete_release_asset(owner, repo, asset_id, opts \\ [])

View Source
@spec delete_release_asset(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a release asset

resources

Resources

Link to this function

delete_repo_ruleset(owner, repo, ruleset_id, opts \\ [])

View Source
@spec delete_repo_ruleset(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a repository ruleset

resources

Resources

Link to this function

delete_tag_protection(owner, repo, tag_protection_id, opts \\ [])

View Source
@spec delete_tag_protection(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a tag protection state for a repository

resources

Resources

Link to this function

delete_webhook(owner, repo, hook_id, opts \\ [])

View Source
@spec delete_webhook(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Delete a repository webhook

resources

Resources

Link to this function

disable_automated_security_fixes(owner, repo, opts \\ [])

View Source
@spec disable_automated_security_fixes(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Disable automated security fixes

resources

Resources

Link to this function

disable_deployment_protection_rule(owner, repo, environment_name, protection_rule_id, opts \\ [])

View Source
@spec disable_deployment_protection_rule(
  String.t(),
  String.t(),
  String.t(),
  integer(),
  keyword()
) ::
  :ok | {:error, GitHub.Error.t()}

Disable a custom protection rule for an environment

resources

Resources

Link to this function

disable_lfs_for_repo(owner, repo, opts \\ [])

View Source
@spec disable_lfs_for_repo(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Disable Git LFS for a repository

resources

Resources

Link to this function

disable_vulnerability_alerts(owner, repo, opts \\ [])

View Source
@spec disable_vulnerability_alerts(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Disable vulnerability alerts

resources

Resources

Link to this function

download_tarball_archive(owner, repo, ref, opts \\ [])

View Source
@spec download_tarball_archive(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Download a repository archive (tar)

resources

Resources

Link to this function

download_zipball_archive(owner, repo, ref, opts \\ [])

View Source
@spec download_zipball_archive(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Download a repository archive (zip)

resources

Resources

Link to this function

enable_automated_security_fixes(owner, repo, opts \\ [])

View Source
@spec enable_automated_security_fixes(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Enable automated security fixes

resources

Resources

Link to this function

enable_lfs_for_repo(owner, repo, opts \\ [])

View Source
@spec enable_lfs_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

Enable Git LFS for a repository

resources

Resources

Link to this function

enable_vulnerability_alerts(owner, repo, opts \\ [])

View Source
@spec enable_vulnerability_alerts(String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Enable vulnerability alerts

resources

Resources

Link to this function

generate_release_notes(owner, repo, body, opts \\ [])

View Source
@spec generate_release_notes(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Release.NotesContent.t()} | {:error, GitHub.Error.t()}

Generate release notes content for a release

resources

Resources

Link to this function

get(owner, repo, opts \\ [])

View Source
@spec get(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Repository.full()} | {:error, GitHub.Error.t()}

Get a repository

resources

Resources

Link to this function

get_access_restrictions(owner, repo, branch, opts \\ [])

View Source
@spec get_access_restrictions(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Branch.RestrictionPolicy.t()} | {:error, GitHub.Error.t()}

Get access restrictions

resources

Resources

Link to this function

get_admin_branch_protection(owner, repo, branch, opts \\ [])

View Source
@spec get_admin_branch_protection(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.ProtectedBranch.AdminEnforced.t()} | {:error, GitHub.Error.t()}

Get admin branch protection

resources

Resources

Link to this function

get_all_deployment_protection_rules(owner, repo, environment_name, opts \\ [])

View Source
@spec get_all_deployment_protection_rules(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

Get all deployment protection rules for an environment

resources

Resources

Link to this function

get_all_environments(owner, repo, opts \\ [])

View Source
@spec get_all_environments(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

List environments

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

get_all_status_check_contexts(owner, repo, branch, opts \\ [])

View Source
@spec get_all_status_check_contexts(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, [String.t()]} | {:error, GitHub.Error.t()}

Get all status check contexts

resources

Resources

Link to this function

get_all_topics(owner, repo, opts \\ [])

View Source
@spec get_all_topics(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Topic.t()} | {:error, GitHub.Error.t()}

Get all repository topics

options

Options

  • page (integer): Page number of the results to fetch.
  • per_page (integer): The number of results per page (max 100).

resources

Resources

Link to this function

get_apps_with_access_to_protected_branch(owner, repo, branch, opts \\ [])

View Source
@spec get_apps_with_access_to_protected_branch(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, [GitHub.App.t()]} | {:error, GitHub.Error.t()}

Get apps with access to the protected branch

resources

Resources

Link to this function

get_autolink(owner, repo, autolink_id, opts \\ [])

View Source
@spec get_autolink(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Autolink.t()} | {:error, GitHub.Error.t()}

Get an autolink reference of a repository

resources

Resources

Link to this function

get_branch(owner, repo, branch, opts \\ [])

View Source
@spec get_branch(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Branch.WithProtection.t()} | {:error, GitHub.Error.t()}

Get a branch

resources

Resources

Link to this function

get_branch_protection(owner, repo, branch, opts \\ [])

View Source
@spec get_branch_protection(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Branch.Protection.t()} | {:error, GitHub.Error.t()}

Get branch protection

resources

Resources

Link to this function

get_branch_rules(owner, repo, branch, opts \\ [])

View Source

Get rules for a branch

resources

Resources

Link to this function

get_clones(owner, repo, opts \\ [])

View Source
@spec get_clones(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.CloneTraffic.t()} | {:error, GitHub.Error.t()}

Get repository clones

options

Options

  • per (String.t()): The time frame to display results for.

resources

Resources

Link to this function

get_code_frequency_stats(owner, repo, opts \\ [])

View Source
@spec get_code_frequency_stats(String.t(), String.t(), keyword()) ::
  {:ok, map() | [[integer()]]} | {:error, GitHub.Error.t()}

Get the weekly commit activity

resources

Resources

Link to this function

get_collaborator_permission_level(owner, repo, username, opts \\ [])

View Source
@spec get_collaborator_permission_level(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Repository.CollaboratorPermission.t()}
  | {:error, GitHub.Error.t()}

Get repository permissions for a user

resources

Resources

Link to this function

get_combined_status_for_ref(owner, repo, ref, opts \\ [])

View Source
@spec get_combined_status_for_ref(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.CombinedCommitStatus.t()} | {:error, GitHub.Error.t()}

Get the combined status for a specific reference

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

get_commit(owner, repo, ref, opts \\ [])

View Source
@spec get_commit(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Commit.t()} | {:error, GitHub.Error.t()}

Get a commit

options

Options

  • page (integer): Page number of the results to fetch.
  • per_page (integer): The number of results per page (max 100).

resources

Resources

Link to this function

get_commit_activity_stats(owner, repo, opts \\ [])

View Source
@spec get_commit_activity_stats(String.t(), String.t(), keyword()) ::
  {:ok, map() | [GitHub.Commit.Activity.t()]} | {:error, GitHub.Error.t()}

Get the last year of commit activity

resources

Resources

Link to this function

get_commit_comment(owner, repo, comment_id, opts \\ [])

View Source
@spec get_commit_comment(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Commit.Comment.t()} | {:error, GitHub.Error.t()}

Get a commit comment

resources

Resources

Link to this function

get_commit_signature_protection(owner, repo, branch, opts \\ [])

View Source
@spec get_commit_signature_protection(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.ProtectedBranch.AdminEnforced.t()} | {:error, GitHub.Error.t()}

Get commit signature protection

resources

Resources

Link to this function

get_community_profile_metrics(owner, repo, opts \\ [])

View Source
@spec get_community_profile_metrics(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.CommunityProfile.t()} | {:error, GitHub.Error.t()}

Get community profile metrics

resources

Resources

Link to this function

get_content(owner, repo, path, opts \\ [])

View Source
@spec get_content(String.t(), String.t(), String.t(), keyword()) ::
  {:ok,
   GitHub.Content.File.t()
   | GitHub.Content.Submodule.t()
   | GitHub.Content.Symlink.t()
   | [map()]}
  | {:error, GitHub.Error.t()}

Get repository content

options

Options

  • ref (String.t()): The name of the commit/branch/tag. Default: the repository’s default branch.

resources

Resources

Link to this function

get_contributors_stats(owner, repo, opts \\ [])

View Source
@spec get_contributors_stats(String.t(), String.t(), keyword()) ::
  {:ok, map() | [GitHub.ContributorActivity.t()]} | {:error, GitHub.Error.t()}

Get all contributor commit activity

resources

Resources

Link to this function

get_custom_deployment_protection_rule(owner, repo, environment_name, protection_rule_id, opts \\ [])

View Source
@spec get_custom_deployment_protection_rule(
  String.t(),
  String.t(),
  String.t(),
  integer(),
  keyword()
) :: {:ok, GitHub.Deployment.ProtectionRule.t()} | {:error, GitHub.Error.t()}

Get a custom deployment protection rule

resources

Resources

Link to this function

get_deploy_key(owner, repo, key_id, opts \\ [])

View Source
@spec get_deploy_key(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.DeployKey.t()} | {:error, GitHub.Error.t()}

Get a deploy key

resources

Resources

Link to this function

get_deployment(owner, repo, deployment_id, opts \\ [])

View Source
@spec get_deployment(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Deployment.t()} | {:error, GitHub.Error.t()}

Get a deployment

resources

Resources

Link to this function

get_deployment_branch_policy(owner, repo, environment_name, branch_policy_id, opts \\ [])

View Source
@spec get_deployment_branch_policy(
  String.t(),
  String.t(),
  String.t(),
  integer(),
  keyword()
) ::
  {:ok, GitHub.Deployment.BranchPolicy.t()} | {:error, GitHub.Error.t()}

Get a deployment branch policy

resources

Resources

Link to this function

get_deployment_status(owner, repo, deployment_id, status_id, opts \\ [])

View Source
@spec get_deployment_status(String.t(), String.t(), integer(), integer(), keyword()) ::
  {:ok, GitHub.Deployment.Status.t()} | {:error, GitHub.Error.t()}

Get a deployment status

resources

Resources

Link to this function

get_environment(owner, repo, environment_name, opts \\ [])

View Source
@spec get_environment(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Environment.t()} | {:error, GitHub.Error.t()}

Get an environment

resources

Resources

Link to this function

get_latest_pages_build(owner, repo, opts \\ [])

View Source
@spec get_latest_pages_build(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Pages.Build.t()} | {:error, GitHub.Error.t()}

Get latest Pages build

resources

Resources

Link to this function

get_latest_release(owner, repo, opts \\ [])

View Source
@spec get_latest_release(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Release.t()} | {:error, GitHub.Error.t()}

Get the latest release

resources

Resources

Link to this function

get_org_ruleset(org, ruleset_id, opts \\ [])

View Source
@spec get_org_ruleset(String.t(), integer(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Get an organization repository ruleset

resources

Resources

Link to this function

get_org_rulesets(org, opts \\ [])

View Source
@spec get_org_rulesets(
  String.t(),
  keyword()
) :: {:ok, [GitHub.Repository.Ruleset.t()]} | {:error, GitHub.Error.t()}

Get all organization repository rulesets

resources

Resources

Link to this function

get_pages(owner, repo, opts \\ [])

View Source
@spec get_pages(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Page.t()} | {:error, GitHub.Error.t()}

Get a GitHub Pages site

resources

Resources

Link to this function

get_pages_build(owner, repo, build_id, opts \\ [])

View Source
@spec get_pages_build(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Pages.Build.t()} | {:error, GitHub.Error.t()}

Get GitHub Pages build

resources

Resources

Link to this function

get_pages_health_check(owner, repo, opts \\ [])

View Source
@spec get_pages_health_check(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.EmptyObject.t() | GitHub.Pages.HealthCheck.t()}
  | {:error, GitHub.Error.t()}

Get a DNS health check for GitHub Pages

resources

Resources

Link to this function

get_participation_stats(owner, repo, opts \\ [])

View Source
@spec get_participation_stats(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.ParticipationStats.t()} | {:error, GitHub.Error.t()}

Get the weekly commit count

resources

Resources

Link to this function

get_pull_request_review_protection(owner, repo, branch, opts \\ [])

View Source
@spec get_pull_request_review_protection(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, GitHub.ProtectedBranch.PullRequestReview.t()}
  | {:error, GitHub.Error.t()}

Get pull request review protection

resources

Resources

Link to this function

get_punch_card_stats(owner, repo, opts \\ [])

View Source
@spec get_punch_card_stats(String.t(), String.t(), keyword()) ::
  {:ok, [[integer()]]} | {:error, GitHub.Error.t()}

Get the hourly commit count for each day

resources

Resources

Link to this function

get_readme(owner, repo, opts \\ [])

View Source
@spec get_readme(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Content.File.t()} | {:error, GitHub.Error.t()}

Get a repository README

options

Options

  • ref (String.t()): The name of the commit/branch/tag. Default: the repository’s default branch.

resources

Resources

Link to this function

get_readme_in_directory(owner, repo, dir, opts \\ [])

View Source
@spec get_readme_in_directory(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Content.File.t()} | {:error, GitHub.Error.t()}

Get a repository README for a directory

options

Options

  • ref (String.t()): The name of the commit/branch/tag. Default: the repository’s default branch.

resources

Resources

Link to this function

get_release(owner, repo, release_id, opts \\ [])

View Source
@spec get_release(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Release.t()} | {:error, GitHub.Error.t()}

Get a release

resources

Resources

Link to this function

get_release_asset(owner, repo, asset_id, opts \\ [])

View Source
@spec get_release_asset(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Release.Asset.t()} | {:error, GitHub.Error.t()}

Get a release asset

resources

Resources

Link to this function

get_release_by_tag(owner, repo, tag, opts \\ [])

View Source
@spec get_release_by_tag(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Release.t()} | {:error, GitHub.Error.t()}

Get a release by tag name

resources

Resources

Link to this function

get_repo_ruleset(owner, repo, ruleset_id, opts \\ [])

View Source
@spec get_repo_ruleset(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Get a repository ruleset

options

Options

  • includes_parents (boolean): Include rulesets configured at higher levels that apply to this repository

resources

Resources

Link to this function

get_repo_rulesets(owner, repo, opts \\ [])

View Source
@spec get_repo_rulesets(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Repository.Ruleset.t()]} | {:error, GitHub.Error.t()}

Get all repository rulesets

options

Options

  • includes_parents (boolean): Include rulesets configured at higher levels that apply to this repository

resources

Resources

Link to this function

get_status_checks_protection(owner, repo, branch, opts \\ [])

View Source
@spec get_status_checks_protection(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.StatusCheckPolicy.t()} | {:error, GitHub.Error.t()}

Get status checks protection

resources

Resources

Link to this function

get_teams_with_access_to_protected_branch(owner, repo, branch, opts \\ [])

View Source
@spec get_teams_with_access_to_protected_branch(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, [GitHub.Team.t()]} | {:error, GitHub.Error.t()}

Get teams with access to the protected branch

resources

Resources

Link to this function

get_top_paths(owner, repo, opts \\ [])

View Source
@spec get_top_paths(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Content.Traffic.t()]} | {:error, GitHub.Error.t()}

Get top referral paths

resources

Resources

Link to this function

get_top_referrers(owner, repo, opts \\ [])

View Source
@spec get_top_referrers(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.ReferrerTraffic.t()]} | {:error, GitHub.Error.t()}

Get top referral sources

resources

Resources

Link to this function

get_users_with_access_to_protected_branch(owner, repo, branch, opts \\ [])

View Source
@spec get_users_with_access_to_protected_branch(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, [GitHub.User.simple()]} | {:error, GitHub.Error.t()}

Get users with access to the protected branch

resources

Resources

Link to this function

get_views(owner, repo, opts \\ [])

View Source
@spec get_views(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.ViewTraffic.t()} | {:error, GitHub.Error.t()}

Get page views

options

Options

  • per (String.t()): The time frame to display results for.

resources

Resources

Link to this function

get_webhook(owner, repo, hook_id, opts \\ [])

View Source
@spec get_webhook(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Hook.t()} | {:error, GitHub.Error.t()}

Get a repository webhook

resources

Resources

Link to this function

get_webhook_config_for_repo(owner, repo, hook_id, opts \\ [])

View Source
@spec get_webhook_config_for_repo(String.t(), String.t(), integer(), keyword()) ::
  {:ok, GitHub.Webhook.Config.t()} | {:error, GitHub.Error.t()}

Get a webhook configuration for a repository

resources

Resources

Link to this function

get_webhook_delivery(owner, repo, hook_id, delivery_id, opts \\ [])

View Source
@spec get_webhook_delivery(String.t(), String.t(), integer(), integer(), keyword()) ::
  {:ok, GitHub.Hook.Delivery.t()} | {:error, GitHub.Error.t()}

Get a delivery for a repository webhook

resources

Resources

Link to this function

list_autolinks(owner, repo, opts \\ [])

View Source
@spec list_autolinks(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Autolink.t()]} | {:error, GitHub.Error.t()}

List all autolinks of a repository

options

Options

  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_branches(owner, repo, opts \\ [])

View Source
@spec list_branches(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.ShortBranch.t()]} | {:error, GitHub.Error.t()}

List branches

options

Options

  • protected (boolean): Setting to true returns only protected branches. When set to false, only unprotected branches are returned. Omitting this parameter returns all branches.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_branches_for_head_commit(owner, repo, commit_sha, opts \\ [])

View Source
@spec list_branches_for_head_commit(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Branch.Short.t()]} | {:error, GitHub.Error.t()}

List branches for HEAD commit

resources

Resources

Link to this function

list_collaborators(owner, repo, opts \\ [])

View Source
@spec list_collaborators(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Collaborator.t()]} | {:error, GitHub.Error.t()}

List repository collaborators

options

Options

  • affiliation (String.t()): Filter collaborators returned by their affiliation. outside means all outside collaborators of an organization-owned repository. direct means all collaborators with permissions to an organization-owned repository, regardless of organization membership status. all means all collaborators the authenticated user can see.
  • permission (String.t()): Filter collaborators by the permissions they have on the repository. If not specified, all collaborators will be returned.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_comments_for_commit(owner, repo, commit_sha, opts \\ [])

View Source
@spec list_comments_for_commit(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Commit.Comment.t()]} | {:error, GitHub.Error.t()}

List commit comments

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_commit_comments_for_repo(owner, repo, opts \\ [])

View Source
@spec list_commit_comments_for_repo(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Commit.Comment.t()]} | {:error, GitHub.Error.t()}

List commit comments for a repository

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_commit_statuses_for_ref(owner, repo, ref, opts \\ [])

View Source
@spec list_commit_statuses_for_ref(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Status.t()]} | {:error, GitHub.Error.t()}

List commit statuses for a reference

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_commits(owner, repo, opts \\ [])

View Source
@spec list_commits(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Commit.t()]} | {:error, GitHub.Error.t()}

List commits

options

Options

  • sha (String.t()): SHA or branch to start listing commits from. Default: the repository’s default branch (usually main).
  • path (String.t()): Only commits containing this file path will be returned.
  • author (String.t()): GitHub username or email address to use to filter by commit author.
  • committer (String.t()): GitHub username or email address to use to filter by commit committer.
  • since (String.t()): Only show notifications updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • until (String.t()): Only commits before this date will be returned. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_contributors(owner, repo, opts \\ [])

View Source
@spec list_contributors(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Contributor.t()]} | {:error, GitHub.Error.t()}

List repository contributors

options

Options

  • anon (String.t()): Set to 1 or true to include anonymous contributors in results.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_custom_deployment_rule_integrations(owner, repo, environment_name, opts \\ [])

View Source
@spec list_custom_deployment_rule_integrations(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

List custom deployment rule integrations available for an environment

options

Options

  • page (integer): Page number of the results to fetch.
  • per_page (integer): The number of results per page (max 100).

resources

Resources

Link to this function

list_deploy_keys(owner, repo, opts \\ [])

View Source
@spec list_deploy_keys(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.DeployKey.t()]} | {:error, GitHub.Error.t()}

List deploy keys

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_deployment_branch_policies(owner, repo, environment_name, opts \\ [])

View Source
@spec list_deployment_branch_policies(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

List deployment branch policies

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_deployment_statuses(owner, repo, deployment_id, opts \\ [])

View Source
@spec list_deployment_statuses(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Deployment.Status.t()]} | {:error, GitHub.Error.t()}

List deployment statuses

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_deployments(owner, repo, opts \\ [])

View Source
@spec list_deployments(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Deployment.t()]} | {:error, GitHub.Error.t()}

List deployments

options

Options

  • sha (String.t()): The SHA recorded at creation time.
  • ref (String.t()): The name of the ref. This can be a branch, tag, or SHA.
  • task (String.t()): The name of the task for the deployment (e.g., deploy or deploy:migrations).
  • environment (String.t() | nil): The name of the environment that was deployed to (e.g., staging or production).

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_for_authenticated_user(opts \\ [])

View Source
@spec list_for_authenticated_user(keyword()) ::
  {:ok, [GitHub.Repository.t()]} | {:error, GitHub.Error.t()}

List repositories for the authenticated user

options

Options

  • visibility (String.t()): Limit results to repositories with the specified visibility.
  • affiliation (String.t()): Comma-separated list of values. Can include:
  • owner: Repositories that are owned by the authenticated user.
  • collaborator: Repositories that the user has been added to as a collaborator.
  • organization_member: Repositories that the user has access to through being a member of an organization. This includes every repository on every team that the user is on.
  • type (String.t()): Limit results to repositories of the specified type. Will cause a 422 error if used in the same request as visibility or affiliation.
  • sort (String.t()): The property to sort the results by.
  • direction (String.t()): The order to sort by. Default: asc when using full_name, otherwise desc.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.
  • since (String.t()): Only show repositories updated after the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
  • before (String.t()): Only show repositories updated before the given time. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.

resources

Resources

Link to this function

list_for_org(org, opts \\ [])

View Source
@spec list_for_org(
  String.t(),
  keyword()
) :: {:ok, [GitHub.Repository.minimal()]} | {:error, GitHub.Error.t()}

List organization repositories

options

Options

  • type (String.t()): Specifies the types of repositories you want returned.
  • sort (String.t()): The property to sort the results by.
  • direction (String.t()): The order to sort by. Default: asc when using full_name, otherwise desc.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_for_user(username, opts \\ [])

View Source
@spec list_for_user(
  String.t(),
  keyword()
) :: {:ok, [GitHub.Repository.minimal()]} | {:error, GitHub.Error.t()}

List repositories for a user

options

Options

  • type (String.t()): Limit results to repositories of the specified type.
  • sort (String.t()): The property to sort the results by.
  • direction (String.t()): The order to sort by. Default: asc when using full_name, otherwise desc.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_forks(owner, repo, opts \\ [])

View Source
@spec list_forks(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Repository.minimal()]} | {:error, GitHub.Error.t()}

List forks

options

Options

  • sort (String.t()): The sort order. stargazers will sort by star count.
  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_invitations(owner, repo, opts \\ [])

View Source
@spec list_invitations(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Repository.Invitation.t()]} | {:error, GitHub.Error.t()}

List repository invitations

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_invitations_for_authenticated_user(opts \\ [])

View Source
@spec list_invitations_for_authenticated_user(keyword()) ::
  {:ok, [GitHub.Repository.Invitation.t()]} | {:error, GitHub.Error.t()}

List repository invitations for the authenticated user

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_languages(owner, repo, opts \\ [])

View Source
@spec list_languages(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Language.t()} | {:error, GitHub.Error.t()}

List repository languages

resources

Resources

Link to this function

list_pages_builds(owner, repo, opts \\ [])

View Source
@spec list_pages_builds(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Pages.Build.t()]} | {:error, GitHub.Error.t()}

List GitHub Pages builds

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

@spec list_public(keyword()) ::
  {:ok, [GitHub.Repository.minimal()]} | {:error, GitHub.Error.t()}

List public repositories

options

Options

  • since (integer): A repository ID. Only return repositories with an ID greater than this ID.

resources

Resources

Link to this function

list_pull_requests_associated_with_commit(owner, repo, commit_sha, opts \\ [])

View Source
@spec list_pull_requests_associated_with_commit(
  String.t(),
  String.t(),
  String.t(),
  keyword()
) ::
  {:ok, [GitHub.PullRequest.simple()]} | {:error, GitHub.Error.t()}

List pull requests associated with a commit

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_release_assets(owner, repo, release_id, opts \\ [])

View Source
@spec list_release_assets(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Release.Asset.t()]} | {:error, GitHub.Error.t()}

List release assets

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_releases(owner, repo, opts \\ [])

View Source
@spec list_releases(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Release.t()]} | {:error, GitHub.Error.t()}

List releases

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_tag_protection(owner, repo, opts \\ [])

View Source
@spec list_tag_protection(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.TagProtection.t()]} | {:error, GitHub.Error.t()}

List tag protection states for a repository

resources

Resources

Link to this function

list_tags(owner, repo, opts \\ [])

View Source
@spec list_tags(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Tag.t()]} | {:error, GitHub.Error.t()}

List repository tags

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_teams(owner, repo, opts \\ [])

View Source
@spec list_teams(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Team.t()]} | {:error, GitHub.Error.t()}

List repository teams

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

list_webhook_deliveries(owner, repo, hook_id, opts \\ [])

View Source
@spec list_webhook_deliveries(String.t(), String.t(), integer(), keyword()) ::
  {:ok, [GitHub.Hook.DeliveryItem.t()]} | {:error, GitHub.Error.t()}

List deliveries for a repository webhook

options

Options

  • per_page (integer): The number of results per page (max 100).
  • cursor (String.t()): Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the link header for the next and previous page cursors.
  • redelivery (boolean):

resources

Resources

Link to this function

list_webhooks(owner, repo, opts \\ [])

View Source
@spec list_webhooks(String.t(), String.t(), keyword()) ::
  {:ok, [GitHub.Hook.t()]} | {:error, GitHub.Error.t()}

List repository webhooks

options

Options

  • per_page (integer): The number of results per page (max 100).
  • page (integer): Page number of the results to fetch.

resources

Resources

Link to this function

merge(owner, repo, body, opts \\ [])

View Source
@spec merge(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Commit.t()} | {:error, GitHub.Error.t()}

Merge a branch

resources

Resources

Link to this function

merge_upstream(owner, repo, body, opts \\ [])

View Source
@spec merge_upstream(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.MergedUpstream.t()} | {:error, GitHub.Error.t()}

Sync a fork branch with the upstream repository

resources

Resources

Link to this function

ping_webhook(owner, repo, hook_id, opts \\ [])

View Source
@spec ping_webhook(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Ping a repository webhook

resources

Resources

Link to this function

redeliver_webhook_delivery(owner, repo, hook_id, delivery_id, opts \\ [])

View Source
@spec redeliver_webhook_delivery(
  String.t(),
  String.t(),
  integer(),
  integer(),
  keyword()
) ::
  {:ok, map()} | {:error, GitHub.Error.t()}

Redeliver a delivery for a repository webhook

resources

Resources

Link to this function

remove_app_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec remove_app_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.App.t()]} | {:error, GitHub.Error.t()}

Remove app access restrictions

resources

Resources

Link to this function

remove_collaborator(owner, repo, username, opts \\ [])

View Source
@spec remove_collaborator(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Remove a repository collaborator

resources

Resources

Link to this function

remove_status_check_contexts(owner, repo, branch, body, opts \\ [])

View Source
@spec remove_status_check_contexts(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [String.t()]} | {:error, GitHub.Error.t()}

Remove status check contexts

resources

Resources

Link to this function

remove_status_check_protection(owner, repo, branch, opts \\ [])

View Source
@spec remove_status_check_protection(String.t(), String.t(), String.t(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Remove status check protection

resources

Resources

Link to this function

remove_team_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec remove_team_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.Team.t()]} | {:error, GitHub.Error.t()}

Remove team access restrictions

resources

Resources

Link to this function

remove_user_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec remove_user_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.User.simple()]} | {:error, GitHub.Error.t()}

Remove user access restrictions

resources

Resources

Link to this function

rename_branch(owner, repo, branch, body, opts \\ [])

View Source
@spec rename_branch(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Branch.WithProtection.t()} | {:error, GitHub.Error.t()}

Rename a branch

resources

Resources

Link to this function

replace_all_topics(owner, repo, body, opts \\ [])

View Source
@spec replace_all_topics(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Topic.t()} | {:error, GitHub.Error.t()}

Replace all repository topics

resources

Resources

Link to this function

request_pages_build(owner, repo, opts \\ [])

View Source
@spec request_pages_build(String.t(), String.t(), keyword()) ::
  {:ok, GitHub.Pages.BuildStatus.t()} | {:error, GitHub.Error.t()}

Request a GitHub Pages build

resources

Resources

Link to this function

set_admin_branch_protection(owner, repo, branch, opts \\ [])

View Source
@spec set_admin_branch_protection(String.t(), String.t(), String.t(), keyword()) ::
  {:ok, GitHub.ProtectedBranch.AdminEnforced.t()} | {:error, GitHub.Error.t()}

Set admin branch protection

resources

Resources

Link to this function

set_app_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec set_app_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.App.t()]} | {:error, GitHub.Error.t()}

Set app access restrictions

resources

Resources

Link to this function

set_status_check_contexts(owner, repo, branch, body, opts \\ [])

View Source
@spec set_status_check_contexts(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) ::
  {:ok, [String.t()]} | {:error, GitHub.Error.t()}

Set status check contexts

resources

Resources

Link to this function

set_team_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec set_team_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.Team.t()]} | {:error, GitHub.Error.t()}

Set team access restrictions

resources

Resources

Link to this function

set_user_access_restrictions(owner, repo, branch, body, opts \\ [])

View Source
@spec set_user_access_restrictions(
  String.t(),
  String.t(),
  String.t(),
  map() | [String.t()],
  keyword()
) :: {:ok, [GitHub.User.simple()]} | {:error, GitHub.Error.t()}

Set user access restrictions

resources

Resources

Link to this function

test_push_webhook(owner, repo, hook_id, opts \\ [])

View Source
@spec test_push_webhook(String.t(), String.t(), integer(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Test the push repository webhook

resources

Resources

Link to this function

transfer(owner, repo, body, opts \\ [])

View Source
@spec transfer(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.minimal()} | {:error, GitHub.Error.t()}

Transfer a repository

resources

Resources

Link to this function

update(owner, repo, body, opts \\ [])

View Source
@spec update(String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.Repository.full()} | {:error, GitHub.Error.t()}

Update a repository

resources

Resources

Link to this function

update_branch_protection(owner, repo, branch, body, opts \\ [])

View Source
@spec update_branch_protection(String.t(), String.t(), String.t(), map(), keyword()) ::
  {:ok, GitHub.ProtectedBranch.t()} | {:error, GitHub.Error.t()}

Update branch protection

resources

Resources

Link to this function

update_commit_comment(owner, repo, comment_id, body, opts \\ [])

View Source
@spec update_commit_comment(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Commit.Comment.t()} | {:error, GitHub.Error.t()}

Update a commit comment

resources

Resources

Link to this function

update_deployment_branch_policy(owner, repo, environment_name, branch_policy_id, body, opts \\ [])

View Source
@spec update_deployment_branch_policy(
  String.t(),
  String.t(),
  String.t(),
  integer(),
  GitHub.Deployment.BranchPolicyNamePattern.t(),
  keyword()
) :: {:ok, GitHub.Deployment.BranchPolicy.t()} | {:error, GitHub.Error.t()}

Update a deployment branch policy

resources

Resources

Link to this function

update_information_about_pages_site(owner, repo, body, opts \\ [])

View Source
@spec update_information_about_pages_site(String.t(), String.t(), map(), keyword()) ::
  :ok | {:error, GitHub.Error.t()}

Update information about a GitHub Pages site

resources

Resources

Link to this function

update_invitation(owner, repo, invitation_id, body, opts \\ [])

View Source
@spec update_invitation(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Repository.Invitation.t()} | {:error, GitHub.Error.t()}

Update a repository invitation

resources

Resources

Link to this function

update_org_ruleset(org, ruleset_id, body, opts \\ [])

View Source
@spec update_org_ruleset(String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Update an organization repository ruleset

resources

Resources

Link to this function

update_pull_request_review_protection(owner, repo, branch, body, opts \\ [])

View Source
@spec update_pull_request_review_protection(
  String.t(),
  String.t(),
  String.t(),
  map(),
  keyword()
) ::
  {:ok, GitHub.ProtectedBranch.PullRequestReview.t()}
  | {:error, GitHub.Error.t()}

Update pull request review protection

resources

Resources

Link to this function

update_release(owner, repo, release_id, body, opts \\ [])

View Source
@spec update_release(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Release.t()} | {:error, GitHub.Error.t()}

Update a release

resources

Resources

Link to this function

update_release_asset(owner, repo, asset_id, body, opts \\ [])

View Source
@spec update_release_asset(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Release.Asset.t()} | {:error, GitHub.Error.t()}

Update a release asset

resources

Resources

Link to this function

update_repo_ruleset(owner, repo, ruleset_id, body, opts \\ [])

View Source
@spec update_repo_ruleset(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Repository.Ruleset.t()} | {:error, GitHub.Error.t()}

Update a repository ruleset

resources

Resources

Link to this function

update_status_check_protection(owner, repo, branch, body, opts \\ [])

View Source
@spec update_status_check_protection(
  String.t(),
  String.t(),
  String.t(),
  map(),
  keyword()
) ::
  {:ok, GitHub.StatusCheckPolicy.t()} | {:error, GitHub.Error.t()}

Update status check protection

resources

Resources

Link to this function

update_webhook(owner, repo, hook_id, body, opts \\ [])

View Source
@spec update_webhook(String.t(), String.t(), integer(), map(), keyword()) ::
  {:ok, GitHub.Hook.t()} | {:error, GitHub.Error.t()}

Update a repository webhook

resources

Resources

Link to this function

update_webhook_config_for_repo(owner, repo, hook_id, body, opts \\ [])

View Source
@spec update_webhook_config_for_repo(
  String.t(),
  String.t(),
  integer(),
  map(),
  keyword()
) ::
  {:ok, GitHub.Webhook.Config.t()} | {:error, GitHub.Error.t()}

Update a webhook configuration for a repository

resources

Resources

Link to this function

upload_release_asset(owner, repo, release_id, body, opts \\ [])

View Source
@spec upload_release_asset(String.t(), String.t(), integer(), String.t(), keyword()) ::
  {:ok, GitHub.Release.Asset.t()} | {:error, GitHub.Error.t()}

Upload a release asset

options

Options

  • name (String.t()):
  • label (String.t()):

resources

Resources