assets_guardian.core.domain.ports.client

Classes

IClientProvider(config)

Port: Client provider used to collect data.

class assets_guardian.core.domain.ports.client.IClientProvider(config: dict[str, Any])[source]

Bases: ABC

Port: Client provider used to collect data.

Defines the contract for obtaining a client specific to a data source.

Initialize the client provider with the instance’s configuration dictionary.

abstractmethod health_check() bool[source]

Verifies that the client connection, return True if the remote service is reachable and credentials are valid, else False.

abstractmethod instantiate_client() HttpClient | MySQLClient | Any[source]

Returns a ready-to-use client.

The return type depends on the specific implementation (e.g., GraphServiceClient, requests Session, GitLab client, etc.).