Find exact public hash matches
curl --request GET \
--url https://api.truthlocks.com/v1/consumer/similarity \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.truthlocks.com/v1/consumer/similarity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/consumer/similarity"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/consumer/similarity"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"content_hash": "<string>",
"exact_match": true,
"total": 123,
"matches": [
{
"attestation_id": "<string>",
"title": "<string>",
"category": "<string>",
"similarity_score": 1,
"protected_at": "2023-11-07T05:31:56Z"
}
]
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}Consumer (B2C)
Content similarity check
Check whether a content hash already has existing public protections.
GET
/
v1
/
consumer
/
similarity
Find exact public hash matches
curl --request GET \
--url https://api.truthlocks.com/v1/consumer/similarity \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.truthlocks.com/v1/consumer/similarity', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.truthlocks.com/v1/consumer/similarity"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.truthlocks.com/v1/consumer/similarity"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"content_hash": "<string>",
"exact_match": true,
"total": 123,
"matches": [
{
"attestation_id": "<string>",
"title": "<string>",
"category": "<string>",
"similarity_score": 1,
"protected_at": "2023-11-07T05:31:56Z"
}
]
}{
"code": "AUTH_REQUIRED",
"message": "Authentication required",
"http_status": 401
}GET
Check whether a SHA-256 content hash already has public protections. This detects exact public hash matches; it does not perform perceptual or semantic similarity analysis or establish copyright ownership.
Send an authenticated session using the authorization shown in Try It. Protections belonging to your workspace are excluded. The required /v1/consumer/similarityhash query parameter is the SHA-256 digest you want to compare.
Only protections with visibility: "public" are searched. Private protections are never returned.
Responses
Response fields
| Field | Type | Description |
|---|---|---|
content_hash | string | The hash you submitted, echoed back for confirmation. |
exact_match | boolean | true if at least one public protection exists for this hash. |
matches | array | Up to 10 matching protections, ordered by creation date. |
matches[].attestation_id | string | Attestation ID of the matching protection. |
matches[].title | string | Title of the matching protection. |
matches[].category | string | Content category (e.g. photography, code, design). |
matches[].similarity_score | number | Always 1.0 for exact hash matches. |
matches[].protected_at | string | ISO 8601 timestamp when the content was protected. |
total | integer | Number of returned matches, not an unbounded total. |
Authorizations
JWT for user-initiated operations
Query Parameters
SHA-256 content digest to compare, as hexadecimal text.

