diff --git a/utils/persist_payload.py b/utils/persist_payload.py index 3abc11c..210ba3e 100644 --- a/utils/persist_payload.py +++ b/utils/persist_payload.py @@ -56,7 +56,11 @@ def persist_http(self, payload: HTTPPayload, update: bool = False) -> None: try: if not update: self.client[self.db][self.external_msgs_collection].insert_one( - payload.model_dump() + { + **payload.model_dump(), + "createdAt": datetime.now().replace(tzinfo=timezone.utc), + "updatedAt": datetime.now().replace(tzinfo=timezone.utc), + } ) logging.info( "Added HTTP Payload for community id: "