harp_apps.storage.models.messages

Inheritance diagram of harp_apps.storage.models.messages

class Message[source]

Bases: Base

A simple constructor that allows initialization from kwargs.

Sets attributes on the constructed instance using the names and values in kwargs.

Only keys that are present as attributes of the instance’s class are allowed. These could be, for example, any mapped columns or relationships.

__init__(**kwargs)

A simple constructor that allows initialization from kwargs.

Sets attributes on the constructed instance using the names and values in kwargs.

Only keys that are present as attributes of the instance’s class are allowed. These could be, for example, any mapped columns or relationships.

classmethod from_models(transaction, message, headers, content)[source]
Parameters:

message (BaseMessage)

to_model()[source]
body: Mapped[str | None]
created_at: Mapped[datetime]
headers: Mapped[str]
id: Mapped[int]
kind: Mapped[str]
summary: Mapped[str]
transaction: Mapped[Transaction]
transaction_id: Mapped[str]
class MessagesRepository[source]

Bases: Repository[Message]

Type

alias of Message

async create(values, /, *, session)[source]
Parameters:

values (dict | Message)