@taazkareem/clickup-mcp-server 0.8.2 → 0.8.4
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.
- package/README.md +123 -55
- package/build/config.js +38 -7
- package/build/logger.js +2 -26
- package/build/middleware/security.js +231 -0
- package/build/server.js +32 -6
- package/build/services/clickup/task/task-core.js +1 -1
- package/build/services/clickup/task/task-search.js +163 -0
- package/build/sse_server.js +172 -8
- package/build/tools/documents.js +0 -9
- package/build/tools/task/bulk-operations.js +2 -2
- package/build/tools/task/handlers.js +142 -7
- package/build/tools/task/single-operations.js +2 -2
- package/build/tools/task/workspace-operations.js +1 -0
- package/build/utils/color-processor.js +3 -3
- package/build/utils/date-utils.js +3 -27
- package/package.json +1 -1
- package/build/schemas/member.js +0 -13
|
@@ -171,9 +171,9 @@ export const updateTaskTool = {
|
|
|
171
171
|
description: "New status. Must be valid for the task's current list."
|
|
172
172
|
},
|
|
173
173
|
priority: {
|
|
174
|
-
type: "
|
|
174
|
+
type: "string",
|
|
175
175
|
nullable: true,
|
|
176
|
-
enum: [1, 2, 3, 4, null],
|
|
176
|
+
enum: ["1", "2", "3", "4", null],
|
|
177
177
|
description: "New priority: 1 (urgent) to 4 (low). Set null to clear priority."
|
|
178
178
|
},
|
|
179
179
|
dueDate: {
|
|
@@ -35,6 +35,7 @@ Notes:
|
|
|
35
35
|
- "summary": Returns lightweight task data (name, status, list, tags)
|
|
36
36
|
- "detailed": Returns complete task data with all fields (DEFAULT if not specified)
|
|
37
37
|
- Responses exceeding 50,000 tokens automatically switch to summary format to avoid hitting LLM token limits
|
|
38
|
+
- **Enhanced List Filtering**: When list_ids are provided, the tool leverages ClickUp's Views API to include tasks that are *associated with* the specified lists, including tasks that have been added to multiple lists. This provides comprehensive coverage of all tasks related to your specified lists, not just tasks that were originally created in those lists.
|
|
38
39
|
`,
|
|
39
40
|
parameters: {
|
|
40
41
|
type: 'object',
|
|
@@ -86,7 +86,7 @@ const COLOR_VARIATIONS = {
|
|
|
86
86
|
* @param text - Natural language text that contains a color reference
|
|
87
87
|
* @returns The extracted color name or null if no color is found
|
|
88
88
|
*/
|
|
89
|
-
|
|
89
|
+
function extractColorFromText(text) {
|
|
90
90
|
if (!text)
|
|
91
91
|
return null;
|
|
92
92
|
// Convert to lowercase for case-insensitive matching
|
|
@@ -115,7 +115,7 @@ export function extractColorFromText(text) {
|
|
|
115
115
|
* @param colorName - Name of the color to convert (e.g., "blue", "dark red")
|
|
116
116
|
* @returns HEX color code or null if color name is not recognized
|
|
117
117
|
*/
|
|
118
|
-
|
|
118
|
+
function colorNameToHex(colorName) {
|
|
119
119
|
if (!colorName)
|
|
120
120
|
return null;
|
|
121
121
|
const lowercaseColor = colorName.toLowerCase();
|
|
@@ -154,7 +154,7 @@ function calculateLuminance(hex) {
|
|
|
154
154
|
* @param backgroundColor - HEX code of the background color
|
|
155
155
|
* @returns HEX code of the foreground color (either black or white)
|
|
156
156
|
*/
|
|
157
|
-
|
|
157
|
+
function generateContrastingForeground(backgroundColor) {
|
|
158
158
|
const luminance = calculateLuminance(backgroundColor);
|
|
159
159
|
// Use white text on dark backgrounds and black text on light backgrounds
|
|
160
160
|
// The threshold 0.5 is based on WCAG guidelines for contrast
|
|
@@ -37,7 +37,7 @@ export function getRelativeTimestamp(minutes = 0, hours = 0, days = 0, weeks = 0
|
|
|
37
37
|
* Get the start of today (midnight) in Unix milliseconds
|
|
38
38
|
* @returns Timestamp in milliseconds for start of current day
|
|
39
39
|
*/
|
|
40
|
-
|
|
40
|
+
function getStartOfDay() {
|
|
41
41
|
const now = new Date();
|
|
42
42
|
now.setHours(0, 0, 0, 0);
|
|
43
43
|
return now.getTime();
|
|
@@ -46,7 +46,7 @@ export function getStartOfDay() {
|
|
|
46
46
|
* Get the end of today (23:59:59.999) in Unix milliseconds
|
|
47
47
|
* @returns Timestamp in milliseconds for end of current day
|
|
48
48
|
*/
|
|
49
|
-
|
|
49
|
+
function getEndOfDay() {
|
|
50
50
|
const now = new Date();
|
|
51
51
|
now.setHours(23, 59, 59, 999);
|
|
52
52
|
return now.getTime();
|
|
@@ -55,7 +55,7 @@ export function getEndOfDay() {
|
|
|
55
55
|
* Get the current time in Unix milliseconds
|
|
56
56
|
* @returns Current timestamp in milliseconds
|
|
57
57
|
*/
|
|
58
|
-
|
|
58
|
+
function getCurrentTimestamp() {
|
|
59
59
|
return new Date().getTime();
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
@@ -310,30 +310,6 @@ export function formatDueDate(timestamp) {
|
|
|
310
310
|
throw new Error(`Invalid timestamp: ${timestamp}`);
|
|
311
311
|
}
|
|
312
312
|
}
|
|
313
|
-
/**
|
|
314
|
-
* Checks if a timestamp is for today
|
|
315
|
-
*
|
|
316
|
-
* @param timestamp Unix timestamp in milliseconds
|
|
317
|
-
* @returns Boolean indicating if the timestamp is for today
|
|
318
|
-
*/
|
|
319
|
-
export function isToday(timestamp) {
|
|
320
|
-
const date = new Date(timestamp);
|
|
321
|
-
const today = new Date();
|
|
322
|
-
return date.getDate() === today.getDate() &&
|
|
323
|
-
date.getMonth() === today.getMonth() &&
|
|
324
|
-
date.getFullYear() === today.getFullYear();
|
|
325
|
-
}
|
|
326
|
-
/**
|
|
327
|
-
* Get timestamp range for today (start to end)
|
|
328
|
-
*
|
|
329
|
-
* @returns Object with start and end timestamps for today
|
|
330
|
-
*/
|
|
331
|
-
export function getTodayRange() {
|
|
332
|
-
return {
|
|
333
|
-
start: getStartOfDay(),
|
|
334
|
-
end: getEndOfDay()
|
|
335
|
-
};
|
|
336
|
-
}
|
|
337
313
|
/**
|
|
338
314
|
* Format a date for display in errors and messages
|
|
339
315
|
* @param timestamp The timestamp to format
|
package/package.json
CHANGED
package/build/schemas/member.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
// src/schemas/member.ts
|
|
2
|
-
import { z } from 'zod';
|
|
3
|
-
export const MemberSchema = z.object({
|
|
4
|
-
id: z.number(),
|
|
5
|
-
username: z.string().optional(),
|
|
6
|
-
email: z.string().optional(),
|
|
7
|
-
full_name: z.string().optional(),
|
|
8
|
-
profile_picture: z.string().optional(),
|
|
9
|
-
role: z.number(),
|
|
10
|
-
role_name: z.string().optional(),
|
|
11
|
-
initials: z.string().optional(),
|
|
12
|
-
last_active: z.string().optional(),
|
|
13
|
-
});
|