eo-magazine-mcp

v0.4.2
@eo-studio-dev/eo-magazine-mcp Checked 1 day ago Published 12 days ago

EO Magazine article drafting and explicit publishing MCP server

Bulk Korean translation tools are documented in docs/development/magazine-bulk-translation-mcp.md. The batch defaults to PRD, supports explicit DEV and isolated loopback targets, uses the backend's durable ten-worker queue, and separates draft readiness from explicit version-bound batch publication and post-publication refresh. Korean translations inherit the original English slug: /article/name and /ko/article/name. Neither the server nor MCP translates or reserves a separate slug. Historical Korean addresses remain aliases.

Summary extracted from the README.

@eo-studio-dev/eo-magazine-mcp

Bulk Korean translation tools are documented in docs/development/magazine-bulk-translation-mcp.md. The batch defaults to PRD, supports explicit DEV and isolated loopback targets, uses the backend's durable ten-worker queue, and separates draft readiness from explicit version-bound batch publication and post-publication refresh.

Korean translations inherit the original English slug: /article/name and /ko/article/name. Neither the server nor MCP translates or reserves a separate slug. Historical Korean addresses remain aliases. This requires the matching server implementation of inherited translation settings; completion/publication fail closed on an older server. Source-address changes require a newly reviewed batch token. Start a new batch after upgrading older private batch journals.

Installing this package updates the MCP client only. Bulk translation requires the matching generation, publication, batch-status and recommendation APIs plus the frontend cache-refresh route in the selected environment. For DEV use, ask explicitly for DEV; batches default to PRD and retain their initial environment. PRD use becomes available after the corresponding service changes are released. Keep separate authorized sessions for each environment. Protected DEV frontend refreshes also require the user's valid DEV site session.

MCP server for EO Magazine editors to find articles, create and edit drafts in the existing editor-block format, inspect publication readiness, and explicitly publish a specific draft.

It uses an authenticated EO Magazine editor session and existing editorial APIs. It supports manual-caption YouTube imports, publishing metadata, image/PDF uploads, credits, custom slugs, reviewed transcript PDFs and explicitly confirmed scheduled publication. The server supplies editorial workflow instructions during MCP initialization; the Codex/Claude client presents questions and previews.

Install or update

Use Node.js 20.9 or later. Image conversion uses Sharp's platform-specific prebuilt binaries; keep npm's optional dependencies enabled when installing. Node.js 24 was verified with version 0.4.0. Editors do not need this repository or a local build: register the published package in your MCP client.

For clients with JSON MCP configuration:

{
  "mcpServers": {
    "eo-magazine": {
      "command": "npx",
      "args": ["-y", "@eo-studio-dev/eo-magazine-mcp@latest"]
    }
  }
}

If eo-magazine already exists, update that entry instead of adding a duplicate. Preserve its environment, private login caches and other MCP servers. The default Magazine and Veda endpoints are production; keep DEV/test aliases separate.

To update an npx installation, use the @latest selector and restart/reconnect the MCP so a new process resolves the current published version. An already running process does not update itself. A pinned selector such as @0.2.0 stays on that version until you change it. For a globally installed executable, run npm install -g @eo-studio-dev/eo-magazine-mcp@latest before reconnecting. Confirm the version of the process actually started, rather than only checking npm's latest version. Updating the package does not invalidate a valid login cache.

Company Chrome setup prompt

Copy this prompt into Codex or Claude Code on the computer running the MCP. It covers installation/update, discovery of your own company Chrome profile, Veda authentication, local session storage and verification after reconnecting. Pasting it authorizes only the Veda application-session import described below; it does not authorize exporting your browser profile or other credentials.

Set up or update @eo-studio-dev/eo-magazine-mcp for production use on this computer.
Complete the setup and verify actual MCP reads; do not stop after editing config.

For this setup, I permit importing ONLY my production Veda application cookie
named veda-token from my own company Chrome session into a private local cache,
and sending it only to https://api.veda25.net for Veda authentication. Never show
its value in chat, logs, screenshots, repository files or MCP configuration.
Do not export all cookies or copy a Chrome profile. Preserve my separate Magazine
session, other MCP servers and DEV/test aliases.

1. Inspect the current operating system, Node/npm installation, existing MCP
   entry and installed/published versions. Register or update eo-magazine with
   npx -y @eo-studio-dev/eo-magazine-mcp@latest. Keep optional npm dependencies
   enabled for Sharp. Explain the update procedure if an existing installation
   is pinned to a version or uses a globally installed executable.

2. Verify these production endpoints:
   EO_MAGAZINE_API_URL=https://api.eomag.io
   EO_MAGAZINE_LOGIN_URL=https://www.eomag.io
   EO_MAGAZINE_EDITOR_URL=https://www.eomag.io
   VEDA_API_URL=https://api.veda25.net
   VEDA_LOGIN_URL=https://www.veda25.net
   Reuse valid Magazine access/refresh credentials. Magazine and Veda sessions
   are separate; do not use Magazine credentials to authorize Veda.

3. Check VEDA_TOKEN_FILE and the supported existing Veda cache first. Reuse only
   a current-user-owned, private, origin-matching session valid for more than
   the next 60 seconds. Do not require login just because the package updated.

4. If no usable Veda session exists, inspect Chrome profile metadata to find my
   @eoeoeo.net account. On macOS, use the relevant profile metadata in
   ~/Library/Application Support/Google/Chrome/Local State. On other systems,
   locate the equivalent Chrome metadata. Do not read browser cookie databases.
   Do not assume a profile directory, display name or another person's path.
   If multiple company accounts are available, ask which one to use. Reuse that
   profile's window/tab, or open that existing profile through Chrome's selector.

5. Open https://www.veda25.net in that same company Chrome profile. Reuse its
   valid Veda login, otherwise use normal Google sign-in with the selected
   @eoeoeo.net account. I will complete passwords, MFA or device authentication
   when required. Do not open Chrome for Testing, an empty automation profile
   or a separate Playwright login window. If your browser tool cannot attach to
   the existing company profile, explain that exact limitation and ask only for
   the user action needed to continue. Chrome login is not automatically shared
   with the MCP, and this prompt does not add browser-control capabilities.

6. Through a supported, authorized browser/UI mechanism, import only veda-token
   without printing it. Do not bypass browser security warnings, install a broad
   cookie-export extension or extract Google credentials. Save a current-user-
   owned regular file, not a symlink, with mode 0600 and a 0700 parent directory.
   If this environment cannot satisfy the MCP's private-file checks, report the
   limitation instead of weakening them. Resolve the absolute path on this
   computer; do not put a literal ~ in an MCP env value.
   A suitable path is ~/.eo-magazine-mcp/veda-www.veda25.net/session.json, resolved
   to the current user's home. Its JSON is:
   {"origin":"https://www.veda25.net","api_origin":"https://api.veda25.net","token":"<locally imported veda-token>"}
   Populate the real token privately, never by asking me to paste it into chat.
   Verify the actual logged-in origin. Do not add refresh_token: Veda has no
   refresh-token API.

7. Configure this eo-magazine entry with the production Veda URLs above and:
   VEDA_TOKEN_FILE=<resolved absolute path to that private cache>
   VEDA_ALLOW_BROWSER_LOGIN=false
   Check for conflicting VEDA_API_KEY or VEDA_API_TOKEN overrides: an API key
   bypasses session authentication, and a static token takes precedence over
   the cache. Remove obsolete overrides from this entry without displaying them.
   Preserve unrelated credentials. Do not change Magazine authentication options
   solely to fix Veda. If Magazine authentication also needs a new session import,
   explain that separate need and request only the necessary scoped permission.

8. After package or environment changes, restart/reconnect the MCP. If this chat
   still uses the old process or tool schema, give the exact client-specific
   reconnect/restart step and tell me to open a new session when needed. Do not
   claim the setup is verified until the new MCP process has been checked.
   Replacing only the token-file contents does not intrinsically require a
   restart: the MCP rereads that file on requests.

9. Verify the fresh MCP process's actual version and tool list. Check Magazine
   with eo_magazine_auth, eo_magazine_list_categories, eo_magazine_list_topics
   and eo_magazine_list_articles with {"offset":0,"limit":1,"is_deleted":false}.
   Check Veda with eo_magazine_get_video_transcript and
   eo_magazine_get_youtube_chapters with the video argument set to my YouTube
   URL, or https://www.youtube.com/watch?v=LQy2FTnwiLk. Confirm English captions
   and verified chapter results. Distinguish missing source files from rejected
   authentication; do not substitute another language. A Google login alone
   is not API verification.
   Do not create, edit, upload or publish real CMS content during setup.

10. Report the selected company account/profile, actual MCP version, production
    endpoints, private cache path, read-only results and any remaining reconnect
    action. Never report the token. If Veda expires or rejects its session,
    establish a fresh Veda login in the same company Chrome profile and repeat
    the approved import. Do not promise automatic Veda refresh. Caption reads
    need no AWS keys, separate Veda MCP, yt-dlp or ffmpeg.

After changing the package or environment, reconnect/restart the MCP in your client. In Codex, open a new session if the current one retains the old tools; in Claude Code, restart the session or use the client's MCP reconnect control. Then paste this read-only check into the fresh session:

Use the production eo-magazine MCP. Check Magazine authentication, categories,
topics and one article-list result. Read the English transcript and chapters for
https://www.youtube.com/watch?v=LQy2FTnwiLk. Report what succeeded and any exact
authentication issue. Do not create, edit, upload or publish CMS content.

Magazine access tokens can renew while their refresh session remains valid. Veda has no refresh-token API: an expired Veda session needs a new Veda login or approved import. Neither service requires a new login solely for a package update. If your assistant cannot securely import the session, it must explain the browser tool limitation rather than asking you to paste credentials into chat.

Persistent transcript document review

Version 0.3.0 adds the persistent transcript document workflow and editorial metadata/retention rules. These endpoints and tools require the matching Veda deployment and Mac mini rollout. Existing 0.2.0 processes keep their loaded code until restarted; reconnect an unpinned/latest MCP entry to load the new package.

Mac mini uses the finalized English SRT, not a translated track or Magazine article body. It registers the original caption revision, builds an EO-format review Markdown and PDF preview using the bundled offline renderer, and saves:

ai/captions/youtube/{video_id}/en/{caption_revision}/documents/
  {document_revision}/transcript.md
  {document_revision}/transcript.pdf
  {document_revision}/manifest.json
  current.json

The immutable manifest binds the video, English caption SHA-256, parent document revision and both content hashes. current.json is updated conditionally only after all three objects exist. Concurrent edits return a conflict. An edit clears previous approval and requires new approval of the edited pair. After successful storage, retention keeps the original MD plus the latest MD/PDF and integrity manifest; all intermediate files and older PDFs are removed. The pointer stores retryable cleanup state, and failed cleanup never deletes the original MD or latest pair. GET is read-only; later saves/approvals retry pending cleanup. Pre-policy history is adopted on the next save. This does not delete original caption sources or separately uploaded CMS attachments. Approval never publishes an article.

The normal MCP flow is:

  1. eo_magazine_get_transcript_document: show full Markdown and the downloaded PDF preview. Review state survives MCP restarts; do not ask the editor to prepare/upload these files. A 404 means Mac mini generation is pending.
  2. eo_magazine_revise_transcript_document: provide video, the displayed expected_document_revision, and requested complete markdown and/or confirmed metadata: {subtitle, article_url}. Previews report missing_metadata: reuse confirmed article context or ask only for missing/unconfirmed values. Metadata-only revisions preserve the body. The shared renderer creates a new clickable PDF, then Veda saves the new MD/PDF revision.
  3. eo_magazine_approve_transcript_document: after explicit human review of both previews, supply document_revision, markdown_sha256, pdf_sha256 and confirm: true. A confirmed interview subtitle and one Magazine article URL are required; provisional previews cannot be approved or attached.
  4. eo_magazine_attach_archived_transcript_pdf: supply video, the approved document_revision, article_id and latest expected_updated_at. Only the latest approved pair can attach. Show the CMS preview and obtain separate publication authorization.

Omit transcript_document when creating a normal YouTube article. Its returned archive preview is independent of the article's headline, prose and future URL. Automatic first drafts use a neutral Video transcript subtitle when confirmed guests are unavailable; they never invent names or an article URL. Verified chapter titles come from the captured original YouTube description. Explicitly marked sponsor/ad chapter intervals are omitted from MD/PDF using cue start times; interview boundary words, product discussions and unknown speakers remain intact. Unmarked advertising needs a verified editorial revision, not a guess. Explicit legacy local-PDF tools remain available for separately requested manual flows. MCP clients use authenticated Veda APIs and need no AWS keys.

eo-magazine-transcript-document is an offline executable bundled with the package. It reads a JSON object containing video, title, the original description, optional verified published_at, and English srt from stdin; it returns markdown and pdf_base64. It neither uploads nor approves anything. When Scribe's original word-level speaker IDs are available, Mac mini aligns them to the exact English SRT and automatically resolves real names using the captured video metadata and each speaker's own speech. Grounded names appear directly in MD and PDF; source-bound mappings are cached for retries. Unsupported identities remain numbered labels, and Whisper's synthetic speaker ID is never treated as voice diarization. The optional offline input diarization contains the exact source_sha256, cue_speaker_ids, and speakers: [{speaker_id, name}]. The renderer rejects a different source hash, cue count or unknown identity. Speaker changes start new paragraphs. Name corrections use the normal revise/review/approve flow; there is no routine request for editors to provide all names.

Mac mini and MCP revisions use the same PDF renderer and EO typography. The existing Helvetica glyph and Markdown-format limits still apply; rendering failures remain pending document jobs rather than being silently simplified.

Authentication reference

Dedicated-profile login

The package's built-in login uses its own persistent browser profile. This is a separate option from the company Chrome import above; the MCP itself does not discover or attach to your regular Chrome profile.

The MCP uses https://api.eomag.io and https://www.eomag.io by default. On the first protected tool call, it opens a browser only if its persistent EO Magazine profile has no valid session. Complete the normal EO Magazine/Google sign-in there once. The MCP saves the same-origin application access and refresh tokens in a private session file and renews the access token through POST /auth/refresh-token when it has at most 60 seconds left. Concurrent calls and MCP processes sharing that file serialize renewal and reuse the resulting session. Run npx playwright@1.65.0 install chromium once if Playwright has no browser installed.

Windows and Claude Desktop

Version 0.4.2 fixes repeated authentication failures on Windows. The cache uses Windows filesystem security rather than POSIX mode bits, which Node reports as 666 even for files created with mode 600. Keep the default cache under your own user profile, or choose an equally private directory with a Windows ACL limited to your account and system administrators. Do not put token files in shared or network folders. Symbolic-link caches are rejected on every platform. macOS and Linux still require current-user ownership and private mode 600.

On Windows, dedicated login first uses installed Google Chrome. Set EO_MAGAZINE_BROWSER_CHANNEL=chrome or msedge to select a browser explicitly; VEDA_BROWSER_CHANNEL selects the separate Veda login browser. This launches the MCP's dedicated profile, not an existing company Chrome session. Keep browser login disabled when your setup uses the company-session import above. If default Chrome is absent, the MCP tries bundled Chromium. Playwright is pinned to an exact version so the browser revision does not change between installs.

Claude Desktop can redirect %LOCALAPPDATA% into its sandbox, preventing bundled Chromium from starting (spawn UNKNOWN or a side-by-side configuration error). Installed Chrome avoids that bundled-browser location. If you need bundled Chromium, install it outside AppData with the matching package version. In PowerShell:

$env:PLAYWRIGHT_BROWSERS_PATH = "$env:USERPROFILE\.eo-magazine-mcp\browsers"
npx playwright@1.65.0 install chromium

Set the same PLAYWRIGHT_BROWSERS_PATH absolute path in the MCP entry's env before restarting Claude Desktop. If Windows Security blocks a browser, inspect Protection history and verify the browser's source with your IT administrator; do not disable Defender. The reported machine had one Defender browser detection. Browser/API errors now report safe cause codes on stderr and preserve their original exception causes without logging tokens or Authorization headers.

Token environment variables

EO_MAGAZINE_API_TOKEN authenticates Magazine article tools. VEDA_API_TOKEN authenticates only Veda transcript/chapter tools and is never used as a Magazine token. Both are static overrides; an expired override must be removed or replaced. For renewable Magazine sessions use EO_MAGAZINE_TOKEN_FILE with access and refresh tokens; VEDA_TOKEN_FILE holds a separate Veda access-only session. Setting a Veda token alone does not sign in to Magazine.

Magazine session configuration

The MCP deliberately does not copy cookies from a person's regular Chrome profile. Browser profiles are OS-protected and copying them would expose a broader signed-in session. Set EO_MAGAZINE_PROFILE_DIR to choose the dedicated profile location, EO_MAGAZINE_LOGIN_URL to override https://www.eomag.io, or EO_MAGAZINE_API_URL and EO_MAGAZINE_EDITOR_URL for a non-production API/editor. EO_MAGAZINE_API_TOKEN remains an optional non-interactive override for service accounts. Set EO_MAGAZINE_ALLOW_BROWSER_LOGIN=false to disable both silent and visible browser launches; a non-interactive token is then required. A regular Chrome login and its Vercel session are not automatically shared with the MCP. An explicitly approved application-token cache can be supplied with EO_MAGAZINE_TOKEN_FILE: a private, current-user-owned JSON file (mode 600):

{
  "origin": "https://www.eomag.io",
  "api_origin": "https://api.eomag.io",
  "token": "<application access token>",
  "refresh_token": "<application refresh token>"
}

Both origins must match the configured login and API origins. The MCP rereads the file on every call and atomically saves renewed credentials with mode 600. Its default dedicated-profile cache is <EO_MAGAZINE_PROFILE_DIR>/session.json. Legacy access-token-only caches still work until that token expires; they need a one-time approved session import including the refresh token. The website stores at in a cookie and rt in same-origin local storage, so a cookie-only export is insufficient. The MCP does not extract sessions from regular Chrome.

API renewal is bounded and browser-free. Network/server failures preserve the refresh session for retry. Rejected or expired refresh credentials require one new login/import: a dedicated browser may open only when browser login is enabled; with it disabled, the MCP requests an approved session import. Access renewal does not extend the refresh credential's lifetime. EO_MAGAZINE_API_TOKEN is a static override and is not auto-renewed.

For a ready-to-copy Codex or Claude Code setup and the editorial workflow, see the shared agent guide.

Safe editorial flow

Metadata completion applies to original articles and supplied manuscripts as well as YouTube drafts. A body save is not the end of registration: inspect metadata_status, call eo_magazine_prepare_article_metadata, derive missing subtitle/category/topics/OG description from the manuscript and real taxonomy, then save through eo_magazine_complete_article_metadata. The client model authors these values; the MCP validates and persists them without rewriting the body. Valid existing values are preserved. Publication rejects missing metadata.

For verified person/company links, provide verified_entities with user-supplied URLs or client-inspected web identity evidence. People link to LinkedIn /in/ profiles and companies to their official HTTPS homepage. The MCP validates the URL/evidence contract; semantic identity checks remain client-attested. It never guesses a profile or domain. YouTube creation links the first interview-body mention automatically. Supplied manuscript drafts use eo_magazine_apply_article_entity_links to preview and save that exact reviewed version, preserving authored anchors, wording and formatting. Unresolved entities stay plain text.

For explicitly supplied links, a registry entry looks like:

{
  "kind": "person",
  "name": "Navin Chaddha",
  "url": "https://www.linkedin.com/in/navinchaddha/",
  "verification": {
    "method": "user_provided",
    "source_excerpt": "[Navin Chaddha](https://www.linkedin.com/in/navinchaddha/)"
  }
}

Use kind: "company" with the supplied official homepage for a company. For a web-inspected destination, use method: "web_verified", evidence_url and an evidence_excerpt identifying that entity. A missing or contradictory evidence contract is rejected; the client must actually inspect the source before making that attestation. The server performs no arbitrary outbound website requests.

For an original article, request the user's manuscript or source material and thumbnail file/path when missing. For a requested video-based article, a YouTube link is enough to start: use the interview flow without demanding a prewritten manuscript. Request missing photos/thumbnail separately. Review the manuscript, suggest metadata from that content, and ask only for missing information. Draft the OG description after the manuscript exists; propose credit order and primary credit for confirmation. Save supported fields, return the CMS preview, then ask whether and when to publish. The server does not initiate a conversation or generate prose: these steps are instructions consumed by the MCP client.

Use the category/topic lookup tools to choose existing CMS taxonomy. Save the category through update_draft.category_id and topics through set_article_topics; a browser is not needed for those fields. Funded-company automation remains unavailable and must be reported accurately. For a YouTube link without a manuscript, use the source-backed interview flow below. The client model writes the prose from verified captions; transcript-PDF review remains separate from the article body.

  1. Call eo_magazine_create_draft with a unique idempotency_key and editor blocks such as [{"type":"text","content":"Hello"}]. Missing IDs are allocated once and returned in article.content.
  2. Open the returned editor_url in the CMS, or use eo_magazine_get_article.
  3. Copy updated_at into eo_magazine_update_draft.expected_updated_at for every edit. This preserves omitted fields and rejects stale writes.
  4. Call eo_magazine_article_status to check readiness.
  5. Call eo_magazine_publish_article only for the target article, with its latest updated_at and confirm: true.

Creating or updating a draft never publishes it. Publishing is a separate, version-checked action. A repeated create key is deduplicated for the life of a running MCP process; callers should retain that key when retrying a request.

Block identity and translation

Generic draft tools assign a random nine-character lowercase alphanumeric ID (such as a7k2m9q4x) only when a new block omits id, matching the CMS editor's format. Randomness comes from Node crypto; collisions are retried against IDs in the document. Newly compiled YouTube articles and legacy SRT imports use the same nine-character format for every block and structured list item. Their IDs derive from the source/request namespace and an internal role, keeping repeated creation and photo references consistent; those roles are not embedded in the saved ID. Only new blocks use this format. Supplied IDs, including older YouTube IDs, are opaque and remain unchanged. Generated IDs are retained for retries using the same creation key within one MCP process. Read back saved content before subsequent edits; never derive an ID from text, language, type or current order.

Blank or duplicate IDs are rejected across the document, native children and structured list-item JSON. Metadata/person/action IDs are not block identities. Updates retain IDs for edits, reordering and moves. Replacing every old identity in a nonempty document or nested container requires replace_block_ids: true; normal deletion, including clearing a container, is allowed. This is a targeted accidental-replacement guard, not a semantic comparison of every edited block. Guest profile updates preserve IDs for uniquely matching names.

For a translated article, copy source block and structured list-item IDs and translate their text. The same IDs can occur in separate language documents; uniqueness is per document. Future translation synchronization should identify a block by source article, source revision and block ID, with a separate content fingerprint to detect stale translations. This change does not add translation storage or synchronization. Legacy HTML/plain-text lists have no saved item IDs; use structured list JSON when item-level correspondence is needed.

Admin reads return the working revision. Edits to an already-published article remain private until publish_article promotes that exact version through POST /article/{id}/publish. Publication uses confirmed: true and the working expected_updated_at token; generic PATCH cannot publish. On a conflict or an ambiguous network failure, read the article again and review its status before deciding whether to publish. Never automatically publish a newer revision. An optional publication date is first staged with a version-checked PATCH; the subsequent confirmed POST promotes that returned revision. A failure between these requests leaves the requested date private.

Publishing fields and tools

create_draft and update_draft accept thumbnail_image_url, open_graph_image_url, open_graph_description, og_logo_url, category_id, theme_id, is_open_access, guests, and transcript_pdf, in addition to the existing title, subtitle, language and blocks. Nullable image/OG fields can be cleared with null. Omitted fields are preserved.

  • guests replaces profile blocks with {name, title?, company?, image?, description?} entries. An empty array removes the profiles.
  • transcript_pdf: {url, file_name} sets the first transcript download button; null clears it. Other body blocks and secondary buttons remain. The server derives article-level guest and PDF fields from these native editor blocks.
  • eo_magazine_upload_asset takes article_id, expected_updated_at, an absolute file_path, purpose (thumbnail, open_graph, transcript_pdf) and content_type (image/jpeg, image/png, image/webp, application/pdf). It checks file signatures, uploads through the existing signed POST, then attaches the result with a version check. The limit is 20 MiB. A fresh storage key avoids overwriting an existing asset; a failed final version check can leave an unattached uploaded object. Storage receives no Magazine token.
  • eo_magazine_prepare_og_image converts a thumbnail on the MCP host into a separate 1200×630 PNG for the social-share background. It works locally without authentication or CMS changes. See the review and upload flow below.
  • eo_magazine_set_slugs replaces the complete slugs array. Include aliases that should remain. It requires article_id and expected_updated_at.
  • eo_magazine_list_categories reads existing categories from the Magazine API. Save the selected ID with eo_magazine_update_draft.category_id.
  • eo_magazine_list_topics reads existing topics, optionally filtered by keyword. eo_magazine_set_article_topics saves the complete tag_ids selection with article_id and the latest expected_updated_at. Include existing topics that should remain; an explicit empty array clears them. Unknown IDs are rejected, and this tool does not create new topics. It uses the article working-revision PATCH, not the deprecated tags endpoint, and preserves article prose and other metadata. Read back the saved revision.
  • eo_magazine_set_article_dates sets interviewed_at (YYYY-MM-DD, the day EO interviewed the guest) and youtube_published_at (RFC3339) with article_id and expected_updated_at. It saves the working revision even for published articles; explicit publication makes the dates public. null clears a date, an omitted date is left unchanged, and neither the publication date nor the content is touched. Both dates are also accepted by create_draft and update_draft, and returned by get_article.
  • eo_magazine_list_credits reads contributor IDs and current credits. eo_magazine_set_credit adds or updates one contributor_hid, role, and order, with article_id and expected_updated_at. Use EDITOR for editors and distinct order values; the lowest order across all roles determines primary_credit. Contributor accounts must already exist. Ask for missing people and roles, propose the display order and primary credit, and confirm the proposal with the human before saving. Do not require the human to assign numeric order values. Retain existing credits unless asked to edit them.
  • eo_magazine_publish_article accepts optional RFC3339 published_at. A future date schedules publication, a past date backdates it, and omission publishes a new article now or preserves an existing publication date. confirm: true and the latest working version remain mandatory. Scheduled and published articles can be edited through draft tools.
  • eo_magazine_list_articles sends is_deleted=false by default, before pagination. Use is_deleted=true to inspect deleted articles separately.

Article, slug, and credit updates share server-side optimistic locking and the same working revision. Pass the returned version to the next tool call. Changes remain private until explicit publication. Multi-tool workflows are not transactions.

Thumbnail to OG image

Ask for the thumbnail file or its absolute path on the MCP host. Then call:

{
  "file_path": "/Users/editor/Downloads/thumbnail.jpg",
  "fit": "contain"
}

Use eo_magazine_prepare_og_image with these arguments. The default contain preserves the entire image and adds dark (#101010) padding when its aspect ratio differs. Use cover only when a centered crop is desired; it can cut off text or faces. Both modes apply EXIF orientation and produce an opaque 1200×630 PNG without source metadata. The original thumbnail is never overwritten. Accepted inputs are still PNG, JPEG and WebP, up to 20 MiB and 40 million pixels. Animated images, unsupported formats and decoding failures are rejected.

Show the returned file_path to the human for approval. Then read the article's latest updated_at and call eo_magazine_upload_asset with that path, purpose: "open_graph", content_type: "image/png", article_id and expected_updated_at. Upload the original thumbnail separately with purpose: "thumbnail" if needed. Neither conversion nor upload publishes.

Each conversion returns a unique temporary file in the MCP host's system temp directory. It must be previewed and uploaded on that host while it exists; copy it elsewhere if it needs to be retained. A remote MCP file path is not a path on the user's laptop. Conversion resizes the supplied artwork; it does not generate new artwork, choose a logo, or render the CMS's complete share-card overlay.

YouTube interview article with photo requests

  1. Call eo_magazine_prepare_youtube_article with video (URL or ID). It returns the exact English SRT/revision, chapter provenance and the writing prompt from youtube-article-prompt.ts. It creates no draft.
  2. The Codex/Claude client writes an EO-format edited full interview, using only that source. Call eo_magazine_create_youtube_article_draft with its caption revision, unique idempotency key, title/subtitle, Who/What/Traction, teaser, exactly five takeaways, chapter sections, positioned image_requests, and required transcript_document: {guest_names, article_url, published_month}. Collect only missing confirmed metadata; an existing PDF is not required when English captions are available. The server compiles native CMS blocks, rechecks captions, saves a draft and automatically prepares the complete EO transcript review Markdown. Return transcript_review.markdown and its .md path to the human before moving to photos. The workflow remains incomplete until its approved PDF is attached. There is no separate backend model or additional model API key.
  3. Show the returned preview and separate photo-request queue. The article uses normal empty image blocks, exactly {id, type: "image", content: "", metadata: {}}. Keep photo descriptions and file/caption/credit requests outside the body. Request a real image file; automatic video-frame insertion is deferred. Request the thumbnail separately. Reference photos are never copied.
  4. Use eo_magazine_upload_article_image with the article version and stable placeholder_block_id to fill one empty image block. Other prose, images and the transcript PDF remain. Photo descriptions are held only in this running workflow's memory; after restart, unknown descriptions are returned as null and must be confirmed instead of invented. Stale versions fail; a conflict after upload can leave an unattached object, so read again before retrying.
  5. The draft already contains a native button labeled Download full transcript immediately after the YouTube block, followed by the italic interview note. Before PDF generation its download URL is unset. Prepare the independent transcript Markdown/PDF through the approved flow below; attaching the real approved PDF fills that same button in place and changes its style to primary; pending or cleared transcript buttons use secondary. The empty button is an editor placeholder, not a valid PDF attachment, and reader previews hide it until a file is attached.

This article flow preserves the reference structure: At a Glance, teaser, YouTube, transcript button, italic interview note, five Key Takeaways and first-person interview sections. Typed spans permit bold/highlight without arbitrary HTML. It never publishes or schedules. Model fidelity to the source still requires editorial review; the compiler validates structure, not factual equivalence.

YouTube manual-caption import

Use eo_magazine_create_youtube_draft on the host where the existing SRT is available. For the caption runtime described in the EO YouTube Caption Automation Notion page, an English import looks like:

{
  "title": "Interview title",
  "language": "en",
  "idempotency_key": "youtube:REsrgNeuZkU:en",
  "youtube_url": "https://www.youtube.com/watch?v=REsrgNeuZkU",
  "srt_path": "/Users/macmini1/.local/share/eo-caption-runtime/elevenlabs-workspace/captions/REsrgNeuZkU/REsrgNeuZkU.en.srt",
  "guests": [{"name": "Guest name", "company": "Company"}],
  "open_graph_description": "Interview summary"
}

The tool reads the existing manual SRT (up to 5 MiB), validates cues, escapes caption text, and creates a YouTube block plus timestamp-linked transcript paragraphs. It does not run transcription, translation, article rewriting, or PDF generation. Upload an existing transcript PDF and images with upload_asset, then set slugs and credits. It creates an unpublished draft; publication remains an explicit, separately confirmed action.

The current Magazine languages are en, ko, vi, and ja. The other four caption-runtime languages are not accepted by the current Magazine API.

For an automated caller, consume only successfully completed caption outputs, persist the returned article ID separately from caption-cursor.json, and resume later steps using that ID and a fresh updated_at. Same-session retries and concurrent calls share one create operation. Idempotency is not durable across MCP restarts; never blindly retry an ambiguous create after restart. This package does not install or change the Mac mini LaunchAgent. Production activation and any npm release are separate from implementing these tools.

English caption to reviewed transcript PDF

Formatted YouTube draft creation requires confirmed transcript_document metadata and automatically returns full review Markdown and its local file path. It does not ask for an existing PDF when English captions are available. If the draft was saved but content/Markdown preparation failed, the result retains its article ID, incomplete phase and exact recovery action; do not create another draft blindly. Retries preserve the current review instead of resetting edits.

eo_magazine_youtube_transcript_status reports required review/approval/attachment phases. A completed attachment persists video, English-caption revision, Markdown/PDF hashes and uploaded asset URL in native PDF-block metadata, allowing source-matched attachment status after restart. Removed/replaced PDFs, changed video or captions are incomplete; article title/body edits remain independent. An older PDF without this provenance is reported as unverified. Publication readiness rejects a YouTube article without an actual PDF download action. This does not make a client follow a conversation or prove approval outside the confirmed tool calls; generic editing remains separate from the formatted flow.

This workflow uses Veda's company-authenticated caption catalog and download API for s3://veda-backend/ai/captions/youtube/<video-id>/en/<revision>/transcript.srt. When the catalog has no English SRT, the per-video descriptor checks the exact newer flat upload at <video-id>/<video-id>.en.srt. The Veda backend extension in this change must be deployed before that fallback is available. A missing catalog entry is not proof that the S3 caption is absent. The descriptor hashes and validates the flat English bytes; the revision-pinned download rechecks the bytes it returns. Access/network/catalog errors do not trigger substitution. Set VEDA_API_URL/VEDA_LOGIN_URL for a non-production archive, or optionally VEDA_API_TOKEN/VEDA_API_KEY for non-interactive access. Veda access is separate from Magazine authentication and must satisfy the existing company-access rules. The server starts and lists its tools without either service's credentials; Veda authentication is requested only when a caption or chapter tool needs it. Its private, origin-bound session defaults to ~/.eo-magazine-mcp/veda-<login-host>/session.json. Set VEDA_MCP_PROFILE_DIR or VEDA_TOKEN_FILE to override the Veda profile or session file. Magazine session files and refresh credentials are never used for Veda. Veda has no refresh-token API: after its access token expires it requires a Veda login or approved session import. VEDA_ALLOW_BROWSER_LOGIN=false disables that browser login; EO_MAGAZINE_ALLOW_BROWSER_LOGIN=false also disables it as a global no-browser setting. Static Veda tokens/API keys do not renew automatically. Editors do not need AWS keys. Only the exact English SRT is downloaded, up to 5 MiB, with its SHA-256 verified against the resolved revision. There is no translation or transcription fallback.

  1. Create/read the target draft with its matching YouTube embed. Collect the confirmed document title, interview subtitle, guest names, intended article URL and source date. Veda's catalog supplies a video title, not company/person identity. Ask only for missing information; do not invent it.

  2. Call eo_magazine_prepare_transcript_pdf, for example with the following fixture values (replace document metadata with confirmed inputs):

    {
      "video": "LQy2FTnwiLk",
      "article_id": 42,
      "title": "Interview title",
      "subtitle": "An interview with Guest, Founder of Company",
      "guest_names": ["Guest"],
      "article_url": "https://dev.eomag.io/article/confirmed-slug",
      "published_month": "2026-11"
    }
    

    Omit chapters to read the exact S3 sidecar ai/captions/youtube/<video-id>/chapters.json through Veda. The endpoint validates the schema, video identity, description hash and chapter ranges, and returns the raw sidecar SHA-256 as provenance. It falls back to the current official YouTube description only on an actual missing S3 object; malformed data, permission and network errors stop the lookup. eo_magazine_get_youtube_chapters reads that evidence separately. found and successfully verified none are distinct from failures. This requires the new Veda chapter endpoint to be deployed. Only the description fallback needs the existing YouTube API key. Both paths use explicit creator timestamps, rather than YouTube's inferred automatic chapters.

    Supply chapters explicitly only after independent verification. A verified empty list is []; failed/unavailable metadata is not an empty list. Creator titles are retained verbatim as H2, aligned to whole SRT cues at the chapter boundary. All cues remain in spoken order with no timestamps. Initial paragraph grouping is mechanical; no LLM edits or summaries occur. Return/show the complete Markdown and its markdown_sha256. The call creates only a private temporary Markdown file, with no PDF or CMS mutation.

  3. Review for transcript noise and source-confirmed duplicate cold-open material. Preserve substantive content, first-person voice and spoken order. Submit edits to eo_magazine_revise_transcript_pdf with preparation_id, the current markdown_sha256, and full markdown. Confirmed header/source/chapters remain fixed; prepare anew to change metadata. Show the new preview again. Initial caption noise or unsupported glyphs are returned as a review_issue so the client can fix them before rendering. Every saved revision invalidates the previous rendered PDF. No source text is silently discarded.

  4. After the human approves this exact Markdown, call eo_magazine_render_transcript_pdf with its preparation_id, markdown_sha256, and confirm: true. The server rechecks the English caption revision and renders that stored text without rewriting. The Node-native renderer uses US Letter, Helvetica, EO source attribution, divider, footer, page numbers and PDF metadata. It requires no Python installation. Standard Helvetica glyphs are checked explicitly; unsupported characters must be corrected in the visible review. Line wrapping/page count can differ from the older ReportLab renderer while preserving the reviewed content and styling.

  5. Inspect the returned local PDF. Read the target article's latest updated_at, then call eo_magazine_attach_transcript_pdf with preparation_id, markdown_sha256, returned pdf_sha256, expected_updated_at, and confirm: true. This authorization covers attaching the approved transcript to the confirmed article, including replacing its existing transcript button. The server checks the source revision, target video and local PDF integrity, uploads with the existing article-asset flow, and saves the working revision. It returns the editor and preview links. It never publishes.

The PDF is a standalone video transcript. Editing the article title/body does not invalidate it. Changing the reviewed manuscript or English captions requires review/rendering again; a different target video requires a new preparation. Stale article versions fail before upload. A final CMS conflict can leave an unattached storage object, as with the existing asset tool; do not blindly retry.

Reviews/hashes are bound to a running MCP session (maximum 20 preparations). After restart, prepare and show the Markdown again. Local Markdown/PDF files live in a private system temporary directory on the MCP host; copy them if retention is needed. A remote host path is not a path on the editor's laptop. Hashes and confirm: true prevent stale operations; the client remains responsible for obtaining actual human approval before asserting confirmation.

If English SRT is unavailable, ask for a supplied transcript/PDF. The existing local-SRT import and eo_magazine_upload_asset can consume those files; do not silently substitute another language. Confirm the target and use purpose: "transcript_pdf" when attaching a user-supplied PDF.

Verification

npm test

Unit tests use API fixtures. The stdio test starts the actual MCP process and calls it through the SDK against a local HTTP fixture. These checks do not establish live API or CMS acceptance; validate an isolated draft after release.

Magazine MCP npm releases use the manual-only magazine_mcp_publish.yaml workflow from main. It checks the pinned source, tests, preserves the exact tarball as an artifact, publishes that tarball with the existing npm credential, and verifies the registry version. Publication still requires an explicit human request.