Image and prompt generation over REST and MCP.
Base URL https://www.fonori.com/api/v1
Connect this server to Claude
https://www.fonori.com/mcp
claude mcp add www-fonori-com --transport http https://www.fonori.com/mcp
Paste the address into any MCP client. Sign-in happens in the browser over
OAuth 2.1 β with a CML account if this installation has CML sign-in
configured, otherwise with a local account. No API key goes into the client.
Read-only variant: https://www.fonori.com/mcp/read β
plans and composes every deliverable and cannot spend a credit.
An instant link carries its credential in the address, so the assistant is
connected the moment you paste it: no OAuth window, no header. Name it, pick
read-only or read-and-write, give it an expiry date and revoke it whenever you
like on the MCP page.
Authentication
Every non-public endpoint takes an API key in a header. Either form works:
X-API-Key: <key>
Authorization: Bearer <key>
Keys are issued by the master key via POST /api/v1/keys
and can be revoked there. A key is shown in full only when it is created.
Quick check
curl https://www.fonori.com/api/v1/health
Public. Reports service status, the image provider, installed fonts
and their Czech coverage, and whether client brand profiles can be synced.
REST API v1
GET
/api/v1/health
Service health and supported generation settings.
Public
GET, POST, DELETE
/api/v1/video-briefs
Real image analysis via LiteLLM β private video proposal β refine/edit β explicit revision approval β export and source download.
Schema public; drafts owner session + CSRF or API key
GET, POST
/api/v1/prompt-studio
Search the complete prompt database and compile country-aware photo/video megaprompts. No rendering or credit charge.
GET public; POST API key
GET, POST
/api/v1/creatives
Discover formats and templates, validate a brief with dry_run, or render exact-copy creatives.
GET public; POST API key
GET, POST, DELETE
/api/v1/keys
Issue, list and revoke API keys. A minted key is returned once; the listing shows a masked form only.
Master API key
GET, POST, DELETE
/api/v1/brands
Client brand profiles synced from Verbio: visual DNA, brand voice, colours, logo and approved photography. POST syncs a client or pins manual overrides that survive later re-syncs.
API key
GET
/api/v1/iab-formats
The IAB display, native and video unit catalog with per-unit composition, copy-space, safe-area and file-weight direction.
Public
GET, POST
/api/v1/brand-studio
Compile client-specific photography prompts, per-IAB-unit banner plates and video storyboards with per-beat keyframes. Only banner rendering charges credits.
GET public; POST API key
GET, POST
/api/v1/niche-generate
List all niches; inspect ?slug= for exact attributes; generate specialized or source-based images.
GET public; POST API key
GET, POST
/api/v1/presets
Search imported presets or generate from an exact pack/slug preset ID.
GET public; POST API key
GET, POST
/api/v1/products
List public product photos or remix a source product image.
GET public; POST API key
GET, POST
/api/v1/jobs
List jobs owned by the caller key or submit a background generation job.
API key
GET, DELETE
/api/v1/jobs/{id}
Read progress and result photos; DELETE removes the job record.
Owning API key
POST
/api/v1/auto-generate
Submit an autonomous photography job; returns HTTP 202 with poll and result URLs.
API key
GET
/api/v1/myimages
Read your generated images, including private creative and niche results.
API key
GET
/api/v1/photos
Search the public photo catalog with pagination.
Public
GET, DELETE
/api/v1/photos/{slug}
Read one public photo; delete a photo you own.
GET public; DELETE owner or administrator key
GET, POST
/api/v1/queue
List the shared queue or enqueue one item / items array.
Administrator API key
DELETE
/api/v1/queue/{id}
Delete one shared queue item.
Administrator API key
POST
/api/v1/queue/clear
Purge queue records matching statuses.
Administrator API key
POST
/api/v1/queue/import-xml
Import an XML queue, deduplicating client_ref; maximum 2 MB and 1000 items.
Administrator API key
GET
/api/v1/reference
Machine-readable endpoint reference, full niche fields and creative input schemas.
Public
Browser endpoints
GET
/api/random-source.php
Return a source-image suggestion for ?niche=slug.
Public
GET
/api/niche-photos.php
Paginate public examples with slug, limit (max 48), offset.
Public
GET
/api/job-status.php
Read web-job progress using ?id=.
Owner session or administrator
GET
/api/job-run.php
Run an eligible web job via ?id= as a web-worker fallback.
Job authorization; see endpoint guide
POST
/api/generate.php
Generate one image using prompt, size, quality, style, purpose, logo and inspiration.
Session or API key; login may be required
POST
/api/analyze.php
Analyze description / url and suggest category and niche.
Web helper; session requests require CSRF
POST
/api/prompts.php
Produce prompts from description, subjects and style direction.
Web helper; session requests require CSRF
POST
/api/expand-prompt.php
Expand topic (3β400 characters) using niche and language.
Web helper; session requests require CSRF
POST
/api/scrape.php
Read a public website URL into a company brief.
Web helper; session requests require CSRF
POST
/api/upload.php
Multipart image upload, PNG/JPEG/WebP up to 8 MB each; returns files[].
Web helper; session requests require CSRF
POST
/api/zip.php
Build a ZIP from files:[{name,b64,prompt}] and optional meta.
Web helper; session requests require CSRF
POST
/api/report.php
Report photo_id with reason (10β2000 characters).
Public report; session requests require CSRF
POST
/api/checkout.php
Create Stripe checkout for form field plan_id.
Signed-in session + CSRF
POST
/api/portal.php
Open the signed-in customerβs Stripe billing portal.
Signed-in session + CSRF
POST
/api/stripe-webhook.php
Receive raw Stripe event body with Stripe-Signature. Not a client API.
Stripe signature
GET
/api/social-oauth.php
Provider OAuth callback: provider, code, state or OAuth 1 verifier/token.
Administrator session
POST
/api/social-test.php
Test social connection ?id=.
Administrator session + CSRF
Other
POST
/mcp
Stateless Streamable HTTP JSON-RPC: initialize, tools/list, tools/call, prompts and resources.
OAuth Bearer or API key
POST
/mcp/k/{token}
Same JSON-RPC surface, authenticated by an instant link. No header, no OAuth. Read-only or read-and-write, per link.
The token in the URL
GET
/.well-known/oauth-authorization-server
Discover authorize/token/register/revoke endpoints and PKCE capabilities.
Public
GET
/.well-known/oauth-protected-resource
Discover the MCP resource audience and authorization server.
Public
POST
/oauth/register
Register public MCP client: client_name, redirect_uris[], token_endpoint_auth_method:none.
Signed-in session for approved return addresses, otherwise account password; POST CSRF
POST
/oauth/token
Exchange code or rotate refresh token. resource and client_id are required.
Public client + PKCE or refresh token
POST
/oauth/revoke
Revoke token or refresh token with client_id.
Token possession
GET
/auth/cml/start
Start CML OIDC login; optional local next path.
Session
GET
/auth/cml/callback
OIDC return endpoint; validates state, issuer, PKCE and identity.
One-time session state + CML code
MCP
The same capabilities are exposed to agents over Streamable HTTP with OAuth 2.1:
claude mcp add www-fonori-com --transport http https://www.fonori.com/mcp
/mcp/read is a read-only surface: it can plan and compose
every deliverable and cannot spend a credit. Connection details and token revocation
are at /mcp.php.
Conventions
Responses are JSON. Add ?format=xml for XML.
Errors return {"error":{"type","message","status"}} with a matching HTTP status.
Composing prompts, specs and layouts is free. Only rendering consumes credits, one per image, and failures are refunded.
GET /api/v1/reference returns this endpoint list, the full niche field definitions and the creative input schemas as JSON.