apple-mail-mcp 2.10.21 → 2.10.22

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 (2) hide show
  1. package/build/index.js +27 -25
  2. package/package.json +1 -1
package/build/index.js CHANGED
@@ -84110,6 +84110,33 @@ function registerResourcesAndPrompts(server2, mailManager2) {
84110
84110
  );
84111
84111
  }
84112
84112
 
84113
+ // src/schemas.ts
84114
+ var MESSAGE_ID_SCHEMA = external_exports.string().regex(/^(\d+|imap:[A-Za-z0-9_-]+)$/, "Message ID must be numeric or an IMAP id (imap:\u2026)");
84115
+ var BATCH_IDS_SCHEMA = external_exports.array(MESSAGE_ID_SCHEMA).min(1, "At least one message ID is required").max(100, "Cannot process more than 100 messages in a single batch");
84116
+ var DATE_FILTER_SCHEMA = external_exports.string().regex(
84117
+ /^[a-zA-Z0-9 ,/\-:]+$/,
84118
+ "Date must contain only alphanumeric characters, spaces, commas, slashes, hyphens, and colons"
84119
+ ).refine((val) => !isNaN(new Date(val).getTime()), {
84120
+ message: "Date string must be a valid date (e.g., 'January 1, 2026' or '2026-03-15')"
84121
+ }).optional();
84122
+ var ATTACHMENTS_SCHEMA = external_exports.array(
84123
+ external_exports.union([
84124
+ external_exports.string().describe("Absolute path to an existing file"),
84125
+ external_exports.object({
84126
+ filename: external_exports.string().min(1).max(255).describe("Filename to give the attachment"),
84127
+ contentBase64: external_exports.string().min(1).max(
84128
+ MAX_INLINE_ATTACHMENT_BASE64_INPUT_CHARS,
84129
+ "Inline attachment exceeds the 25 MiB decoded size limit"
84130
+ ).refine(
84131
+ isInlineAttachmentBase64WithinLimit,
84132
+ "Inline attachment exceeds the 25 MiB decoded size limit"
84133
+ ).describe("Base64-encoded file content (maximum 25 MiB decoded)")
84134
+ })
84135
+ ])
84136
+ ).max(20, "Cannot attach more than 20 files").optional().describe(
84137
+ "Files to attach: absolute paths (e.g. '/Users/me/report.pdf') and/or inline {filename, contentBase64} objects up to 25 MiB decoded each."
84138
+ );
84139
+
84113
84140
  // src/tools/thread.ts
84114
84141
  function normalizeSubject(subject) {
84115
84142
  const prefix = /^\s*(?:(?:re|fwd?|fw|aw|wg|sv|vs|antw|antwort|enc|rif)\s*(?:\[\d+\])?\s*:\s*)+/i;
@@ -84392,8 +84419,6 @@ function withJsonSchema2020_12(transport2) {
84392
84419
 
84393
84420
  // src/index.ts
84394
84421
  loadFileConfig();
84395
- var MESSAGE_ID_SCHEMA = external_exports.string().regex(/^(\d+|imap:[A-Za-z0-9_-]+)$/, "Message ID must be numeric or an IMAP id (imap:\u2026)");
84396
- var BATCH_IDS_SCHEMA = external_exports.array(MESSAGE_ID_SCHEMA).min(1, "At least one message ID is required").max(100, "Cannot process more than 100 messages in a single batch");
84397
84422
  var BATCH_SOURCE_MAILBOX_SCHEMA = external_exports.string().optional().describe(
84398
84423
  "Mailbox the numeric ids were listed from (e.g. 'INBOX'). Pins each id to that mailbox \u2014 strongly recommended, since one numeric id can match in several mailboxes. Works on its own: without sourceAccount it means that mailbox in the default account. Ignored for imap: ids."
84399
84424
  );
@@ -84413,29 +84438,6 @@ var FLAG_COLOR_INDEX = {
84413
84438
  var FLAG_COLOR_SCHEMA = external_exports.enum(["red", "orange", "yellow", "green", "blue", "purple", "gray", "grey"]).optional().describe(
84414
84439
  "Optional flag color (Apple Mail palette: red, orange, yellow, green, blue, purple, gray \u2014 'grey' accepted). Omit for Mail's default flag. The color is applied on both routes: AppleScript sets the flag index, and IMAP writes the equivalent $MailFlagBit0/1/2 keywords Mail.app reads \u2014 so a smart mailbox keyed on flag color matches either way."
84415
84440
  );
84416
- var DATE_FILTER_SCHEMA = external_exports.string().regex(
84417
- /^[a-zA-Z0-9 ,/\-:]+$/,
84418
- "Date must contain only alphanumeric characters, spaces, commas, slashes, hyphens, and colons"
84419
- ).refine((val) => !isNaN(new Date(val).getTime()), {
84420
- message: "Date string must be a valid date (e.g., 'January 1, 2026' or '2026-03-15')"
84421
- }).optional();
84422
- var ATTACHMENTS_SCHEMA = external_exports.array(
84423
- external_exports.union([
84424
- external_exports.string().describe("Absolute path to an existing file"),
84425
- external_exports.object({
84426
- filename: external_exports.string().min(1).max(255).describe("Filename to give the attachment"),
84427
- contentBase64: external_exports.string().min(1).max(
84428
- MAX_INLINE_ATTACHMENT_BASE64_INPUT_CHARS,
84429
- "Inline attachment exceeds the 25 MiB decoded size limit"
84430
- ).refine(
84431
- isInlineAttachmentBase64WithinLimit,
84432
- "Inline attachment exceeds the 25 MiB decoded size limit"
84433
- ).describe("Base64-encoded file content (maximum 25 MiB decoded)")
84434
- })
84435
- ])
84436
- ).max(20, "Cannot attach more than 20 files").optional().describe(
84437
- "Files to attach: absolute paths (e.g. '/Users/me/report.pdf') and/or inline {filename, contentBase64} objects up to 25 MiB decoded each."
84438
- );
84439
84441
  var MESSAGE_ROW_SCHEMA = external_exports.object({}).passthrough();
84440
84442
  var LIST_OUTPUT_SCHEMA = {
84441
84443
  messages: external_exports.array(MESSAGE_ROW_SCHEMA).optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "apple-mail-mcp",
3
- "version": "2.10.21",
3
+ "version": "2.10.22",
4
4
  "description": "MCP server for Apple Mail - read, search, send, and manage emails via Claude and other AI assistants",
5
5
  "type": "module",
6
6
  "main": "build/index.js",