KinoraSDK
  • Overview
  • Quickstart
  • Contracts
  • Subgraphs
  • Open Source Code
  • SDK Reference
    • Envoker
      • Instantiate Envoker
      • Instantiate New Quest
      • Terminate & Withdraw
      • Delete Quest
      • Verify Player Milestone
    • Dispatch
      • Instantiate Dispatch
      • Join Quest
      • Milestone Eligibility Check
      • Complete Milestone
    • Kinora Player Wrapper
      • Kinora Provider
      • Kinora Player Wrapper
      • Send Metrics On-Chain
    • Helpers
  • Live
    • Quest No Code
    • Cypher Search
    • Chromadin
  • Architecture
    • Data Corruption Mitigation
  • Resources
    • Issues
    • Testing
    • Contributors
    • About the Devs
    • Storefront
  • Github
  • Livepeer Developer Docs
Powered by GitBook
On this page
  1. SDK Reference
  2. Dispatch

Join Quest

Enroll Player in Quest.

Players join a Quest by "Acting On" your Quest Publication on Lens protocol through the Kinora Open Action Contract. This action ensures their interaction is recorded both within the Kinora Contract Suite, where each player maintains a unique profile linked to their Lens profile ID, and additionally within Lens networks and communities.

const polygonProvider = new ethers.providers.JsonRpcProvider(
    "https://polygonprovider.com",
    137,
  );

const {txHash, error, errorMessage } = await newDispatch.playerJoinQuest(
    "0x32-0x46",
    new ethers.Wallet(process.env.PLAYER_PRIVATE_KEY, polygonProvider));

Player Join Quest Props:

/* Enter the Lens pubId of the invoked Quest. */
pubId: `0x${string}`;

/* Wallet instance for the Player on Polygon Network. */
wallet: ethers.Wallet;

Result Object:

/* The txHash for acting on the Publication and joining the Quest. */
txHash?: `0x${string}`;

/* Boolean to indicate whether an error was encountered during joining. */
error: boolean;

/* Message of the encountered error. */
errorMessage?: string;
PreviousInstantiate DispatchNextMilestone Eligibility Check

Last updated 1 year ago