'staff_3', 'requestData' => [ 'name' => [ 'validation' => DataValidator::notBlank()->length(2, 55), 'error' => ERRORS::INVALID_NAME ] ] ]; } public function handler() { $name = Controller::request('name'); $keyInstance = APIKey::getDataStore($name, 'name'); if($keyInstance->isNull()) { throw new RequestException(ERRORS::INVALID_NAME); return; } $keyInstance->delete(); Response::respondSuccess(); } }