def internal_send_stream_message_by_name(realm: Realm, sender: UserProfile, stream_name: str, topic: str, content: str) -> Optional[int]:
    message = internal_prep_stream_message_by_name(realm, sender, stream_name, topic, content)
    if (message is None):
        return None
    message_ids = do_send_messages([message])
    return message_ids[0]
def internal_send_stream_message_by_name(realm: Realm, sender: UserProfile, stream_name: str, topic: str, content: str) -> Optional[int]:
    message = internal_prep_stream_message_by_name(realm, sender, stream_name, topic, content)
    if (message is None):
        return None
    message_ids = do_send_messages([message])
    return message_ids[0]