Introduction
The Patchwork Development Kit provides a toolset for defining onchain metadata schemas and generating Patchwork-compatible contracts. Define schemas in JSON and use the PDK tool to validate and generate solidity.
Workflow
- Define a contract configuration in JSON, adding the features and metadata fields your app requires.
- Run the PDK contract generator to convert the JSON into a Solidity contract.
- Customize your solidity contract by adding your own custom logic.
- Deploy to any EVM-compatible chain where Patchwork Protocol is deployed.
Installing
In a git repository root directory, perform the following steps to prepare a project:
1
Install Foundry
Foundry is a smart contract development toolchain. You can install it by following the instructions at Foundry’s installation guide.
2
Install Patchwork Contracts Library
3
Install OpenZeppelin Contracts
4
Configure Project Remappings
In project directory, create the file remappings.txt
5
Install PDK
Option 1 - Local project installation (recommended for npm/js projects)
Option 2 - Global binary installation