Reference
Getting the token client-side
The token this package verifies is minted when a user signs in with the client SDKs. Send it to your backend as Authorization: Bearer <token>.
tsxweb — decane-connect-kit
import { useSocialAuth } from "decane-connect-kit";
const { getAccessToken } = useSocialAuth();
const token = await getAccessToken();
await fetch("/api/me", { headers: { Authorization: "Bearer " + token } });tsReact Native — decane-connect-kit-expo
const token = decane.getAccessToken(); // Decane JWT | null
await fetch("https://api.example.com/me", {
headers: { Authorization: "Bearer " + token },
});Both SDKs mint tokens from the same backend, so one DecaneClient verifies users from web and mobile alike.