Metadata-Version: 2.4
Name: writefreely-mcp-server
Version: 0.1.2
Summary: An MCP server for interacting with WriteFreely API, enabling AI agents like Claude to perform blogging actions. Supports both self-hosted WriteFreely instances and the Write.as hosted service. This is a community-built, independent project.
Project-URL: Homepage, https://github.com/laxmena/writefreely-mcp-server
Project-URL: Repository, https://github.com/laxmena/writefreely-mcp-server.git
Project-URL: Documentation, https://github.com/laxmena/writefreely-mcp-server#readme
Project-URL: Issues, https://github.com/laxmena/writefreely-mcp-server/issues
Author: Lakshmanan Meiyappan
License-Expression: MIT
License-File: LICENSE
Keywords: ai-agent,api,blogging,mcp,writefreely
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Requires-Dist: httpx>=0.28.1
Requires-Dist: mcp[cli]>=1.25.0
Requires-Dist: pydantic>=2.12.5
Requires-Dist: python-dotenv>=1.0.1
Provides-Extra: dev
Requires-Dist: mypy>=1.12.0; extra == 'dev'
Requires-Dist: pre-commit>=4.0.1; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24.0; extra == 'dev'
Requires-Dist: pytest-httpx>=0.30.0; extra == 'dev'
Requires-Dist: pytest>=8.3.3; extra == 'dev'
Requires-Dist: ruff>=0.6.9; extra == 'dev'
Description-Content-Type: text/markdown

# writefreely-mcp-server

An MCP server for WriteFreely that enables AI agents to publish and manage content on WriteFreely instances (including self-hosted instances and Write.as).

## Features

- Publish posts (anonymous or authenticated)
- Manage collections and posts
- Browse public feeds
- Support for Write.as and self-hosted WriteFreely instances

## Installation

### Installing `uv` or `uvx`

If you don't have `uv` or `uvx` installed, you can install them using one of the following methods:

**macOS/Linux:**
```bash
curl -LsSf https://astral.sh/uv/install.sh | sh
```

**Windows (PowerShell):**
```powershell
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
```

**Using Homebrew (macOS):**
```bash
brew install uv
```

**Using pip:**
```bash
pip install uv
```

After installation, `uvx` will be available as part of `uv`. See the [uv documentation](https://github.com/astral-sh/uv) for more details.

### Using `uvx` (recommended)

```bash
uvx --from writefreely-mcp-server writefreely-mcp
```

### Using `uv`

```bash
uv tool install writefreely-mcp-server
writefreely-mcp
```

### Using `pip`

```bash
pip install writefreely-mcp-server
```

## Configuration

Configure via environment variables:

- `WRITEFREELY_BASE_URL` - Base URL (default: `https://write.as`)
- `WRITEFREELY_ACCESS_TOKEN` - Access token for authentication
- `WRITEFREELY_DEFAULT_LANGUAGE` - Default language (default: `en`)

### Getting an Access Token

```bash
curl -X POST https://write.as/api/auth/login \
  -H "Content-Type: application/json" \
  -d '{"alias": "your_username", "pass": "your_password"}'
```

### MCP Client Configuration

```json
{
  "mcpServers": {
    "writefreely": {
      "command": "uvx",
      "args": ["--from", "writefreely-mcp-server", "writefreely-mcp"],
      "env": {
        "WRITEFREELY_BASE_URL": "https://write.as",
        "WRITEFREELY_ACCESS_TOKEN": "your_token_here"
      }
    }
  }
}
```

## Available Tools

- `login()` - Authenticate with username/password
- `publish_post()` - Create and publish a new post
- `edit_post()` - Update an existing post
- `delete_post()` - Delete a post
- `read_post()` - Read a post by ID
- `list_my_posts()` - List all your posts
- `list_my_collections()` - List all your collections/blogs
- `browse_collection()` - Browse posts in a collection
- `browse_public_feed()` - Browse the public feed

## License

MIT

## Links

- [Development](https://github.com/laxmena/writefreely-mcp-server/blob/main/DEVELOPMENT.md)
- [Contributing](https://github.com/laxmena/writefreely-mcp-server)
- [Issues](https://github.com/laxmena/writefreely-mcp-server/issues)
