Encontrar coincidencias exactas de hash público
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
}Consumidor (B2C)
Verificación de similitud de contenido
Verifique si un hash de contenido ya tiene protecciones públicas existentes.
GET
/
v1
/
consumer
/
similarity
Encontrar coincidencias exactas de hash público
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
Verifique si un hash de contenido SHA-256 ya tiene protecciones públicas. Esto detecta coincidencias exactas de hash público; no realiza análisis de similitud perceptual o semántica ni establece la propiedad de los derechos de autor.
Envíe una sesión autenticada utilizando la autorización que se muestra en Try It. Las protecciones que pertenecen a su espacio de trabajo están excluidas. El parámetro de consulta /v1/consumer/similarityhash requerido es el resumen SHA-256 que desea comparar.
Solo se buscan protecciones con visibility: "public". Las protecciones privadas nunca se devuelven.
Respuestas
Campos de respuesta
| Campo | Tipo | Descripción |
|---|---|---|
content_hash | string | El hash que envió, devuelto para confirmación. |
exact_match | boolean | true si existe al menos una protección pública para este hash. |
matches | array | Hasta 10 protecciones coincidentes, ordenadas por fecha de creación. |
matches[].attestation_id | string | ID de atestación de la protección coincidente. |
matches[].title | string | Título de la protección coincidente. |
matches[].category | string | Categoría de contenido (p. ej. photography, code, design). |
matches[].similarity_score | number | Siempre 1.0 para coincidencias exactas de hash. |
matches[].protected_at | string | Marca de tiempo ISO 8601 de cuando se protegió el contenido. |
total | integer | Número de coincidencias devueltas, no un total ilimitado. |

