Skip to main content

fork_pr_contributor_approval_permissions

Creates, updates, deletes, gets or lists a fork_pr_contributor_approval_permissions resource.

Overview

Namefork_pr_contributor_approval_permissions
TypeResource
Idgithub.actions.fork_pr_contributor_approval_permissions

Fields

The following fields are returned by SELECT queries:

Response

NameDatatypeDescription
approval_policystringThe policy that controls when fork PR workflows require approval from a maintainer. (first_time_contributors_new_to_github, first_time_contributors, all_external_contributors)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_fork_pr_contributor_approval_permissions_repositoryselectowner, repoGets the fork PR contributor approval policy for a repository.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
set_fork_pr_contributor_approval_permissions_repositoryreplaceowner, repo, approval_policySets the fork PR contributor approval policy for a repository.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
ownerstringThe account owner of the repository. The name is not case sensitive.
repostringThe name of the repository without the .git extension. The name is not case sensitive.

SELECT examples

Gets the fork PR contributor approval policy for a repository.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.

SELECT
approval_policy
FROM github.actions.fork_pr_contributor_approval_permissions
WHERE owner = '{{ owner }}' -- required
AND repo = '{{ repo }}' -- required
;

REPLACE examples

Sets the fork PR contributor approval policy for a repository.

OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.

REPLACE github.actions.fork_pr_contributor_approval_permissions
SET
approval_policy = '{{ approval_policy }}'
WHERE
owner = '{{ owner }}' --required
AND repo = '{{ repo }}' --required
AND approval_policy = '{{ approval_policy }}' --required;