Search API
Records Rocket provides powerful search capabilities through its API, allowing you to query for text across an entire case or within a specific document.
Search Within a Case
Performs a search for one or more terms across all documents within a given case.
GET /api/searchcase?caseId={caseId}&q={searchQuery}
Parameters
caseId(string, required): The ID of the case to search within.q(string, required): The search term. To search for multiple terms with OR logic, separate them with a space. (e.g.,q=herniation%20surgery)
Response
Returns an array of PageRecord objects that contain the search term(s), including the full OCR text of the page.
[
{
"pageId": "doc123-45",
"pageNumber": 45,
"ocrText": "... The MRI revealed a significant L4-L5 disc herniation...",
"documentId": "doc123",
// ... other page fields
}
]
Search Within a Document
Performs a targeted search within a single document.
GET /api/search?documentId={documentId}&q={searchQuery}
Parameters
documentId(string, required): The ID of the document to search within.q(string, required): The search term(s).
Response
Returns an array of PageRecord objects from the specified document that contain the search term.