function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Maguy Fogaing 2Maguy Fogaing 2 

Get user infos (name and email) in chat without pre-chat form

I am creating an Einstein chatbot and I want to greet the user by their name. The Apex class that I have written for this purpose returns "Platform Integration User". An answer to another post says to use a pre-chat form. Is there any way to get the logged-in user's details without having them fill a pre-chat form? Because for my purpose my chatbot will not have pre-chat form.

Please is there anyone who knows how l can do it ?
SwethaSwetha (Salesforce Developers) 
HI Maguy,
I don't think it is possible without a prechat form.
See related: https://salesforce.stackexchange.com/questions/222573/einstein-chat-bot
https://salesforce.stackexchange.com/questions/235781/einstein-bot-get-current-community-user-for-live-agent-pre-chat

Thanks