mirror of
https://github.com/profullstack/logicsrc.git
synced 2026-08-13 14:37:26 +00:00
Mount @logicsrc/plugin-agentmail in the CommandBoard API so members can list/read/search/send mail over the existing agentbbs Mailu server. - src/agentmail.ts: inject imapflow + nodemailer + mailparser drivers into the plugin's Mailu transport (kept out of the plugin by design); env-driven builder (AGENTMAIL_BACKEND=mailu → bbs Mailu, else in-memory singleton for dev/test). Handles STARTTLS cert-vs-loopback via AGENTMAIL_SMTP_TLS_SERVERNAME. - index.ts: register agentMailPlugin + 7 routes under /api/plugins/agentmail/* (mailboxes, list, read, search, send, PATCH flags, delete). Acting member from x-agentmail-member header (else AGENTMAIL_MEMBER), paid-gated; MailAccessError->402, DraftError->422. - 6 route tests (in-memory backend) + contract test plugin-id list updated. commandboard-api 20/20, builds clean. Note: run `npm install` to refresh the lockfile for the 3 new deps. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
35 lines
1.3 KiB
JSON
35 lines
1.3 KiB
JSON
{
|
|
"name": "@logicsrc/commandboard-api",
|
|
"version": "0.1.0",
|
|
"description": "CommandBoard.run REST API reference service.",
|
|
"type": "module",
|
|
"main": "./dist/index.js",
|
|
"scripts": {
|
|
"build": "tsc -p tsconfig.json",
|
|
"dev": "tsx src/index.ts",
|
|
"start": "node dist/index.js",
|
|
"test": "vitest run src",
|
|
"test:contract": "vitest run src/contract.test.ts"
|
|
},
|
|
"dependencies": {
|
|
"@logicsrc/plugin-core": "file:../../packages/plugin-core",
|
|
"@logicsrc/plugin-agentmail": "file:../../plugins/agentmail",
|
|
"@logicsrc/plugin-c0mpute": "file:../../plugins/c0mpute",
|
|
"@logicsrc/plugin-coinpay": "file:../../plugins/coinpay",
|
|
"@logicsrc/plugin-email-accounts": "file:../../plugins/email-accounts",
|
|
"@logicsrc/plugin-feed-discovery": "file:../../plugins/feed-discovery",
|
|
"@logicsrc/plugin-sh1pt": "file:../../plugins/sh1pt",
|
|
"@logicsrc/plugin-social-accounts": "file:../../plugins/social-accounts",
|
|
"@logicsrc/plugin-ugig": "file:../../plugins/ugig",
|
|
"@logicsrc/validators": "file:../../packages/validators",
|
|
"imapflow": "^1.4.3",
|
|
"mailparser": "^3.9.12",
|
|
"nodemailer": "^9.0.1"
|
|
},
|
|
"devDependencies": {
|
|
"@types/mailparser": "^3.4.6",
|
|
"@types/nodemailer": "^8.0.1",
|
|
"tsx": "^4.21.0",
|
|
"vitest": "^4.0.8"
|
|
}
|
|
}
|