Source code for dxaws_accounts.models

from __future__ import annotations

from dataclasses import dataclass
from typing import Any


[docs] @dataclass(frozen=True) class DesiredState: """Represents the desired state for this module. Concrete modules should replace or extend this model with module-specific desired-state fields. """ spec: Any
[docs] @dataclass(frozen=True) class Plan: """Represents a plan to converge current state to desired state. Planners should return a Plan instance describing what actions need to be taken. The structure of `plan` is module-defined. """ plan: Any
[docs] @dataclass(frozen=True) class ApplyResult: """Represents the result of applying a plan. Executors should return an ApplyResult capturing what actually occurred (created, updated, no-op, etc.). """ result: Any
[docs] @dataclass(frozen=True) class AwsOrgAccount: """Represents an AWS account as returned by AWS Organizations.""" id: str name: str email: str status: str
[docs] @dataclass(frozen=True) class AccountAlias: """Human-friendly alias for an AWS account ID.""" alias: str account_id: str
[docs] @dataclass(frozen=True) class AccountSelection: """Represents the resolved account selection used for command execution.""" account_id: str source: str # id | alias | name | email | default
[docs] @dataclass(frozen=True) class SyncResult: """Result of syncing accounts from AWS Organizations into local state.""" added: list[AwsOrgAccount] updated: list[AwsOrgAccount] removed: list[str]