Our Android SDK offers the easiest way to integrate "Sign in with device" to your android app. You can simply call a function and it does most of the heavy lifting and authentication for you.
Overview
Authenticating users using Trusted Devices with Cotter's Android SDK consists of the following steps:
Import and Initialize Cotter
Calling functions to register devices a Trusted Device
Calling functions to authenticate from Trusted and Non-Trusted Device
You can now use the SDK to enroll and verify Trusted Devices for the user you just created.
In your MainActivity, initialize Cotter with API keys, Cotter's URL to use (prod/test), and your User ID.
Production Endpoint: https://www.cotter.app/api/v0
Example:
Step 5: Register this device as a Registered Device
Right after your user finished their registration to your app, you should automatically register the device as a Trusted Device (or prompt your user if they want to make this device as a Trusted Device).