Struct octorust::interactions::Interactions [−][src]
pub struct Interactions { /* fields omitted */ }
Implementations
Get interaction restrictions for an organization.
This function performs a GET
to the /orgs/{org}/interaction-limits
endpoint.
Shows which type of GitHub user can interact with this organization and when the restriction expires. If there is no restrictions, you will see an empty response.
FROM: https://docs.github.com/rest/reference/interactions#get-interaction-restrictions-for-an-organization
Parameters:
org: &str
pub async fn set_restrictions_for_org(
&self,
org: &str,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
pub async fn set_restrictions_for_org(
&self,
org: &str,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
Set interaction restrictions for an organization.
This function performs a PUT
to the /orgs/{org}/interaction-limits
endpoint.
Temporarily restricts interactions to a certain type of GitHub user in any public repository in the given organization. You must be an organization owner to set these restrictions. Setting the interaction limit at the organization level will overwrite any interaction limits that are set for individual repositories owned by the organization.
FROM: https://docs.github.com/rest/reference/interactions#set-interaction-restrictions-for-an-organization
Parameters:
org: &str
Remove interaction restrictions for an organization.
This function performs a DELETE
to the /orgs/{org}/interaction-limits
endpoint.
Removes all interaction restrictions from public repositories in the given organization. You must be an organization owner to remove restrictions.
Parameters:
org: &str
pub async fn get_restrictions_for_repo(
&self,
owner: &str,
repo: &str
) -> Result<InteractionLimitResponse>
pub async fn get_restrictions_for_repo(
&self,
owner: &str,
repo: &str
) -> Result<InteractionLimitResponse>
Get interaction restrictions for a repository.
This function performs a GET
to the /repos/{owner}/{repo}/interaction-limits
endpoint.
Shows which type of GitHub user can interact with this repository and when the restriction expires. If there are no restrictions, you will see an empty response.
FROM: https://docs.github.com/rest/reference/interactions#get-interaction-restrictions-for-a-repository
Parameters:
owner: &str
repo: &str
pub async fn set_restrictions_for_repo(
&self,
owner: &str,
repo: &str,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
pub async fn set_restrictions_for_repo(
&self,
owner: &str,
repo: &str,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
Set interaction restrictions for a repository.
This function performs a PUT
to the /repos/{owner}/{repo}/interaction-limits
endpoint.
Temporarily restricts interactions to a certain type of GitHub user within the given repository. You must have owner or admin access to set these restrictions. If an interaction limit is set for the user or organization that owns this repository, you will receive a 409 Conflict
response and will not be able to use this endpoint to change the interaction limit for a single repository.
FROM: https://docs.github.com/rest/reference/interactions#set-interaction-restrictions-for-a-repository
Parameters:
owner: &str
repo: &str
Remove interaction restrictions for a repository.
This function performs a DELETE
to the /repos/{owner}/{repo}/interaction-limits
endpoint.
Removes all interaction restrictions from the given repository. You must have owner or admin access to remove restrictions. If the interaction limit is set for the user or organization that owns this repository, you will receive a 409 Conflict
response and will not be able to use this endpoint to change the interaction limit for a single repository.
FROM: https://docs.github.com/rest/reference/interactions#remove-interaction-restrictions-for-a-repository
Parameters:
owner: &str
repo: &str
pub async fn get_restrictions_for_authenticated_user(
&self
) -> Result<InteractionLimitResponse>
pub async fn get_restrictions_for_authenticated_user(
&self
) -> Result<InteractionLimitResponse>
Get interaction restrictions for your public repositories.
This function performs a GET
to the /user/interaction-limits
endpoint.
Shows which type of GitHub user can interact with your public repositories and when the restriction expires.
pub async fn set_restrictions_for_authenticated_user(
&self,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
pub async fn set_restrictions_for_authenticated_user(
&self,
body: &InteractionLimit
) -> Result<InteractionLimitResponse>
Set interaction restrictions for your public repositories.
This function performs a PUT
to the /user/interaction-limits
endpoint.
Temporarily restricts which type of GitHub user can interact with your public repositories. Setting the interaction limit at the user level will overwrite any interaction limits that are set for individual repositories owned by the user.
Remove interaction restrictions from your public repositories.
This function performs a DELETE
to the /user/interaction-limits
endpoint.
Removes any interaction restrictions from your public repositories.
Auto Trait Implementations
impl !RefUnwindSafe for Interactions
impl Send for Interactions
impl Sync for Interactions
impl Unpin for Interactions
impl !UnwindSafe for Interactions