NFTProtect Evidence Display
Evidence Display for NFTProtect, according to EIP-1497 MetaEvidence.
- Clone this repo.
- Duplicate
.env.example, rename it to.envand fill in the environment variables. - Run
yarnto install dependencies and thenyarn startto run the UI in development mode.
Remember to provide dispute data on the URL. It should be a JSON object containing the arbitrator and arbitrable addresses, the disputeID, RPC endpoint and chainID as follows:
?{"arbitrableContractAddress":"0xdeadbeef...","arbitratorContractAddress":"0xdeadbeef...","disputeID":"111","jsonRpcUrl":"http://localhost:8545","chainId":"1"}
Here is a sample encoded string that should work out of the box. Paste it as it is.
?%7B%22disputeID%22%3A%2295%22%2C%22chainID%22%3A100%2C%22arbitratorContractAddress%22%3A%220x9C1dA9A04925bDfDedf0f6421bC7EEa8305F9002%22%2C%22arbitratorJsonRpcUrl%22%3A%22https%3A%2F%2Frpc.gnosischain.com%22%2C%22arbitratorChainID%22%3A100%2C%22arbitrableContractAddress%22%3A%220xAeECFa44639b61d2e0A9534D918789d94A24a9DE%22%2C%22arbitrableChainID%22%3A100%2C%22arbitrableJsonRpcUrl%22%3A%22https%3A%2F%2Frpc.gnosischain.com%22%7D
This interface is meant to be deployed to IPFS. To do so, you should:
- Copy the
.env.examplefile to.env:cp .env.example .env
- Set the appropriate environment variables.
- Bundle the app for production:
yarn build
- Test the app by opening
index.htmland appending in the encoded parameters. Don't proceed if it doesn't work. - Clone this repo and follow the instructions: https://github.com/kleros/ipfs-upload-folder
- The
evidenceDisplayURIwill be/ipfs/<root_hash>/index.html - Test it out first, if it works fine, you are ready to set the
evidenceDisplayInterfaceURIfield of themetaEvidence.json, uploading the newmetaEvidence.jsonto IPFS, and emitting this path as MetaEvidence in your Arbitrable contract.