Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to take the user's email ? #62

Closed
m7vm7v opened this issue Mar 7, 2017 · 3 comments
Closed

How to take the user's email ? #62

m7vm7v opened this issue Mar 7, 2017 · 3 comments

Comments

@m7vm7v
Copy link

m7vm7v commented Mar 7, 2017

Hi,

Is it possible to take the user's email ?

Thanks

@CasperLaiTW
Copy link
Owner

Please follow this :)

use Casperlaitw\LaravelFbMessenger\Messages\User;

/**
 * Class DefaultHandler
 * @package Casperlaitw\LaravelFbMessenger\Contracts
 */
class DefaultHandler extends BaseHandler
{
    /**
     * Handle the chatbot message
     *
     * @param ReceiveMessage $message
     *
     * @return mixed
     */
    public function handle(ReceiveMessage $message)
    {
        // You will get user profile.
        $profile = $this->send(new User($message->getSender()));
    }
}

@m7vm7v
Copy link
Author

m7vm7v commented Mar 7, 2017

I need to save the information in the database and I need the user's email not the ID.
Is it possible to get the email?

@CasperLaiTW
Copy link
Owner

I think you can't get email.

document

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants