cadrumo.adapters.persistence.profile.apoderado module

Encrypted persistence adapter for apoderado configuration.

This module is the outward implementation of the application-owned ApoderadoConfigurationRepository. It owns the secure-envelope substrate, namespace contract, bucket key derivation, and translation of row-identity refusals into the application error understood by the service.

Core types: Envelope, SensitivityClass.

class ApoderadoConfigRepository(*, bucket_id, settings)[source]

Bases: ApoderadoConfigurationRepository

Encrypted per-bucket adapter for apoderado configuration.

Parameters:
namespace: ClassVar[str]
sensitivity: ClassVar[SensitivityClass]
schema_version: ClassVar[int]
classmethod payload_model()[source]

Return the application configuration DTO wrapped by this adapter.

Return type:

type[ApoderadoConfiguration]

extract_identifier(payload)[source]

Return the safe secure-object key for payload’s bucket.

Return type:

str

Parameters:

payload (ApoderadoConfiguration)

load()[source]

Load this bucket’s configuration, or return None when absent.

Return type:

ApoderadoConfiguration | None

save(configuration)[source]

Persist a configuration only when it names this bound bucket.

Return type:

None

Parameters:

configuration (ApoderadoConfiguration)

delete()[source]

Delete this bucket’s configuration, returning whether it existed.

Return type:

bool

build_apoderado_config_repository(*, bucket_id, settings)[source]

Build the concrete adapter for one explicitly routed bucket.

Return type:

ApoderadoConfigurationRepository

Parameters: