GetRecord
Retrieve a specific record by its unique ID from the RushDB graph database to access stored data quickly.
Instructions
Get a specific record by ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| recordId | Yes | ID of the record to retrieve |
Implementation Reference
- tools/GetRecord.ts:17-23 (handler)The main handler function for the GetRecord tool, which retrieves a specific record by its ID from the database using db.records.findById.export async function GetRecord(params: { recordId: string }) { const { recordId } = params const result = await db.records.findById(recordId) return result.data }
- tools.ts:159-167 (schema)The JSON schema definition for the GetRecord tool, including input parameters (recordId: string, required). Used for tool listing and validation.{ name: 'GetRecord', description: 'Get a specific record by ID', inputSchema: { type: 'object', properties: { recordId: { type: 'string', description: 'ID of the record to retrieve' } }, required: ['recordId'] } },
- index.ts:208-219 (registration)The registration and dispatching logic in the MCP server's CallToolRequest handler switch statement, which calls the GetRecord function and formats the response.case 'GetRecord': const record = await GetRecord({ recordId: args.recordId as string }) return { content: [ { type: 'text', text: JSON.stringify(record, null, 2) } ] }