Koha::ApiKey - Koha API Key Object class
my $api_key = Koha::ApiKey->new({ patron_id => $patron_id })->store;
Overloaded store method.
if ( $api_key->validate_secret( $secret ) ) { ... }
Returns a boolean that tells if the passed secret matches the one on the DB.
my $generated_secret = $api_key->store->plain_text_secret;
Returns the generated secret so it can be displayed to the end user. This is only accessible when the object is new and has just been stored.
Returns undef if the object was retrieved from the database.
my $string = $self->_generate_unused_uuid($column);
$column can be 'client_id' or 'secret'.