Proof Schema Definition
Guidance on defining JSON Schemas for your proof types used with the Token Burn API.
Validating Proofs for Token Burns
When you use the /v1/tokenomics/burn
endpoint, you provide a type
(e.g., "PRODUCT_BUY"
) and a corresponding proof
object.
This document provides guidance on how to:
- Conceptualize the different proof types your application might use.
- Define the actual JSON Schema for each of these proof types
Conceptualizing Your Proof Types
Before defining the detailed JSON Schemas, it’s helpful to list out the different types of events in your application that could trigger a token burn. For each type, you should have a clear understanding of the data that constitutes valid proof for that event.
Here’s an illustrative example of how you might catalogue your proof types:
This list helps you identify each unique event type
for which you’ll need to create a specific JSON Schema.
Defining JSON Schemas for Your Proof Types
For each unique type
of burn event your application supports (like those conceptualized above), you need to create a detailed JSON Schema. By clearly defining these JSON Schemas for each of your proof types, you ensure that the data sent to the burn endpoint is structured correctly, leading to reliable validation and processing.
You can find more details about the burn endpoint itself in the Burn Tokens API reference.