@rashidazarang/airtable-mcp 1.6.0 → 2.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/README.md +1 -0
  2. package/airtable_simple_production.js +532 -0
  3. package/package.json +15 -6
  4. package/.claude/settings.local.json +0 -12
  5. package/.github/ISSUE_TEMPLATE/bug_report.md +0 -38
  6. package/.github/ISSUE_TEMPLATE/custom.md +0 -10
  7. package/.github/ISSUE_TEMPLATE/feature_request.md +0 -20
  8. package/CAPABILITY_REPORT.md +0 -118
  9. package/CLAUDE_INTEGRATION.md +0 -96
  10. package/CONTRIBUTING.md +0 -81
  11. package/DEVELOPMENT.md +0 -190
  12. package/Dockerfile +0 -39
  13. package/Dockerfile.node +0 -20
  14. package/IMPROVEMENT_PROPOSAL.md +0 -371
  15. package/INSTALLATION.md +0 -183
  16. package/ISSUE_RESPONSES.md +0 -171
  17. package/MCP_REVIEW_SUMMARY.md +0 -142
  18. package/QUICK_START.md +0 -60
  19. package/RELEASE_NOTES_v1.2.0.md +0 -50
  20. package/RELEASE_NOTES_v1.2.1.md +0 -40
  21. package/RELEASE_NOTES_v1.2.2.md +0 -48
  22. package/RELEASE_NOTES_v1.2.3.md +0 -105
  23. package/RELEASE_NOTES_v1.2.4.md +0 -60
  24. package/RELEASE_NOTES_v1.4.0.md +0 -104
  25. package/RELEASE_NOTES_v1.5.0.md +0 -185
  26. package/RELEASE_NOTES_v1.6.0.md +0 -248
  27. package/SECURITY_NOTICE.md +0 -40
  28. package/airtable-mcp-1.1.0.tgz +0 -0
  29. package/airtable_enhanced.js +0 -499
  30. package/airtable_mcp/__init__.py +0 -5
  31. package/airtable_mcp/src/server.py +0 -329
  32. package/airtable_simple_v1.2.4_backup.js +0 -277
  33. package/airtable_v1.4.0.js +0 -654
  34. package/cleanup.sh +0 -71
  35. package/index.js +0 -179
  36. package/inspector.py +0 -148
  37. package/inspector_server.py +0 -337
  38. package/publish-steps.txt +0 -27
  39. package/quick_test.sh +0 -30
  40. package/rashidazarang-airtable-mcp-1.1.0.tgz +0 -0
  41. package/rashidazarang-airtable-mcp-1.2.0.tgz +0 -0
  42. package/rashidazarang-airtable-mcp-1.2.1.tgz +0 -0
  43. package/requirements.txt +0 -10
  44. package/setup.py +0 -29
  45. package/simple_airtable_server.py +0 -151
  46. package/smithery.yaml +0 -45
  47. package/test_all_features.sh +0 -146
  48. package/test_all_operations.sh +0 -120
  49. package/test_client.py +0 -70
  50. package/test_enhanced_features.js +0 -389
  51. package/test_mcp_comprehensive.js +0 -163
  52. package/test_mock_server.js +0 -180
  53. package/test_v1.4.0_final.sh +0 -131
  54. package/test_v1.5.0_comprehensive.sh +0 -96
  55. package/test_v1.5.0_final.sh +0 -224
  56. package/test_v1.6.0_comprehensive.sh +0 -187
  57. package/test_webhooks.sh +0 -105
@@ -1,389 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- /**
4
- * Test Script for Enhanced Airtable MCP v1.3.0
5
- * Tests all CRUD operations and new features
6
- */
7
-
8
- const http = require('http');
9
-
10
- // Test configuration - using environment variables
11
- const MCP_SERVER_URL = 'http://localhost:8010/mcp';
12
- const TEST_TOKEN = process.env.AIRTABLE_TOKEN || 'YOUR_AIRTABLE_TOKEN';
13
- const TEST_BASE_ID = process.env.AIRTABLE_BASE_ID || 'YOUR_BASE_ID';
14
-
15
- if (TEST_TOKEN === 'YOUR_AIRTABLE_TOKEN' || TEST_BASE_ID === 'YOUR_BASE_ID') {
16
- console.error('❌ Error: Please set AIRTABLE_TOKEN and AIRTABLE_BASE_ID environment variables');
17
- console.error('Example:');
18
- console.error(' export AIRTABLE_TOKEN=your_token_here');
19
- console.error(' export AIRTABLE_BASE_ID=your_base_id_here');
20
- process.exit(1);
21
- }
22
-
23
- // Test data
24
- let createdRecordId = null;
25
- const testTableName = 'Tasks'; // Change this to your actual table name
26
-
27
- // Helper function to make MCP requests
28
- function makeMCPRequest(method, params = {}) {
29
- return new Promise((resolve, reject) => {
30
- const postData = JSON.stringify({
31
- jsonrpc: '2.0',
32
- id: Date.now(),
33
- method: method,
34
- params: params
35
- });
36
-
37
- const options = {
38
- hostname: 'localhost',
39
- port: 8010,
40
- path: '/mcp',
41
- method: 'POST',
42
- headers: {
43
- 'Content-Type': 'application/json',
44
- 'Content-Length': Buffer.byteLength(postData)
45
- }
46
- };
47
-
48
- const req = http.request(options, (res) => {
49
- let data = '';
50
- res.on('data', (chunk) => {
51
- data += chunk;
52
- });
53
- res.on('end', () => {
54
- try {
55
- const response = JSON.parse(data);
56
- resolve(response);
57
- } catch (e) {
58
- reject(new Error(`Failed to parse response: ${e.message}\nRaw data: ${data}`));
59
- }
60
- });
61
- });
62
-
63
- req.on('error', (e) => {
64
- reject(new Error(`Request failed: ${e.message}`));
65
- });
66
-
67
- req.write(postData);
68
- req.end();
69
- });
70
- }
71
-
72
- // Test functions
73
- async function testListTools() {
74
- console.log('\n📋 TEST 1: List Available Tools');
75
- console.log('================================');
76
-
77
- try {
78
- const response = await makeMCPRequest('tools/list');
79
-
80
- if (response.result && response.result.tools) {
81
- console.log(`✅ Found ${response.result.tools.length} tools:`);
82
- response.result.tools.forEach(tool => {
83
- console.log(` - ${tool.name}: ${tool.description}`);
84
- });
85
- return true;
86
- } else {
87
- console.error('❌ No tools found in response');
88
- return false;
89
- }
90
- } catch (error) {
91
- console.error('❌ Error:', error.message);
92
- return false;
93
- }
94
- }
95
-
96
- async function testListTables() {
97
- console.log('\n📊 TEST 2: List Tables');
98
- console.log('======================');
99
-
100
- try {
101
- const response = await makeMCPRequest('tools/call', {
102
- name: 'list_tables'
103
- });
104
-
105
- if (response.result && response.result.content) {
106
- console.log('✅ Response:', response.result.content[0].text);
107
- return true;
108
- } else {
109
- console.error('❌ No content in response');
110
- return false;
111
- }
112
- } catch (error) {
113
- console.error('❌ Error:', error.message);
114
- return false;
115
- }
116
- }
117
-
118
- async function testCreateRecord() {
119
- console.log('\n➕ TEST 3: Create Record');
120
- console.log('========================');
121
-
122
- try {
123
- const response = await makeMCPRequest('tools/call', {
124
- name: 'create_record',
125
- arguments: {
126
- table: testTableName,
127
- fields: {
128
- 'Name': 'Test Task from MCP v1.3.0',
129
- 'Notes': 'This is a test record created by the enhanced MCP',
130
- 'Status': 'In progress'
131
- }
132
- }
133
- });
134
-
135
- if (response.result && response.result.content) {
136
- console.log('✅ Created record:', response.result.content[0].text);
137
-
138
- // Extract record ID from response
139
- const match = response.result.content[0].text.match(/Record ID: (rec\w+)/);
140
- if (match) {
141
- createdRecordId = match[1];
142
- console.log(`📝 Saved record ID: ${createdRecordId}`);
143
- }
144
- return true;
145
- } else {
146
- console.error('❌ Failed to create record');
147
- return false;
148
- }
149
- } catch (error) {
150
- console.error('❌ Error:', error.message);
151
- return false;
152
- }
153
- }
154
-
155
- async function testGetRecord() {
156
- console.log('\n🔍 TEST 4: Get Single Record');
157
- console.log('=============================');
158
-
159
- if (!createdRecordId) {
160
- console.log('⚠️ Skipping: No record ID available');
161
- return false;
162
- }
163
-
164
- try {
165
- const response = await makeMCPRequest('tools/call', {
166
- name: 'get_record',
167
- arguments: {
168
- table: testTableName,
169
- recordId: createdRecordId
170
- }
171
- });
172
-
173
- if (response.result && response.result.content) {
174
- console.log('✅ Retrieved record:', response.result.content[0].text);
175
- return true;
176
- } else {
177
- console.error('❌ Failed to retrieve record');
178
- return false;
179
- }
180
- } catch (error) {
181
- console.error('❌ Error:', error.message);
182
- return false;
183
- }
184
- }
185
-
186
- async function testUpdateRecord() {
187
- console.log('\n✏️ TEST 5: Update Record');
188
- console.log('=========================');
189
-
190
- if (!createdRecordId) {
191
- console.log('⚠️ Skipping: No record ID available');
192
- return false;
193
- }
194
-
195
- try {
196
- const response = await makeMCPRequest('tools/call', {
197
- name: 'update_record',
198
- arguments: {
199
- table: testTableName,
200
- recordId: createdRecordId,
201
- fields: {
202
- 'Status': 'Done',
203
- 'Notes': 'Updated by MCP test suite at ' + new Date().toISOString()
204
- }
205
- }
206
- });
207
-
208
- if (response.result && response.result.content) {
209
- console.log('✅ Updated record:', response.result.content[0].text);
210
- return true;
211
- } else {
212
- console.error('❌ Failed to update record');
213
- return false;
214
- }
215
- } catch (error) {
216
- console.error('❌ Error:', error.message);
217
- return false;
218
- }
219
- }
220
-
221
- async function testSearchRecords() {
222
- console.log('\n🔎 TEST 6: Search Records');
223
- console.log('=========================');
224
-
225
- try {
226
- const response = await makeMCPRequest('tools/call', {
227
- name: 'search_records',
228
- arguments: {
229
- table: testTableName,
230
- filterByFormula: "{Status} = 'Done'",
231
- maxRecords: 5,
232
- sort: [{field: 'Name', direction: 'asc'}]
233
- }
234
- });
235
-
236
- if (response.result && response.result.content) {
237
- console.log('✅ Search results:', response.result.content[0].text);
238
- return true;
239
- } else {
240
- console.error('❌ No search results');
241
- return false;
242
- }
243
- } catch (error) {
244
- console.error('❌ Error:', error.message);
245
- return false;
246
- }
247
- }
248
-
249
- async function testListRecords() {
250
- console.log('\n📝 TEST 7: List Records');
251
- console.log('=======================');
252
-
253
- try {
254
- const response = await makeMCPRequest('tools/call', {
255
- name: 'list_records',
256
- arguments: {
257
- table: testTableName,
258
- maxRecords: 3
259
- }
260
- });
261
-
262
- if (response.result && response.result.content) {
263
- console.log('✅ Listed records:', response.result.content[0].text.substring(0, 200) + '...');
264
- return true;
265
- } else {
266
- console.error('❌ Failed to list records');
267
- return false;
268
- }
269
- } catch (error) {
270
- console.error('❌ Error:', error.message);
271
- return false;
272
- }
273
- }
274
-
275
- async function testDeleteRecord() {
276
- console.log('\n🗑️ TEST 8: Delete Record');
277
- console.log('=========================');
278
-
279
- if (!createdRecordId) {
280
- console.log('⚠️ Skipping: No record ID available');
281
- return false;
282
- }
283
-
284
- try {
285
- const response = await makeMCPRequest('tools/call', {
286
- name: 'delete_record',
287
- arguments: {
288
- table: testTableName,
289
- recordId: createdRecordId
290
- }
291
- });
292
-
293
- if (response.result && response.result.content) {
294
- console.log('✅ Deleted record:', response.result.content[0].text);
295
- return true;
296
- } else {
297
- console.error('❌ Failed to delete record');
298
- return false;
299
- }
300
- } catch (error) {
301
- console.error('❌ Error:', error.message);
302
- return false;
303
- }
304
- }
305
-
306
- // Main test runner
307
- async function runTests() {
308
- console.log('🚀 Enhanced Airtable MCP v1.3.0 Test Suite');
309
- console.log('==========================================');
310
- console.log(`📍 Testing server at: ${MCP_SERVER_URL}`);
311
- console.log(`🔑 Token: ${TEST_TOKEN.slice(0, 5)}...${TEST_TOKEN.slice(-5)}`);
312
- console.log(`📦 Base ID: ${TEST_BASE_ID}`);
313
- console.log(`📊 Test table: ${testTableName}`);
314
-
315
- const tests = [
316
- { name: 'List Tools', fn: testListTools },
317
- { name: 'List Tables', fn: testListTables },
318
- { name: 'Create Record', fn: testCreateRecord },
319
- { name: 'Get Record', fn: testGetRecord },
320
- { name: 'Update Record', fn: testUpdateRecord },
321
- { name: 'Search Records', fn: testSearchRecords },
322
- { name: 'List Records', fn: testListRecords },
323
- { name: 'Delete Record', fn: testDeleteRecord }
324
- ];
325
-
326
- let passed = 0;
327
- let failed = 0;
328
-
329
- for (const test of tests) {
330
- try {
331
- const result = await test.fn();
332
- if (result) {
333
- passed++;
334
- } else {
335
- failed++;
336
- }
337
- } catch (error) {
338
- console.error(`❌ Test "${test.name}" crashed:`, error.message);
339
- failed++;
340
- }
341
-
342
- // Small delay between tests
343
- await new Promise(resolve => setTimeout(resolve, 1000));
344
- }
345
-
346
- console.log('\n' + '='.repeat(50));
347
- console.log('📊 TEST RESULTS SUMMARY');
348
- console.log('='.repeat(50));
349
- console.log(`✅ Passed: ${passed}/${tests.length}`);
350
- console.log(`❌ Failed: ${failed}/${tests.length}`);
351
- console.log(`📈 Success Rate: ${Math.round((passed/tests.length) * 100)}%`);
352
-
353
- if (failed === 0) {
354
- console.log('\n🎉 All tests passed! The enhanced MCP is working perfectly!');
355
- } else {
356
- console.log('\n⚠️ Some tests failed. Please check the errors above.');
357
- }
358
-
359
- process.exit(failed === 0 ? 0 : 1);
360
- }
361
-
362
- // Check if server is running
363
- async function checkServer() {
364
- try {
365
- await makeMCPRequest('tools/list');
366
- return true;
367
- } catch (error) {
368
- return false;
369
- }
370
- }
371
-
372
- // Main
373
- (async () => {
374
- console.log('🔍 Checking if MCP server is running...');
375
-
376
- const serverRunning = await checkServer();
377
-
378
- if (!serverRunning) {
379
- console.error('❌ MCP server is not running at ' + MCP_SERVER_URL);
380
- console.error('\nPlease start the server first:');
381
- console.error(' node airtable_enhanced.js --token YOUR_TOKEN --base YOUR_BASE_ID');
382
- process.exit(1);
383
- }
384
-
385
- console.log('✅ Server is running!\n');
386
-
387
- // Run tests
388
- await runTests();
389
- })();
@@ -1,163 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- /**
4
- * Comprehensive Test Script for Airtable MCP
5
- * Tests all available MCP tools and functionality
6
- */
7
-
8
- const http = require('http');
9
-
10
- const MCP_SERVER_URL = 'http://localhost:8010/mcp';
11
- const TEST_TOKEN = process.env.AIRTABLE_TOKEN || 'YOUR_AIRTABLE_TOKEN_HERE';
12
- const TEST_BASE_ID = process.env.AIRTABLE_BASE_ID || 'YOUR_BASE_ID_HERE';
13
-
14
- if (TEST_TOKEN === 'YOUR_AIRTABLE_TOKEN_HERE' || TEST_BASE_ID === 'YOUR_BASE_ID_HERE') {
15
- console.error('Error: Please set AIRTABLE_TOKEN and AIRTABLE_BASE_ID environment variables');
16
- console.error('Example: export AIRTABLE_TOKEN=your_token_here');
17
- console.error(' export AIRTABLE_BASE_ID=your_base_id_here');
18
- process.exit(1);
19
- }
20
-
21
- // Helper function to make MCP requests
22
- function makeMCPRequest(method, params = {}) {
23
- return new Promise((resolve, reject) => {
24
- const postData = JSON.stringify({
25
- jsonrpc: '2.0',
26
- id: Date.now(),
27
- method: method,
28
- params: params
29
- });
30
-
31
- const options = {
32
- hostname: 'localhost',
33
- port: 8010,
34
- path: '/mcp',
35
- method: 'POST',
36
- headers: {
37
- 'Content-Type': 'application/json',
38
- 'Content-Length': Buffer.byteLength(postData)
39
- }
40
- };
41
-
42
- const req = http.request(options, (res) => {
43
- let data = '';
44
- res.on('data', (chunk) => {
45
- data += chunk;
46
- });
47
- res.on('end', () => {
48
- try {
49
- const response = JSON.parse(data);
50
- resolve(response);
51
- } catch (e) {
52
- reject(new Error(`Failed to parse response: ${e.message}`));
53
- }
54
- });
55
- });
56
-
57
- req.on('error', (e) => {
58
- reject(new Error(`Request failed: ${e.message}`));
59
- });
60
-
61
- req.write(postData);
62
- req.end();
63
- });
64
- }
65
-
66
- async function runComprehensiveTest() {
67
- console.log('🔌 Airtable MCP Comprehensive Test');
68
- console.log('===================================');
69
- console.log(`Server: ${MCP_SERVER_URL}`);
70
- console.log(`Base ID: ${TEST_BASE_ID}`);
71
- console.log(`Token: ${TEST_TOKEN.substring(0, 10)}...${TEST_TOKEN.substring(TEST_TOKEN.length - 10)}`);
72
- console.log('');
73
-
74
- try {
75
- // Test 1: List Resources
76
- console.log('📋 Test 1: Listing Resources');
77
- console.log('----------------------------');
78
- const resourcesResponse = await makeMCPRequest('resources/list');
79
- console.log('✅ Resources Response:');
80
- console.log(JSON.stringify(resourcesResponse, null, 2));
81
- console.log('');
82
-
83
- // Test 2: List Prompts
84
- console.log('📝 Test 2: Listing Prompts');
85
- console.log('-------------------------');
86
- const promptsResponse = await makeMCPRequest('prompts/list');
87
- console.log('✅ Prompts Response:');
88
- console.log(JSON.stringify(promptsResponse, null, 2));
89
- console.log('');
90
-
91
- // Test 3: List Tables
92
- console.log('📊 Test 3: Listing Tables');
93
- console.log('------------------------');
94
- const tablesResponse = await makeMCPRequest('tools/call', {
95
- name: 'list_tables'
96
- });
97
- console.log('✅ Tables Response:');
98
- console.log(JSON.stringify(tablesResponse, null, 2));
99
- console.log('');
100
-
101
- // Test 4: List Records from Requests table
102
- console.log('📄 Test 4: Listing Records (Requests Table)');
103
- console.log('-------------------------------------------');
104
- const recordsResponse = await makeMCPRequest('tools/call', {
105
- name: 'list_records',
106
- arguments: {
107
- table_name: 'requests',
108
- max_records: 3
109
- }
110
- });
111
- console.log('✅ Records Response:');
112
- console.log(JSON.stringify(recordsResponse, null, 2));
113
- console.log('');
114
-
115
- // Test 5: List Records from Providers table
116
- console.log('👥 Test 5: Listing Records (Providers Table)');
117
- console.log('--------------------------------------------');
118
- const providersResponse = await makeMCPRequest('tools/call', {
119
- name: 'list_records',
120
- arguments: {
121
- table_name: 'providers',
122
- max_records: 3
123
- }
124
- });
125
- console.log('✅ Providers Response:');
126
- console.log(JSON.stringify(providersResponse, null, 2));
127
- console.log('');
128
-
129
- // Test 6: List Records from Categories table
130
- console.log('🏷️ Test 6: Listing Records (Categories Table)');
131
- console.log('---------------------------------------------');
132
- const categoriesResponse = await makeMCPRequest('tools/call', {
133
- name: 'list_records',
134
- arguments: {
135
- table_name: 'categories',
136
- max_records: 3
137
- }
138
- });
139
- console.log('✅ Categories Response:');
140
- console.log(JSON.stringify(categoriesResponse, null, 2));
141
- console.log('');
142
-
143
- console.log('🎉 All Tests Completed Successfully!');
144
- console.log('');
145
- console.log('📊 Test Summary:');
146
- console.log('✅ MCP Server is running and accessible');
147
- console.log('✅ Airtable API connection is working');
148
- console.log('✅ All MCP tools are functioning properly');
149
- console.log('✅ JSON-RPC protocol is correctly implemented');
150
- console.log('✅ Error handling is working');
151
- console.log('');
152
- console.log('🚀 The Airtable MCP is ready for use!');
153
-
154
- } catch (error) {
155
- console.error('❌ Test failed:', error.message);
156
- process.exit(1);
157
- }
158
- }
159
-
160
- // Run the comprehensive test
161
- runComprehensiveTest();
162
-
163
-