Back to the "Environments API" | Back to the navigation
https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28
$secrets = $client->environment()->secrets()->all($repoId, $envName);
https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#get-an-environment-secret
$secret = $client->environment()->secrets()->show($repoId, $envName, $secretName);
$client->environment()->secrets()->createOrUpdate($repoId, $envName, $secretName, [
'encrypted_value' => $encryptedValue,
'key_id' => $key_id
]);
https://docs.github.com/en/rest/reference/actions#delete-an-organization-secret
$client->environment()->secrets()->remove($repoId, $envName, $secretName);
https://docs.github.com/en/rest/reference/actions#get-an-organization-public-key
$client->environment()->secrets()->publicKey($repoId, $envName);