cancel
Showing results for 
Search instead for 
Did you mean: 

Smart home Washer codelabs INVALID_AUTH_TOKEN

imdantheman32
Community Member

Hi, I did the smart home washer codelabs. When I try to link my account to my test service, I get the error: 'Could not reach [test] my smart home. Please try again later.

I checked the error logs, it says "SYNC: Request ID 12685237494986108439 failed with code: INVALID_AUTH_TOKEN"

Notes:

I've triple checked my fulfilment URL and Oauth endpoint URLs.

I've done the same codelabs a few times using the same project, adding edits to the index.js each time. This was a fresh project I did with no edits.

 

 

1 Recommended Answer

sipriyadarshi
Solutions Expert
Solutions Expert
  • When you try out the codelab, before you link your account for the first time make sure to press Test in the Actions Console > Develop > Account Linking Tab. Once you do, the test project will be listed in GHA and you should be able to proceed with linking. As the linking attempt fail, can you share a screenshot of the error you see on GCP?
  • Besides the GCP logs, with the codelab, since the account linking server is implemented using Firebase, you can check the firebase backend logs to see a detailed error. Can you check the firebase backend logs (you may need console log to print the log) and see if your service is returning HTTP 401 successfully?

View Recommended Answer in original post

5 REPLIES 5

sipriyadarshi
Solutions Expert
Solutions Expert
  • When you try out the codelab, before you link your account for the first time make sure to press Test in the Actions Console > Develop > Account Linking Tab. Once you do, the test project will be listed in GHA and you should be able to proceed with linking. As the linking attempt fail, can you share a screenshot of the error you see on GCP?
  • Besides the GCP logs, with the codelab, since the account linking server is implemented using Firebase, you can check the firebase backend logs to see a detailed error. Can you check the firebase backend logs (you may need console log to print the log) and see if your service is returning HTTP 401 successfully?

I did the first point, didn't work. 

In the end I decided to just setup my own Oauth code instead of using fakeauth and faketoken. I will still present my logs. Thanks a lot for help though! error_message.png

 

 

I also am experiencing this exact same issue (with this codelab).  Could you tell me, did you have to publish to a production app before you could utilize the oauth implementation you used to replace fakeauth/faketoken? 

Thank you!

Hi, no I did not need to publish the production app. I just replaced the fakeauth/faketoken with webhooks that does the proper OAuth2.0 flow. It all works now and I'm still in testing.

Hope that helps!

Thanks for responding - good luck! Oh and the irony...

Screen Shot 2023-04-19 at 10.11.27 AM.png