2026-07-20 16:17:55 +03:00
|
|
|
# Muninn
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
Muninn is a personal content-operations hub. It keeps track of your
|
|
|
|
|
**Sites**, **Social Accounts**, and **Posts**, and exposes them over a
|
|
|
|
|
local JSON API so an AI agent (or you, via the built-in UI) can draft,
|
|
|
|
|
schedule, and publish content across WordPress blogs, Reddit, and other
|
|
|
|
|
platforms.
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
Built with Laravel 13, Livewire, and Tailwind CSS.
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
## What it does
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
- **Sites** — the websites you own (WordPress, custom, or other), with
|
|
|
|
|
optional WordPress Application Password credentials for publishing.
|
|
|
|
|
- **Social Accounts** — logins for social networks (Twitter, Instagram,
|
|
|
|
|
Facebook, Reddit, TikTok, LinkedIn, YouTube, etc.).
|
|
|
|
|
- **Posts** — the actual content, each tied to a Site and optionally a
|
|
|
|
|
Social Account, moving through `draft -> scheduled -> published/failed`.
|
|
|
|
|
- A **JSON API** (`/api/sites`, `/api/accounts`, `/api/posts`) plus thin
|
|
|
|
|
Python CLI wrappers in `python_scripts/`, so an agent can poll for due
|
|
|
|
|
posts (`?due=1`) and drive the publish lifecycle without hand-rolling
|
|
|
|
|
HTTP requests.
|
|
|
|
|
- Built-in publishing paths:
|
|
|
|
|
- **WordPress**: `php artisan posts:publish {post_id}` posts directly to
|
|
|
|
|
a site's WordPress REST API and updates the post's status.
|
|
|
|
|
- **Reddit**: a standalone Playwright sidecar at
|
|
|
|
|
`sidecars/reddit-post/` logs in and creates a post.
|
|
|
|
|
- Anything else: publish however fits, then report back via the API.
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
See `AI_API.md` for the full API reference and publishing contract, and
|
|
|
|
|
`python_scripts/README.md` for the CLI wrapper usage.
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
**Note:** the JSON API has no authentication and returns credentials in
|
|
|
|
|
plain text by design — it's meant to run on your local network only, not
|
|
|
|
|
be exposed to the public internet.
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
## Requirements
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
- PHP 8.3+
|
|
|
|
|
- Composer
|
|
|
|
|
- Node.js + npm
|
|
|
|
|
- MySQL (or another Laravel-supported database)
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
## Setup
|
2026-07-18 14:35:53 +03:00
|
|
|
|
|
|
|
|
```bash
|
2026-07-20 16:17:55 +03:00
|
|
|
composer install
|
|
|
|
|
cp .env.example .env
|
|
|
|
|
php artisan key:generate
|
2026-07-18 14:35:53 +03:00
|
|
|
```
|
|
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
Edit `.env` and set your database credentials (`DB_DATABASE`,
|
|
|
|
|
`DB_USERNAME`, `DB_PASSWORD`, etc. — defaults assume a local MySQL
|
|
|
|
|
database named `muninn`), then run migrations:
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
```bash
|
|
|
|
|
php artisan migrate
|
|
|
|
|
```
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
Install JS dependencies and build frontend assets:
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
```bash
|
|
|
|
|
npm install
|
|
|
|
|
npm run build
|
|
|
|
|
```
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
Alternatively, run everything in one shot with:
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
```bash
|
|
|
|
|
composer run setup
|
|
|
|
|
```
|
2026-07-18 14:35:53 +03:00
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
### Running locally
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
composer run dev
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
This starts the PHP dev server, queue listener, log viewer (Pail), and
|
|
|
|
|
Vite dev server together. The app is served at `http://localhost:8000` by
|
|
|
|
|
default.
|
|
|
|
|
|
|
|
|
|
### Reddit sidecar (optional)
|
|
|
|
|
|
|
|
|
|
If you plan to publish to Reddit, set up the Playwright sidecar separately:
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
cd sidecars/reddit-post
|
|
|
|
|
npm install
|
|
|
|
|
npx playwright install
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
See `sidecars/reddit-post/README.md` for usage.
|
|
|
|
|
|
|
|
|
|
## Testing
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
composer test
|
|
|
|
|
```
|
2026-07-18 14:35:53 +03:00
|
|
|
|
|
|
|
|
## License
|
|
|
|
|
|
2026-07-20 16:17:55 +03:00
|
|
|
The Laravel framework is open-sourced software licensed under the
|
|
|
|
|
[MIT license](https://opensource.org/licenses/MIT).
|