Can I embed a dynamic private message in WordPress post?

Angus,

Thank you for the quick response.

I am creating a custom post called group in WP for people to work together on projects. Only the people associated with this group post can see the post.
This group would be working together for 2 months and I want to allow them to have a conversation. I don’t want to create a chat/ discussion system in WP just for this and want to leverage Discourse instead.

Topics vs PMs in Discourse
I am not sure how to create a private topic for every ‘group’ post in WP and dynamically give access to only certain people to read and edit. Although it’s a manual process, I know how to create a private message and use it as a proxy for a topic. Is there a way to create a private topic with dynamic user restrictions on creation of a custom post in WP?

Why private?
Because these are young professionals looking to build their skills by working together on a project. I want to provide them a safe space to connect without being judged by other members on the platform.
I want to display the thread (message or topic) only on the related ‘group’ custom post in WP i.e. one post in WP will have one private thread which should be visible to the people in the group.