Markdown to Google Docs Enhanced icon

Markdown to Google Docs Enhanced

Transform Markdown content into Google Docs API requests with Google Drive image support

Convert to API Requests

AI-generated

Summary

Convert Markdown content into Google Docs API requests (single batchUpdate or multiple individual requests).

Inputs

  • markdownInput (required) — The Markdown content to convert (string).
  • documentTitle (required) — Title for the Google Docs document (string, default 'Untitled Document').
  • additionalOptions.templateSettings.templateFolderId — Folder containing Google Docs templates (resource locator).
  • additionalOptions.templateSettings.templateDocumentId — Template document to copy (resource locator).
  • additionalOptions.templateSettings.placeholders.placeholderData — JSON object of key‑value pairs for placeholder replacement (default {}).
  • additionalOptions.templateSettings.placeholders.useMarkdownInput — Whether to insert the Markdown Input content (boolean, default true).
  • additionalOptions.templateSettings.placeholders.mainContentPlaceholder — Placeholder text to be replaced by the Markdown content (string, default '{{MainContent}}').
  • additionalOptions.pageBreakSettings.pageBreakStrategy — Page break strategy: 'h1' (before each H1 after first), 'h2' (before each H2), or 'custom' (replace custom text).
  • additionalOptions.pageBreakSettings.customPageBreakText — Custom text replaced with a page break when strategy is 'custom' (string, default '').
  • outputFormat (required) — Choose 'single' for one batchUpdate request or 'multiple' for separate requests (string, default 'single').

Output shape

Returns an object containing:

When outputFormat is 'single', includes documentTitle, createDocumentRequest.title, and batchUpdateRequest.requests. When 'multiple', also includes a requests array with requestId and request objects.

Examples

Example 1: Generate API requests to create a document from Markdown with a template.

Set markdownInput to your markdown, documentTitle to 'Report', enable templateSettings with a template folder and document, set placeholders.placeholderData as needed, choose outputFormat 'single'.

Example 2: Get individual requests for each operation.

Same as above but set outputFormat to 'multiple' to receive an array of requests ready for sequential execution.

Links

Discussion