TL;DR
- Ownership transfer on the Photon is fluid. Physical ownership is virtual ownership. This solves one of the most common issues experienced on the Core.
- End user ownership is completely separate from a product manufacturerâs ability to control her devices in the field.
Longer Explanation
If youâve ever been at a hackathon where a hundred Cores were set up via the mobile app using TIâs Smart Config and everyone claimed the wrong Core or one person claimed all the Cores, then you understand the problem we needed to solve.
In those cases, there is no way to be able to control a Core you are holding in your hand and are the rightful owner of. The only recourse is to find the person who owns it, and ask her to unclaim it so you can claim it. Eventually we automated this process in Particle Build to reduce the burden on our support team and allow users to take care of the issue quickly themselves.
With the Photonâs soft AP setup process, only one Photon can be claimed at a time so no one can take over a whole roomful of devices in an instant.
More importantly, if you have a Photon in your possession, and it is claimed by someone else, you just need to perform setup to claim the device. If you are borrowing the device from a friend, you can claim it from your friend, and then when you give it back, the friend can simply claim it again.
It is important to know that building a product on the Particle platform requires additional steps that one does not normally take when prototyping with Photons. Products identify themselves to the cloud, and the team members that belong to the organization that created the product always have the ability to control the devices regardless of which end user has claimed each one. Product management for organizations is completely separate from claiming.
These product management capabilities are exposed in the organization dashboard that is in private beta right now.
Photon Claiming Flow
As part of the soft AP setup process (technical docs), in addition to sending Wi-Fi credentials, we transfer something called a âclaim codeâ. At a high level the process looks like this:
- Mobile app (with user access token) gets a claim code from the cloud
- Mobile app gives Photon (both offline) the claim code
- When Photon connects to cloud it publishes the claim code, which the device service uses to make the association between the Photon and the user.
Another important thing to knowâthe cloud is the source of truth for ownership. Sometimes I notice people implying that the device knows who its owner isâit does not. We control access through the cloud.
And one last important thing to remember about soft AP setupâboth the mobile app and the Photon are offline during soft AP and can not know for certain the current status of ownership.
@jeiden just came up with this great diagram today â weâll be incorporating this or some revision of it into some product creator documentation soon, but he suggested it could be helpful here. It describes one specific way (out of many) that product creators can manage customer authentication. Itâs not the whole story, but itâs helpful info in this conversation.