# `PLCResolver`

A class in `fastatp.did.plc` ([source](https://github.com/jacoblapenna/fastatp/blob/main/fastatp/did/plc.py#L322)).

```python
PLCResolver(
    *,
    directory: str = PLC_DIRECTORY,
    verify: bool = True,
    timeout: float = 10.0,
    cache_size: int = 1024,
    cache_ttl: float = 300.0,
    client: httpx.AsyncClient | None = None,
)
```

[`DIDResolver`](https://fastatp.com/api/didresolver.md) for did:plc via a PLC directory. Resolve-only.

With `verify=True` (default) each resolution fetches
`{directory}/{did}/log/audit` and runs `verify_audit_log`, so the
document comes from the self-certified chain, not the directory's word.
With `verify=False` it fetches the directory's rendered document and
trusts it (the ecosystem-typical posture).

Results are cached in a small LRU for `cache_ttl` seconds (the PLC
directory sets no meaningful cache headers, so the TTL is ours) with the
same `invalidate()` seam as [`WebResolver`](https://fastatp.com/api/webresolver.md) — a firehose `#identity`
event should invalidate rather than wait out the TTL.

## Methods

### `invalidate`

```python
invalidate(did: str) -> None
```

Drop a cached document so the next resolve refetches.

### `aclose`

```python
async aclose() -> None
```
