Moraya
Moraya is a Tauri-based local AI / Markdown editor. With Picora it has two complementary integration paths:
| Integration | Purpose |
|---|---|
| One-click image hosting (v0.11.0) | Moraya uploads inline screenshots / drag-and-drop images to Picora as you write |
| MCP integration (v0.13+) | Moraya’s AI assistant can call Picora tools — upload, list, manage your library |
Use both for the most complete experience.
One-click image hosting
This is the traditional image-host integration via Picora’s /v1/images endpoint with an API Key. Moraya bundles a Picora preset; you just paste your API Key.
Setup
- Open Moraya → Preferences → Image Upload → Custom Provider
- Pick Picora from the preset dropdown (or paste the JSON below if using a custom config)
- Replace
sk_live_YOUR_KEYwith your actual API Key from Settings → API Keys:
{ "name": "Picora", "url": "https://api.picora.me/v1/images", "method": "POST", "headers": { "Authorization": "Bearer sk_live_YOUR_KEY" }, "bodyType": "multipart", "fileField": "file", "responseUrlPath": "data.url"}For mainland China users, replace https://api.picora.me with https://api.picora.cn.
- Click Save, then drag any image onto Moraya — it uploads to Picora and inserts the public URL into your markdown automatically.
One-click deep link (v0.11.0)
If you don’t want to manually copy/paste JSON, Picora provides a deep link:
- Open Settings → Integration → Moraya
- Click Open in Moraya
- Browser triggers
moraya://configure?provider=picora&apiKey=sk_live_... - Moraya prompts to confirm and saves the config
This is faster but obviously requires Moraya already installed and the deep-link handler registered.
Verifying
After saving, Moraya’s Test Connection button uploads a tiny dummy image. Don’t use this on a real account: it pollutes your image library with the test image. Instead, drag a real screenshot you’d actually use, then delete it from Picora’s Library if you didn’t want to keep it.
MCP integration
Moraya 2.0+ supports MCP. The setup is similar to Claude Desktop.
Setup (HTTP OAuth)
- Open Moraya → Preferences → AI / MCP
- Click Add MCP Server
- Pick Picora (HTTP OAuth) from the preset
- Click Authorize — browser opens consent page
- Grant scopes; redirect back; done
Setup (stdio)
npm install -g @picora/mcpThen in Moraya MCP config:
{ "name": "Picora", "command": "npx", "args": ["-y", "@picora/mcp"], "env": { "PICORA_API_KEY": "sk_live_YOUR_KEY", "PICORA_API_URL": "https://api.picora.me" }}Using both integrations together
Moraya’s killer feature is combining the two:
You: "Tidy up the image library — show me images larger than 2 MB and let me decide which to delete."
Moraya AI: 1. Calls Picora list_media with sizeBytes filter 2. Renders a table with thumbnails 3. You click selected items 4. Calls delete_image (dryRun first, then real)Or:
You: (drag screenshot.png onto editor)
Moraya: 1. (one-click image hosting) Uploads to Picora 2. Inserts  at cursor
You: "Set the image I just uploaded to private."
Moraya AI: 1. Calls list_media to find the image (recent uploads first) 2. Calls update_image with isPublic: false 3. Confirms in chatThe image-host integration moves files to Picora; the MCP integration manages them.
CORS note
Earlier Picora versions had CORS issues that prevented Tauri-based apps (Moraya is Tauri) from calling /v1/* directly. v0.12.0 fixed this by skipping Origin checks for API-Key authenticated requests (Tauri’s Origin is tauri://localhost which a strict CORS policy would block).
If you’re hitting CORS errors:
- Confirm Picora API is at v0.12.0+ (always true on hosted Picora; only a concern for self-hosted)
- Confirm you’re using API Key (not a JWT) — JWTs still go through CORS
Limitations
- Moraya MCP support varies between versions — features described here require Moraya 2.0+
- Moraya’s mobile app does not yet support MCP (desktop only as of 2026-04)
- Some MCP tools (like
delete_*withdryRun: true) require Moraya UI confirmation; this is a feature, not a bug
Troubleshooting
Moraya says “Connection failed” on test image — verify the API Key is correct and not revoked. Check the URL matches your Picora platform (.me vs .cn).
MCP server appears connected but no tools listed — restart Moraya completely (some versions cache MCP schema until restart).
Deep link doesn’t trigger Moraya — the URL handler may not be registered. On Mac: Settings → Default Apps → register moraya://. On Windows: registry entry under HKEY_CLASSES_ROOT\moraya.
Related
- Image upload guide — what one-click image hosting actually does
- Claude Desktop integration — same patterns, different host
- Tool catalog — what Moraya AI can call
- Moraya official docs
- API Keys management