shipmail-mcp 0.2.10 → 0.3.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.
- package/README.md +19 -13
- package/dist/index.js +204 -7
- package/package.json +2 -2
- package/server.json +2 -2
- package/smithery.yaml +1 -1
package/README.md
CHANGED
|
@@ -181,18 +181,18 @@ Once connected, ask your agent:
|
|
|
181
181
|
|
|
182
182
|
All tools are namespaced with `shipmail_` to avoid collisions with peer MCP servers.
|
|
183
183
|
|
|
184
|
-
| Group | Tools
|
|
185
|
-
| -------------------- |
|
|
186
|
-
| Status | `shipmail_status`
|
|
187
|
-
| Domains | `shipmail_list_domains`, `shipmail_get_domain`, `shipmail_get_domain_dns_records`, `shipmail_create_domain`, `shipmail_update_domain`, `shipmail_delete_domain`, `shipmail_verify_domain`, `shipmail_search_domains`
|
|
188
|
-
| Mailboxes | `shipmail_list_mailboxes`, `shipmail_get_mailbox`, `shipmail_create_mailbox`, `shipmail_update_mailbox`, `shipmail_delete_mailbox`, `shipmail_suspend_mailbox`, `shipmail_resume_mailbox`, `shipmail_list_mailbox_forwarding`, `shipmail_create_mailbox_forwarding`, `shipmail_delete_mailbox_forwarding`, `shipmail_list_mailbox_folders`, `shipmail_create_mailbox_folder`, `shipmail_update_mailbox_folder`, `shipmail_delete_mailbox_folder`, `shipmail_list_mailbox_identities`, `shipmail_get_mailbox_rules`, `shipmail_set_mailbox_rules`, `shipmail_reset_mailbox_password`, `shipmail_set_auto_reply`, `shipmail_set_spam_filter`, `shipmail_inject_sandbox_inbound` |
|
|
189
|
-
| Mailbox inbox | `shipmail_list_mailbox_inbox_messages`, `shipmail_get_mailbox_inbox_thread`, `shipmail_update_inbox_message`, `shipmail_move_inbox_message`, `shipmail_delete_inbox_message`
|
|
190
|
-
| Messages and threads | `shipmail_list_messages`, `shipmail_get_message`, `shipmail_send_message`, `shipmail_reply_to_message`, `shipmail_list_threads`, `shipmail_get_thread`, `shipmail_reply_to_thread`
|
|
191
|
-
| Webhooks | `shipmail_list_webhooks`, `shipmail_get_webhook`, `shipmail_create_webhook`, `shipmail_update_webhook`, `shipmail_delete_webhook`, `shipmail_rotate_webhook_secret`, `shipmail_test_webhook`, `shipmail_list_webhook_deliveries`, `shipmail_get_webhook_delivery`, `shipmail_replay_webhook_delivery`
|
|
192
|
-
| Suppressions | `shipmail_list_suppressions`, `shipmail_remove_suppression`
|
|
193
|
-
| Audiences | `shipmail_list_audiences`, `shipmail_get_audience`, `shipmail_create_audience`, `shipmail_update_audience`, `shipmail_delete_audience`, `shipmail_list_subscribers`, `shipmail_get_subscriber`, `shipmail_get_subscriber_by_email`, `shipmail_add_subscriber`, `shipmail_add_subscribers_batch`, `shipmail_update_subscriber`, `shipmail_unsubscribe_subscriber`, `shipmail_resubscribe_subscriber`, `shipmail_remove_subscriber`
|
|
194
|
-
| Newsletters | `shipmail_list_newsletter_domains`, `shipmail_list_newsletter_assets`, `shipmail_list_newsletters`, `shipmail_get_newsletter`, `shipmail_preview_newsletter`, `shipmail_create_newsletter`, `shipmail_create_newsletter_from_changelog`, `shipmail_update_newsletter`, `shipmail_run_newsletter_preflight`, `shipmail_send_newsletter_test`, `shipmail_schedule_newsletter`, `shipmail_cancel_newsletter`, `shipmail_resume_newsletter`
|
|
195
|
-
| Partner beta | `shipmail_list_partner_organizations`, `shipmail_create_partner_organization`, `shipmail_get_partner_organization`, `shipmail_update_partner_organization`, `shipmail_resend_partner_ownership_invitation`, `shipmail_suspend_partner_organization`, `shipmail_resume_partner_organization`, `shipmail_offboard_partner_organization`, `shipmail_get_partner_usage`
|
|
184
|
+
| Group | Tools |
|
|
185
|
+
| -------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
186
|
+
| Status | `shipmail_status` |
|
|
187
|
+
| Domains | `shipmail_list_domains`, `shipmail_get_domain`, `shipmail_get_domain_dns_records`, `shipmail_create_domain`, `shipmail_update_domain`, `shipmail_delete_domain`, `shipmail_verify_domain`, `shipmail_search_domains` |
|
|
188
|
+
| Mailboxes | `shipmail_list_mailboxes`, `shipmail_get_mailbox`, `shipmail_create_mailbox`, `shipmail_update_mailbox`, `shipmail_delete_mailbox`, `shipmail_suspend_mailbox`, `shipmail_resume_mailbox`, `shipmail_list_mailbox_app_passwords`, `shipmail_create_mailbox_app_password`, `shipmail_revoke_mailbox_app_password`, `shipmail_list_mailbox_forwarding`, `shipmail_create_mailbox_forwarding`, `shipmail_delete_mailbox_forwarding`, `shipmail_list_mailbox_folders`, `shipmail_create_mailbox_folder`, `shipmail_update_mailbox_folder`, `shipmail_delete_mailbox_folder`, `shipmail_list_mailbox_identities`, `shipmail_get_mailbox_rules`, `shipmail_set_mailbox_rules`, `shipmail_reset_mailbox_password`, `shipmail_set_auto_reply`, `shipmail_set_spam_filter`, `shipmail_inject_sandbox_inbound` |
|
|
189
|
+
| Mailbox inbox | `shipmail_list_mailbox_inbox_messages`, `shipmail_get_mailbox_inbox_thread`, `shipmail_update_inbox_message`, `shipmail_move_inbox_message`, `shipmail_delete_inbox_message` |
|
|
190
|
+
| Messages and threads | `shipmail_list_messages`, `shipmail_get_message`, `shipmail_send_message`, `shipmail_reply_to_message`, `shipmail_list_threads`, `shipmail_get_thread`, `shipmail_reply_to_thread` |
|
|
191
|
+
| Webhooks | `shipmail_list_webhooks`, `shipmail_get_webhook`, `shipmail_create_webhook`, `shipmail_update_webhook`, `shipmail_delete_webhook`, `shipmail_rotate_webhook_secret`, `shipmail_test_webhook`, `shipmail_list_webhook_deliveries`, `shipmail_get_webhook_delivery`, `shipmail_replay_webhook_delivery` |
|
|
192
|
+
| Suppressions | `shipmail_list_suppressions`, `shipmail_remove_suppression` |
|
|
193
|
+
| Audiences | `shipmail_list_audiences`, `shipmail_get_audience`, `shipmail_create_audience`, `shipmail_update_audience`, `shipmail_delete_audience`, `shipmail_list_subscribers`, `shipmail_get_subscriber`, `shipmail_get_subscriber_by_email`, `shipmail_add_subscriber`, `shipmail_add_subscribers_batch`, `shipmail_update_subscriber`, `shipmail_unsubscribe_subscriber`, `shipmail_resubscribe_subscriber`, `shipmail_remove_subscriber` |
|
|
194
|
+
| Newsletters | `shipmail_list_newsletter_domains`, `shipmail_list_newsletter_assets`, `shipmail_list_newsletters`, `shipmail_get_newsletter`, `shipmail_preview_newsletter`, `shipmail_create_newsletter`, `shipmail_create_newsletter_from_changelog`, `shipmail_update_newsletter`, `shipmail_run_newsletter_preflight`, `shipmail_send_newsletter_test`, `shipmail_schedule_newsletter`, `shipmail_cancel_newsletter`, `shipmail_resume_newsletter` |
|
|
195
|
+
| Partner beta | `shipmail_list_partner_organizations`, `shipmail_create_partner_organization`, `shipmail_get_partner_organization`, `shipmail_update_partner_organization`, `shipmail_resend_partner_ownership_invitation`, `shipmail_suspend_partner_organization`, `shipmail_resume_partner_organization`, `shipmail_offboard_partner_organization`, `shipmail_list_partner_mailbox_credential_grants`, `shipmail_consume_partner_mailbox_credential_grant`, `shipmail_get_partner_usage` |
|
|
196
196
|
|
|
197
197
|
Message send and reply tools accept optional `client_reference`, scalar `metadata`,
|
|
198
198
|
`source_rfc_message_id`, and validated safe `headers`. `shipmail_list_messages` accepts either a
|
|
@@ -200,6 +200,12 @@ Message send and reply tools accept optional `client_reference`, scalar `metadat
|
|
|
200
200
|
|
|
201
201
|
With an `sm_test_...` API key, send and reply tools accept `sandbox_outcome` and the sandbox inbound tool creates fake inbound mail. The API keeps test storage and events isolated and never delivers sandbox mail to real recipients.
|
|
202
202
|
|
|
203
|
+
App-password creation, revocation, and partner grant consumption are destructive/high-risk tools.
|
|
204
|
+
Creation and grant consumption return a live secret once; revocation disconnects that client
|
|
205
|
+
immediately. Partner grant consumption requires the exact `partner:mailbox_credentials:issue`
|
|
206
|
+
scope and an operator-approved one-time grant. App-password creation and grant consumption do not
|
|
207
|
+
accept idempotency keys.
|
|
208
|
+
|
|
203
209
|
To restrict the surface, pass `--tools` (overrides `SHIPMAIL_MCP_TOOLS`):
|
|
204
210
|
|
|
205
211
|
```json
|
|
@@ -258,7 +264,7 @@ Shipmail generates the primary credential and never returns it to the partner.
|
|
|
258
264
|
|
|
259
265
|
- **Tool namespacing**: All tools are prefixed with `shipmail_` to avoid collisions with peer MCP servers in the same host.
|
|
260
266
|
- **Structured outputs**: Successful tools return both text fallback content and structured MCP `structuredContent`.
|
|
261
|
-
- **Idempotency**: Mutating tools accept an optional `idempotency_key`. When omitted, the server generates a fresh key per tool call. Supply your own key if a specific request must stay idempotent across MCP retries.
|
|
267
|
+
- **Idempotency**: Mutating tools accept an optional `idempotency_key`. When omitted, the server generates a fresh key per tool call. Supply your own key if a specific request must stay idempotent across MCP retries. Mailbox app-password creation and partner grant consumption are excluded because their one-time plaintext secrets must never be cached.
|
|
262
268
|
- **Input sanitization**: Email content, addresses, and error text are stripped of ASCII control characters, DEL, and Unicode directional or BiDi markers (U+061C, U+200E/F, U+202A-E, U+2066-9). Long strings are truncated.
|
|
263
269
|
- **Error redaction**: 5xx and unexpected Shipmail errors are redacted to a generic message; the original `request_id` is preserved for support. Generic `Error` thrown values (network errors, deserialization) are redacted to "Internal MCP error" before reaching the LLM. Detail lands on stderr.
|
|
264
270
|
- **Circuit breaker**: Each session enforces per-tool rate limits and a hard total-call ceiling as a runaway-agent guard. These are not abuse controls. Real abuse limits live at the API per API key. Restart the server to reset.
|
package/dist/index.js
CHANGED
|
@@ -438,6 +438,39 @@ var mailboxExportSchema = z.object({
|
|
|
438
438
|
started_at: z.string().nullable(),
|
|
439
439
|
completed_at: z.string().nullable()
|
|
440
440
|
});
|
|
441
|
+
var mailboxAppPasswordSchema = z.object({
|
|
442
|
+
object: z.literal("mailbox_app_password"),
|
|
443
|
+
id: z.string(),
|
|
444
|
+
mailbox_id: z.string(),
|
|
445
|
+
name: z.string(),
|
|
446
|
+
state: z.enum(["pending_create", "active", "pending_revoke", "revoked", "failed"]),
|
|
447
|
+
purpose: z.enum(["operator_client", "partner_embedded_webmail"]),
|
|
448
|
+
expires_at: z.string().nullable(),
|
|
449
|
+
allowed_cidrs: z.array(z.string()),
|
|
450
|
+
last_used_at: z.string().nullable(),
|
|
451
|
+
created_at: z.string(),
|
|
452
|
+
revoked_at: z.string().nullable()
|
|
453
|
+
});
|
|
454
|
+
var createdMailboxAppPasswordSchema = mailboxAppPasswordSchema.extend({
|
|
455
|
+
secret: z.string()
|
|
456
|
+
});
|
|
457
|
+
var partnerMailboxCredentialSchema = createdMailboxAppPasswordSchema.extend({
|
|
458
|
+
operator_notified: z.boolean()
|
|
459
|
+
});
|
|
460
|
+
var partnerMailboxCredentialGrantSchema = z.object({
|
|
461
|
+
object: z.literal("partner_mailbox_credential_grant"),
|
|
462
|
+
id: z.string(),
|
|
463
|
+
partner_organization_id: z.string(),
|
|
464
|
+
organization_id: z.string(),
|
|
465
|
+
organization_name: z.string(),
|
|
466
|
+
external_reference: z.string(),
|
|
467
|
+
operator_email: z.string(),
|
|
468
|
+
mailbox_id: z.string(),
|
|
469
|
+
mailbox_address: z.string(),
|
|
470
|
+
disclosure_version: z.string(),
|
|
471
|
+
expires_at: z.string(),
|
|
472
|
+
consented_at: z.string()
|
|
473
|
+
});
|
|
441
474
|
var mailboxFolderSchema = z.object({
|
|
442
475
|
object: z.literal("mailbox_folder"),
|
|
443
476
|
id: z.string(),
|
|
@@ -813,6 +846,26 @@ var domainOutputSchema = z.object({ domain: domainSchema });
|
|
|
813
846
|
var domainDnsRecordsOutputSchema = z.object({ dns_records: domainDnsRecordSetSchema });
|
|
814
847
|
var mailboxOutputSchema = z.object({ mailbox: mailboxSchema });
|
|
815
848
|
var mailboxExportOutputSchema = z.object({ export: mailboxExportSchema });
|
|
849
|
+
var mailboxAppPasswordOutputSchema = z.object({
|
|
850
|
+
app_password: mailboxAppPasswordSchema
|
|
851
|
+
});
|
|
852
|
+
var createdMailboxAppPasswordOutputSchema = z.object({
|
|
853
|
+
app_password: createdMailboxAppPasswordSchema
|
|
854
|
+
});
|
|
855
|
+
var mailboxAppPasswordsOutputSchema = z.object({
|
|
856
|
+
app_passwords: z.object({
|
|
857
|
+
object: z.literal("list"),
|
|
858
|
+
data: z.array(mailboxAppPasswordSchema)
|
|
859
|
+
})
|
|
860
|
+
});
|
|
861
|
+
var partnerMailboxCredentialOutputSchema = z.object({
|
|
862
|
+
credential: partnerMailboxCredentialSchema
|
|
863
|
+
});
|
|
864
|
+
var partnerMailboxCredentialGrantsOutputSchema = z.object({
|
|
865
|
+
grants: z.object({
|
|
866
|
+
data: z.array(partnerMailboxCredentialGrantSchema)
|
|
867
|
+
})
|
|
868
|
+
});
|
|
816
869
|
var mailboxFolderOutputSchema = z.object({ folder: mailboxFolderSchema });
|
|
817
870
|
var mailboxFoldersOutputSchema = z.object({ folders: mailboxFoldersSchema });
|
|
818
871
|
var mailboxIdentitiesOutputSchema = z.object({ identities: mailboxIdentitiesSchema });
|
|
@@ -879,11 +932,22 @@ var idempotentByIdInputSchema = z.object({
|
|
|
879
932
|
});
|
|
880
933
|
var createMailboxImportInputSchema = z.object({
|
|
881
934
|
id: idSchema,
|
|
882
|
-
provider: z.enum([
|
|
935
|
+
provider: z.enum([
|
|
936
|
+
"gmail",
|
|
937
|
+
"yahoo",
|
|
938
|
+
"aol",
|
|
939
|
+
"icloud",
|
|
940
|
+
"fastmail",
|
|
941
|
+
"zoho",
|
|
942
|
+
"infomaniak",
|
|
943
|
+
"ovh",
|
|
944
|
+
"gandi",
|
|
945
|
+
"imap"
|
|
946
|
+
]).describe("Source provider. Outlook imports require the dashboard's Microsoft sign-in."),
|
|
883
947
|
email: z.string().min(3).max(320).describe("Address of the source mailbox"),
|
|
884
|
-
password: z.string().min(1).max(1024).describe("App password
|
|
885
|
-
host: z.string().min(1).max(253).optional().describe("IMAP server
|
|
886
|
-
port: z.number().int().min(1).max(65535).optional().describe("IMAP port
|
|
948
|
+
password: z.string().min(1).max(1024).describe("App password, device password, or IMAP password for the source mailbox"),
|
|
949
|
+
host: z.string().min(1).max(253).optional().describe("IMAP server. Required for 'imap'; optional OVHcloud server override for 'ovh'."),
|
|
950
|
+
port: z.number().int().min(1).max(65535).optional().describe("IMAP port. Used for 'imap' and optional OVHcloud overrides."),
|
|
887
951
|
range: z.enum(["all", "12m", "3m", "1m"]).optional().describe("How far back to import. Defaults to all."),
|
|
888
952
|
include_spam: z.boolean().optional().describe("Also import the source spam folder"),
|
|
889
953
|
include_trash: z.boolean().optional().describe("Also import the source trash folder")
|
|
@@ -993,6 +1057,20 @@ var updateMailboxInputSchema = z.object({
|
|
|
993
1057
|
display_name: recipientNameSchema.max(200).nullable().describe("New display name, or null to clear."),
|
|
994
1058
|
idempotency_key: idempotencyKeySchema
|
|
995
1059
|
});
|
|
1060
|
+
var appPasswordCidrInputSchema = z.union([
|
|
1061
|
+
z.cidrv4("Must be a valid IPv4 CIDR range."),
|
|
1062
|
+
z.cidrv6("Must be a valid IPv6 CIDR range.")
|
|
1063
|
+
]);
|
|
1064
|
+
var createMailboxAppPasswordInputSchema = z.object({
|
|
1065
|
+
id: idSchema.describe("Mailbox ID."),
|
|
1066
|
+
name: noControlString(100, "name").trim().min(1),
|
|
1067
|
+
expires_at: z.iso.datetime().optional(),
|
|
1068
|
+
allowed_cidrs: z.array(appPasswordCidrInputSchema).max(20).optional()
|
|
1069
|
+
});
|
|
1070
|
+
var revokeMailboxAppPasswordInputSchema = z.object({
|
|
1071
|
+
id: idSchema.describe("Mailbox ID."),
|
|
1072
|
+
app_password_id: idSchema.describe("App password ID.")
|
|
1073
|
+
});
|
|
996
1074
|
var createMailboxFolderInputSchema = z.object({
|
|
997
1075
|
id: idSchema,
|
|
998
1076
|
name: folderNameSchema.describe("Custom folder name to create."),
|
|
@@ -2015,6 +2093,12 @@ var resendPartnerInvitationInputSchema = partnerOrganizationByIdInputSchema.exte
|
|
|
2015
2093
|
owner_email: emailSchema.optional(),
|
|
2016
2094
|
idempotency_key: idempotencyKeySchema
|
|
2017
2095
|
});
|
|
2096
|
+
var consumePartnerMailboxCredentialGrantInputSchema = z.object({
|
|
2097
|
+
grant_id: idSchema.describe("Single-use mailbox credential grant ID."),
|
|
2098
|
+
name: noControlString(100, "name").trim().min(1).optional(),
|
|
2099
|
+
expires_at: z.iso.datetime().optional(),
|
|
2100
|
+
allowed_cidrs: z.array(appPasswordCidrInputSchema).max(20).optional()
|
|
2101
|
+
});
|
|
2018
2102
|
|
|
2019
2103
|
// src/prompts.ts
|
|
2020
2104
|
var MAILBOX_LOCAL_REGEX = /^[a-zA-Z0-9]([a-zA-Z0-9._-]{0,62}[a-zA-Z0-9])?$/;
|
|
@@ -2460,6 +2544,8 @@ var SESSION_LIMITS = {
|
|
|
2460
2544
|
shipmail_create_domain: 10,
|
|
2461
2545
|
shipmail_create_mailbox: 20,
|
|
2462
2546
|
shipmail_create_mailbox_export: 5,
|
|
2547
|
+
shipmail_create_mailbox_app_password: 10,
|
|
2548
|
+
shipmail_revoke_mailbox_app_password: 20,
|
|
2463
2549
|
shipmail_create_mailbox_import: 5,
|
|
2464
2550
|
shipmail_cancel_mailbox_import: 10,
|
|
2465
2551
|
shipmail_undo_mailbox_import: 10,
|
|
@@ -2513,7 +2599,8 @@ var SESSION_LIMITS = {
|
|
|
2513
2599
|
shipmail_resend_partner_ownership_invitation: 20,
|
|
2514
2600
|
shipmail_suspend_partner_organization: 20,
|
|
2515
2601
|
shipmail_resume_partner_organization: 20,
|
|
2516
|
-
shipmail_offboard_partner_organization: 10
|
|
2602
|
+
shipmail_offboard_partner_organization: 10,
|
|
2603
|
+
shipmail_consume_partner_mailbox_credential_grant: 20
|
|
2517
2604
|
};
|
|
2518
2605
|
var SESSION_TOTAL_LIMIT = 500;
|
|
2519
2606
|
var DEBUG_ENABLED = process.env["SHIPMAIL_MCP_DEBUG"] === "1";
|
|
@@ -2805,6 +2892,72 @@ function registerTools(server, client, selectedTools) {
|
|
|
2805
2892
|
}))
|
|
2806
2893
|
);
|
|
2807
2894
|
});
|
|
2895
|
+
registerIfAllowed("shipmail_list_mailbox_app_passwords", () => {
|
|
2896
|
+
server.registerTool(
|
|
2897
|
+
"shipmail_list_mailbox_app_passwords",
|
|
2898
|
+
{
|
|
2899
|
+
title: "List Mailbox App Passwords",
|
|
2900
|
+
description: "List app-password metadata for one mailbox. Secret values are never returned by this read operation.",
|
|
2901
|
+
inputSchema: getByIdInputSchema,
|
|
2902
|
+
outputSchema: mailboxAppPasswordsOutputSchema,
|
|
2903
|
+
annotations: { readOnlyHint: true, openWorldHint: false }
|
|
2904
|
+
},
|
|
2905
|
+
async ({ id }) => runTool(
|
|
2906
|
+
"shipmail_list_mailbox_app_passwords",
|
|
2907
|
+
mailboxAppPasswordsOutputSchema,
|
|
2908
|
+
async () => ({ app_passwords: await client.mailboxes.listAppPasswords(id) })
|
|
2909
|
+
)
|
|
2910
|
+
);
|
|
2911
|
+
});
|
|
2912
|
+
registerIfAllowed("shipmail_create_mailbox_app_password", () => {
|
|
2913
|
+
server.registerTool(
|
|
2914
|
+
"shipmail_create_mailbox_app_password",
|
|
2915
|
+
{
|
|
2916
|
+
title: "Create Mailbox App Password",
|
|
2917
|
+
description: "Create a revocable mailbox credential for an email client. The secret is returned exactly once in this tool result, so only call after explicit operator approval and store it securely.",
|
|
2918
|
+
inputSchema: createMailboxAppPasswordInputSchema,
|
|
2919
|
+
outputSchema: createdMailboxAppPasswordOutputSchema,
|
|
2920
|
+
annotations: {
|
|
2921
|
+
readOnlyHint: false,
|
|
2922
|
+
destructiveHint: true,
|
|
2923
|
+
idempotentHint: false,
|
|
2924
|
+
openWorldHint: false
|
|
2925
|
+
}
|
|
2926
|
+
},
|
|
2927
|
+
async (args) => runTool(
|
|
2928
|
+
"shipmail_create_mailbox_app_password",
|
|
2929
|
+
createdMailboxAppPasswordOutputSchema,
|
|
2930
|
+
async () => ({
|
|
2931
|
+
app_password: await client.mailboxes.createAppPassword(args.id, {
|
|
2932
|
+
name: args.name,
|
|
2933
|
+
...args.expires_at ? { expires_at: args.expires_at } : {},
|
|
2934
|
+
...args.allowed_cidrs ? { allowed_cidrs: args.allowed_cidrs } : {}
|
|
2935
|
+
})
|
|
2936
|
+
})
|
|
2937
|
+
)
|
|
2938
|
+
);
|
|
2939
|
+
});
|
|
2940
|
+
registerIfAllowed("shipmail_revoke_mailbox_app_password", () => {
|
|
2941
|
+
server.registerTool(
|
|
2942
|
+
"shipmail_revoke_mailbox_app_password",
|
|
2943
|
+
{
|
|
2944
|
+
title: "Revoke Mailbox App Password",
|
|
2945
|
+
description: "Permanently revoke one mailbox app password. The associated client will lose access immediately.",
|
|
2946
|
+
inputSchema: revokeMailboxAppPasswordInputSchema,
|
|
2947
|
+
outputSchema: acknowledgmentOutputSchema,
|
|
2948
|
+
annotations: {
|
|
2949
|
+
readOnlyHint: false,
|
|
2950
|
+
destructiveHint: true,
|
|
2951
|
+
idempotentHint: true,
|
|
2952
|
+
openWorldHint: false
|
|
2953
|
+
}
|
|
2954
|
+
},
|
|
2955
|
+
async ({ id, app_password_id }) => runTool("shipmail_revoke_mailbox_app_password", acknowledgmentOutputSchema, async () => {
|
|
2956
|
+
await client.mailboxes.revokeAppPassword(id, app_password_id);
|
|
2957
|
+
return { result: { ok: true, id: app_password_id } };
|
|
2958
|
+
})
|
|
2959
|
+
);
|
|
2960
|
+
});
|
|
2808
2961
|
registerIfAllowed("shipmail_suspend_mailbox", () => {
|
|
2809
2962
|
server.registerTool(
|
|
2810
2963
|
"shipmail_suspend_mailbox",
|
|
@@ -2920,7 +3073,7 @@ function registerTools(server, client, selectedTools) {
|
|
|
2920
3073
|
"shipmail_create_mailbox_import",
|
|
2921
3074
|
{
|
|
2922
3075
|
title: "Import a Mailbox",
|
|
2923
|
-
description: "Start importing mail from another provider into a shipmail mailbox over IMAP. Use an app password for the source account. Outlook sources require the dashboard's Sign in with Microsoft and cannot be started here. The import runs in the background; poll shipmail_get_mailbox_import for progress.",
|
|
3076
|
+
description: "Start importing mail from another provider into a shipmail mailbox over IMAP. Use an app or device password for the source account. Outlook sources require the dashboard's Sign in with Microsoft and cannot be started here. The import runs in the background; poll shipmail_get_mailbox_import for progress.",
|
|
2924
3077
|
inputSchema: createMailboxImportInputSchema,
|
|
2925
3078
|
outputSchema: importOutputSchema,
|
|
2926
3079
|
annotations: {
|
|
@@ -4819,6 +4972,50 @@ function registerTools(server, client, selectedTools) {
|
|
|
4819
4972
|
);
|
|
4820
4973
|
});
|
|
4821
4974
|
}
|
|
4975
|
+
registerIfAllowed("shipmail_consume_partner_mailbox_credential_grant", () => {
|
|
4976
|
+
server.registerTool(
|
|
4977
|
+
"shipmail_consume_partner_mailbox_credential_grant",
|
|
4978
|
+
{
|
|
4979
|
+
title: "Consume Partner Mailbox Credential Grant",
|
|
4980
|
+
description: "Consume an operator-approved, single-use grant and issue an embedded-webmail credential. The secret is returned exactly once and the operator is notified. Call only after explicit partner approval.",
|
|
4981
|
+
inputSchema: consumePartnerMailboxCredentialGrantInputSchema,
|
|
4982
|
+
outputSchema: partnerMailboxCredentialOutputSchema,
|
|
4983
|
+
annotations: {
|
|
4984
|
+
readOnlyHint: false,
|
|
4985
|
+
destructiveHint: true,
|
|
4986
|
+
idempotentHint: false,
|
|
4987
|
+
openWorldHint: true
|
|
4988
|
+
}
|
|
4989
|
+
},
|
|
4990
|
+
async (args) => runTool(
|
|
4991
|
+
"shipmail_consume_partner_mailbox_credential_grant",
|
|
4992
|
+
partnerMailboxCredentialOutputSchema,
|
|
4993
|
+
async () => ({
|
|
4994
|
+
credential: await client.partner.consumeMailboxCredentialGrant(args.grant_id, {
|
|
4995
|
+
...args.name ? { name: args.name } : {},
|
|
4996
|
+
...args.expires_at ? { expires_at: args.expires_at } : {},
|
|
4997
|
+
...args.allowed_cidrs ? { allowed_cidrs: args.allowed_cidrs } : {}
|
|
4998
|
+
})
|
|
4999
|
+
})
|
|
5000
|
+
)
|
|
5001
|
+
);
|
|
5002
|
+
});
|
|
5003
|
+
registerIfAllowed("shipmail_list_partner_mailbox_credential_grants", () => {
|
|
5004
|
+
server.registerTool(
|
|
5005
|
+
"shipmail_list_partner_mailbox_credential_grants",
|
|
5006
|
+
{
|
|
5007
|
+
title: "List Partner Mailbox Credential Grants",
|
|
5008
|
+
description: "List active ten-minute mailbox approvals created by operator owners. Grant metadata contains no app-password secret.",
|
|
5009
|
+
outputSchema: partnerMailboxCredentialGrantsOutputSchema,
|
|
5010
|
+
annotations: { readOnlyHint: true, openWorldHint: false }
|
|
5011
|
+
},
|
|
5012
|
+
async () => runTool(
|
|
5013
|
+
"shipmail_list_partner_mailbox_credential_grants",
|
|
5014
|
+
partnerMailboxCredentialGrantsOutputSchema,
|
|
5015
|
+
async () => ({ grants: await client.partner.listMailboxCredentialGrants() })
|
|
5016
|
+
)
|
|
5017
|
+
);
|
|
5018
|
+
});
|
|
4822
5019
|
registerIfAllowed("shipmail_get_partner_usage", () => {
|
|
4823
5020
|
server.registerTool(
|
|
4824
5021
|
"shipmail_get_partner_usage",
|
|
@@ -4843,7 +5040,7 @@ function registerTools(server, client, selectedTools) {
|
|
|
4843
5040
|
}
|
|
4844
5041
|
|
|
4845
5042
|
// src/version.ts
|
|
4846
|
-
var VERSION = "0.
|
|
5043
|
+
var VERSION = "0.3.1";
|
|
4847
5044
|
|
|
4848
5045
|
// src/server.ts
|
|
4849
5046
|
var INSTRUCTIONS = `ShipMail MCP exposes business email tools for domains, mailboxes, messages, threads, webhooks, and suppressions.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "shipmail-mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.1",
|
|
4
4
|
"mcpName": "io.github.jcoulaud/shipmail-mcp",
|
|
5
5
|
"description": "Official Model Context Protocol (MCP) server for Shipmail, a business email provider with REST API, webhooks, and custom-domain inboxes for AI agents.",
|
|
6
6
|
"type": "module",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
61
|
"@modelcontextprotocol/sdk": "1.29.0",
|
|
62
|
-
"shipmail": "0.1
|
|
62
|
+
"shipmail": "0.2.1",
|
|
63
63
|
"zod": "4.4.3"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
package/server.json
CHANGED
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
"url": "https://github.com/jcoulaud/shipmail-mcp",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
|
-
"version": "0.
|
|
9
|
+
"version": "0.3.1",
|
|
10
10
|
"websiteUrl": "https://shipmail.to/docs/mcp",
|
|
11
11
|
"packages": [
|
|
12
12
|
{
|
|
13
13
|
"registryType": "npm",
|
|
14
14
|
"registryBaseUrl": "https://registry.npmjs.org",
|
|
15
15
|
"identifier": "shipmail-mcp",
|
|
16
|
-
"version": "0.
|
|
16
|
+
"version": "0.3.1",
|
|
17
17
|
"transport": {
|
|
18
18
|
"type": "stdio"
|
|
19
19
|
},
|
package/smithery.yaml
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Smithery configuration file: https://smithery.ai/docs/build/project-config/smithery-yaml
|
|
2
2
|
name: shipmail-mcp
|
|
3
|
-
version: 0.
|
|
3
|
+
version: 0.3.1
|
|
4
4
|
description: Official Shipmail MCP server for AI-agent custom-domain business email inboxes with REST API and webhooks.
|
|
5
5
|
author: ShipMail
|
|
6
6
|
repository: https://github.com/jcoulaud/shipmail-mcp
|