Skip to content

setGasSpendLimit

Sets the gas spend limit and returns the current instance for method chaining.

Import

import { SessionKeyPermissionsBuilder } from "@account-kit/smart-contracts";

Usage

import { SessionKeyPermissionsBuilder } from "@account-kit/smart-contracts";
 
const builder = new SessionKeyPermissionsBuilder();
builder.setGasSpendLimit({
  spendLimit: 1000000000000000000n,
  refreshInterval: 3600,
});

Parameters

limit

GasSpendLimit

  • The gas spend limit to be set

Returns

SessionKeyPermissionsBuilder The current instance for chaining