Skip to main content
Glama

blogger-mcp

A custom MCP server based on the Google Blogger API v3. It provides tools for MCP hosts like Claude Code / Claude Desktop to list, create, edit, and delete posts on your Blogger blog.

Key Features (MCP Tools)

Tool

Description

list_blogs

List blogs for the authenticated user

get_blog_by_url

Blog URL → Blog ID lookup

list_posts

List blog posts (supports status filter)

get_post

Retrieve a specific post

create_post

Create a new post (save as draft with isDraft=true)

update_post

Update a post (title/content/labels)

delete_post

Permanently delete a post

publish_post

Publish a draft post

revert_post

Revert a published post to draft status

Related MCP server: MCP-Google-Doc

Architecture

Claude Code ──stdio──► blogger-mcp (Node)
                          │
                          ├─ src/index.ts     : MCP server (tools 등록/디스패치)
                          ├─ src/auth.ts      : OAuth 2.0 토큰 로드/저장/갱신
                          └─ src/auth-cli.ts  : 최초 1회 대화형 인증용 CLI
                          │
                          ▼
                  Google Blogger API v3
  • Authentication: OAuth 2.0 (Desktop app). Run npm run auth once to launch a local callback server, receive the token, and save it to ~/.config/blogger-mcp/token.json. It is automatically refreshed using a refresh token thereafter.

  • Scopes: https://www.googleapis.com/auth/blogger

  • Transport: stdio (MCP host launches as a child process)

Quick Start

1. Installation and Build

git clone https://github.com/mech12/blogger-mcp.git
cd blogger-mcp
npm install
npm run build

2. Prepare OAuth Client

Enable Blogger API v3 in the Google Cloud Console, create a Desktop app type OAuth client, and download client_secret.json.

mkdir -p ~/.config/blogger-mcp
cp /path/to/client_secret.json ~/.config/blogger-mcp/client_secret.json

For detailed Google Cloud configuration, refer to Blogger API v3 Authentication Issuance below.

3. Initial Authentication

npm run auth

Open the URL displayed in your browser and grant permission to generate ~/.config/blogger-mcp/token.json.

4. Register with Claude Code

claude mcp add blogger --scope user -- node /absolute/path/to/blogger-mcp/dist/index.js

Or directly in ~/.claude.json:

{
  "mcpServers": {
    "blogger": {
      "command": "node",
      "args": ["/absolute/path/to/blogger-mcp/dist/index.js"]
    }
  }
}

Environment Variables

Variable

Default

Description

BLOGGER_MCP_CRED_DIR

~/.config/blogger-mcp

Credentials directory

BLOGGER_MCP_CLIENT_SECRET

$CRED_DIR/client_secret.json

OAuth client JSON path

Blogger API v3 Authentication Issuance (Summary)

  1. Create a Google Cloud Project — https://console.cloud.google.com/

  2. Enable Blogger API v3 in the API Library

  3. Configure OAuth Consent Screen

    • User Type: External

    • Add Scope: https://www.googleapis.com/auth/blogger

    • Add your Google account as a test user

  4. Credentials → OAuth Client ID

    • Application type: Desktop app

    • Download JSON after creation → ~/.config/blogger-mcp/client_secret.json

  5. Verify Blog ID

    • Use the blogID=... number from the Blogger admin URL or the get_blog_by_url tool.

Detailed project-specific guides are managed in docs/vibe/mcp/blogger-mcp.md of the host project.

Design Notes

  • Stack: TypeScript + Node 18+, @modelcontextprotocol/sdk, googleapis, google-auth-library.

  • Token Storage: ~/.config/blogger-mcp/. Protected by .gitignore.

  • Error Strategy: Tool call failures are automatically wrapped by MCP. If authentication is missing, guide the user with the message No stored token. Run npm run auth first..

  • Expansion Roadmap:

    • Markdown → HTML conversion tool (based on marked)

    • Image upload (Blogger requires bypassing Picasa/Google Photos → future option)

    • Scheduled publishing (setting the published field)

Development

npm run dev       # tsc --watch
npm run build     # dist/ 생성
npm start         # dist/index.js 실행 (MCP stdio 서버)
npm run auth      # OAuth 최초 인증

License

MIT

Available Tools

9 tools
create_postC

Create a new blog post. Content is HTML; labels is a list of tags. isDraft=true saves as draft.

Inputs: blogId (required), title (required), content (required), labels, +1 more.

delete_postC

Delete a post permanently

Inputs: blogId (required), postId (required).

get_blog_by_urlC

Resolve a Blog ID from a blog URL (e.g. https://xxx.blogspot.com)

Inputs: url (required).

get_postC

Fetch a single post

Inputs: blogId (required), postId (required).

list_blogsB

List blogs owned by the authenticated user

Inputs: no named parameters.

list_postsC

List posts of a blog

Inputs: blogId (required), maxResults, status.

publish_postC

Publish a draft post

Inputs: blogId (required), postId (required).

revert_postC

Revert a published post back to draft

Inputs: blogId (required), postId (required).

update_postC

Update an existing post (title/content/labels).

Inputs: blogId (required), postId (required), title, content, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 9 tools

    Disambiguation5/5

    Every tool has a clearly distinct purpose with no ambiguity. Each tool targets a specific resource (blog, post) and action (create, delete, get, list, publish, revert, update), making it easy for an agent to select the correct one. The separation between operations like publish_post and revert_post is particularly clear.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern with snake_case throughout, such as create_post, delete_post, and list_blogs. There are no deviations in naming conventions, making the set predictable and readable for an agent.

    Tool Count5/5

    With 9 tools, this server is well-scoped for managing blogs and posts, covering essential operations without bloat. Each tool earns its place by addressing a specific need in the blogging workflow, from listing blogs to handling post lifecycles.

    Completeness5/5

    The tool surface provides complete CRUD/lifecycle coverage for the blogging domain. It includes create, read (get/list), update, and delete for posts, plus additional lifecycle actions like publish and revert, with no obvious gaps that would cause agent failures.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers