Skip to content

setPrivateKey

Allow to set private key after creation, to enable auth logic. Private key has to be in hex format and starting with 0x.

Usage

import { BcodeSDK } from "@bcode-tech/bcode-sdk";

const fun = () => {
  const sdk = new BcodeSDK({
    apiKey: "your-api-key",
    config: { env: "MUMBAI" },
  });

  sdk.setPrivateKey("new-private-key");
};

Returns

No data returned.