_base
_base ¶
DomoAccount_Config
dataclass
¶
DomoAccount_Config(
data_provider_type: str,
is_oauth: bool,
allow_external_use: bool = True,
parent: Any = None,
raw: dict = None,
)
Bases: DomoBase
DomoAccount Config abstract base class
from_dict
classmethod
¶
from_dict(
obj: dict[str, Any], parent: Any = None, **kwargs
)
Create instance from dict, handling camelCase, snake_case, and _field_map. Robust to missing or None _field_map. Uses _field_map for both directions.
Source code in src/crew_dcs/classes/DomoAccount/account_configs/_base.py
87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 | |
to_dict ¶
to_dict(
export_fields: list[str] | None = None,
override_fn: Callable | None = None,
return_snake_case: bool = False,
**kwargs
) -> dict
Convert config to dictionary using provided fields or all _fields_for_serialization.
Source code in src/crew_dcs/classes/DomoAccount/account_configs/_base.py
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 | |
validate_compare_serialization ¶
validate_compare_serialization(
raise_on_mismatch: bool = True,
) -> bool
Validate that to_dict() output matches raw data keys (ignoring values).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
raise_on_mismatch
|
bool
|
If True, raises AccountConfig_SerializationMismatchError on mismatch. If False, returns False on mismatch. |
True
|
Returns:
| Type | Description |
|---|---|
bool
|
True if keys match, False otherwise (only if raise_on_mismatch=False) |
Raises:
| Type | Description |
|---|---|
AccountConfig_SerializationMismatchError
|
If keys don't match and raise_on_mismatch=True |
Source code in src/crew_dcs/classes/DomoAccount/account_configs/_base.py
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |