md2wechat Agent API markAgent API Docs
md2wechat Agent API markAgent API Docs
Homepage

Start

Markdown to WeChat API DocsQuickstartAuth

APIs

Integrations

Operations

ErrorsPricingContact
X (Twitter)

Cover Image

Every draft needs an explicit cover — flags, checks, generation, and the hero confusion.

Cover Image

Every draft needs a cover

Draft creation requires an explicit cover, in one of two mutually exclusive forms:

md2wechat convert article.md --draft --cover cover.jpg
md2wechat convert article.md --draft --cover-media-id <permanent_media_id>
  • --cover <path> uploads a local image as the cover material.
  • --cover-media-id <media_id> reuses an existing permanent material. URLs are rejected here.

Checks

inspect fails closed on cover problems with stable codes:

  • CONFLICTING_COVER_INPUTS — both --cover and --cover-media-id were given
  • COVER_MEDIA_ID_INVALID — the media id is not a valid permanent material id
  • MISSING_COVER — --draft was requested without any cover

Generate a cover

md2wechat generate_cover --preset cover-default --article article.md

Generation produces and uploads the cover (a WeChat side effect). md2wechat write --cover-only instead returns a style-matched cover prompt for the host agent to render.

Cover vs hero module

  • There is no cover-hero layout module. cover-hero is an image preset for generate_image.
  • The :::hero advanced layout module is the opening card inside the article body — unrelated to the draft cover.
  • The draft cover is submitted as WeChat thumb_media_id, produced by uploadCoverImage → UploadMaterial → media_id.

Pipeline

--cover <path> → upload as material → media_id → attached to draft/add.

Related

  • Image Generation
  • Publishing API
  • Convert

Table of Contents

Cover Image
Every draft needs a cover
Checks
Generate a cover
Cover vs hero module
Pipeline
Related