@softeria/ms-365-mcp-server 0.25.0 → 0.26.0

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.
@@ -112,13 +112,15 @@
112
112
  "pathPattern": "/me/events",
113
113
  "method": "get",
114
114
  "toolName": "list-calendar-events",
115
- "scopes": ["Calendars.Read"]
115
+ "scopes": ["Calendars.Read"],
116
+ "supportsTimezone": true
116
117
  },
117
118
  {
118
119
  "pathPattern": "/me/events/{event-id}",
119
120
  "method": "get",
120
121
  "toolName": "get-calendar-event",
121
- "scopes": ["Calendars.Read"]
122
+ "scopes": ["Calendars.Read"],
123
+ "supportsTimezone": true
122
124
  },
123
125
  {
124
126
  "pathPattern": "/me/events",
@@ -144,13 +146,15 @@
144
146
  "pathPattern": "/me/calendars/{calendar-id}/events",
145
147
  "method": "get",
146
148
  "toolName": "list-specific-calendar-events",
147
- "scopes": ["Calendars.Read"]
149
+ "scopes": ["Calendars.Read"],
150
+ "supportsTimezone": true
148
151
  },
149
152
  {
150
153
  "pathPattern": "/me/calendars/{calendar-id}/events/{event-id}",
151
154
  "method": "get",
152
155
  "toolName": "get-specific-calendar-event",
153
- "scopes": ["Calendars.Read"]
156
+ "scopes": ["Calendars.Read"],
157
+ "supportsTimezone": true
154
158
  },
155
159
  {
156
160
  "pathPattern": "/me/calendars/{calendar-id}/events",
@@ -176,7 +180,8 @@
176
180
  "pathPattern": "/me/calendarView",
177
181
  "method": "get",
178
182
  "toolName": "get-calendar-view",
179
- "scopes": ["Calendars.Read"]
183
+ "scopes": ["Calendars.Read"],
184
+ "supportsTimezone": true
180
185
  },
181
186
  {
182
187
  "pathPattern": "/me/calendars",
@@ -44,6 +44,11 @@ function registerGraphTools(server, graphClient, readOnly = false, enabledToolsP
44
44
  }
45
45
  paramSchema["includeHeaders"] = z.boolean().describe("Include response headers (including ETag) in the response metadata").optional();
46
46
  paramSchema["excludeResponse"] = z.boolean().describe("Exclude the full response body and only return success or failure indication").optional();
47
+ if (endpointConfig?.supportsTimezone) {
48
+ paramSchema["timezone"] = z.string().describe(
49
+ 'IANA timezone name (e.g., "America/New_York", "Europe/London", "Asia/Tokyo") for calendar event times. If not specified, times are returned in UTC.'
50
+ ).optional();
51
+ }
47
52
  let toolDescription = tool.description || `Execute ${tool.method.toUpperCase()} request to ${tool.path}`;
48
53
  if (endpointConfig?.llmTip) {
49
54
  toolDescription += `
@@ -128,6 +133,10 @@ function registerGraphTools(server, graphClient, readOnly = false, enabledToolsP
128
133
  logger.info(`Set body param: ${JSON.stringify(body)}`);
129
134
  }
130
135
  }
136
+ if (endpointConfig?.supportsTimezone && params.timezone) {
137
+ headers["Prefer"] = `outlook.timezone="${params.timezone}"`;
138
+ logger.info(`Setting timezone header: Prefer: outlook.timezone="${params.timezone}"`);
139
+ }
131
140
  if (Object.keys(queryParams).length > 0) {
132
141
  const queryString = Object.entries(queryParams).map(([key, value]) => `${encodeURIComponent(key)}=${encodeURIComponent(value)}`).join("&");
133
142
  path2 = `${path2}${path2.includes("?") ? "&" : "?"}${queryString}`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@softeria/ms-365-mcp-server",
3
- "version": "0.25.0",
3
+ "version": "0.26.0",
4
4
  "description": " A Model Context Protocol (MCP) server for interacting with Microsoft 365 and Office services through the Graph API",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -112,13 +112,15 @@
112
112
  "pathPattern": "/me/events",
113
113
  "method": "get",
114
114
  "toolName": "list-calendar-events",
115
- "scopes": ["Calendars.Read"]
115
+ "scopes": ["Calendars.Read"],
116
+ "supportsTimezone": true
116
117
  },
117
118
  {
118
119
  "pathPattern": "/me/events/{event-id}",
119
120
  "method": "get",
120
121
  "toolName": "get-calendar-event",
121
- "scopes": ["Calendars.Read"]
122
+ "scopes": ["Calendars.Read"],
123
+ "supportsTimezone": true
122
124
  },
123
125
  {
124
126
  "pathPattern": "/me/events",
@@ -144,13 +146,15 @@
144
146
  "pathPattern": "/me/calendars/{calendar-id}/events",
145
147
  "method": "get",
146
148
  "toolName": "list-specific-calendar-events",
147
- "scopes": ["Calendars.Read"]
149
+ "scopes": ["Calendars.Read"],
150
+ "supportsTimezone": true
148
151
  },
149
152
  {
150
153
  "pathPattern": "/me/calendars/{calendar-id}/events/{event-id}",
151
154
  "method": "get",
152
155
  "toolName": "get-specific-calendar-event",
153
- "scopes": ["Calendars.Read"]
156
+ "scopes": ["Calendars.Read"],
157
+ "supportsTimezone": true
154
158
  },
155
159
  {
156
160
  "pathPattern": "/me/calendars/{calendar-id}/events",
@@ -176,7 +180,8 @@
176
180
  "pathPattern": "/me/calendarView",
177
181
  "method": "get",
178
182
  "toolName": "get-calendar-view",
179
- "scopes": ["Calendars.Read"]
183
+ "scopes": ["Calendars.Read"],
184
+ "supportsTimezone": true
180
185
  },
181
186
  {
182
187
  "pathPattern": "/me/calendars",