renounceRole

Lets the target account renounce the role. (The target account must be the sender of the transaction.)

Example

import { renounceRole } from "thirdweb/extensions/permissions";
import { sendTransaction } from "thirdweb";
const transaction = renounceRole({
contract,
role: "admin",
targetAccountAddress: "0x1234567890123456789012345678901234567890",
});
await sendTransaction({ transaction, account });
function renounceRole(

Parameters

The options for renouncing the role.

Type

Returns

let returnType: PreparedTransaction<
any,
AbiFunction,
>;

A transaction that revokes the role when sent.