Skip to content
scsiwyg
sign insign up
get startedhow it worksmcpscsiblogcommunityapiplaygroundswaggersign insign up

API

Most creators never touch the API directly โ€” the MCP server gives your IDE agent full access to your blog, and that's usually all you need.

But the REST API is there, and your IDE will use it when it needs to โ€” we've seen Claude and Cursor reach for it directly more than once. It's also the right choice for scripts, CI/CD pipelines, and programmatic publishing.

Base URL https://scsiwyg.com/api
Interactive Swagger docs

Authentication

Write endpoints require a Bearer token in the Authorization header. Get your token from the account page. Read endpoints are public โ€” no auth required.

Authorization: Bearer YOUR_TOKEN_HERE

Post format

{
  "slug": "my-post-slug",
  "title": "Post Title",
  "body": "# Markdown\n\nFull markdown body.",
  "tags": ["tag1", "tag2"],
  "visibility": "public",
  "images": [
    {
      "id": "img1",
      "name": "photo.jpg",
      "data": "data:image/jpeg;base64,..."
    }
  ]
}
  • slug โ€” URL-safe identifier, unique per blog
  • body โ€” Markdown (GFM supported)
  • visibility โ€” public or journal (subscriber-only)
  • images โ€” base64 data URIs, self-contained in the JSON
  • date โ€” ISO 8601, defaults to now. Use for backdating.
  • draft: true โ€” saves without publishing

Endpoints

GET/api/sites

Platform directory โ€” all public sites. No auth.

curl https://scsiwyg.com/api/sites
POST/api/sites

Create a new blog. Auth required.

curl -X POST https://scsiwyg.com/api/sites \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"username": "myname", "title": "My Blog"}'
GET/api/{username}

Site info and published posts. Public.

curl https://scsiwyg.com/api/myname
PATCH/api/{username}

Update blog settings โ€” title, bio, theme, newsletter, community mode. Auth required.

curl -X PATCH https://scsiwyg.com/api/myname \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"theme":"ocean","themeOverrides":{"link":"#ff6600"}}'
GET/api/{username}/posts

List published posts. Public.

curl https://scsiwyg.com/api/myname/posts
POST/api/{username}/posts

Publish a new post. Auth required. Publishes immediately unless draft: true. Set isNewsletter: true for newsletter posts.

curl -X POST https://scsiwyg.com/api/myname/posts \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"slug":"hello","title":"Hello","body":"# Hi","visibility":"public"}'
GET/api/{username}/posts/{slug}

Get a single post with full body. Public.

curl https://scsiwyg.com/api/myname/posts/hello
PUT/api/{username}/posts/{slug}

Update a post. Send only changed fields. Auth required.

curl -X PUT https://scsiwyg.com/api/myname/posts/hello \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"title": "Updated title"}'
DELETE/api/{username}/posts/{slug}

Permanently delete a post. Auth required.

curl -X DELETE https://scsiwyg.com/api/myname/posts/hello \
  -H "Authorization: Bearer $TOKEN"
POST/api/{username}/posts/{slug}/view

Track a post view. Public. Deduplicates by visitor within 24 hours.

curl -X POST https://scsiwyg.com/api/myname/posts/hello/view
GET/api/{username}/contributors

List contributors for a blog. Shows community mode status. Public.

curl https://scsiwyg.com/api/myname/contributors
POST/api/{username}/contributors

Add a contributor by email. Auth required, site owner only.

curl -X POST https://scsiwyg.com/api/myname/contributors \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"email": "collaborator@example.com"}'
POST/api/subscribers

Subscribe an email to a site newsletter. Public. Rate limited 10/hour.

curl -X POST https://scsiwyg.com/api/subscribers \
  -H "Content-Type: application/json" \
  -d '{"email":"reader@example.com","siteId":"SITE_ID"}'
GET/api/subscribers

List subscribers for a site. Auth required (site owner).

curl "https://scsiwyg.com/api/subscribers?username=myname" \
  -H "Authorization: Bearer $TOKEN"
GET/api/newsletter/send-status

Poll newsletter send status. Auth required. For IDE polling after initiation.

curl "https://scsiwyg.com/api/newsletter/send-status?slug=hello" \
  -H "Authorization: Bearer $TOKEN"
GET/api/analytics

Site analytics โ€” views, top posts, referrers, daily trends. Pro plan, session auth.

curl https://scsiwyg.com/api/analytics?days=30
GET/api/openapi.json

OpenAPI 3.1 spec โ€” machine-readable, for AI tools and Swagger UI.

curl https://scsiwyg.com/api/openapi.json

Limits

Free tier60 req/min
Pro tier600 req/min
Max post body500 KB
Max image size5 MB per image (base64)
Max images per post20
Swagger UI (interactive)MCP setupOpenAPI specAccount & token