{
  "hash": "a1999ce28adcecc054b19196cb9fa5fb",
  "result": {
    "engine": "jupyter",
    "markdown": "---\ntitle: Messages\n---\n\n\n\nIbis Birdbrain communicates with the user, itself, and (eventually) other bots through `Messages`. A `Message` is a simple wrapper around text with metadata and optional [`Attachments`](./attachments.qmd).\n\n\n## Usage\n\n\n::: {#7600ef36 .cell execution_count=1}\n``` {.python .cell-code}\nfrom ibis_birdbrain.messages import Message, Messages, Email\n\nm1 = Message(\"Hello, world!\")\nm1\n```\n\n::: {.cell-output .cell-output-display execution_count=1}\n```\nMessage(df8f6f11-7362-47d8-b932-62424d3cba8d)\n```\n:::\n:::\n\n\n## Emails\n\nCurrently, the only implementation of `Message` that is viewable as a proper string is `Email`.\n\n::: {#cd8d157a .cell execution_count=2}\n``` {.python .cell-code}\ne1 = Email(\"Hello\")\ne2 = Email(\", world!\")\n\nmessages = Messages([e1, e2])\nmessages\n```\n\n::: {.cell-output .cell-output-display execution_count=2}\n```\nTo: \nFrom: \nSubject: \nSent at: 2024-03-05 09:03:08.698844\nMessage: adca7673-ec5c-4377-bd33-b933fb423af7\n\nHello\n\nAttachments:\n\n\n---\nTo: \nFrom: \nSubject: \nSent at: 2024-03-05 09:03:08.698872\nMessage: 22619ca0-0390-4eaf-951d-459ad636a13f\n\n, world!\n\nAttachments:\n\n```\n:::\n:::\n\n\n",
    "supporting": [
      "messages_files"
    ],
    "filters": [],
    "includes": {}
  }
}