Back to the "Organization API" | Back to the navigation
https://docs.github.com/en/rest/reference/actions#list-organization-secrets
$secrets = $client->organization()->secrets()->all('KnpLabs');
https://docs.github.com/en/rest/reference/actions#get-an-organization-secret
$secret = $client->organization()->secrets()->show('KnpLabs', $secretName);
https://docs.github.com/en/rest/reference/actions#create-or-update-an-organization-secret
$client->organization()->secrets()->create('KnpLabs', $secretName, [
'encrypted_value' => $encryptedValue,
'visibility' => $visibility,
'selected_repository_ids' => $selectedRepositoryIds,
]);
https://docs.github.com/en/rest/reference/actions#create-or-update-an-organization-secret
$client->organization()->secrets()->update('KnpLabs', $secretName, [
'key_id' => 'keyId',
'encrypted_value' => 'encryptedValue',
'visibility' => 'private',
]);
https://docs.github.com/en/rest/reference/actions#delete-an-organization-secret
$client->organization()->secrets()->remove('KnpLabs', $secretName);
$client->organization()->secrets()->selectedRepositories('KnpLabs', $secretName);
$client->organization()->secrets()->setSelectedRepositories('KnpLabs', 'secretName', [
'selected_repository_ids' => [1, 2, 3],
]);
$client->organization()->secrets()->addSecret('KnpLabs', $repositoryId, $secretName);
https://docs.github.com/en/rest/reference/actions#get-an-organization-public-key
$client->organization()->secrets()->publicKey('KnpLabs');