Verify Record at Location API

  • Any party with the original record can check whether it exists at the Location

  • The result indicates a match, a mismatch or unknown

Example code:

curl -X "POST" \
     -L "$URL/api/v1/records/$LOC/match" \
     -H "x-api-key: $KEY" \
     -H "accept: text/plain" \
     -H "Content-Type: application/octet-stream" \
     --data-binary "hello"

Example matching response:

{
  "match": true,
  "confirmation": {
    "confirmedBlocks": 2,
    "blockHash": "279062b6c3b09774ce665....0413ea9bdc6c1603819b11b",
    "blockTimestamp": "2024-01-11T16:23:05Z",
    "merkleProof": {
      "index": 1,
      "txOrId": "7d2aef40841f0109....c31c83a5505a4c147e",
      ....
    }
  }
}

Example mismatching response:

{
  "match": true,
  "confirmation": {
    "confirmedBlocks": 1,
    "blockHash": "279062b6c3b09774ce665....0413ea9bdc6c1603819b11b",
    "blockTimestamp": "2024-01-11T16:23:05Z",
    "merkleProof": {
      "index": 1,
      "txOrId": "7d2aef40841f0109....c31c83a5505a4c147e",
      ....
    }
  }
}

Example unknown response:

{
  "title": "Content not found",
  "status": 404,
  ....
}

Last updated

Copyright © nChain Licensing AG 2024