Trust
Canonical JSON digest API
Canonicalize JSON with stable key ordering and return deterministic SHA digests for signing or comparison.
Price$0.01per request
MethodPOST
Route/v1/trust/canonicalize/json
StatusLive
MIME typeapplication/json
Rate limit180/minute
CacheNo cache
trustjsoncanonicalizehashdigest
API URL
Integration docshttps://x402.hexl.dev/v1/trust/canonicalize/jsonExample request
{
"value": {
"b": 2,
"a": 1
}
}Example response
{
"canonical": "{\"a\":1,\"b\":2}",
"hashes": {
"sha256": "43258cff783fe7036d8a43033f830adfc60ec037382473548ac742b888292777"
},
"provider": "local-json-canonicalizer"
}Input schema
{
"type": "object",
"required": [
"value"
],
"properties": {
"value": {},
"algorithms": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sha256",
"sha512",
"sha1"
]
},
"default": [
"sha256"
]
}
}
}Output schema
{
"type": "object",
"additionalProperties": true
}