Update api-key:disable command to allow passing a name

This commit is contained in:
Alejandro Celaya
2024-11-06 20:10:06 +01:00
parent f6d70c599e
commit bd73362c94
6 changed files with 188 additions and 37 deletions

View File

@@ -19,7 +19,13 @@ interface ApiKeyServiceInterface
/**
* @throws InvalidArgumentException
*/
public function disable(string $key): ApiKey;
public function disableByName(string $apiKeyName): ApiKey;
/**
* @deprecated Use `self::disableByName($name)` instead
* @throws InvalidArgumentException
*/
public function disableByKey(string $key): ApiKey;
/**
* @return ApiKey[]