loading…
Search for a command to run...
loading…
A secure Model Context Protocol server for interacting with Plurk, allowing agents to read account context, post updates, and manage replies. It includes built-
A secure Model Context Protocol server for interacting with Plurk, allowing agents to read account context, post updates, and manage replies. It includes built-in safety guardrails such as daily post limits and reply cooldowns to ensure controlled execution.
plurk-mcp is a guarded Plurk MCP execution layer for OpenClaw.
It is designed for MCP callers that may operate multiple Plurk accounts and gives an agent a narrow, controlled tool surface for:
This repository does not implement editorial strategy, scheduling logic, or campaign decisions. OpenClaw decides what to post and when to post it. plurk-mcp only reads context, executes approved actions, applies safeguards, and records local audit logs.
MCP and debug entrypointsplurk_get_meplurk_get_alertsplurk_get_mentions_contextplurk_get_thread_contextplurk_postplurk_replyThis project is intentionally restrictive.
Allowed in v1:
Not exposed in v1:
>= 22If the package is published to npm:
npm install plurk-mcp
For local verification from this repository:
npm install
npm run build
Run MCP mode:
npx plurk-mcp
Run debug mode:
npx plurk-mcp-debug
You can also use the main binary with the debug subcommand:
npx plurk-mcp debug
Optional:
export PLURK_MCP_TIMEZONE="UTC"
export PLURK_MCP_DAILY_POST_LIMIT="10"
export PLURK_MCP_REPLY_COOLDOWN_MINUTES="15"
export PLURK_MCP_DEBUG_HOST="127.0.0.1"
export PLURK_MCP_DEBUG_PORT="3939"
export PLURK_MCP_DATA_DIR="./data"
Meaning of the optional values:
PLURK_MCP_TIMEZONE
Used for daily quota rollover and audit file partitioning.PLURK_MCP_DAILY_POST_LIMIT
Maximum number of new plurks per local day. Replies do not consume this budget.PLURK_MCP_REPLY_COOLDOWN_MINUTES
Minimum cooldown between automatic replies in the same thread.PLURK_MCP_DEBUG_HOST
Debug server bind host. Defaults to 127.0.0.1.PLURK_MCP_DEBUG_PORT
Debug server port. Must be a positive integer.PLURK_MCP_DATA_DIR
Root directory for audit logs and policy state.Every supported MCP tool now requires a credentials object:
{
"credentials": {
"appKey": "your-app-key",
"appSecret": "your-app-secret",
"accessToken": "your-access-token",
"accessTokenSecret": "your-access-token-secret"
}
}
This is a breaking change from the original env-bound single-account model.
plurk_get_meReturns the authenticated account profile for the credentials supplied in this call.
plurk_get_alertsReturns recent normalized alerts for the credentials supplied in this call.
plurk_get_mentions_contextReturns recent mention-driven interactions suitable for summarization or reply planning for the credentials supplied in this call.
plurk_get_thread_contextReturns the parent plurk plus normalized replies for a specific thread using the credentials supplied in this call.
plurk_postCreates a new plurk and consumes the daily new-post quota for the authenticated account tied to the supplied credentials.
plurk_replyCreates a reply only when:
Replies outside that boundary are rejected before the server calls Plurk.
The server enforces these rules regardless of what the agent asks it to do:
10 per local day by default for each authenticated account15 minute cooldown for that accountThe debug console is local-only by default and is intended for operator testing, not public access.
It provides:
Credential-bearing debug actions use JSON POST bodies so secrets do not appear in query strings.
Default URL:
http://127.0.0.1:3939
By default the server writes:
data/audit/YYYY-MM-DD.jsonldata/policy-state.jsonThe audit log records:
Secrets are intentionally excluded from the logged metadata.
{
"mcpServers": {
"plurk": {
"command": "npx",
"args": ["plurk-mcp"],
"env": {
"PLURK_MCP_TIMEZONE": "UTC",
"PLURK_MCP_DAILY_POST_LIMIT": "10",
"PLURK_MCP_REPLY_COOLDOWN_MINUTES": "15"
}
}
}
}
Your MCP caller must now inject the Plurk credential bundle into each tool invocation instead of binding one account through process env vars.
Install dependencies:
npm install
Build:
npm run build
Type-check:
npm run lint
Run tests:
npm test
Create a tarball for local install verification:
npm pack
src/
bin/ CLI entrypoints
config/ environment parsing and runtime config
domain/ shared types and error helpers
integrations/plurk/ OAuth signing, API calls, normalization
services/ policy and application services
storage/ audit and policy-state persistence
transports/mcp/ MCP tool registration
transports/debug/ local web debug console
test/ automated tests
The package, CLI entrypoints, tests, and npm artifact verification are in place.
What still depends on your real environment:
Добавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"plurk-mcp": {
"command": "npx",
"args": []
}
}
}