read_file
Read the text of one uploaded file.
Cost class: fast.
path names an uploaded source file — the only namespace this tool serves. A workspace-internal path is refused with invalid_request naming the uploaded file to use instead.
A file with several components (a spreadsheet's tabs, a pdf's sections) answers with their text concatenated in the file's own order, each part under a one-line header naming the component; components_returned and components_omitted report exactly what made it into the budget. Scope the read with component=<name> (the names file_metadata lists) when only one tab or section matters, and with pages (1-based) for paged documents — spreadsheets have no pages, so scope those by component instead. Images are refused — ask about them with qa_file.
Args: body: Source path, optional component name, optional page list, and character limit. workspace: Resolved workspace and caller access predicate. A non-existent workspace returns workspace_not_found before the body executes. session: Database session.
Request
- Base URLhttps://ndi-api.nace.ai (the document declares no server; this is the origin it was published from)
- AuthAPI key in header X-API-Key
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
Workspace identifier.
Headers
Replaying a request with the same key returns the original job with 200, never a second job. The key is kept with the job for replay and never cleared, so it must not contain personal data.
Request body
Response
Successful Response
Changes
No recorded changes to this operation across all 1 revision of this API.