Closed rlbartle closed 11 months ago
My amazon account was changed to the amazon.com.au store, making my skills and devices from the original store hidden. When changing it back to amazon.com, the cognito id stuff works properly.
Having skills enabled in different stores seems to be part of the problem. I tried removing the skill from the amazon.com store, and switching back to the au one, but the discover wouldn't even log anything. It seems like the topic issue occurs when a discover is performed with the main amazon.com store but instead the au variant sends bogus stuff. Perhaps of note, the development skill in my account is always the US variant. Maybe that's part of the problem as it should be AU.
I'd say the reason why the au store version doesn't discover anything is because of all the errors here in the web console log
I believe that is most likely endpoint issue. If a user is AU, you need to use US West (Oregon) endpoint. https://developer.amazon.com/en-US/docs/alexa/smarthome/develop-smart-home-skills-in-multiple-languages.html#deploy If this doesn't solve the issue, please feel free to use https://alexa.design/contactus
This had worked for the last 2 months and was used for a published skill. A couple of days ago I tried to discover devices and it didn't work anymore and it turns out the behaviour of something has changed. My skill uses the linked account identity to determine what devices the user can discover/control. This is done by storing the CognitoID of the linked account and the id of each device in a database. Here is the code that previously worked.
When I check the logs I see that the cognito id returned by each new discovery request results in a unique cognito id. Before it returned the cognito id of the linked user account.
EDIT:
Ok it turns out these are unsolicited discovery requests (about 60 a day) and each one has a unique user id. Using the token info REST api endpoint, the users are definitely not linked accounts. I don't know where they're coming from but it pollutes my cognito identity store with all these bogus identities. If only cognito had an option to retrieve and not generate identities.