Skip to main content
Glama
LawrenceCirillo

QuickBase MCP Server

quickbase_query_records

Retrieve and filter records from a QuickBase table using specific criteria, select fields, and apply sorting for efficient data management. Simplify querying with customizable options.

Instructions

Query records from a table with optional filtering and sorting

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
selectNoField IDs to select
skipNoNumber of records to skip
sortByNoSort criteria
tableIdYesTable ID to query
topNoMax number of records
whereNoQuickBase query filter (e.g., "{6.EX.'John'}")

Implementation Reference

  • Core implementation of the quickbase_query_records tool. Constructs query parameters from options and calls QuickBase /records/query API endpoint.
    async getRecords(tableId: string, options?: QueryOptions): Promise<any[]> { const params: any = { from: tableId }; if (options?.select) { params.select = options.select; } if (options?.where) { params.where = options.where; } if (options?.sortBy) { params.sortBy = options.sortBy; } if (options?.groupBy) { params.groupBy = options.groupBy; } if (options?.top) { params.top = options.top; } if (options?.skip) { params.skip = options.skip; } const response = await this.axios.post('/records/query', params); return response.data.data; }
  • src/index.ts:211-229 (registration)
    MCP server dispatch handler for quickbase_query_records tool call, validates args and invokes QuickBaseClient.getRecords.
    case 'quickbase_query_records': if (!args || typeof args !== 'object') { throw new Error('Invalid arguments'); } const records = await this.qbClient.getRecords(args.tableId as string, { select: args.select as number[], where: args.where as string, sortBy: args.sortBy as any[], top: args.top as number, skip: args.skip as number }); return { content: [ { type: 'text', text: JSON.stringify(records, null, 2), }, ], };
  • Tool definition and JSON input schema for quickbase_query_records, used for MCP tool listing and validation.
    name: 'quickbase_query_records', description: 'Query records from a table with optional filtering and sorting', inputSchema: { type: 'object', properties: { tableId: { type: 'string', description: 'Table ID to query' }, select: { type: 'array', items: { type: 'number' }, description: 'Field IDs to select' }, where: { type: 'string', description: 'QuickBase query filter (e.g., "{6.EX.\'John\'}")' }, sortBy: { type: 'array', items: { type: 'object', properties: { fieldId: { type: 'number' }, order: { type: 'string', enum: ['ASC', 'DESC'] } } }, description: 'Sort criteria' }, top: { type: 'number', description: 'Max number of records' }, skip: { type: 'number', description: 'Number of records to skip' } }, required: ['tableId'] } },
  • Zod schema for input validation of quickbase_query_records parameters (QueryRecordsSchema).
    const QueryRecordsSchema = z.object({ tableId: z.string().describe('Table ID to query'), select: z.array(z.number()).optional().describe('Field IDs to select'), where: z.string().optional().describe('QuickBase query filter'), sortBy: z.array(z.object({ fieldId: z.number(), order: z.enum(['ASC', 'DESC']).default('ASC') })).optional().describe('Sort criteria'), top: z.number().optional().describe('Max number of records'), skip: z.number().optional().describe('Number of records to skip') });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LawrenceCirillo/QuickBase-MCP-Server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server