@@ -55,6 +55,7 @@ func UserList(client *deskclient.Client) server.ServerTool {
55
55
mcp .WithArray ("lastName" , mcp .Description ("The last names of the users to filter by." )),
56
56
mcp .WithArray ("email" , mcp .Description ("The email addresses of the users to filter by." )),
57
57
mcp .WithArray ("inboxIDs" , mcp .Description ("The IDs of the inboxes to filter by." )),
58
+ mcp .WithBoolean ("isPartTime" , mcp .Description ("Whether to include part-time users in the results." )),
58
59
),
59
60
Handler : func (ctx context.Context , request mcp.CallToolRequest ) (* mcp.CallToolResult , error ) {
60
61
// Apply filters to the user list
@@ -65,10 +66,10 @@ func UserList(client *deskclient.Client) server.ServerTool {
65
66
66
67
filter := deskclient .NewFilter ()
67
68
if len (firstNames ) > 0 {
68
- filter = filter .In ("first_name " , firstNames )
69
+ filter = filter .In ("firstName " , firstNames )
69
70
}
70
71
if len (lastNames ) > 0 {
71
- filter = filter .In ("last_name " , lastNames )
72
+ filter = filter .In ("lastName " , lastNames )
72
73
}
73
74
if len (emails ) > 0 {
74
75
filter = filter .In ("email" , emails )
@@ -77,6 +78,11 @@ func UserList(client *deskclient.Client) server.ServerTool {
77
78
filter = filter .In ("inboxes.id" , inboxIDs )
78
79
}
79
80
81
+ isPartTime := request .GetBool ("isPartTime" , false )
82
+ if isPartTime {
83
+ filter = filter .Eq ("isPartTime" , true )
84
+ }
85
+
80
86
params := url.Values {}
81
87
params .Set ("filter" , filter .Build ())
82
88
0 commit comments