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

Can't make Gmail.User.start_mail() work #18

Open
silvagustin opened this issue Nov 11, 2020 · 1 comment
Open

Can't make Gmail.User.start_mail() work #18

silvagustin opened this issue Nov 11, 2020 · 1 comment

Comments

@silvagustin
Copy link

Hi! I'm trying to use this dependency and after setting everything up and running:
{:ok, pid} = Gmail.User.start_mail(user_email, user_refresh_token)

I got the following error:
** (MatchError) no match of right hand side value: {:error, {:function_clause, [{Gmail.OAuth2, :do_refresh_access_token, [%{}, "1//04ml-27by0C3PCgYIARAAGAQSNwF-L9Irco4pMbDE1fJWAG38b-LpVPd-sfm9V9Fr6-3Xk-0Ecp883KXO40eANwViDYqCW3klUWU"], [file: 'lib/gmail/oauth2.ex', line: 53]}, {Gmail.OAuth2, :refresh_access_token, 1, [file: 'lib/gmail/oauth2.ex', line: 34]}, {Gmail.User, :init, 1, [file: 'lib/gmail/user.ex', line: 20]}, {:gen_server, :init_it, 2, [file: 'gen_server.erl', line: 417]}, {:gen_server, :init_it, 6, [file: 'gen_server.erl', line: 385]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}}

Is this still working?

Cheers.

@emilykay2
Copy link

I had this same issue, and I realized it was because I had not added the client id and client secret to my config file. Look at the dev.exs.sample config file in the repo for an example of what it should look like. That solved it for me!

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