Skip to content

Commit ee1c781

Browse files
committed
Bump version to 0.1.21, update dependencies, and add MCP server functionality
1 parent 1979fff commit ee1c781

File tree

5 files changed

+2295
-125
lines changed

5 files changed

+2295
-125
lines changed

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ You can install python-substack using:
1313

1414
$ pip install python-substack
1515

16+
For the MCP server tools, install the extra dependency set:
17+
18+
$ poetry install --with mcp
19+
20+
> NOTE: We had to upgrade the package requirements to support Python 3.10 because 3.9 is basically vintage now. If you still run 3.9, please join us in the future (or bring snacks).
21+
1622
---
1723

1824
# Setup
@@ -247,6 +253,22 @@ body:
247253
src: "local_image.jpg" # Local images will be uploaded automatically
248254
```
249255
256+
## MCP FastMCP server
257+
258+
This package now includes a FastMCP server in `substack/mcp_fastmcp.py` with the following tools:
259+
260+
- `post_draft_from_markdown(...)`: create draft from markdown, optional tag/add/prepublish/publish, and control send/share_automatically.
261+
- `put_draft(draft_id, update_payload)`: update draft fields.
262+
- `add_tags(draft_id, tags)`: add tags to a draft/post.
263+
- `prepublish_draft(draft_id)`: prepublish a draft.
264+
- `publish_draft(draft_id, send=True, share_automatically=False)`: publish a draft.
265+
266+
Use via stdio transport:
267+
268+
```bash
269+
python -c "from substack.mcp_fastmcp import main; main()"
270+
```
271+
250272
# Contributing
251273

252274
Install pre-commit:

0 commit comments

Comments
 (0)