Skip to main content

org_oidc_custom_property_inclusions

Creates, updates, deletes, gets or lists an org_oidc_custom_property_inclusions resource.

Overview​

Nameorg_oidc_custom_property_inclusions
TypeResource
Idgithub.oidc.org_oidc_custom_property_inclusions

Fields​

The following fields are returned by SELECT queries:

A JSON array of OIDC custom property inclusions

NameDatatypeDescription
custom_property_namestringThe name of the custom property that is included in the OIDC token
inclusion_sourcestringWhether the inclusion was defined at the organization or enterprise level (organization, enterprise) (example: organization)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_oidc_custom_property_inclusions_for_orgselectorgLists the repository custom properties that are included in the OIDC token for repository actions in an organization.

OAuth app tokens and personal access tokens (classic) need the read:org scope to use this endpoint.
create_oidc_custom_property_inclusion_for_orginsertorg, custom_property_nameAdds a repository custom property to be included in the OIDC token for repository actions in an organization.

OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.
delete_oidc_custom_property_inclusion_for_orgdeleteorg, custom_property_nameRemoves a repository custom property from being included in the OIDC token for repository actions in an organization.

OAuth app tokens and personal access tokens (classic) need the admin:org 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
custom_property_namestringThe name of the custom property to remove from OIDC token inclusion
orgstringThe organization name. The name is not case sensitive.

SELECT examples​

Lists the repository custom properties that are included in the OIDC token for repository actions in an organization.

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

SELECT
custom_property_name,
inclusion_source
FROM github.oidc.org_oidc_custom_property_inclusions
WHERE org = '{{ org }}' -- required
;

INSERT examples​

Adds a repository custom property to be included in the OIDC token for repository actions in an organization.

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

INSERT INTO github.oidc.org_oidc_custom_property_inclusions (
custom_property_name,
org
)
SELECT
'{{ custom_property_name }}' /* required */,
'{{ org }}'
RETURNING
custom_property_name,
inclusion_source
;

DELETE examples​

Removes a repository custom property from being included in the OIDC token for repository actions in an organization.

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

DELETE FROM github.oidc.org_oidc_custom_property_inclusions
WHERE org = '{{ org }}' --required
AND custom_property_name = '{{ custom_property_name }}' --required
;