Recupera contenuti dei documenti
Returns the content of the document with the specified ID, along with the index of the latest retrieved chunk. Each call fetches up to 20 chunks. To get more, use the end_chunk value from the response as the start_chunk for the next call.
The ID of the document to retrieve contents for.
Indicate the starting chunk that you want to retrieve. If not specified, the default value is 0.
Indicate the ending chunk that you want to retrieve. If not specified, the default value is start_chunk + 20.
GET /api/v1/documents/{document_id}/contents/ HTTP/1.1
Host: api.rememberizer.ai
Accept: */*
{
"content": "text",
"end_chunk": 1
}
Esempi di Richieste
curl -X GET \
"https://api.rememberizer.ai/api/v1/documents/12345/contents/?start_chunk=0&end_chunk=20" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"
Parametri del percorso
document_id
intero
Obbligatorio. L'ID del documento di cui recuperare i contenuti.
Parametri di Query
start_chunk
intero
L'indice del chunk di partenza. Il valore predefinito è 0.
end_chunk
intero
L'indice del chunk finale. Il valore predefinito è start_chunk + 20.
Formato di Risposta
{
"content": "Il testo completo dei contenuti del documento...",
"end_chunk": 20
}
Risposte di Errore
404
Documento non trovato
500
Errore interno del server
Paginazione per Documenti di Grandi Dimensioni
Per documenti di grandi dimensioni, il contenuto è suddiviso in parti. Puoi recuperare il documento completo effettuando più richieste:
Effettua una richiesta iniziale con
start_chunk=0
Usa il valore
end_chunk
restituito comestart_chunk
per la richiesta successivaContinua fino a quando non hai recuperato tutte le parti
Questo endpoint restituisce il contenuto testuale grezzo di un documento, consentendoti di accedere a tutte le informazioni per un'elaborazione o analisi dettagliata.
Last updated