"""Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT."""

from __future__ import annotations
import dataclasses
from ..shared import sublineitemgrouping as shared_sublineitemgrouping
from ..shared import sublineitemmatrixconfig as shared_sublineitemmatrixconfig
from dataclasses_json import Undefined, dataclass_json
from enum import Enum
from orb import utils
from typing import Optional, Union



@dataclasses.dataclass
class MatrixSubLineItemQuantity:
    pass

class MatrixSubLineItemType(str, Enum):
    MATRIX = 'matrix'


@dataclass_json(undefined=Undefined.EXCLUDE)

@dataclasses.dataclass
class MatrixSubLineItem:
    amount: str = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('amount') }})
    r"""The total amount for this sub line item."""
    grouping: Optional[shared_sublineitemgrouping.SubLineItemGrouping] = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('grouping') }})
    matrix_config: shared_sublineitemmatrixconfig.SubLineItemMatrixConfig = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('matrix_config') }})
    name: str = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('name') }})
    quantity: Union[float, str] = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('quantity') }})
    type: MatrixSubLineItemType = dataclasses.field(metadata={'dataclasses_json': { 'letter_case': utils.get_field_name('type') }})
    

