> ## Documentation Index
> Fetch the complete documentation index at: https://docs.notareum.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Api reference

# Python: API Reference

Complete method surface for the `notareum` Python SDK. All write methods require an `eth_account.Account` (or compatible) passed as `account=` to the `Notareum` constructor.

## Factory

```python theme={"system"}
from notareum import Notareum

Notareum(
    provider,                  # web3.Web3 instance
    contracts: dict[str, str], # see ContractAddresses
    account=None,              # optional eth_account.Account
) -> Notareum
```

`Notareum` exposes six sub-clients as attributes: `nota`, `registry`, `verification`, `staking`, `governance`, `fee`.

## `NotaFileClient` (`ntm.nota`)

```python theme={"system"}
class NotaFileClient:
    def create(
        self,
        *,
        type: str,
        chain_name: str,
        chain_id: int,
        identifier: str,
        network: str | None = None,
        name: str | None = None,
        alias: str | None = None,
        description: str | None = None,
        resource_metadata: dict | None = None,
        issuer_name: str | None = None,
        issuer_entity_type: str | None = None,
    ) -> NotaBuilder

    def parse(self, content: str) -> dict
    def validate(self, nota: dict) -> None
    def is_valid(self, nota: dict) -> bool
    def serialize(self, nota: dict) -> str

class NotaBuilder:
    def sign(self, private_key: str) -> NotaBuilder
    def validate(self) -> NotaBuilder
    def serialize(self) -> str
    def build(self) -> dict
```

## `RegistryClient` (`ntm.registry`)

```python theme={"system"}
class RegistryClient:
    def register_resource(
        self, *,
        resource_type: int,
        chain_id: int,
        identifier: str,
        proof_hash: str | bytes,
        alias: str = "",
    ) -> str

    def get_resource(self, resource_id: bytes | str) -> ResourceInfo
    def resolve_alias(self, alias: str) -> str
    def revoke_resource(self, resource_id: bytes | str) -> str

    def compute_resource_id(
        self, *,
        resource_type: int,
        chain_id: int,
        identifier: str,
    ) -> str

    def add_resource_type(self, type_id: int, name: str) -> str
    def remove_resource_type(self, type_id: int) -> str
    def is_valid_resource_type(self, type_id: int) -> bool
    def get_resource_type_name(self, type_id: int) -> str
```

## `VerificationClient` (`ntm.verification`)

```python theme={"system"}
class VerificationClient:
    def request_verification(
        self,
        resource_id: bytes | str,
        level: VerificationLevel | int,
    ) -> str

    def submit_attestation(
        self,
        resource_id: bytes | str,
        approved: bool,
    ) -> str

    def get_verification_request(self, request_id: int) -> VerificationRequest
    def get_verification_fee(self, level: VerificationLevel | int) -> int
```

## `StakingClient` (`ntm.staking`)

```python theme={"system"}
class StakingClient:
    def stake(self, amount: int) -> str
    def unstake(self) -> str
    def claim_stake(self) -> str

    def get_validator_info(self, address: str) -> ValidatorInfo
    def get_tier(self, address: str) -> ValidatorTier
    def get_daily_verifications_remaining(self, address: str) -> int
    def get_tier_threshold(self, tier: ValidatorTier | int) -> int
```

## `GovernanceClient` (`ntm.governance`)

```python theme={"system"}
class GovernanceClient:
    def lock(self, amount: int, duration: int) -> str
    def extend_lock(self, lock_id: int, additional_duration: int) -> str
    def unlock(self, lock_id: int) -> str

    def get_voting_power(self, address: str) -> int
    def get_lock(self, lock_id: int) -> VeNOTALock
    def get_total_supply(self) -> int
```

## `FeeClient` (`ntm.fee`)

```python theme={"system"}
class FeeClient:
    def get_verification_fee(self, level: int) -> int
    def get_alias_fee(self) -> int
    def get_dispute_bond(self) -> int
    def get_fee_collector(self) -> str
    def get_fee_config(self) -> FeeConfig

    # Governance only
    def set_verification_fee(self, level: int, fee: int) -> str
    def set_alias_fee(self, fee: int) -> str
```

## Enums and dataclasses

```python theme={"system"}
from enum import IntEnum

class VerificationLevel(IntEnum):
    BASIC = 0
    ENHANCED = 1
    INSTITUTIONAL = 2

class VerificationStatus(IntEnum):
    PENDING = 0
    APPROVED = 1
    REJECTED = 2
    EXPIRED = 3

class ValidatorTier(IntEnum):
    NONE = 0
    BRONZE = 1       # protocol: BASIC
    SILVER = 2       # protocol: PROFESSIONAL
    GOLD = 3         # protocol: ENTERPRISE
    PLATINUM = 4     # protocol: INSTITUTIONAL
```

Dataclasses live under `notareum.types`: `ContractAddresses`, `ResourceInfo`, `ValidatorInfo`, `VeNOTALock`, `VerificationRequest`, `FeeConfig`.

## Errors

```python theme={"system"}
from notareum.core.errors import (
    ConfigurationError,
    SignerRequiredError,
    ContractCallError,
    ResourceNotFoundError,
)
```

See [Error Codes](../../reference/error-codes.md) for the full mapping of Python exceptions to on-chain revert reasons.
