Sample - GitHub REST API
POST/enterprises/{enterprise}/actions/oidc/customization/properties/repo

Create an OIDC custom property inclusion for an enterprise

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

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

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

1 parameter · 1 body field
enterprisestringrequired
The slug version of the enterprise name.
custom_property_namestringrequired
The name of the custom property to include in the OIDC token

4 status codes
201OIDC custom property inclusion created
custom_property_namestringrequired
The name of the custom property that is included in the OIDC token
inclusion_sourcestringrequired
Whether the inclusion was defined at the organization or enterprise level
Allowed:organizationenterprise
400Invalid input
403Forbidden
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
422Property inclusion already exists

Error handling

A 400 is returned: Invalid input. A 403 is returned: Forbidden. A 422 is returned: Property inclusion already exists.