def METHOD_NAME(event):
    name = None
    if event.recipient_id:
        name = case_or_user_id_to_name(event.recipient_id, {
            "couch_recipient_doc_type": event.get_recipient_doc_type()
        })
    return {
        "recipient_id": event.recipient_id,
        "type": MessagingSubEvent.RECIPIENT_SLUGS.get(event.recipient_type, "unknown"),
        "name": name or "unknown",
    }