curl --request GET \
--url http://localhost:8080/v1/knowledge/entities/{entity_id}import requests
url = "http://localhost:8080/v1/knowledge/entities/{entity_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('http://localhost:8080/v1/knowledge/entities/{entity_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/v1/knowledge/entities/{entity_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "http://localhost:8080/v1/knowledge/entities/{entity_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://localhost:8080/v1/knowledge/entities/{entity_id}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/v1/knowledge/entities/{entity_id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{}{
"message": "<string>",
"error_code": "bad_request",
"details": {}
}{
"error_code": "authentication_error",
"message": "Invalid or missing credentials.",
"details": {}
}{
"error_code": "permission_denied",
"message": "You do not have permission to perform this action.",
"details": {}
}{
"message": "<string>",
"error_code": "not_found",
"details": {}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error_code": "internal_server_error",
"message": "An unexpected error occurred.",
"details": {}
}{
"error_code": "service_unavailable",
"message": "The service is currently experiencing issues. Please try again later.",
"details": {}
}Get Entity
Fetch an entity or raw piece of evidence by its id.
When a search result or entity listing carries a urn (l1_…, l2_…,
l3_…), pass it bare — the URN is the stable, self-describing identifier.
Example: l2_01kvtxh78ky384gq9xvgsyakg7.
Records without a URN use an assembled reference instead:
- Raw evidence —
evidence:{type}:{id}, where{type}and{id}are theevidence_typeandidof a result fromPOST /knowledge/search. Example:evidence:email:19f04210caef6e91. If you searched withgroup_by=chunk, drop the trailing:{chunk_index}suffix from the result id first. - Extracted entity —
entity:{prefix}:{type}:{id}, where{prefix}isl1,l2, orl3(matching the entity’surnprefix), and{type}/{id}come fromGET /knowledge/entities. Example:entity:l1:person:42.
The {id} segment never contains a colon; some type names use dots (e.g.
person.v2).
curl --request GET \
--url http://localhost:8080/v1/knowledge/entities/{entity_id}import requests
url = "http://localhost:8080/v1/knowledge/entities/{entity_id}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('http://localhost:8080/v1/knowledge/entities/{entity_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/v1/knowledge/entities/{entity_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "http://localhost:8080/v1/knowledge/entities/{entity_id}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://localhost:8080/v1/knowledge/entities/{entity_id}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/v1/knowledge/entities/{entity_id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{}{
"message": "<string>",
"error_code": "bad_request",
"details": {}
}{
"error_code": "authentication_error",
"message": "Invalid or missing credentials.",
"details": {}
}{
"error_code": "permission_denied",
"message": "You do not have permission to perform this action.",
"details": {}
}{
"message": "<string>",
"error_code": "not_found",
"details": {}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error_code": "internal_server_error",
"message": "An unexpected error occurred.",
"details": {}
}{
"error_code": "service_unavailable",
"message": "The service is currently experiencing issues. Please try again later.",
"details": {}
}Path Parameters
Response
Successful Response
- ResolvedRef
- ResolvedHyperedge
The object a ref resolves to. The ref itself says what kind of record it
names, so the response is the typed object with no envelope: raw evidence
resolves to the generated EvidenceData union (evidence_type + data,
identical to the evidence field on search results), extracted entities to
the generated EntityData union (entity_type + data), and
relationships to a [ResolvedHyperedge].
Was this page helpful?