Forgejo

Struct Forgejo 

Source
pub struct Forgejo { /* private fields */ }
Expand description

An async client for Forgejo’s web API. For a blocking client, see [sync::Forgejo]

For more info on how to use this, see the crate level docs

Implementations§

Source§

impl Forgejo

Source

pub fn activitypub_instance_actor( &self, ) -> Request<'_, ActivitypubInstanceActor, ActivityPub>

Returns the instance’s Actor

Source

pub fn activitypub_instance_actor_inbox( &self, ) -> Request<'_, ActivitypubInstanceActorInbox, ()>

Send to the inbox

Source

pub fn activitypub_repository( &self, repository_id: i64, ) -> Request<'_, ActivitypubRepository, ActivityPub>

Returns the Repository actor for a repo

  • repository-id: repository ID of the repo
Source

pub fn activitypub_repository_inbox( &self, repository_id: i64, body: ForgeLike, ) -> Request<'_, ActivitypubRepositoryInbox, ()>

Send to the inbox

  • repository-id: repository ID of the repo
  • body: See ForgeLike
Source

pub fn activitypub_person( &self, user_id: i64, ) -> Request<'_, ActivitypubPerson, ActivityPub>

Returns the Person actor for a user

  • user-id: user ID of the user
Source

pub fn activitypub_person_activity_note( &self, user_id: u32, activity_id: u32, ) -> Request<'_, ActivitypubPersonActivityNote, ActivityPub>

Get a specific activity object of the user

  • user-id: user ID of the user
  • activity-id: activity ID of the sought activity
Source

pub fn activitypub_person_activity( &self, user_id: u32, activity_id: u32, ) -> Request<'_, ActivitypubPersonActivity, ActivityPub>

Get a specific activity of the user

  • user-id: user ID of the user
  • activity-id: activity ID of the sought activity
Source

pub fn activitypub_person_inbox( &self, user_id: i64, ) -> Request<'_, ActivitypubPersonInbox, ()>

Send to the inbox

  • user-id: user ID of the user
Source

pub fn activitypub_person_feed( &self, user_id: u32, ) -> Request<'_, ActivitypubPersonFeed, Vec<APPersonFollowItem>>

List the user’s recorded activity

  • user-id: user ID of the user
Source

pub fn admin_cron_list( &self, ) -> Request<'_, AdminCronList, (CronListHeaders, Vec<Cron>)>

List cron tasks

Source

pub fn admin_cron_run(&self, task: &str) -> Request<'_, AdminCronRun<'_>, ()>

Run cron task

  • task: task to run
Source

pub fn admin_get_all_emails(&self) -> Request<'_, AdminGetAllEmails, Vec<Email>>

List all users’ email addresses

Source

pub fn admin_search_emails( &self, query: AdminSearchEmailsQuery, ) -> Request<'_, AdminSearchEmails, Vec<Email>>

Search users’ email addresses

Source

pub fn admin_list_hooks( &self, ) -> Request<'_, AdminListHooks, (HookListHeaders, Vec<Hook>)>

List global (system) webhooks

Source

pub fn admin_create_hook( &self, body: CreateHookOption, ) -> Request<'_, AdminCreateHook, Hook>

Create a hook

Source

pub fn admin_get_hook(&self, id: i64) -> Request<'_, AdminGetHook, Hook>

Get a hook

  • id: id of the hook to get
Source

pub fn admin_delete_hook(&self, id: i64) -> Request<'_, AdminDeleteHook, ()>

Delete a hook

  • id: id of the hook to delete
Source

pub fn admin_edit_hook( &self, id: i64, body: EditHookOption, ) -> Request<'_, AdminEditHook, Hook>

Update a hook

Source

pub fn admin_get_all_orgs( &self, ) -> Request<'_, AdminGetAllOrgs, (OrganizationListHeaders, Vec<Organization>)>

List all organizations

Source

pub fn admin_list_quota_groups( &self, ) -> Request<'_, AdminListQuotaGroups, (QuotaGroupListHeaders, Vec<QuotaGroup>)>

List the available quota groups

Source

pub fn admin_create_quota_group( &self, group: CreateQuotaGroupOptions, ) -> Request<'_, AdminCreateQuotaGroup, QuotaGroup>

Create a new quota group

Source

pub fn admin_get_quota_group( &self, quotagroup: &str, ) -> Request<'_, AdminGetQuotaGroup<'_>, QuotaGroup>

Get information about the quota group

  • quotagroup: quota group to query
Source

pub fn admin_delete_quota_group( &self, quotagroup: &str, ) -> Request<'_, AdminDeleteQuotaGroup<'_>, ()>

Delete a quota group

  • quotagroup: quota group to delete
Source

pub fn admin_add_rule_to_quota_group( &self, quotagroup: &str, quotarule: &str, ) -> Request<'_, AdminAddRuleToQuotaGroup<'_>, ()>

Adds a rule to a quota group

  • quotagroup: quota group to add a rule to
  • quotarule: the name of the quota rule to add to the group
Source

pub fn admin_remove_rule_from_quota_group( &self, quotagroup: &str, quotarule: &str, ) -> Request<'_, AdminRemoveRuleFromQuotaGroup<'_>, ()>

Removes a rule from a quota group

  • quotagroup: quota group to remove a rule from
  • quotarule: the name of the quota rule to remove from the group
Source

pub fn admin_list_users_in_quota_group( &self, quotagroup: &str, ) -> Request<'_, AdminListUsersInQuotaGroup<'_>, (UserListHeaders, Vec<User>)>

List users in a quota group

  • quotagroup: quota group to list members of
Source

pub fn admin_add_user_to_quota_group( &self, quotagroup: &str, username: &str, ) -> Request<'_, AdminAddUserToQuotaGroup<'_>, ()>

Add a user to a quota group

  • quotagroup: quota group to add the user to
  • username: username of the user to add to the quota group
Source

pub fn admin_remove_user_from_quota_group( &self, quotagroup: &str, username: &str, ) -> Request<'_, AdminRemoveUserFromQuotaGroup<'_>, ()>

Remove a user from a quota group

  • quotagroup: quota group to remove a user from
  • username: username of the user to remove from the quota group
Source

pub fn admin_list_quota_rules( &self, ) -> Request<'_, AdminListQuotaRules, (QuotaRuleInfoListHeaders, Vec<QuotaRuleInfo>)>

List the available quota rules

Source

pub fn admin_create_quota_rule( &self, rule: CreateQuotaRuleOptions, ) -> Request<'_, AdminCreateQuotaRule, QuotaRuleInfo>

Create a new quota rule

Source

pub fn admin_get_quota_rule( &self, quotarule: &str, ) -> Request<'_, AdminGetQuotaRule<'_>, QuotaRuleInfo>

Get information about a quota rule

  • quotarule: quota rule to query
Source

pub fn admin_delete_quota_rule( &self, quotarule: &str, ) -> Request<'_, AdminDeleteQuotaRule<'_>, ()>

Deletes a quota rule

  • quotarule: quota rule to delete
Source

pub fn admin_edit_quota_rule( &self, quotarule: &str, rule: EditQuotaRuleOptions, ) -> Request<'_, AdminEditQuotaRule<'_>, QuotaRuleInfo>

Change an existing quota rule

Source

pub fn admin_search_run_jobs( &self, query: AdminSearchRunJobsQuery, ) -> Request<'_, AdminSearchRunJobs, Vec<ActionRunJob>>

Search action jobs according filter conditions

Source

pub fn admin_get_runner_registration_token( &self, ) -> Request<'_, AdminGetRunnerRegistrationToken, RegistrationToken>

Get an global actions runner registration token

Source

pub fn admin_unadopted_list( &self, query: AdminUnadoptedListQuery, ) -> Request<'_, AdminUnadoptedList, Vec<String>>

List unadopted repositories

Source

pub fn admin_adopt_repository( &self, owner: &str, repo: &str, ) -> Request<'_, AdminAdoptRepository<'_>, ()>

Adopt unadopted files as a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn admin_delete_unadopted_repository( &self, owner: &str, repo: &str, ) -> Request<'_, AdminDeleteUnadoptedRepository<'_>, ()>

Delete unadopted files

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn admin_search_users( &self, query: AdminSearchUsersQuery, ) -> Request<'_, AdminSearchUsers, (UserListHeaders, Vec<User>)>

Search users according filter conditions

Source

pub fn admin_create_user( &self, body: CreateUserOption, ) -> Request<'_, AdminCreateUser, User>

Create a user account

Source

pub fn admin_delete_user( &self, username: &str, query: AdminDeleteUserQuery, ) -> Request<'_, AdminDeleteUser<'_>, ()>

Delete user account

  • username: username of user to delete
Source

pub fn admin_edit_user( &self, username: &str, body: EditUserOption, ) -> Request<'_, AdminEditUser<'_>, User>

Edit an existing user

Source

pub fn admin_create_public_key( &self, username: &str, key: CreateKeyOption, ) -> Request<'_, AdminCreatePublicKey<'_>, PublicKey>

Add an SSH public key to user’s account

Source

pub fn admin_delete_user_public_key( &self, username: &str, id: i64, ) -> Request<'_, AdminDeleteUserPublicKey<'_>, ()>

Remove a public key from user’s account

  • username: username of user
  • id: id of the key to delete
Source

pub fn admin_create_org( &self, username: &str, organization: CreateOrgOption, ) -> Request<'_, AdminCreateOrg<'_>, Organization>

Create an organization

  • username: username of the user that will own the created organization
  • organization: See CreateOrgOption
Source

pub fn admin_get_user_quota( &self, username: &str, ) -> Request<'_, AdminGetUserQuota<'_>, QuotaInfo>

Get the user’s quota info

  • username: username of user to query
Source

pub fn admin_set_user_quota_groups( &self, username: &str, groups: SetUserQuotaGroupsOptions, ) -> Request<'_, AdminSetUserQuotaGroups<'_>, ()>

Set the user’s quota groups to a given list.

  • username: username of the user to modify the quota groups from
  • groups: list of groups that the user should be a member of See SetUserQuotaGroupsOptions
Source

pub fn admin_rename_user( &self, username: &str, body: RenameUserOption, ) -> Request<'_, AdminRenameUser<'_>, ()>

Rename a user

Source

pub fn admin_create_repo( &self, username: &str, repository: CreateRepoOption, ) -> Request<'_, AdminCreateRepo<'_>, Repository>

Create a repository on behalf of a user

  • username: username of the user. This user will own the created repository
  • repository: See CreateRepoOption
Source

pub fn list_gitignores_templates( &self, ) -> Request<'_, ListGitignoresTemplates, Vec<String>>

Returns a list of all gitignore templates

Source

pub fn get_gitignore_template_info( &self, name: &str, ) -> Request<'_, GetGitignoreTemplateInfo<'_>, GitignoreTemplateInfo>

Returns information about a gitignore template

  • name: name of the template
Source

pub fn list_label_templates( &self, ) -> Request<'_, ListLabelTemplates, Vec<String>>

Returns a list of all label templates

Source

pub fn get_label_template_info( &self, name: &str, ) -> Request<'_, GetLabelTemplateInfo<'_>, Vec<LabelTemplate>>

Returns all labels in a template

  • name: name of the template
Source

pub fn list_license_templates( &self, ) -> Request<'_, ListLicenseTemplates, Vec<LicensesTemplateListEntry>>

Returns a list of all license templates

Source

pub fn get_license_template_info( &self, name: &str, ) -> Request<'_, GetLicenseTemplateInfo<'_>, LicenseTemplateInfo>

Returns information about a license template

  • name: name of the license
Source

pub fn render_markdown( &self, body: MarkdownOption, ) -> Request<'_, RenderMarkdown, String>

Render a markdown document as HTML

Source

pub fn render_markdown_raw( &self, body: String, ) -> Request<'_, RenderMarkdownRaw, String>

Render raw markdown as HTML

  • body: Request body to render See String
Source

pub fn render_markup( &self, body: MarkupOption, ) -> Request<'_, RenderMarkup, String>

Render a markup document as HTML

Source

pub fn get_node_info(&self) -> Request<'_, GetNodeInfo, NodeInfo>

Returns the nodeinfo of the Forgejo application

Source

pub fn notify_get_list( &self, query: NotifyGetListQuery, ) -> Request<'_, NotifyGetList, (NotificationThreadListHeaders, Vec<NotificationThread>)>

List users’s notification threads

Source

pub fn notify_read_list( &self, query: NotifyReadListQuery, ) -> Request<'_, NotifyReadList, (NotificationThreadListHeaders, Vec<NotificationThread>)>

Mark notification threads as read, pinned or unread

Source

pub fn notify_new_available( &self, ) -> Request<'_, NotifyNewAvailable, NotificationCount>

Check if unread notifications exist

Source

pub fn notify_get_thread( &self, id: i64, ) -> Request<'_, NotifyGetThread, NotificationThread>

Get notification thread by ID

  • id: id of notification thread
Source

pub fn notify_read_thread( &self, id: i64, query: NotifyReadThreadQuery, ) -> Request<'_, NotifyReadThread, NotificationThread>

Mark notification thread as read by ID

  • id: id of notification thread
Source

pub fn create_org_repo_deprecated( &self, org: &str, body: CreateRepoOption, ) -> Request<'_, CreateOrgRepoDeprecated<'_>, Repository>

Create a repository in an organization

Source

pub fn org_get_all( &self, ) -> Request<'_, OrgGetAll, (OrganizationListHeaders, Vec<Organization>)>

List all organizations

Source

pub fn org_create( &self, organization: CreateOrgOption, ) -> Request<'_, OrgCreate, Organization>

Create an organization

Source

pub fn org_get(&self, org: &str) -> Request<'_, OrgGet<'_>, Organization>

Get an organization

  • org: name of the organization to get
Source

pub fn org_delete(&self, org: &str) -> Request<'_, OrgDelete<'_>, ()>

Delete an organization

  • org: organization that is to be deleted
Source

pub fn org_edit( &self, org: &str, body: EditOrgOption, ) -> Request<'_, OrgEdit<'_>, Organization>

Edit an organization

Source

pub fn org_search_run_jobs( &self, org: &str, query: OrgSearchRunJobsQuery, ) -> Request<'_, OrgSearchRunJobs<'_>, Vec<ActionRunJob>>

Search for organization’s action jobs according filter conditions

  • org: name of the organization
Source

pub fn org_get_runner_registration_token( &self, org: &str, ) -> Request<'_, OrgGetRunnerRegistrationToken<'_>, RegistrationToken>

Get an organization’s actions runner registration token

  • org: name of the organization
Source

pub fn org_list_actions_secrets( &self, org: &str, ) -> Request<'_, OrgListActionsSecrets<'_>, (SecretListHeaders, Vec<Secret>)>

List actions secrets of an organization

  • org: name of the organization
Source

pub fn update_org_secret( &self, org: &str, secretname: &str, body: CreateOrUpdateSecretOption, ) -> Request<'_, UpdateOrgSecret<'_>, ()>

Create or Update a secret value in an organization

Source

pub fn delete_org_secret( &self, org: &str, secretname: &str, ) -> Request<'_, DeleteOrgSecret<'_>, ()>

Delete a secret in an organization

  • org: name of organization
  • secretname: name of the secret
Source

pub fn get_org_variables_list( &self, org: &str, ) -> Request<'_, GetOrgVariablesList<'_>, (VariableListHeaders, Vec<ActionVariable>)>

List variables of an organization

  • org: name of the organization
Source

pub fn get_org_variable( &self, org: &str, variablename: &str, ) -> Request<'_, GetOrgVariable<'_>, ActionVariable>

Get organization’s variable by name

  • org: name of the organization
  • variablename: name of the variable
Source

pub fn update_org_variable( &self, org: &str, variablename: &str, body: UpdateVariableOption, ) -> Request<'_, UpdateOrgVariable<'_>, ()>

Update variable in organization

Source

pub fn create_org_variable( &self, org: &str, variablename: &str, body: CreateVariableOption, ) -> Request<'_, CreateOrgVariable<'_>, ()>

Create a new variable in organization

Source

pub fn delete_org_variable( &self, org: &str, variablename: &str, ) -> Request<'_, DeleteOrgVariable<'_>, ()>

Delete organization’s variable by name

  • org: name of the organization
  • variablename: name of the variable
Source

pub fn org_list_activity_feeds( &self, org: &str, query: OrgListActivityFeedsQuery, ) -> Request<'_, OrgListActivityFeeds<'_>, (ActivityFeedsListHeaders, Vec<Activity>)>

List an organization’s activity feeds

  • org: name of the org
Source

pub fn org_update_avatar( &self, org: &str, body: UpdateUserAvatarOption, ) -> Request<'_, OrgUpdateAvatar<'_>, ()>

Update an organization’s avatar

Source

pub fn org_delete_avatar( &self, org: &str, ) -> Request<'_, OrgDeleteAvatar<'_>, ()>

Delete an organization’s avatar. It will be replaced by a default one

  • org: name of the organization
Source

pub fn org_block_user( &self, org: &str, username: &str, ) -> Request<'_, OrgBlockUser<'_>, ()>

Blocks a user from the organization

  • org: name of the org
  • username: username of the user
Source

pub fn org_list_hooks( &self, org: &str, ) -> Request<'_, OrgListHooks<'_>, (HookListHeaders, Vec<Hook>)>

List an organization’s webhooks

  • org: name of the organization
Source

pub fn org_create_hook( &self, org: &str, body: CreateHookOption, ) -> Request<'_, OrgCreateHook<'_>, Hook>

Create a hook

Source

pub fn org_get_hook( &self, org: &str, id: i64, ) -> Request<'_, OrgGetHook<'_>, Hook>

Get a hook

  • org: name of the organization
  • id: id of the hook to get
Source

pub fn org_delete_hook( &self, org: &str, id: i64, ) -> Request<'_, OrgDeleteHook<'_>, ()>

Delete a hook

  • org: name of the organization
  • id: id of the hook to delete
Source

pub fn org_edit_hook( &self, org: &str, id: i64, body: EditHookOption, ) -> Request<'_, OrgEditHook<'_>, Hook>

Update a hook

  • org: name of the organization
  • id: id of the hook to update
  • body: See EditHookOption
Source

pub fn org_list_labels( &self, org: &str, query: OrgListLabelsQuery, ) -> Request<'_, OrgListLabels<'_>, (LabelListHeaders, Vec<Label>)>

List an organization’s labels

  • org: name of the organization
Source

pub fn org_create_label( &self, org: &str, body: CreateLabelOption, ) -> Request<'_, OrgCreateLabel<'_>, Label>

Create a label for an organization

Source

pub fn org_get_label( &self, org: &str, id: i64, ) -> Request<'_, OrgGetLabel<'_>, Label>

Get a single label

  • org: name of the organization
  • id: id of the label to get
Source

pub fn org_delete_label( &self, org: &str, id: i64, ) -> Request<'_, OrgDeleteLabel<'_>, ()>

Delete a label

  • org: name of the organization
  • id: id of the label to delete
Source

pub fn org_edit_label( &self, org: &str, id: i64, body: EditLabelOption, ) -> Request<'_, OrgEditLabel<'_>, Label>

Update a label

  • org: name of the organization
  • id: id of the label to edit
  • body: See EditLabelOption
Source

pub fn org_list_blocked_users( &self, org: &str, ) -> Request<'_, OrgListBlockedUsers<'_>, (BlockedUserListHeaders, Vec<BlockedUser>)>

List the organization’s blocked users

  • org: name of the org
Source

pub fn org_list_members( &self, org: &str, ) -> Request<'_, OrgListMembers<'_>, (UserListHeaders, Vec<User>)>

List an organization’s members

  • org: name of the organization
Source

pub fn org_is_member( &self, org: &str, username: &str, ) -> Request<'_, OrgIsMember<'_>, ()>

Check if a user is a member of an organization

  • org: name of the organization
  • username: username of the user
Source

pub fn org_delete_member( &self, org: &str, username: &str, ) -> Request<'_, OrgDeleteMember<'_>, ()>

Remove a member from an organization

  • org: name of the organization
  • username: username of the user
Source

pub fn org_list_public_members( &self, org: &str, ) -> Request<'_, OrgListPublicMembers<'_>, (UserListHeaders, Vec<User>)>

List an organization’s public members

  • org: name of the organization
Source

pub fn org_is_public_member( &self, org: &str, username: &str, ) -> Request<'_, OrgIsPublicMember<'_>, ()>

Check if a user is a public member of an organization

  • org: name of the organization
  • username: username of the user
Source

pub fn org_publicize_member( &self, org: &str, username: &str, ) -> Request<'_, OrgPublicizeMember<'_>, ()>

Publicize a user’s membership

  • org: name of the organization
  • username: username of the user
Source

pub fn org_conceal_member( &self, org: &str, username: &str, ) -> Request<'_, OrgConcealMember<'_>, ()>

Conceal a user’s membership

  • org: name of the organization
  • username: username of the user
Source

pub fn org_get_quota( &self, org: &str, ) -> Request<'_, OrgGetQuota<'_>, QuotaInfo>

Get quota information for an organization

  • org: name of the organization
Source

pub fn org_list_quota_artifacts( &self, org: &str, ) -> Request<'_, OrgListQuotaArtifacts<'_>, (QuotaUsedArtifactListHeaders, Vec<QuotaUsedArtifact>)>

List the artifacts affecting the organization’s quota

  • org: name of the organization
Source

pub fn org_list_quota_attachments( &self, org: &str, ) -> Request<'_, OrgListQuotaAttachments<'_>, (QuotaUsedAttachmentListHeaders, Vec<QuotaUsedAttachment>)>

List the attachments affecting the organization’s quota

  • org: name of the organization
Source

pub fn org_check_quota( &self, org: &str, query: OrgCheckQuotaQuery, ) -> Request<'_, OrgCheckQuota<'_>, bool>

Check if the organization is over quota for a given subject

  • org: name of the organization
Source

pub fn org_list_quota_packages( &self, org: &str, ) -> Request<'_, OrgListQuotaPackages<'_>, (QuotaUsedPackageListHeaders, Vec<QuotaUsedPackage>)>

List the packages affecting the organization’s quota

  • org: name of the organization
Source

pub fn rename_org( &self, org: &str, body: RenameOrgOption, ) -> Request<'_, RenameOrg<'_>, ()>

Rename an organization

Source

pub fn org_list_repos( &self, org: &str, ) -> Request<'_, OrgListRepos<'_>, (RepositoryListHeaders, Vec<Repository>)>

List an organization’s repos

  • org: name of the organization
Source

pub fn create_org_repo( &self, org: &str, body: CreateRepoOption, ) -> Request<'_, CreateOrgRepo<'_>, Repository>

Create a repository in an organization

Source

pub fn org_list_teams( &self, org: &str, ) -> Request<'_, OrgListTeams<'_>, (TeamListHeaders, Vec<Team>)>

List an organization’s teams

  • org: name of the organization
Source

pub fn org_create_team( &self, org: &str, body: CreateTeamOption, ) -> Request<'_, OrgCreateTeam<'_>, Team>

Create a team

Search for teams within an organization

  • org: name of the organization
Source

pub fn org_unblock_user( &self, org: &str, username: &str, ) -> Request<'_, OrgUnblockUser<'_>, ()>

Unblock a user from the organization

  • org: name of the org
  • username: username of the user
Source

pub fn list_packages( &self, owner: &str, query: ListPackagesQuery, ) -> Request<'_, ListPackages<'_>, (PackageListHeaders, Vec<Package>)>

Gets all packages of an owner

  • owner: owner of the packages

Link a package to a repository

  • owner: owner of the package
  • type: type of the package
  • name: name of the package
  • repo_name: name of the repository to link.

Unlink a package from a repository

  • owner: owner of the package
  • type: type of the package
  • name: name of the package
Source

pub fn get_package( &self, owner: &str, type: &str, name: &str, version: &str, ) -> Request<'_, GetPackage<'_>, Package>

Gets a package

  • owner: owner of the package
  • type: type of the package
  • name: name of the package
  • version: version of the package
Source

pub fn delete_package( &self, owner: &str, type: &str, name: &str, version: &str, ) -> Request<'_, DeletePackage<'_>, ()>

Delete a package

  • owner: owner of the package
  • type: type of the package
  • name: name of the package
  • version: version of the package
Source

pub fn list_package_files( &self, owner: &str, type: &str, name: &str, version: &str, ) -> Request<'_, ListPackageFiles<'_>, (PackageFileListHeaders, Vec<PackageFile>)>

Gets all files of a package

  • owner: owner of the package
  • type: type of the package
  • name: name of the package
  • version: version of the package
Source

pub fn issue_search_issues( &self, query: IssueSearchIssuesQuery, ) -> Request<'_, IssueSearchIssues, (IssueListHeaders, Vec<Issue>)>

Search for issues across the repositories that the user has access to

Source

pub fn repo_migrate( &self, body: MigrateRepoOptions, ) -> Request<'_, RepoMigrate, Repository>

Migrate a remote git repository

Search for repositories

Source

pub fn repo_get( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGet<'_>, Repository>

Get a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_delete( &self, owner: &str, repo: &str, ) -> Request<'_, RepoDelete<'_>, ()>

Delete a repository

  • owner: owner of the repo to delete
  • repo: name of the repo to delete
Source

pub fn repo_edit( &self, owner: &str, repo: &str, body: EditRepoOption, ) -> Request<'_, RepoEdit<'_>, Repository>

Edit a repository’s properties. Only fields that are set will be changed.

  • owner: owner of the repo to edit
  • repo: name of the repo to edit
  • body: Properties of a repo that you can edit See EditRepoOption
Source

pub fn repo_search_run_jobs( &self, owner: &str, repo: &str, query: RepoSearchRunJobsQuery, ) -> Request<'_, RepoSearchRunJobs<'_>, Vec<ActionRunJob>>

Search for repository’s action jobs according filter conditions

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_runner_registration_token( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetRunnerRegistrationToken<'_>, RegistrationToken>

Get a repository’s actions runner registration token

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn list_action_runs( &self, owner: &str, repo: &str, query: ListActionRunsQuery, ) -> Request<'_, ListActionRuns<'_>, ListActionRunResponse>

List a repository’s action runs

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn get_action_run( &self, owner: &str, repo: &str, run_id: i64, ) -> Request<'_, GetActionRun<'_>, ActionRun>

Get an action run

  • owner: owner of the repo
  • repo: name of the repo
  • run_id: id of the action run
Source

pub fn repo_list_actions_secrets( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListActionsSecrets<'_>, (SecretListHeaders, Vec<Secret>)>

List an repo’s actions secrets

  • owner: owner of the repository
  • repo: name of the repository
Source

pub fn update_repo_secret( &self, owner: &str, repo: &str, secretname: &str, body: CreateOrUpdateSecretOption, ) -> Request<'_, UpdateRepoSecret<'_>, ()>

Create or Update a secret value in a repository

Source

pub fn delete_repo_secret( &self, owner: &str, repo: &str, secretname: &str, ) -> Request<'_, DeleteRepoSecret<'_>, ()>

Delete a secret in a repository

  • owner: owner of the repository
  • repo: name of the repository
  • secretname: name of the secret
Source

pub fn list_action_tasks( &self, owner: &str, repo: &str, ) -> Request<'_, ListActionTasks<'_>, ActionTaskResponse>

List a repository’s action tasks

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn get_repo_variables_list( &self, owner: &str, repo: &str, ) -> Request<'_, GetRepoVariablesList<'_>, (VariableListHeaders, Vec<ActionVariable>)>

Get repo-level variables list

  • owner: name of the owner
  • repo: name of the repository
Source

pub fn get_repo_variable( &self, owner: &str, repo: &str, variablename: &str, ) -> Request<'_, GetRepoVariable<'_>, ActionVariable>

Get a repo-level variable

  • owner: name of the owner
  • repo: name of the repository
  • variablename: name of the variable
Source

pub fn update_repo_variable( &self, owner: &str, repo: &str, variablename: &str, body: UpdateVariableOption, ) -> Request<'_, UpdateRepoVariable<'_>, ()>

Update a repo-level variable

  • owner: name of the owner
  • repo: name of the repository
  • variablename: name of the variable
  • body: See UpdateVariableOption
Source

pub fn create_repo_variable( &self, owner: &str, repo: &str, variablename: &str, body: CreateVariableOption, ) -> Request<'_, CreateRepoVariable<'_>, ()>

Create a repo-level variable

  • owner: name of the owner
  • repo: name of the repository
  • variablename: name of the variable
  • body: See CreateVariableOption
Source

pub fn delete_repo_variable( &self, owner: &str, repo: &str, variablename: &str, ) -> Request<'_, DeleteRepoVariable<'_>, ()>

Delete a repo-level variable

  • owner: name of the owner
  • repo: name of the repository
  • variablename: name of the variable
Source

pub fn dispatch_workflow( &self, owner: &str, repo: &str, workflowfilename: &str, body: DispatchWorkflowOption, ) -> Request<'_, DispatchWorkflow<'_>, Option<DispatchWorkflowRun>>

Dispatches a workflow

  • owner: owner of the repo
  • repo: name of the repo
  • workflowfilename: name of the workflow
  • body: See DispatchWorkflowOption
Source

pub fn repo_list_activity_feeds( &self, owner: &str, repo: &str, query: RepoListActivityFeedsQuery, ) -> Request<'_, RepoListActivityFeeds<'_>, (ActivityFeedsListHeaders, Vec<Activity>)>

List a repository’s activity feeds

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_archive( &self, owner: &str, repo: &str, archive: &str, ) -> Request<'_, RepoGetArchive<'_>, Bytes>

Get an archive of a repository

  • owner: owner of the repo
  • repo: name of the repo
  • archive: the git reference for download with attached archive format (e.g. master.zip)
Source

pub fn repo_get_assignees( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetAssignees<'_>, (UserListHeaders, Vec<User>)>

Return all users that have write access and can be assigned to issues

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_update_avatar( &self, owner: &str, repo: &str, body: UpdateRepoAvatarOption, ) -> Request<'_, RepoUpdateAvatar<'_>, ()>

Update a repository’s avatar

Source

pub fn repo_delete_avatar( &self, owner: &str, repo: &str, ) -> Request<'_, RepoDeleteAvatar<'_>, ()>

Delete a repository’s avatar

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_list_branch_protection( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListBranchProtection<'_>, Vec<BranchProtection>>

List branch protections for a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_branch_protection( &self, owner: &str, repo: &str, body: CreateBranchProtectionOption, ) -> Request<'_, RepoCreateBranchProtection<'_>, BranchProtection>

Create a branch protections for a repository

Source

pub fn repo_get_branch_protection( &self, owner: &str, repo: &str, name: &str, ) -> Request<'_, RepoGetBranchProtection<'_>, BranchProtection>

Get a specific branch protection for the repository

  • owner: owner of the repo
  • repo: name of the repo
  • name: name of protected branch
Source

pub fn repo_delete_branch_protection( &self, owner: &str, repo: &str, name: &str, ) -> Request<'_, RepoDeleteBranchProtection<'_>, ()>

Delete a specific branch protection for the repository

  • owner: owner of the repo
  • repo: name of the repo
  • name: name of protected branch
Source

pub fn repo_edit_branch_protection( &self, owner: &str, repo: &str, name: &str, body: EditBranchProtectionOption, ) -> Request<'_, RepoEditBranchProtection<'_>, BranchProtection>

Edit a branch protections for a repository. Only fields that are set will be changed

Source

pub fn repo_list_branches( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListBranches<'_>, (BranchListHeaders, Vec<Branch>)>

List a repository’s branches

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_branch( &self, owner: &str, repo: &str, body: CreateBranchRepoOption, ) -> Request<'_, RepoCreateBranch<'_>, Branch>

Create a branch

Source

pub fn repo_get_branch( &self, owner: &str, repo: &str, branch: &str, ) -> Request<'_, RepoGetBranch<'_>, Branch>

Retrieve a specific branch from a repository, including its effective branch protection

  • owner: owner of the repo
  • repo: name of the repo
  • branch: branch to get
Source

pub fn repo_delete_branch( &self, owner: &str, repo: &str, branch: &str, ) -> Request<'_, RepoDeleteBranch<'_>, ()>

Delete a specific branch from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • branch: branch to delete
Source

pub fn repo_update_branch( &self, owner: &str, repo: &str, branch: &str, body: UpdateBranchRepoOption, ) -> Request<'_, RepoUpdateBranch<'_>, ()>

Update a branch

Source

pub fn repo_list_collaborators( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListCollaborators<'_>, (UserListHeaders, Vec<User>)>

List a repository’s collaborators

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_check_collaborator( &self, owner: &str, repo: &str, collaborator: &str, ) -> Request<'_, RepoCheckCollaborator<'_>, ()>

Check if a user is a collaborator of a repository

  • owner: owner of the repo
  • repo: name of the repo
  • collaborator: username of the collaborator
Source

pub fn repo_add_collaborator( &self, owner: &str, repo: &str, collaborator: &str, body: AddCollaboratorOption, ) -> Request<'_, RepoAddCollaborator<'_>, ()>

Add a collaborator to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • collaborator: username of the collaborator to add
  • body: See AddCollaboratorOption
Source

pub fn repo_delete_collaborator( &self, owner: &str, repo: &str, collaborator: &str, ) -> Request<'_, RepoDeleteCollaborator<'_>, ()>

Delete a collaborator from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • collaborator: username of the collaborator to delete
Source

pub fn repo_get_repo_permissions( &self, owner: &str, repo: &str, collaborator: &str, ) -> Request<'_, RepoGetRepoPermissions<'_>, RepoCollaboratorPermission>

Get repository permissions for a user

  • owner: owner of the repo
  • repo: name of the repo
  • collaborator: username of the collaborator
Source

pub fn repo_get_all_commits( &self, owner: &str, repo: &str, query: RepoGetAllCommitsQuery, ) -> Request<'_, RepoGetAllCommits<'_>, (CommitListHeaders, Vec<Commit>)>

Get a list of all commits from a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_combined_status_by_ref( &self, owner: &str, repo: &str, ref: &str, ) -> Request<'_, RepoGetCombinedStatusByRef<'_>, (CombinedStatusHeaders, CombinedStatus)>

Get a commit’s combined status, by branch/tag/commit reference

  • owner: owner of the repo
  • repo: name of the repo
  • ref: name of branch/tag/commit
Source

pub fn repo_list_statuses_by_ref( &self, owner: &str, repo: &str, ref: &str, query: RepoListStatusesByRefQuery, ) -> Request<'_, RepoListStatusesByRef<'_>, (CommitStatusListHeaders, Vec<CommitStatus>)>

Get a commit’s statuses, by branch/tag/commit reference

  • owner: owner of the repo
  • repo: name of the repo
  • ref: name of branch/tag/commit
Source

pub fn repo_get_commit_pull_request( &self, owner: &str, repo: &str, sha: &str, ) -> Request<'_, RepoGetCommitPullRequest<'_>, PullRequest>

Get the pull request of the commit

  • owner: owner of the repo
  • repo: name of the repo
  • sha: SHA of the commit to get
Source

pub fn repo_compare_diff( &self, owner: &str, repo: &str, basehead: &str, ) -> Request<'_, RepoCompareDiff<'_>, Compare>

Get commit comparison information

  • owner: owner of the repo
  • repo: name of the repo
  • basehead: compare two branches or commits
Source

pub fn repo_get_contents_list( &self, owner: &str, repo: &str, query: RepoGetContentsListQuery, ) -> Request<'_, RepoGetContentsList<'_>, Vec<ContentsResponse>>

Gets the metadata of all the entries of the root dir

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_change_files( &self, owner: &str, repo: &str, body: ChangeFilesOptions, ) -> Request<'_, RepoChangeFiles<'_>, FilesResponse>

Modify multiple files in a repository

Source

pub fn repo_get_contents( &self, owner: &str, repo: &str, filepath: &str, query: RepoGetContentsQuery, ) -> Request<'_, RepoGetContents<'_>, ContentsResponse>

Gets the metadata and contents (if a file) of an entry in a repository, or a list of entries if a dir

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: path of the dir, file, symlink or submodule in the repo
Source

pub fn repo_update_file( &self, owner: &str, repo: &str, filepath: &str, body: UpdateFileOptions, ) -> Request<'_, RepoUpdateFile<'_>, FileResponse>

Update a file in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: path of the file to update
  • body: See UpdateFileOptions
Source

pub fn repo_create_file( &self, owner: &str, repo: &str, filepath: &str, body: CreateFileOptions, ) -> Request<'_, RepoCreateFile<'_>, FileResponse>

Create a file in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: path of the file to create
  • body: See CreateFileOptions
Source

pub fn repo_delete_file( &self, owner: &str, repo: &str, filepath: &str, body: DeleteFileOptions, ) -> Request<'_, RepoDeleteFile<'_>, FileDeleteResponse>

Delete a file in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: path of the file to delete
  • body: See DeleteFileOptions
Source

pub fn repo_convert( &self, owner: &str, repo: &str, ) -> Request<'_, RepoConvert<'_>, Repository>

Convert a mirror repo to a normal repo.

  • owner: owner of the repo to convert
  • repo: name of the repo to convert
Source

pub fn repo_apply_diff_patch( &self, owner: &str, repo: &str, body: UpdateFileOptions, ) -> Request<'_, RepoApplyDiffPatch<'_>, FileResponse>

Apply diff patch to repository

Source

pub fn repo_get_editor_config( &self, owner: &str, repo: &str, filepath: &str, query: RepoGetEditorConfigQuery, ) -> Request<'_, RepoGetEditorConfig<'_>, BTreeMap<String, String>>

Get the EditorConfig definitions of a file in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: filepath of file to get
Source

pub fn repo_list_flags( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListFlags<'_>, Vec<String>>

List a repository’s flags

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_replace_all_flags( &self, owner: &str, repo: &str, body: ReplaceFlagsOption, ) -> Request<'_, RepoReplaceAllFlags<'_>, ()>

Replace all flags of a repository

Source

pub fn repo_delete_all_flags( &self, owner: &str, repo: &str, ) -> Request<'_, RepoDeleteAllFlags<'_>, ()>

Remove all flags from a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_check_flag( &self, owner: &str, repo: &str, flag: &str, ) -> Request<'_, RepoCheckFlag<'_>, ()>

Check if a repository has a given flag

  • owner: owner of the repo
  • repo: name of the repo
  • flag: name of the flag
Source

pub fn repo_add_flag( &self, owner: &str, repo: &str, flag: &str, ) -> Request<'_, RepoAddFlag<'_>, ()>

Add a flag to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • flag: name of the flag
Source

pub fn repo_delete_flag( &self, owner: &str, repo: &str, flag: &str, ) -> Request<'_, RepoDeleteFlag<'_>, ()>

Remove a flag from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • flag: name of the flag
Source

pub fn list_forks( &self, owner: &str, repo: &str, ) -> Request<'_, ListForks<'_>, (RepositoryListHeaders, Vec<Repository>)>

List a repository’s forks

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn create_fork( &self, owner: &str, repo: &str, body: CreateForkOption, ) -> Request<'_, CreateFork<'_>, Repository>

Fork a repository

  • owner: owner of the repo to fork
  • repo: name of the repo to fork
  • body: See CreateForkOption
Source

pub fn get_blobs( &self, owner: &str, repo: &str, query: GetBlobsQuery, ) -> Request<'_, GetBlobs<'_>, Vec<GitBlob>>

Gets multiplbe blobs of a repository.

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn get_blob( &self, owner: &str, repo: &str, sha: &str, ) -> Request<'_, GetBlob<'_>, GitBlob>

Gets the blob of a repository.

  • owner: owner of the repo
  • repo: name of the repo
  • sha: sha of the blob to retrieve
Source

pub fn repo_get_single_commit( &self, owner: &str, repo: &str, sha: &str, query: RepoGetSingleCommitQuery, ) -> Request<'_, RepoGetSingleCommit<'_>, Commit>

Get a single commit from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • sha: a git ref or commit sha
Source

pub fn repo_download_commit_diff_or_patch( &self, owner: &str, repo: &str, sha: &str, diff_type: &str, ) -> Request<'_, RepoDownloadCommitDiffOrPatch<'_>, String>

Get a commit’s diff or patch

  • owner: owner of the repo
  • repo: name of the repo
  • sha: SHA of the commit to get
  • diffType: whether the output is diff or patch
Source

pub fn repo_get_note( &self, owner: &str, repo: &str, sha: &str, query: RepoGetNoteQuery, ) -> Request<'_, RepoGetNote<'_>, Note>

Get a note corresponding to a single commit from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • sha: a git ref or commit sha
Source

pub fn repo_set_note( &self, owner: &str, repo: &str, sha: &str, body: NoteOptions, ) -> Request<'_, RepoSetNote<'_>, Note>

Set a note corresponding to a single commit from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • sha: a git ref or commit sha
  • body: See NoteOptions
Source

pub fn repo_remove_note( &self, owner: &str, repo: &str, sha: &str, ) -> Request<'_, RepoRemoveNote<'_>, ()>

Removes a note corresponding to a single commit from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • sha: a git ref or commit sha
Source

pub fn repo_list_all_git_refs( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListAllGitRefs<'_>, Vec<Reference>>

Get specified ref or filtered repository’s refs

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_list_git_refs( &self, owner: &str, repo: &str, ref: &str, ) -> Request<'_, RepoListGitRefs<'_>, Vec<Reference>>

Get specified ref or filtered repository’s refs

  • owner: owner of the repo
  • repo: name of the repo
  • ref: part or full name of the ref
Source

pub fn get_annotated_tag( &self, owner: &str, repo: &str, sha: &str, ) -> Request<'_, GetAnnotatedTag<'_>, AnnotatedTag>

Gets the tag object of an annotated tag (not lightweight tags)

  • owner: owner of the repo
  • repo: name of the repo
  • sha: sha of the tag. The Git tags API only supports annotated tag objects, not lightweight tags.
Source

pub fn get_tree( &self, owner: &str, repo: &str, sha: &str, query: GetTreeQuery, ) -> Request<'_, GetTree<'_>, GitTreeResponse>

Gets the tree of a repository.

  • owner: owner of the repo
  • repo: name of the repo
  • sha: sha of the commit
Source

pub fn repo_list_hooks( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListHooks<'_>, (HookListHeaders, Vec<Hook>)>

List the hooks in a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_hook( &self, owner: &str, repo: &str, body: CreateHookOption, ) -> Request<'_, RepoCreateHook<'_>, Hook>

Create a hook

Source

pub fn repo_list_git_hooks( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListGitHooks<'_>, (GitHookListHeaders, Vec<GitHook>)>

List the Git hooks in a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_git_hook( &self, owner: &str, repo: &str, id: &str, ) -> Request<'_, RepoGetGitHook<'_>, GitHook>

Get a Git hook

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to get
Source

pub fn repo_delete_git_hook( &self, owner: &str, repo: &str, id: &str, ) -> Request<'_, RepoDeleteGitHook<'_>, ()>

Delete a Git hook in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to get
Source

pub fn repo_edit_git_hook( &self, owner: &str, repo: &str, id: &str, body: EditGitHookOption, ) -> Request<'_, RepoEditGitHook<'_>, GitHook>

Edit a Git hook in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to get
  • body: See EditGitHookOption
Source

pub fn repo_get_hook( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoGetHook<'_>, Hook>

Get a hook

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to get
Source

pub fn repo_delete_hook( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoDeleteHook<'_>, ()>

Delete a hook in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to delete
Source

pub fn repo_edit_hook( &self, owner: &str, repo: &str, id: i64, body: EditHookOption, ) -> Request<'_, RepoEditHook<'_>, Hook>

Edit a hook in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: index of the hook
  • body: See EditHookOption
Source

pub fn repo_test_hook( &self, owner: &str, repo: &str, id: i64, query: RepoTestHookQuery, ) -> Request<'_, RepoTestHook<'_>, ()>

Test a push webhook

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the hook to test
Source

pub fn repo_get_issue_config( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetIssueConfig<'_>, IssueConfig>

Returns the issue config for a repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_validate_issue_config( &self, owner: &str, repo: &str, ) -> Request<'_, RepoValidateIssueConfig<'_>, IssueConfigValidation>

Returns the validation information for a issue config

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_issue_templates( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetIssueTemplates<'_>, Vec<IssueTemplate>>

Get available issue templates for a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_list_issues( &self, owner: &str, repo: &str, query: IssueListIssuesQuery, ) -> Request<'_, IssueListIssues<'_>, (IssueListHeaders, Vec<Issue>)>

List a repository’s issues

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_create_issue( &self, owner: &str, repo: &str, body: CreateIssueOption, ) -> Request<'_, IssueCreateIssue<'_>, Issue>

Create an issue. If using deadline only the date will be taken into account, and time of day ignored.

Source

pub fn issue_get_repo_comments( &self, owner: &str, repo: &str, query: IssueGetRepoCommentsQuery, ) -> Request<'_, IssueGetRepoComments<'_>, (CommentListHeaders, Vec<Comment>)>

List all comments in a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_get_comment( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueGetComment<'_>, Option<Comment>>

Get a comment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
Source

pub fn issue_delete_comment( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueDeleteComment<'_>, ()>

Delete a comment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of comment to delete
Source

pub fn issue_edit_comment( &self, owner: &str, repo: &str, id: i64, body: EditIssueCommentOption, ) -> Request<'_, IssueEditComment<'_>, Option<Comment>>

Edit a comment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment to edit
  • body: See EditIssueCommentOption
Source

pub fn issue_list_issue_comment_attachments( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueListIssueCommentAttachments<'_>, Vec<Attachment>>

List comment’s attachments

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
Source

pub fn issue_create_issue_comment_attachment( &self, owner: &str, repo: &str, id: i64, attachment: &[u8], query: IssueCreateIssueCommentAttachmentQuery, ) -> Request<'_, IssueCreateIssueCommentAttachment<'_>, Attachment>

Create a comment attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
  • attachment: attachment to upload
Source

pub fn issue_get_issue_comment_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, ) -> Request<'_, IssueGetIssueCommentAttachment<'_>, Attachment>

Get a comment attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
  • attachment_id: id of the attachment to get
Source

pub fn issue_delete_issue_comment_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, ) -> Request<'_, IssueDeleteIssueCommentAttachment<'_>, ()>

Delete a comment attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
  • attachment_id: id of the attachment to delete
Source

pub fn issue_edit_issue_comment_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, body: EditAttachmentOptions, ) -> Request<'_, IssueEditIssueCommentAttachment<'_>, Attachment>

Edit a comment attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment
  • attachment_id: id of the attachment to edit
  • body: See EditAttachmentOptions
Source

pub fn issue_get_comment_reactions( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueGetCommentReactions<'_>, (ReactionListHeaders, Vec<Reaction>)>

Get a list of reactions from a comment of an issue

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment to edit
Source

pub fn issue_post_comment_reaction( &self, owner: &str, repo: &str, id: i64, content: EditReactionOption, ) -> Request<'_, IssuePostCommentReaction<'_>, Reaction>

Add a reaction to a comment of an issue

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment to edit
  • content: See EditReactionOption
Source

pub fn issue_delete_comment_reaction( &self, owner: &str, repo: &str, id: i64, content: EditReactionOption, ) -> Request<'_, IssueDeleteCommentReaction<'_>, ()>

Remove a reaction from a comment of an issue

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the comment to edit
  • content: See EditReactionOption
Source

pub fn repo_list_pinned_issues( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListPinnedIssues<'_>, (IssueListHeaders, Vec<Issue>)>

List a repo’s pinned issues

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_get_issue( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueGetIssue<'_>, Issue>

Get an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to get
Source

pub fn issue_delete( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueDelete<'_>, ()>

Delete an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of issue to delete
Source

pub fn issue_edit_issue( &self, owner: &str, repo: &str, index: i64, body: EditIssueOption, ) -> Request<'_, IssueEditIssue<'_>, Issue>

Edit an issue. If using deadline only the date will be taken into account, and time of day ignored.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to edit
  • body: See EditIssueOption
Source

pub fn issue_list_issue_attachments( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueListIssueAttachments<'_>, Vec<Attachment>>

List issue’s attachments

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_create_issue_attachment( &self, owner: &str, repo: &str, index: i64, attachment: &[u8], query: IssueCreateIssueAttachmentQuery, ) -> Request<'_, IssueCreateIssueAttachment<'_>, Attachment>

Create an issue attachment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • attachment: attachment to upload
Source

pub fn issue_get_issue_attachment( &self, owner: &str, repo: &str, index: i64, attachment_id: i64, ) -> Request<'_, IssueGetIssueAttachment<'_>, Attachment>

Get an issue attachment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • attachment_id: id of the attachment to get
Source

pub fn issue_delete_issue_attachment( &self, owner: &str, repo: &str, index: i64, attachment_id: i64, ) -> Request<'_, IssueDeleteIssueAttachment<'_>, ()>

Delete an issue attachment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • attachment_id: id of the attachment to delete
Source

pub fn issue_edit_issue_attachment( &self, owner: &str, repo: &str, index: i64, attachment_id: i64, body: EditAttachmentOptions, ) -> Request<'_, IssueEditIssueAttachment<'_>, Attachment>

Edit an issue attachment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • attachment_id: id of the attachment to edit
  • body: See EditAttachmentOptions
Source

pub fn issue_list_blocks( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueListBlocks<'_>, (IssueListHeaders, Vec<Issue>)>

List issues that are blocked by this issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_create_issue_blocking( &self, owner: &str, repo: &str, index: i64, body: IssueMeta, ) -> Request<'_, IssueCreateIssueBlocking<'_>, Issue>

Block the issue given in the body by the issue in path

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueMeta
Source

pub fn issue_remove_issue_blocking( &self, owner: &str, repo: &str, index: i64, body: IssueMeta, ) -> Request<'_, IssueRemoveIssueBlocking<'_>, Issue>

Unblock the issue given in the body by the issue in path

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueMeta
Source

pub fn issue_get_comments( &self, owner: &str, repo: &str, index: i64, query: IssueGetCommentsQuery, ) -> Request<'_, IssueGetComments<'_>, (CommentListHeaders, Vec<Comment>)>

List all comments on an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_create_comment( &self, owner: &str, repo: &str, index: i64, body: CreateIssueCommentOption, ) -> Request<'_, IssueCreateComment<'_>, Comment>

Add a comment to an issue

Source

pub fn issue_delete_comment_deprecated( &self, owner: &str, repo: &str, index: u32, id: i64, ) -> Request<'_, IssueDeleteCommentDeprecated<'_>, ()>

Delete a comment

  • owner: owner of the repo
  • repo: name of the repo
  • index: this parameter is ignored
  • id: id of comment to delete
Source

pub fn issue_edit_comment_deprecated( &self, owner: &str, repo: &str, index: u32, id: i64, body: EditIssueCommentOption, ) -> Request<'_, IssueEditCommentDeprecated<'_>, Option<Comment>>

Edit a comment

  • owner: owner of the repo
  • repo: name of the repo
  • index: this parameter is ignored
  • id: id of the comment to edit
  • body: See EditIssueCommentOption
Source

pub fn issue_edit_issue_deadline( &self, owner: &str, repo: &str, index: i64, body: EditDeadlineOption, ) -> Request<'_, IssueEditIssueDeadline<'_>, IssueDeadline>

Set an issue deadline. If set to null, the deadline is deleted. If using deadline only the date will be taken into account, and time of day ignored.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to create or update a deadline on
  • body: See EditDeadlineOption
Source

pub fn issue_list_issue_dependencies( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueListIssueDependencies<'_>, (IssueListHeaders, Vec<Issue>)>

List an issue’s dependencies, i.e all issues that block this issue.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_create_issue_dependencies( &self, owner: &str, repo: &str, index: i64, body: IssueMeta, ) -> Request<'_, IssueCreateIssueDependencies<'_>, Issue>

Make the issue in the url depend on the issue in the form.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueMeta
Source

pub fn issue_remove_issue_dependencies( &self, owner: &str, repo: &str, index: i64, body: IssueMeta, ) -> Request<'_, IssueRemoveIssueDependencies<'_>, Issue>

Remove an issue dependency

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueMeta
Source

pub fn issue_get_labels( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueGetLabels<'_>, (LabelListHeaders, Vec<Label>)>

Get an issue’s labels

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_replace_labels( &self, owner: &str, repo: &str, index: i64, body: IssueLabelsOption, ) -> Request<'_, IssueReplaceLabels<'_>, (LabelListHeaders, Vec<Label>)>

Replace an issue’s labels

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueLabelsOption
Source

pub fn issue_add_label( &self, owner: &str, repo: &str, index: i64, body: IssueLabelsOption, ) -> Request<'_, IssueAddLabel<'_>, (LabelListHeaders, Vec<Label>)>

Add a label to an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See IssueLabelsOption
Source

pub fn issue_clear_labels( &self, owner: &str, repo: &str, index: i64, body: DeleteLabelsOption, ) -> Request<'_, IssueClearLabels<'_>, ()>

Remove all labels from an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See DeleteLabelsOption
Source

pub fn issue_remove_label( &self, owner: &str, repo: &str, index: i64, identifier: &str, body: DeleteLabelsOption, ) -> Request<'_, IssueRemoveLabel<'_>, ()>

Remove a label from an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • identifier: name or id of the label to remove
  • body: See DeleteLabelsOption
Source

pub fn pin_issue( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, PinIssue<'_>, ()>

Pin an Issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of issue to pin
Source

pub fn unpin_issue( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, UnpinIssue<'_>, ()>

Unpin an Issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of issue to unpin
Source

pub fn move_issue_pin( &self, owner: &str, repo: &str, index: i64, position: i64, ) -> Request<'_, MoveIssuePin<'_>, ()>

Moves the Pin to the given Position

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of issue
  • position: the new position
Source

pub fn issue_get_issue_reactions( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueGetIssueReactions<'_>, (ReactionListHeaders, Vec<Reaction>)>

Get a list reactions of an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_post_issue_reaction( &self, owner: &str, repo: &str, index: i64, content: EditReactionOption, ) -> Request<'_, IssuePostIssueReaction<'_>, Reaction>

Add a reaction to an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • content: See EditReactionOption
Source

pub fn issue_delete_issue_reaction( &self, owner: &str, repo: &str, index: i64, content: EditReactionOption, ) -> Request<'_, IssueDeleteIssueReaction<'_>, ()>

Remove a reaction from an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • content: See EditReactionOption
Source

pub fn issue_delete_stop_watch( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueDeleteStopWatch<'_>, ()>

Delete an issue’s existing stopwatch.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to stop the stopwatch on
Source

pub fn issue_start_stop_watch( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueStartStopWatch<'_>, ()>

Start stopwatch on an issue.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to create the stopwatch on
Source

pub fn issue_stop_stop_watch( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueStopStopWatch<'_>, ()>

Stop an issue’s existing stopwatch.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to stop the stopwatch on
Source

pub fn issue_subscriptions( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueSubscriptions<'_>, (UserListHeaders, Vec<User>)>

Get users who subscribed on an issue.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_check_subscription( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueCheckSubscription<'_>, WatchInfo>

Check if user is subscribed to an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_add_subscription( &self, owner: &str, repo: &str, index: i64, user: &str, ) -> Request<'_, IssueAddSubscription<'_>, ()>

Subscribe user to issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • user: user to subscribe
Source

pub fn issue_delete_subscription( &self, owner: &str, repo: &str, index: i64, user: &str, ) -> Request<'_, IssueDeleteSubscription<'_>, ()>

Unsubscribe user from issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • user: user witch unsubscribe
Source

pub fn issue_get_comments_and_timeline( &self, owner: &str, repo: &str, index: i64, query: IssueGetCommentsAndTimelineQuery, ) -> Request<'_, IssueGetCommentsAndTimeline<'_>, (TimelineListHeaders, Vec<TimelineComment>)>

List all comments and events on an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_tracked_times( &self, owner: &str, repo: &str, index: i64, query: IssueTrackedTimesQuery, ) -> Request<'_, IssueTrackedTimes<'_>, (TrackedTimeListHeaders, Vec<TrackedTime>)>

List an issue’s tracked times

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
Source

pub fn issue_add_time( &self, owner: &str, repo: &str, index: i64, body: AddTimeOption, ) -> Request<'_, IssueAddTime<'_>, TrackedTime>

Add tracked time to a issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • body: See AddTimeOption
Source

pub fn issue_reset_time( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, IssueResetTime<'_>, ()>

Reset a tracked time of an issue

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue to add tracked time to
Source

pub fn issue_delete_time( &self, owner: &str, repo: &str, index: i64, id: i64, ) -> Request<'_, IssueDeleteTime<'_>, ()>

Delete specific tracked time

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the issue
  • id: id of time to delete
Source

pub fn repo_list_keys( &self, owner: &str, repo: &str, query: RepoListKeysQuery, ) -> Request<'_, RepoListKeys<'_>, (DeployKeyListHeaders, Vec<DeployKey>)>

List a repository’s keys

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_key( &self, owner: &str, repo: &str, body: CreateKeyOption, ) -> Request<'_, RepoCreateKey<'_>, DeployKey>

Add a key to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • body: See CreateKeyOption
Source

pub fn repo_get_key( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoGetKey<'_>, DeployKey>

Get a repository’s key by id

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the key to get
Source

pub fn repo_delete_key( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoDeleteKey<'_>, ()>

Delete a key from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the key to delete
Source

pub fn issue_list_labels( &self, owner: &str, repo: &str, query: IssueListLabelsQuery, ) -> Request<'_, IssueListLabels<'_>, (LabelListHeaders, Vec<Label>)>

Get all of a repository’s labels

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_create_label( &self, owner: &str, repo: &str, body: CreateLabelOption, ) -> Request<'_, IssueCreateLabel<'_>, Label>

Create a label

Source

pub fn issue_get_label( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueGetLabel<'_>, Label>

Get a single label

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the label to get
Source

pub fn issue_delete_label( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueDeleteLabel<'_>, ()>

Delete a label

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the label to delete
Source

pub fn issue_edit_label( &self, owner: &str, repo: &str, id: i64, body: EditLabelOption, ) -> Request<'_, IssueEditLabel<'_>, Label>

Update a label

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the label to edit
  • body: See EditLabelOption
Source

pub fn repo_get_languages( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetLanguages<'_>, BTreeMap<String, i64>>

Get languages and number of bytes of code written

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_raw_file_or_lfs( &self, owner: &str, repo: &str, filepath: &str, query: RepoGetRawFileOrLfsQuery, ) -> Request<'_, RepoGetRawFileOrLfs<'_>, Bytes>

Get a file or it’s LFS object from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: filepath of the file to get
Source

pub fn issue_get_milestones_list( &self, owner: &str, repo: &str, query: IssueGetMilestonesListQuery, ) -> Request<'_, IssueGetMilestonesList<'_>, (MilestoneListHeaders, Vec<Milestone>)>

Get all of a repository’s opened milestones

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn issue_create_milestone( &self, owner: &str, repo: &str, body: CreateMilestoneOption, ) -> Request<'_, IssueCreateMilestone<'_>, Milestone>

Create a milestone

Source

pub fn issue_get_milestone( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueGetMilestone<'_>, Milestone>

Get a milestone

  • owner: owner of the repo
  • repo: name of the repo
  • id: the milestone to get, identified by ID and if not available by name
Source

pub fn issue_delete_milestone( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, IssueDeleteMilestone<'_>, ()>

Delete a milestone

  • owner: owner of the repo
  • repo: name of the repo
  • id: the milestone to delete, identified by ID and if not available by name
Source

pub fn issue_edit_milestone( &self, owner: &str, repo: &str, id: i64, body: EditMilestoneOption, ) -> Request<'_, IssueEditMilestone<'_>, Milestone>

Update a milestone

  • owner: owner of the repo
  • repo: name of the repo
  • id: the milestone to edit, identified by ID and if not available by name
  • body: See EditMilestoneOption
Source

pub fn repo_mirror_sync( &self, owner: &str, repo: &str, ) -> Request<'_, RepoMirrorSync<'_>, ()>

Sync a mirrored repository

  • owner: owner of the repo to sync
  • repo: name of the repo to sync
Source

pub fn repo_new_pin_allowed( &self, owner: &str, repo: &str, ) -> Request<'_, RepoNewPinAllowed<'_>, NewIssuePinsAllowed>

Returns if new Issue Pins are allowed

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn notify_get_repo_list( &self, owner: &str, repo: &str, query: NotifyGetRepoListQuery, ) -> Request<'_, NotifyGetRepoList<'_>, (NotificationThreadListHeaders, Vec<NotificationThread>)>

List users’s notification threads on a specific repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn notify_read_repo_list( &self, owner: &str, repo: &str, query: NotifyReadRepoListQuery, ) -> Request<'_, NotifyReadRepoList<'_>, (NotificationThreadListHeaders, Vec<NotificationThread>)>

Mark notification threads as read, pinned or unread on a specific repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_list_pull_requests( &self, owner: &str, repo: &str, query: RepoListPullRequestsQuery, ) -> Request<'_, RepoListPullRequests<'_>, (PullRequestListHeaders, Vec<PullRequest>)>

List a repo’s pull requests. If a pull request is selected but fails to be retrieved for any reason, it will be a null value in the list of results.

  • owner: Owner of the repo
  • repo: Name of the repo
Source

pub fn repo_create_pull_request( &self, owner: &str, repo: &str, body: CreatePullRequestOption, ) -> Request<'_, RepoCreatePullRequest<'_>, PullRequest>

Create a pull request

Source

pub fn repo_list_pinned_pull_requests( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListPinnedPullRequests<'_>, (PullRequestListHeaders, Vec<PullRequest>)>

List a repo’s pinned pull requests

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_pull_request_by_base_head( &self, owner: &str, repo: &str, base: &str, head: &str, ) -> Request<'_, RepoGetPullRequestByBaseHead<'_>, PullRequest>

Get a pull request by base and head

  • owner: owner of the repo
  • repo: name of the repo
  • base: base of the pull request to get
  • head: head of the pull request to get
Source

pub fn repo_get_pull_request( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, RepoGetPullRequest<'_>, PullRequest>

Get a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to get
Source

pub fn repo_edit_pull_request( &self, owner: &str, repo: &str, index: i64, body: EditPullRequestOption, ) -> Request<'_, RepoEditPullRequest<'_>, PullRequest>

Update a pull request. If using deadline only the date will be taken into account, and time of day ignored.

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to edit
  • body: See EditPullRequestOption
Source

pub fn repo_download_pull_diff_or_patch( &self, owner: &str, repo: &str, index: i64, diff_type: &str, query: RepoDownloadPullDiffOrPatchQuery, ) -> Request<'_, RepoDownloadPullDiffOrPatch<'_>, String>

Get a pull request diff or patch

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to get
  • diffType: whether the output is diff or patch
Source

pub fn repo_get_pull_request_commits( &self, owner: &str, repo: &str, index: i64, query: RepoGetPullRequestCommitsQuery, ) -> Request<'_, RepoGetPullRequestCommits<'_>, (CommitListHeaders, Vec<Commit>)>

Get commits for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to get
Source

pub fn repo_get_pull_request_files( &self, owner: &str, repo: &str, index: i64, query: RepoGetPullRequestFilesQuery, ) -> Request<'_, RepoGetPullRequestFiles<'_>, (ChangedFileListHeaders, Vec<ChangedFile>)>

Get changed files for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to get
Source

pub fn repo_pull_request_is_merged( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, RepoPullRequestIsMerged<'_>, ()>

Check if a pull request has been merged

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
Source

pub fn repo_merge_pull_request( &self, owner: &str, repo: &str, index: i64, body: MergePullRequestOption, ) -> Request<'_, RepoMergePullRequest<'_>, ()>

Merge a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to merge
  • body: See MergePullRequestOption
Source

pub fn repo_cancel_scheduled_auto_merge( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, RepoCancelScheduledAutoMerge<'_>, ()>

Cancel the scheduled auto merge for the given pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to merge
Source

pub fn repo_create_pull_review_requests( &self, owner: &str, repo: &str, index: i64, body: PullReviewRequestOptions, ) -> Request<'_, RepoCreatePullReviewRequests<'_>, (PullReviewListHeaders, Vec<PullReview>)>

Create review requests for a pull request

Source

pub fn repo_delete_pull_review_requests( &self, owner: &str, repo: &str, index: i64, body: PullReviewRequestOptions, ) -> Request<'_, RepoDeletePullReviewRequests<'_>, ()>

Cancel review requests for a pull request

Source

pub fn repo_list_pull_reviews( &self, owner: &str, repo: &str, index: i64, ) -> Request<'_, RepoListPullReviews<'_>, (PullReviewListHeaders, Vec<PullReview>)>

List all reviews for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
Source

pub fn repo_create_pull_review( &self, owner: &str, repo: &str, index: i64, body: CreatePullReviewOptions, ) -> Request<'_, RepoCreatePullReview<'_>, PullReview>

Create a review to an pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • body: See CreatePullReviewOptions
Source

pub fn repo_get_pull_review( &self, owner: &str, repo: &str, index: i64, id: i64, ) -> Request<'_, RepoGetPullReview<'_>, PullReview>

Get a specific review for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
Source

pub fn repo_submit_pull_review( &self, owner: &str, repo: &str, index: i64, id: i64, body: SubmitPullReviewOptions, ) -> Request<'_, RepoSubmitPullReview<'_>, PullReview>

Submit a pending review to an pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
  • body: See SubmitPullReviewOptions
Source

pub fn repo_delete_pull_review( &self, owner: &str, repo: &str, index: i64, id: i64, ) -> Request<'_, RepoDeletePullReview<'_>, ()>

Delete a specific review from a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
Source

pub fn repo_get_pull_review_comments( &self, owner: &str, repo: &str, index: i64, id: i64, ) -> Request<'_, RepoGetPullReviewComments<'_>, Vec<PullReviewComment>>

Get a specific review for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
Source

pub fn repo_create_pull_review_comment( &self, owner: &str, repo: &str, index: i64, id: i64, body: Value, ) -> Request<'_, RepoCreatePullReviewComment<'_>, PullReviewComment>

Add a new comment to a pull request review

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
  • body: See serde_json::Value
Source

pub fn repo_get_pull_review_comment( &self, owner: &str, repo: &str, index: i64, id: i64, comment: i64, ) -> Request<'_, RepoGetPullReviewComment<'_>, PullReviewComment>

Get a pull review comment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
  • comment: id of the comment
Source

pub fn repo_delete_pull_review_comment( &self, owner: &str, repo: &str, index: i64, id: i64, comment: i64, ) -> Request<'_, RepoDeletePullReviewComment<'_>, ()>

Delete a pull review comment

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
  • comment: id of the comment
Source

pub fn repo_dismiss_pull_review( &self, owner: &str, repo: &str, index: i64, id: i64, body: DismissPullReviewOptions, ) -> Request<'_, RepoDismissPullReview<'_>, PullReview>

Dismiss a review for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
  • body: See DismissPullReviewOptions
Source

pub fn repo_un_dismiss_pull_review( &self, owner: &str, repo: &str, index: i64, id: i64, ) -> Request<'_, RepoUnDismissPullReview<'_>, PullReview>

Cancel to dismiss a review for a pull request

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request
  • id: id of the review
Source

pub fn repo_update_pull_request( &self, owner: &str, repo: &str, index: i64, query: RepoUpdatePullRequestQuery, ) -> Request<'_, RepoUpdatePullRequest<'_>, ()>

Merge PR’s baseBranch into headBranch

  • owner: owner of the repo
  • repo: name of the repo
  • index: index of the pull request to get
Source

pub fn repo_list_push_mirrors( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListPushMirrors<'_>, (PushMirrorListHeaders, Vec<PushMirror>)>

Get all push mirrors of the repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_add_push_mirror( &self, owner: &str, repo: &str, body: CreatePushMirrorOption, ) -> Request<'_, RepoAddPushMirror<'_>, PushMirror>

Set up a new push mirror in a repository

Source

pub fn repo_push_mirror_sync( &self, owner: &str, repo: &str, ) -> Request<'_, RepoPushMirrorSync<'_>, ()>

Sync all push mirrored repository

  • owner: owner of the repo to sync
  • repo: name of the repo to sync
Source

pub fn repo_get_push_mirror_by_remote_name( &self, owner: &str, repo: &str, name: &str, ) -> Request<'_, RepoGetPushMirrorByRemoteName<'_>, PushMirror>

Get push mirror of the repository by remoteName

  • owner: owner of the repo
  • repo: name of the repo
  • name: remote name of push mirror
Source

pub fn repo_delete_push_mirror( &self, owner: &str, repo: &str, name: &str, ) -> Request<'_, RepoDeletePushMirror<'_>, ()>

Remove a push mirror from a repository by remoteName

  • owner: owner of the repo
  • repo: name of the repo
  • name: remote name of the pushMirror
Source

pub fn repo_get_raw_file( &self, owner: &str, repo: &str, filepath: &str, query: RepoGetRawFileQuery, ) -> Request<'_, RepoGetRawFile<'_>, Bytes>

Get a file from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • filepath: filepath of the file to get
Source

pub fn repo_list_releases( &self, owner: &str, repo: &str, query: RepoListReleasesQuery, ) -> Request<'_, RepoListReleases<'_>, (ReleaseListHeaders, Vec<Release>)>

List a repo’s releases

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_release( &self, owner: &str, repo: &str, body: CreateReleaseOption, ) -> Request<'_, RepoCreateRelease<'_>, Release>

Create a release

Source

pub fn repo_get_latest_release( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetLatestRelease<'_>, Release>

Gets the most recent non-prerelease, non-draft release of a repository, sorted by created_at

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_release_by_tag( &self, owner: &str, repo: &str, tag: &str, ) -> Request<'_, RepoGetReleaseByTag<'_>, Release>

Get a release by tag name

  • owner: owner of the repo
  • repo: name of the repo
  • tag: tag name of the release to get
Source

pub fn repo_delete_release_by_tag( &self, owner: &str, repo: &str, tag: &str, ) -> Request<'_, RepoDeleteReleaseByTag<'_>, ()>

Delete a release by tag name

  • owner: owner of the repo
  • repo: name of the repo
  • tag: tag name of the release to delete
Source

pub fn repo_get_release( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoGetRelease<'_>, Release>

Get a release

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release to get
Source

pub fn repo_delete_release( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoDeleteRelease<'_>, ()>

Delete a release

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release to delete
Source

pub fn repo_edit_release( &self, owner: &str, repo: &str, id: i64, body: EditReleaseOption, ) -> Request<'_, RepoEditRelease<'_>, Release>

Update a release

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release to edit
  • body: See EditReleaseOption
Source

pub fn repo_list_release_attachments( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoListReleaseAttachments<'_>, Vec<Attachment>>

List release’s attachments

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release
Source

pub fn repo_create_release_attachment( &self, owner: &str, repo: &str, id: i64, attachment: Option<&[u8]>, external_url: Option<&str>, query: RepoCreateReleaseAttachmentQuery, ) -> Request<'_, RepoCreateReleaseAttachment<'_>, Attachment>

Create a release attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release
  • attachment: attachment to upload (this parameter is incompatible with external_url)
  • external_url: url to external asset (this parameter is incompatible with attachment)
Source

pub fn repo_get_release_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, ) -> Request<'_, RepoGetReleaseAttachment<'_>, Attachment>

Get a release attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release
  • attachment_id: id of the attachment to get
Source

pub fn repo_delete_release_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, ) -> Request<'_, RepoDeleteReleaseAttachment<'_>, ()>

Delete a release attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release
  • attachment_id: id of the attachment to delete
Source

pub fn repo_edit_release_attachment( &self, owner: &str, repo: &str, id: i64, attachment_id: i64, body: EditAttachmentOptions, ) -> Request<'_, RepoEditReleaseAttachment<'_>, Attachment>

Edit a release attachment

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the release
  • attachment_id: id of the attachment to edit
  • body: See EditAttachmentOptions
Source

pub fn repo_get_reviewers( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetReviewers<'_>, (UserListHeaders, Vec<User>)>

Return all users that can be requested to review in this repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_signing_key( &self, owner: &str, repo: &str, ) -> Request<'_, RepoSigningKey<'_>, String>

Get signing-key.gpg for given repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_list_stargazers( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListStargazers<'_>, (UserListHeaders, Vec<User>)>

List a repo’s stargazers

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_list_statuses( &self, owner: &str, repo: &str, sha: &str, query: RepoListStatusesQuery, ) -> Request<'_, RepoListStatuses<'_>, (CommitStatusListHeaders, Vec<CommitStatus>)>

Get a commit’s statuses

  • owner: owner of the repo
  • repo: name of the repo
  • sha: sha of the commit
Source

pub fn repo_create_status( &self, owner: &str, repo: &str, sha: &str, body: CreateStatusOption, ) -> Request<'_, RepoCreateStatus<'_>, CommitStatus>

Create a commit status

  • owner: owner of the repo
  • repo: name of the repo
  • sha: sha of the commit
  • body: See CreateStatusOption
Source

pub fn repo_list_subscribers( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListSubscribers<'_>, (UserListHeaders, Vec<User>)>

List a repo’s watchers

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn user_current_check_subscription( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentCheckSubscription<'_>, WatchInfo>

Check if the current user is watching a repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn user_current_put_subscription( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentPutSubscription<'_>, WatchInfo>

Watch a repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn user_current_delete_subscription( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentDeleteSubscription<'_>, ()>

Unwatch a repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_sync_fork_default_info( &self, owner: &str, repo: &str, ) -> Request<'_, RepoSyncForkDefaultInfo<'_>, SyncForkInfo>

Gets information about syncing the fork default branch with the base branch

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_sync_fork_default( &self, owner: &str, repo: &str, ) -> Request<'_, RepoSyncForkDefault<'_>, ()>

Syncs the default branch of a fork with the base branch

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_sync_fork_branch_info( &self, owner: &str, repo: &str, branch: &str, ) -> Request<'_, RepoSyncForkBranchInfo<'_>, SyncForkInfo>

Gets information about syncing a fork branch with the base branch

  • owner: owner of the repo
  • repo: name of the repo
  • branch: The branch
Source

pub fn repo_sync_fork_branch( &self, owner: &str, repo: &str, branch: &str, ) -> Request<'_, RepoSyncForkBranch<'_>, ()>

Syncs a fork branch with the base branch

  • owner: owner of the repo
  • repo: name of the repo
  • branch: The branch
Source

pub fn repo_list_tag_protection( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListTagProtection<'_>, Vec<TagProtection>>

List tag protections for a repository

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_tag_protection( &self, owner: &str, repo: &str, body: CreateTagProtectionOption, ) -> Request<'_, RepoCreateTagProtection<'_>, TagProtection>

Create a tag protections for a repository

Source

pub fn repo_get_tag_protection( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoGetTagProtection<'_>, TagProtection>

Get a specific tag protection for the repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of the tag protect to get
Source

pub fn repo_delete_tag_protection( &self, owner: &str, repo: &str, id: i64, ) -> Request<'_, RepoDeleteTagProtection<'_>, ()>

Delete a specific tag protection for the repository

  • owner: owner of the repo
  • repo: name of the repo
  • id: id of protected tag
Source

pub fn repo_edit_tag_protection( &self, owner: &str, repo: &str, id: i64, body: EditTagProtectionOption, ) -> Request<'_, RepoEditTagProtection<'_>, TagProtection>

Edit a tag protections for a repository. Only fields that are set will be changed

Source

pub fn repo_list_tags( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListTags<'_>, (TagListHeaders, Vec<Tag>)>

List a repository’s tags

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_create_tag( &self, owner: &str, repo: &str, body: CreateTagOption, ) -> Request<'_, RepoCreateTag<'_>, Tag>

Create a new git tag in a repository

  • owner: owner of the repo
  • repo: name of the repo
  • body: See CreateTagOption
Source

pub fn repo_get_tag( &self, owner: &str, repo: &str, tag: &str, ) -> Request<'_, RepoGetTag<'_>, Tag>

Get the tag of a repository by tag name

  • owner: owner of the repo
  • repo: name of the repo
  • tag: name of tag
Source

pub fn repo_delete_tag( &self, owner: &str, repo: &str, tag: &str, ) -> Request<'_, RepoDeleteTag<'_>, ()>

Delete a repository’s tag by name

  • owner: owner of the repo
  • repo: name of the repo
  • tag: name of tag to delete
Source

pub fn repo_list_teams( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListTeams<'_>, (TeamListHeaders, Vec<Team>)>

List a repository’s teams

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_check_team( &self, owner: &str, repo: &str, team: &str, ) -> Request<'_, RepoCheckTeam<'_>, Team>

Check if a team is assigned to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • team: team name
Source

pub fn repo_add_team( &self, owner: &str, repo: &str, team: &str, ) -> Request<'_, RepoAddTeam<'_>, ()>

Add a team to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • team: team name
Source

pub fn repo_delete_team( &self, owner: &str, repo: &str, team: &str, ) -> Request<'_, RepoDeleteTeam<'_>, ()>

Delete a team from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • team: team name
Source

pub fn repo_tracked_times( &self, owner: &str, repo: &str, query: RepoTrackedTimesQuery, ) -> Request<'_, RepoTrackedTimes<'_>, (TrackedTimeListHeaders, Vec<TrackedTime>)>

List a repo’s tracked times

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn user_tracked_times( &self, owner: &str, repo: &str, user: &str, ) -> Request<'_, UserTrackedTimes<'_>, (TrackedTimeListHeaders, Vec<TrackedTime>)>

List a user’s tracked times in a repo

  • owner: owner of the repo
  • repo: name of the repo
  • user: username of user
Source

pub fn repo_list_topics( &self, owner: &str, repo: &str, ) -> Request<'_, RepoListTopics<'_>, TopicName>

Get list of topics that a repository has

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_update_topics( &self, owner: &str, repo: &str, body: RepoTopicOptions, ) -> Request<'_, RepoUpdateTopics<'_>, ()>

Replace list of topics for a repository

Source

pub fn repo_add_topic( &self, owner: &str, repo: &str, topic: &str, ) -> Request<'_, RepoAddTopic<'_>, ()>

Add a topic to a repository

  • owner: owner of the repo
  • repo: name of the repo
  • topic: name of the topic to add
Source

pub fn repo_delete_topic( &self, owner: &str, repo: &str, topic: &str, ) -> Request<'_, RepoDeleteTopic<'_>, ()>

Delete a topic from a repository

  • owner: owner of the repo
  • repo: name of the repo
  • topic: name of the topic to delete
Source

pub fn repo_transfer( &self, owner: &str, repo: &str, body: TransferRepoOption, ) -> Request<'_, RepoTransfer<'_>, Repository>

Transfer a repo ownership

  • owner: owner of the repo to transfer
  • repo: name of the repo to transfer
  • body: Transfer Options See TransferRepoOption
Source

pub fn accept_repo_transfer( &self, owner: &str, repo: &str, ) -> Request<'_, AcceptRepoTransfer<'_>, Repository>

Accept a repo transfer

  • owner: owner of the repo to transfer
  • repo: name of the repo to transfer
Source

pub fn reject_repo_transfer( &self, owner: &str, repo: &str, ) -> Request<'_, RejectRepoTransfer<'_>, Repository>

Reject a repo transfer

  • owner: owner of the repo to transfer
  • repo: name of the repo to transfer
Source

pub fn repo_create_wiki_page( &self, owner: &str, repo: &str, body: CreateWikiPageOptions, ) -> Request<'_, RepoCreateWikiPage<'_>, WikiPage>

Create a wiki page

Source

pub fn repo_get_wiki_page( &self, owner: &str, repo: &str, page_name: &str, ) -> Request<'_, RepoGetWikiPage<'_>, WikiPage>

Get a wiki page

  • owner: owner of the repo
  • repo: name of the repo
  • pageName: name of the page
Source

pub fn repo_delete_wiki_page( &self, owner: &str, repo: &str, page_name: &str, ) -> Request<'_, RepoDeleteWikiPage<'_>, ()>

Delete a wiki page

  • owner: owner of the repo
  • repo: name of the repo
  • pageName: name of the page
Source

pub fn repo_edit_wiki_page( &self, owner: &str, repo: &str, page_name: &str, body: CreateWikiPageOptions, ) -> Request<'_, RepoEditWikiPage<'_>, WikiPage>

Edit a wiki page

  • owner: owner of the repo
  • repo: name of the repo
  • pageName: name of the page
  • body: See CreateWikiPageOptions
Source

pub fn repo_get_wiki_pages( &self, owner: &str, repo: &str, ) -> Request<'_, RepoGetWikiPages<'_>, (WikiPageListHeaders, Vec<WikiPageMetaData>)>

Get all wiki pages

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn repo_get_wiki_page_revisions( &self, owner: &str, repo: &str, page_name: &str, ) -> Request<'_, RepoGetWikiPageRevisions<'_>, (WikiCommitListHeaders, WikiCommitList)>

Get revisions of a wiki page

  • owner: owner of the repo
  • repo: name of the repo
  • pageName: name of the page
Source

pub fn generate_repo( &self, template_owner: &str, template_repo: &str, body: GenerateRepoOption, ) -> Request<'_, GenerateRepo<'_>, Repository>

Create a repository using a template

  • template_owner: name of the template repository owner
  • template_repo: name of the template repository
  • body: See GenerateRepoOption
Source

pub fn repo_get_by_id(&self, id: i64) -> Request<'_, RepoGetById, Repository>

Get a repository by id

  • id: id of the repo to get
Source

pub fn get_general_api_settings( &self, ) -> Request<'_, GetGeneralApiSettings, GeneralAPISettings>

Get instance’s global settings for api

Source

pub fn get_general_attachment_settings( &self, ) -> Request<'_, GetGeneralAttachmentSettings, GeneralAttachmentSettings>

Get instance’s global settings for Attachment

Source

pub fn get_general_repository_settings( &self, ) -> Request<'_, GetGeneralRepositorySettings, GeneralRepoSettings>

Get instance’s global settings for repositories

Source

pub fn get_general_ui_settings( &self, ) -> Request<'_, GetGeneralUiSettings, GeneralUISettings>

Get instance’s global settings for ui

Source

pub fn get_signing_key(&self) -> Request<'_, GetSigningKey, String>

Get default signing-key.gpg

Source

pub fn get_ssh_signing_key(&self) -> Request<'_, GetSshSigningKey, String>

Get default signing-key.ssh

Source

pub fn org_get_team(&self, id: i64) -> Request<'_, OrgGetTeam, Team>

Get a team

  • id: id of the team to get
Source

pub fn org_delete_team(&self, id: i64) -> Request<'_, OrgDeleteTeam, ()>

Delete a team

  • id: id of the team to delete
Source

pub fn org_edit_team( &self, id: i64, body: EditTeamOption, ) -> Request<'_, OrgEditTeam, Team>

Edit a team

Source

pub fn org_list_team_activity_feeds( &self, id: i64, query: OrgListTeamActivityFeedsQuery, ) -> Request<'_, OrgListTeamActivityFeeds, (ActivityFeedsListHeaders, Vec<Activity>)>

List a team’s activity feeds

  • id: id of the team
Source

pub fn org_list_team_members( &self, id: i64, ) -> Request<'_, OrgListTeamMembers, (UserListHeaders, Vec<User>)>

List a team’s members

  • id: id of the team
Source

pub fn org_list_team_member( &self, id: i64, username: &str, ) -> Request<'_, OrgListTeamMember<'_>, User>

List a particular member of team

  • id: id of the team
  • username: username of the member to list
Source

pub fn org_add_team_member( &self, id: i64, username: &str, ) -> Request<'_, OrgAddTeamMember<'_>, ()>

Add a team member

  • id: id of the team
  • username: username of the user to add
Source

pub fn org_remove_team_member( &self, id: i64, username: &str, ) -> Request<'_, OrgRemoveTeamMember<'_>, ()>

Remove a team member

  • id: id of the team
  • username: username of the user to remove
Source

pub fn org_list_team_repos( &self, id: i64, ) -> Request<'_, OrgListTeamRepos, (RepositoryListHeaders, Vec<Repository>)>

List a team’s repos

  • id: id of the team
Source

pub fn org_list_team_repo( &self, id: i64, org: &str, repo: &str, ) -> Request<'_, OrgListTeamRepo<'_>, Repository>

List a particular repo of team

  • id: id of the team
  • org: organization that owns the repo to list
  • repo: name of the repo to list
Source

pub fn org_add_team_repository( &self, id: i64, org: &str, repo: &str, ) -> Request<'_, OrgAddTeamRepository<'_>, ()>

Add a repository to a team

  • id: id of the team
  • org: organization that owns the repo to add
  • repo: name of the repo to add
Source

pub fn org_remove_team_repository( &self, id: i64, org: &str, repo: &str, ) -> Request<'_, OrgRemoveTeamRepository<'_>, ()>

Remove a repository from a team

  • id: id of the team
  • org: organization that owns the repo to remove
  • repo: name of the repo to remove

Search for topics by keyword

Source

pub fn user_get_current(&self) -> Request<'_, UserGetCurrent, User>

Get the authenticated user

Source

pub fn user_search_run_jobs( &self, query: UserSearchRunJobsQuery, ) -> Request<'_, UserSearchRunJobs, Vec<ActionRunJob>>

Search for user’s action jobs according filter conditions

Source

pub fn user_get_runner_registration_token( &self, ) -> Request<'_, UserGetRunnerRegistrationToken, RegistrationToken>

Get an user’s actions runner registration token

Source

pub fn update_user_secret( &self, secretname: &str, body: CreateOrUpdateSecretOption, ) -> Request<'_, UpdateUserSecret<'_>, ()>

Create or Update a secret value in a user scope

Source

pub fn delete_user_secret( &self, secretname: &str, ) -> Request<'_, DeleteUserSecret<'_>, ()>

Delete a secret in a user scope

  • secretname: name of the secret
Source

pub fn get_user_variables_list( &self, ) -> Request<'_, GetUserVariablesList, (VariableListHeaders, Vec<ActionVariable>)>

Get the user-level list of variables which is created by current doer

Source

pub fn get_user_variable( &self, variablename: &str, ) -> Request<'_, GetUserVariable<'_>, ActionVariable>

Get a user-level variable which is created by current doer

  • variablename: name of the variable
Source

pub fn update_user_variable( &self, variablename: &str, body: UpdateVariableOption, ) -> Request<'_, UpdateUserVariable<'_>, ()>

Update a user-level variable which is created by current doer

Source

pub fn create_user_variable( &self, variablename: &str, body: CreateVariableOption, ) -> Request<'_, CreateUserVariable<'_>, ()>

Create a user-level variable

Source

pub fn delete_user_variable( &self, variablename: &str, ) -> Request<'_, DeleteUserVariable<'_>, ()>

Delete a user-level variable which is created by current doer

  • variablename: name of the variable
Source

pub fn user_get_oauth2_applications( &self, ) -> Request<'_, UserGetOAuth2Applications, (OAuth2ApplicationListHeaders, Vec<OAuth2Application>)>

List the authenticated user’s oauth2 applications

Source

pub fn user_create_oauth2_application( &self, body: CreateOAuth2ApplicationOptions, ) -> Request<'_, UserCreateOAuth2Application, OAuth2Application>

Creates a new OAuth2 application

Source

pub fn user_get_oauth2_application( &self, id: i64, ) -> Request<'_, UserGetOAuth2Application, OAuth2Application>

Get an OAuth2 application

  • id: Application ID to be found
Source

pub fn user_delete_oauth2_application( &self, id: i64, ) -> Request<'_, UserDeleteOAuth2Application, ()>

Delete an OAuth2 application

  • id: token to be deleted
Source

pub fn user_update_oauth2_application( &self, id: i64, body: CreateOAuth2ApplicationOptions, ) -> Request<'_, UserUpdateOAuth2Application, OAuth2Application>

Update an OAuth2 application, this includes regenerating the client secret

Source

pub fn user_update_avatar( &self, body: UpdateUserAvatarOption, ) -> Request<'_, UserUpdateAvatar, ()>

Update avatar of the current user

Source

pub fn user_delete_avatar(&self) -> Request<'_, UserDeleteAvatar, ()>

Delete avatar of the current user. It will be replaced by a default one

Source

pub fn user_block_user( &self, username: &str, ) -> Request<'_, UserBlockUser<'_>, ()>

Blocks a user from the doer

  • username: username of the user
Source

pub fn user_list_emails(&self) -> Request<'_, UserListEmails, Vec<Email>>

List all email addresses of the current user

Source

pub fn user_add_email( &self, body: CreateEmailOption, ) -> Request<'_, UserAddEmail, Vec<Email>>

Add an email addresses to the current user’s account

Source

pub fn user_delete_email( &self, body: DeleteEmailOption, ) -> Request<'_, UserDeleteEmail, ()>

Delete email addresses from the current user’s account

Source

pub fn user_current_list_followers( &self, ) -> Request<'_, UserCurrentListFollowers, (UserListHeaders, Vec<User>)>

List the authenticated user’s followers

Source

pub fn user_current_list_following( &self, ) -> Request<'_, UserCurrentListFollowing, (UserListHeaders, Vec<User>)>

List the users that the authenticated user is following

Source

pub fn user_current_check_following( &self, username: &str, ) -> Request<'_, UserCurrentCheckFollowing<'_>, ()>

Check whether a user is followed by the authenticated user

  • username: username of followed user
Source

pub fn user_current_put_follow( &self, username: &str, ) -> Request<'_, UserCurrentPutFollow<'_>, ()>

Follow a user

  • username: username of user to follow
Source

pub fn user_current_delete_follow( &self, username: &str, ) -> Request<'_, UserCurrentDeleteFollow<'_>, ()>

Unfollow a user

  • username: username of user to unfollow
Source

pub fn get_verification_token( &self, ) -> Request<'_, GetVerificationToken, String>

Get a Token to verify

Source

pub fn user_verify_gpg_key( &self, body: VerifyGPGKeyOption, ) -> Request<'_, UserVerifyGpgKey, GPGKey>

Verify a GPG key

Source

pub fn user_current_list_gpg_keys( &self, ) -> Request<'_, UserCurrentListGpgKeys, (GpgKeyListHeaders, Vec<GPGKey>)>

List the authenticated user’s GPG keys

Source

pub fn user_current_post_gpg_key( &self, form: CreateGPGKeyOption, ) -> Request<'_, UserCurrentPostGpgKey, GPGKey>

Add a GPG public key to current user’s account

Source

pub fn user_current_get_gpg_key( &self, id: i64, ) -> Request<'_, UserCurrentGetGpgKey, GPGKey>

Get a GPG key

  • id: id of key to get
Source

pub fn user_current_delete_gpg_key( &self, id: i64, ) -> Request<'_, UserCurrentDeleteGpgKey, ()>

Remove a GPG public key from current user’s account

  • id: id of key to delete
Source

pub fn user_list_hooks( &self, ) -> Request<'_, UserListHooks, (HookListHeaders, Vec<Hook>)>

List the authenticated user’s webhooks

Source

pub fn user_create_hook( &self, body: CreateHookOption, ) -> Request<'_, UserCreateHook, Hook>

Create a hook

Source

pub fn user_get_hook(&self, id: i64) -> Request<'_, UserGetHook, Hook>

Get a hook

  • id: id of the hook to get
Source

pub fn user_delete_hook(&self, id: i64) -> Request<'_, UserDeleteHook, ()>

Delete a hook

  • id: id of the hook to delete
Source

pub fn user_edit_hook( &self, id: i64, body: EditHookOption, ) -> Request<'_, UserEditHook, Hook>

Update a hook

Source

pub fn user_current_list_keys( &self, query: UserCurrentListKeysQuery, ) -> Request<'_, UserCurrentListKeys, (PublicKeyListHeaders, Vec<PublicKey>)>

List the authenticated user’s public keys

Source

pub fn user_current_post_key( &self, body: CreateKeyOption, ) -> Request<'_, UserCurrentPostKey, PublicKey>

Create a public key

Source

pub fn user_current_get_key( &self, id: i64, ) -> Request<'_, UserCurrentGetKey, PublicKey>

Get a public key

  • id: id of key to get
Source

pub fn user_current_delete_key( &self, id: i64, ) -> Request<'_, UserCurrentDeleteKey, ()>

Delete a public key

  • id: id of key to delete
Source

pub fn user_list_blocked_users( &self, ) -> Request<'_, UserListBlockedUsers, (BlockedUserListHeaders, Vec<BlockedUser>)>

List the authenticated user’s blocked users

Source

pub fn org_list_current_user_orgs( &self, ) -> Request<'_, OrgListCurrentUserOrgs, (OrganizationListHeaders, Vec<Organization>)>

List the current user’s organizations

Source

pub fn user_get_quota(&self) -> Request<'_, UserGetQuota, QuotaInfo>

Get quota information for the authenticated user

Source

pub fn user_list_quota_artifacts( &self, ) -> Request<'_, UserListQuotaArtifacts, (QuotaUsedArtifactListHeaders, Vec<QuotaUsedArtifact>)>

List the artifacts affecting the authenticated user’s quota

Source

pub fn user_list_quota_attachments( &self, ) -> Request<'_, UserListQuotaAttachments, (QuotaUsedAttachmentListHeaders, Vec<QuotaUsedAttachment>)>

List the attachments affecting the authenticated user’s quota

Source

pub fn user_check_quota( &self, query: UserCheckQuotaQuery, ) -> Request<'_, UserCheckQuota, bool>

Check if the authenticated user is over quota for a given subject

Source

pub fn user_list_quota_packages( &self, ) -> Request<'_, UserListQuotaPackages, (QuotaUsedPackageListHeaders, Vec<QuotaUsedPackage>)>

List the packages affecting the authenticated user’s quota

Source

pub fn user_current_list_repos( &self, query: UserCurrentListReposQuery, ) -> Request<'_, UserCurrentListRepos, (RepositoryListHeaders, Vec<Repository>)>

List the repos that the authenticated user owns

Source

pub fn create_current_user_repo( &self, body: CreateRepoOption, ) -> Request<'_, CreateCurrentUserRepo, Repository>

Create a repository

Source

pub fn get_user_settings(&self) -> Request<'_, GetUserSettings, UserSettings>

Get current user’s account settings

Source

pub fn update_user_settings( &self, body: UserSettingsOptions, ) -> Request<'_, UpdateUserSettings, UserSettings>

Update settings in current user’s account

Source

pub fn user_current_list_starred( &self, ) -> Request<'_, UserCurrentListStarred, (RepositoryListHeaders, Vec<Repository>)>

The repos that the authenticated user has starred

Source

pub fn user_current_check_starring( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentCheckStarring<'_>, ()>

Whether the authenticated is starring the repo

  • owner: owner of the repo
  • repo: name of the repo
Source

pub fn user_current_put_star( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentPutStar<'_>, ()>

Star the given repo

  • owner: owner of the repo to star
  • repo: name of the repo to star
Source

pub fn user_current_delete_star( &self, owner: &str, repo: &str, ) -> Request<'_, UserCurrentDeleteStar<'_>, ()>

Unstar the given repo

  • owner: owner of the repo to unstar
  • repo: name of the repo to unstar
Source

pub fn user_get_stop_watches( &self, ) -> Request<'_, UserGetStopWatches, (StopWatchListHeaders, Vec<StopWatch>)>

Get list of all existing stopwatches

Source

pub fn user_current_list_subscriptions( &self, ) -> Request<'_, UserCurrentListSubscriptions, (RepositoryListHeaders, Vec<Repository>)>

List repositories watched by the authenticated user

Source

pub fn user_list_teams( &self, ) -> Request<'_, UserListTeams, (TeamListHeaders, Vec<Team>)>

List all the teams a user belongs to

Source

pub fn user_current_tracked_times( &self, query: UserCurrentTrackedTimesQuery, ) -> Request<'_, UserCurrentTrackedTimes, (TrackedTimeListHeaders, Vec<TrackedTime>)>

List the current user’s tracked times

Source

pub fn user_unblock_user( &self, username: &str, ) -> Request<'_, UserUnblockUser<'_>, ()>

Unblocks a user from the doer

  • username: username of the user

Search for users

Source

pub fn user_get(&self, username: &str) -> Request<'_, UserGet<'_>, User>

Get a user

  • username: username of user to get
Source

pub fn user_list_activity_feeds( &self, username: &str, query: UserListActivityFeedsQuery, ) -> Request<'_, UserListActivityFeeds<'_>, (ActivityFeedsListHeaders, Vec<Activity>)>

List a user’s activity feeds

  • username: username of user
Source

pub fn user_list_followers( &self, username: &str, ) -> Request<'_, UserListFollowers<'_>, (UserListHeaders, Vec<User>)>

List the given user’s followers

  • username: username of user
Source

pub fn user_list_following( &self, username: &str, ) -> Request<'_, UserListFollowing<'_>, (UserListHeaders, Vec<User>)>

List the users that the given user is following

  • username: username of user
Source

pub fn user_check_following( &self, username: &str, target: &str, ) -> Request<'_, UserCheckFollowing<'_>, ()>

Check if one user is following another user

  • username: username of following user
  • target: username of followed user
Source

pub fn user_list_gpg_keys( &self, username: &str, ) -> Request<'_, UserListGpgKeys<'_>, (GpgKeyListHeaders, Vec<GPGKey>)>

List the given user’s GPG keys

  • username: username of user
Source

pub fn user_get_heatmap_data( &self, username: &str, ) -> Request<'_, UserGetHeatmapData<'_>, Vec<UserHeatmapData>>

Get a user’s heatmap

  • username: username of user to get
Source

pub fn user_list_keys( &self, username: &str, query: UserListKeysQuery, ) -> Request<'_, UserListKeys<'_>, (PublicKeyListHeaders, Vec<PublicKey>)>

List the given user’s public keys

  • username: username of user
Source

pub fn org_list_user_orgs( &self, username: &str, ) -> Request<'_, OrgListUserOrgs<'_>, (OrganizationListHeaders, Vec<Organization>)>

List a user’s organizations

  • username: username of user
Source

pub fn org_get_user_permissions( &self, username: &str, org: &str, ) -> Request<'_, OrgGetUserPermissions<'_>, OrganizationPermissions>

Get user permissions in organization

  • username: username of user
  • org: name of the organization
Source

pub fn user_list_repos( &self, username: &str, ) -> Request<'_, UserListRepos<'_>, (RepositoryListHeaders, Vec<Repository>)>

List the repos owned by the given user

  • username: username of user
Source

pub fn user_list_starred( &self, username: &str, ) -> Request<'_, UserListStarred<'_>, (RepositoryListHeaders, Vec<Repository>)>

The repos that the given user has starred

  • username: username of user
Source

pub fn user_list_subscriptions( &self, username: &str, ) -> Request<'_, UserListSubscriptions<'_>, (RepositoryListHeaders, Vec<Repository>)>

List the repositories watched by a user

  • username: username of the user
Source

pub fn user_get_tokens( &self, username: &str, ) -> Request<'_, UserGetTokens<'_>, (AccessTokenListHeaders, Vec<AccessToken>)>

List the authenticated user’s access tokens

  • username: username of user
Source

pub fn user_create_token( &self, username: &str, body: CreateAccessTokenOption, ) -> Request<'_, UserCreateToken<'_>, AccessToken>

Generate an access token for the current user

Source

pub fn user_delete_access_token( &self, username: &str, token: &str, ) -> Request<'_, UserDeleteAccessToken<'_>, ()>

Delete an access token from current user’s account

  • username: username of user
  • token: token to be deleted, identified by ID and if not available by name
Source

pub fn get_version(&self) -> Request<'_, GetVersion, ServerVersion>

Returns the version of the running application

Source§

impl Forgejo

Source

pub fn new(auth: Auth<'_>, url: Url) -> Result<Self, ForgejoError>

Create a new client connect to the API of the specified Forgejo instance.

The default user agent is “forgejo-api-rs”. Use Forgejo::with_user_agent to set a custom one.

Source

pub fn with_user_agent( auth: Auth<'_>, url: Url, user_agent: &str, ) -> Result<Self, ForgejoError>

Just like Forgejo::new, but includes a custom user agent to be sent with each request.

Source

pub async fn download_release_attachment( &self, owner: &str, repo: &str, release: i64, attach: i64, ) -> Result<Bytes, ForgejoError>

Source

pub async fn oauth_get_access_token( &self, body: OAuthTokenRequest<'_>, ) -> Result<OAuthToken, ForgejoError>

Requests a new OAuth2 access token

More info at Forgejo’s docs.

Source

pub async fn send_request( &self, request: &RawRequest, ) -> Result<ApiResponse, ForgejoError>

Source

pub async fn hit_endpoint<E: Endpoint, R: FromResponse>( &self, endpoint: E, ) -> Result<R, ForgejoError>

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more