from protocols.models import KeyDTO from protocols.repository import Repository class GetKey: def __init__( self, repository: Repository, ) -> None: self.repository = repository def __call__(self, request: KeyDTO) -> KeyDTO | None: return self.repository.get_key(obj=request)