UNPKG

mcp-quickbase

Version:

Work with Quickbase via Model Context Protocol

109 lines (108 loc) 2.39 kB
import { BaseTool } from "../base"; import { QuickbaseClient } from "../../client/quickbase"; /** * Field information returned by get_table_fields */ export interface FieldInfo { /** * The ID of the field */ id: string; /** * The label (display name) of the field */ label: string; /** * The type of the field */ fieldType: string; /** * The description of the field */ description?: string; /** * Whether the field is required */ required?: boolean; /** * Whether the field is unique */ unique?: boolean; /** * Additional properties of the field */ properties?: Record<string, any>; /** * Additional details about the field */ [key: string]: any; } /** * Parameters for get_table_fields tool */ export interface GetTableFieldsParams { /** * The ID of the table */ table_id: string; /** * Whether to include system fields */ include_system?: boolean; /** * Filter fields by type */ field_type?: string; } /** * Response from getting table fields */ export interface GetTableFieldsResult { /** * Array of field information */ fields: FieldInfo[]; /** * The table ID that was queried */ tableId: string; } /** * Tool for retrieving field information for a specific Quickbase table */ export declare class GetTableFieldsTool extends BaseTool<GetTableFieldsParams, GetTableFieldsResult> { name: string; description: string; /** * Parameter schema for get_table_fields */ paramSchema: { type: string; properties: { table_id: { type: string; description: string; }; include_system: { type: string; description: string; }; field_type: { type: string; description: string; }; }; required: string[]; }; /** * Constructor * @param client Quickbase client */ constructor(client: QuickbaseClient); /** * Run the get_table_fields tool * @param params Tool parameters * @returns Table field information */ protected run(params: GetTableFieldsParams): Promise<GetTableFieldsResult>; }