pytenno.models.orders

class pytenno.models.orders.OrderCommon(*, id: str, platinum: int, quantity: int, order_type: OrderType, platform: Platform, region: str, creation_date: datetime, last_update: datetime, visible: bool, mod_rank: Optional[int] = None)[source]

Common base class that orders inherit from.

creation_date: datetime

The time the order was created.

id: str

The ID of the order.

last_update: datetime

The time the order was last updated.

mod_rank: int | None = None

The mod rank of the order’s item. Default is None, meaning not applicable.

order_type: OrderType

The type of order.

platform: Platform

The platform the order is on.

platinum: int

The amount of platinum per item in the order.

quantity: int

How many items the user is selling / buying.

region: str

The region the order is on.

visible: bool

Whether the order is visible to others. In this case, always True.

class pytenno.models.orders.OrderCreated(*, id: str, platinum: int, quantity: int, order_type: OrderType, platform: Platform, region: str, creation_date: datetime, last_update: datetime, visible: bool, mod_rank: Optional[int] = None, item: ItemInOrder)[source]

Represents an Order after it has been passed to the API and is now created.

creation_date: datetime

The time the order was created.

id: str

The ID of the order.

item: ItemInOrder

The item in the order.

last_update: datetime

The time the order was last updated.

mod_rank: int | None = None

The mod rank of the order’s item. Default is None, meaning not applicable.

order_type: OrderType

The type of order.

platform: Platform

The platform the order is on.

platinum: int

The amount of platinum per item in the order.

quantity: int

How many items the user is selling / buying.

region: str

The region the order is on.

visible: bool

Whether the order is visible to others. In this case, always True.

class pytenno.models.orders.OrderFull(*, id: str, platinum: int, quantity: int, order_type: OrderType, platform: Platform, region: str, creation_date: datetime, last_update: datetime, visible: bool, mod_rank: Optional[int] = None, user: UserShort, item: ItemInOrder)[source]

Same as OrderRow, but with a full item model.

creation_date: datetime

The time the order was created.

id: str

The ID of the order.

item: ItemInOrder

The item in the order.

last_update: datetime

The time the order was last updated.

mod_rank: int | None = None

The mod rank of the order’s item. Default is None, meaning not applicable.

order_type: OrderType

The type of order.

platform: Platform

The platform the order is on.

platinum: int

The amount of platinum per item in the order.

quantity: int

How many items the user is selling / buying.

region: str

The region the order is on.

user: UserShort

The user who made the order.

visible: bool

Whether the order is visible to others. In this case, always True.

class pytenno.models.orders.OrderRow(*, id: str, platinum: int, quantity: int, order_type: OrderType, platform: Platform, region: str, creation_date: datetime, last_update: datetime, visible: bool, mod_rank: Optional[int] = None, user: UserShort)[source]

Same as OrderCommon, but with a full user model.

creation_date: datetime

The time the order was created.

id: str

The ID of the order.

last_update: datetime

The time the order was last updated.

mod_rank: int | None = None

The mod rank of the order’s item. Default is None, meaning not applicable.

order_type: OrderType

The type of order.

platform: Platform

The platform the order is on.

platinum: int

The amount of platinum per item in the order.

quantity: int

How many items the user is selling / buying.

region: str

The region the order is on.

user: UserShort

The user who made the order.

visible: bool

Whether the order is visible to others. In this case, always True.