List project documents
curl --request GET \
--url https://api.tensorpro.ai/api/v1/projects/{project_id}/sources \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tensorpro.ai/api/v1/projects/{project_id}/sources', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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 := "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources"
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))
}HttpResponse<String> response = Unirest.get("https://api.tensorpro.ai/api/v1/projects/{project_id}/sources")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tensorpro.ai/api/v1/projects/{project_id}/sources")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"sources": [
{
"id": "9a1c3e5f-7b2d-4f6a-8c0e-3b5d7f9a1c2e",
"title": "launch-plan.pdf",
"source_type": "document",
"provenance": "DOCUMENT_VERIFIED",
"ingest_status": "ready",
"chunk_count": 12,
"external_id": null,
"created_at": "2026-11-09T01:02:03+00:00",
"updated_at": "2026-11-09T01:02:09+00:00"
}
],
"total": 1
}
Documents
List project documents
List the documents added to a project, newest first, with each one’s status.
GET
/
api
/
v1
/
projects
/
{project_id}
/
sources
List project documents
curl --request GET \
--url https://api.tensorpro.ai/api/v1/projects/{project_id}/sources \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tensorpro.ai/api/v1/projects/{project_id}/sources', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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 := "https://api.tensorpro.ai/api/v1/projects/{project_id}/sources"
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))
}HttpResponse<String> response = Unirest.get("https://api.tensorpro.ai/api/v1/projects/{project_id}/sources")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tensorpro.ai/api/v1/projects/{project_id}/sources")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"sources": [
{
"id": "9a1c3e5f-7b2d-4f6a-8c0e-3b5d7f9a1c2e",
"title": "launch-plan.pdf",
"source_type": "document",
"provenance": "DOCUMENT_VERIFIED",
"ingest_status": "ready",
"chunk_count": 12,
"external_id": null,
"created_at": "2026-11-09T01:02:03+00:00",
"updated_at": "2026-11-09T01:02:09+00:00"
}
],
"total": 1
}
Use this endpoint to see which documents a project has, and whether each one is ready to use.
See Error handling.
What EDN does
Returns the project’s documents, newest first, with each one’s status and how many memories were made from it.Required headers
| Header | Value | Description |
|---|---|---|
Authorization | Bearer YOUR_API_KEY | Your EDN API key. Create keys in the Console. See Authentication |
Request
| Parameter | Type | Description |
|---|---|---|
project_id | string | Identifier for the project |
curl "https://api.tensorpro.ai/api/v1/projects/b4c8e2f6-1a3d-4e5f-9b7c-2d6e8f0a1b3c/sources" \
-H "Authorization: Bearer $EDN_API_KEY"
import os
import requests
resp = requests.get(
"https://api.tensorpro.ai/api/v1/projects/b4c8e2f6-1a3d-4e5f-9b7c-2d6e8f0a1b3c/sources",
headers={"Authorization": f"Bearer {os.environ['EDN_API_KEY']}"},
)
resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.tensorpro.ai/api/v1/projects/b4c8e2f6-1a3d-4e5f-9b7c-2d6e8f0a1b3c/sources", {
headers: {
Authorization: `Bearer ${process.env.EDN_API_KEY}`,
},
});
console.log(await resp.json());
Response
200 OK
{
"sources": [
{
"id": "9a1c3e5f-7b2d-4f6a-8c0e-3b5d7f9a1c2e",
"title": "launch-plan.pdf",
"source_type": "document",
"provenance": "DOCUMENT_VERIFIED",
"ingest_status": "ready",
"chunk_count": 12,
"external_id": null,
"created_at": "2026-11-09T01:02:03+00:00",
"updated_at": "2026-11-09T01:02:09+00:00"
}
],
"total": 1
}
| Field | Type | Description |
|---|---|---|
sources | array | The project’s documents, newest first |
sources[].id | string | Identifier for the source. Use it to remove the document |
sources[].title | string | The document’s file name |
sources[].source_type | string | How it was added, such as document for an upload |
sources[].provenance | string | Always DOCUMENT_VERIFIED |
sources[].ingest_status | string | pending while EDN processes it, ready when usable, or failed if it couldn’t be read |
sources[].chunk_count | integer | How many memories EDN made from the document |
sources[].external_id | string or null | The document’s ID in another system, or null for uploads |
sources[].created_at | string (date-time) | When the document was added |
sources[].updated_at | string (date-time) | When the document last changed |
total | integer | How many documents the project has |
Errors
| Status | Code | When |
|---|---|---|
401 | UNAUTHORIZED | The API key is missing, invalid or revoked |
404 | NOT_FOUND | The project doesn’t exist or isn’t yours |
429 | RATE_LIMITED | Per-minute limit reached. Retry after Retry-After seconds |
500 | INTERNAL_ERROR | Something failed on EDN’s side. Retry later |
{
"sources": [
{
"id": "9a1c3e5f-7b2d-4f6a-8c0e-3b5d7f9a1c2e",
"title": "launch-plan.pdf",
"source_type": "document",
"provenance": "DOCUMENT_VERIFIED",
"ingest_status": "ready",
"chunk_count": 12,
"external_id": null,
"created_at": "2026-11-09T01:02:03+00:00",
"updated_at": "2026-11-09T01:02:09+00:00"
}
],
"total": 1
}
