- Guide: Getting Started
- Tool: GetLit CLI
- Example: Fetching Off-Chain Data in a Lit Action
- Example: Conditional Signing with Lit Actions
- Example: Using Mint/Grant/Burn: Use the Mint/Grant/Burn function in the Lit
contracts-sdkto atomically assign a Lit Action(s) to a PKP. The PKP will only return a signed response if the function you've declared in your Lit Action returns 'true'. Learn more about minting PKPs here.
Blockchains like Ethereum have smart contracts that let developers encode logic to change that state. As a key management network, Lit provides a method that allows developers to encode logic that dictates signing.
A simple example is a Lit Action and associated PKP that checks if a number is prime. The PKP gets atomically assigned to the Lit Action, only returning a signature if the required conditions are met (in this case, if a prime number is inputted). Each node will execute the Lit Action in parallel and verify that it meets the required conditions. If it does, each node independently provisions a signing share to the requesting client. Only after more than two-thirds of these shares have been collected is the complete signature returned.
- Blockchain Agnostic: Lit Actions can be used to write data to and across any supported blockchain and state machine using PKPs.
- Immutable: Once a Lit Action has been published, it cannot be modified, just like a smart contract deployed on-chain. The Mint/Grant/Burn function allows you to atomically link a PKP to an authorized set of Lit Actions, guaranteeing that a particular PKP can only ever be used to sign data from within the approved set.
- Off-Chain Compatibility: Lit Actions can pull in data from off-chain sources natively, without requiring the use of a third party oracle.
- Generating proofs
- Condition-based execution
- Looking up permitted actions, addresses and auth methods associated with a PKP
- Checking access control conditions
- Fetching off-chain data