unlinkProfile

Disconnects an existing profile (authentication method) from the current user. Once disconnected, that profile can no longer be used to sign into the account.

Example

import { inAppWallet } from "thirdweb/wallets";
const wallet = inAppWallet();
wallet.connect({ strategy: "google" });
const profiles = await getProfiles({
client,
});
const updatedProfiles = await unlinkProfile({
client,
profileToUnlink: profiles[0],
});
function unlinkProfile(args: UnlinkParams): Promise<Array<Profile>>;

Parameters

The object containing the profile that we want to unlink.

Type

let args: UnlinkParams;

Returns

let returnType: {
details: {
address?: Address;
email?: string;
id?: string;
phone?: string;
};
type: AuthOption;
};

A promise that resolves to the updated linked profiles.