Skip to main content

Curate Classic: Integration for Devs

This covers Curate Classic (V1) with on-chain storage. For the newer Light Curate with subgraph-based storage, see Light Curate Integration. For V2 Curate, see the Developers Curate section.
Curate V1 (Classic Curate and Light Curate) is being deprecated. The V1 smart contracts stay deployed and unchanged, so existing lists keep working: items can still be submitted, challenged, and queried. Kleros will not launch new registries on Curate V1, and creating new lists through Kleros frontends is being disabled. Banners in the Curate V1 app flag the change.

Overview

Curate Classic is the original version of Kleros Curate. All item data (apart from files/images) is stored on-chain in contract storage. This means other contracts can query the TCR for field values directly, but deployment and operation costs are higher. Key characteristics:
  • Item data stored on-chain as encoded bytes
  • Requires @kleros/gtcr-encoder to encode/decode items
  • Client must sync by downloading every item and decoding it
  • Higher gas costs (O(n) storage)
  • Other contracts can read item fields directly

Reading Data

Using the Subgraph

Use the items entity (not litems, which is for Light Curate):
The data field contains encoded bytes. Decode using @kleros/gtcr-encoder.

Using the Encoder


Writing Data

Submitting an Item

Encode the item fields and call addItem() on the GeneralizedTCR contract with the required deposit.

Challenging an Item

Call challengeRequest() on the contract with a deposit. The challenge creates a dispute in Kleros Court.

Executing Requests

Call executeRequest() after the challenge period passes without a challenge.

Resources

Curate Classic Contracts

Source code

Subgraph

legacy-curate-mainnet subgraph on Graph Explorer