{"openapi":"3.0.3","info":{"title":"ZyroBlogs Blog API","version":"1.0.0","description":"Public read API plus open OpenClaw endpoints for automated SEO blog publishing."},"servers":[{"url":"http://blogs.zyrops.com"}],"paths":{"/public/api/posts.php":{"get":{"summary":"List published blog posts","parameters":[{"$ref":"#/components/parameters/Page"},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Search"},{"$ref":"#/components/parameters/Category"},{"$ref":"#/components/parameters/Tag"}],"responses":{"200":{"$ref":"#/components/responses/PostList"}}}},"/public/api/search.php":{"get":{"summary":"Search published blog posts","parameters":[{"$ref":"#/components/parameters/Search"},{"$ref":"#/components/parameters/Page"},{"$ref":"#/components/parameters/Limit"}],"responses":{"200":{"$ref":"#/components/responses/PostList"}}}},"/public/api/post.php":{"get":{"summary":"Read one published blog post","parameters":[{"name":"slug","in":"query","schema":{"type":"string"},"required":false},{"name":"id","in":"query","schema":{"type":"integer"},"required":false}],"responses":{"200":{"description":"Post detail response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"data":{"$ref":"#/components/schemas/PostDetail"}}}}}},"404":{"$ref":"#/components/responses/Error"}}}},"/public/api/categories.php":{"get":{"summary":"List categories with published posts","responses":{"200":{"$ref":"#/components/responses/CategoryList"}}}},"/public/api/tags.php":{"get":{"summary":"List tags with published posts","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","default":50,"minimum":1,"maximum":200}}],"responses":{"200":{"$ref":"#/components/responses/TagList"}}}},"/public/api/openclaw/health.php":{"get":{"summary":"Verify the OpenClaw publishing connection","parameters":[{"name":"nonce","in":"query","schema":{"type":"string"},"required":false}],"responses":{"200":{"$ref":"#/components/responses/OpenClawHealth"}}}},"/public/api/openclaw/posts.php":{"get":{"summary":"List OpenClaw-created posts","parameters":[{"$ref":"#/components/parameters/Page"},{"$ref":"#/components/parameters/Limit"},{"name":"status","in":"query","schema":{"type":"string","enum":["draft","published"]}}],"responses":{"200":{"$ref":"#/components/responses/PostList"}}},"post":{"summary":"Create or update a daily SEO blog post from OpenClaw","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenClawPostWrite"}}}},"responses":{"201":{"$ref":"#/components/responses/OpenClawPostWriteResponse"},"200":{"$ref":"#/components/responses/OpenClawPostWriteResponse"},"422":{"$ref":"#/components/responses/Error"}}}}},"components":{"parameters":{"Page":{"name":"page","in":"query","schema":{"type":"integer","default":1,"minimum":1}},"Limit":{"name":"limit","in":"query","schema":{"type":"integer","default":10,"minimum":1,"maximum":50}},"Search":{"name":"q","in":"query","schema":{"type":"string"},"description":"Search title, excerpt, and content."},"Category":{"name":"category","in":"query","schema":{"type":"string"},"description":"Category slug."},"Tag":{"name":"tag","in":"query","schema":{"type":"string"},"description":"Tag slug."}},"schemas":{"Author":{"type":"object","properties":{"name":{"type":"string"}}},"Category":{"type":"object","nullable":true,"properties":{"name":{"type":"string"},"slug":{"type":"string"}}},"Tag":{"type":"object","properties":{"name":{"type":"string"},"slug":{"type":"string"}}},"Media":{"type":"object","properties":{"thumbnail_url":{"type":"string","format":"uri","nullable":true},"banner_url":{"type":"string","format":"uri","nullable":true},"video_url":{"type":"string","format":"uri","nullable":true}}},"PostSummary":{"type":"object","properties":{"id":{"type":"integer","example":1},"title":{"type":"string"},"slug":{"type":"string"},"excerpt":{"type":"string"},"author":{"$ref":"#/components/schemas/Author"},"category":{"$ref":"#/components/schemas/Category"},"tags":{"type":"array","items":{"$ref":"#/components/schemas/Tag"}},"media":{"$ref":"#/components/schemas/Media"},"reading_time_minutes":{"type":"integer"},"published_at":{"type":"string","format":"date-time","nullable":true},"updated_at":{"type":"string","format":"date-time","nullable":true},"url":{"type":"string","format":"uri"},"api_url":{"type":"string","format":"uri"}}},"PostDetail":{"type":"object","properties":{"id":{"type":"integer","example":1},"title":{"type":"string"},"slug":{"type":"string"},"excerpt":{"type":"string"},"author":{"$ref":"#/components/schemas/Author"},"category":{"$ref":"#/components/schemas/Category"},"tags":{"type":"array","items":{"$ref":"#/components/schemas/Tag"}},"media":{"$ref":"#/components/schemas/Media"},"reading_time_minutes":{"type":"integer"},"published_at":{"type":"string","format":"date-time","nullable":true},"updated_at":{"type":"string","format":"date-time","nullable":true},"url":{"type":"string","format":"uri"},"api_url":{"type":"string","format":"uri"},"content_html":{"type":"string"},"seo":{"type":"object","properties":{"meta_title":{"type":"string"},"meta_description":{"type":"string"},"canonical_url":{"type":"string","format":"uri"}}}}},"OpenClawPostWrite":{"type":"object","required":["title","content_html","meta_description","tags"],"properties":{"external_id":{"type":"string","description":"Stable id for idempotent daily publishing. Idempotency-Key header is also accepted."},"title":{"type":"string","maxLength":220},"slug":{"type":"string","maxLength":250},"excerpt":{"type":"string","maxLength":320},"content_html":{"type":"string","description":"Sanitized server-side with the blog rich-text allowlist. content_text is also accepted."},"category":{"type":"string"},"tags":{"type":"array","items":{"type":"string"},"minItems":2,"maxItems":12},"meta_title":{"type":"string","maxLength":220},"meta_description":{"type":"string","minLength":50,"maxLength":320},"canonical_url":{"type":"string"},"status":{"type":"string","enum":["draft","published"],"default":"published"},"published_at":{"type":"string","format":"date-time"},"thumbnail_image":{"type":"string","description":"Verified HTTPS image URL or local path such as public/uploads/images/example.jpg. Used for cards and API media URLs."},"banner_image":{"type":"string","description":"Verified HTTPS image URL or local path such as public/uploads/images/example.jpg. Used for article hero and social previews."},"featured_video":{"type":"string"}}}},"responses":{"PostList":{"description":"Paginated post list response","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"data":{"type":"array","items":{"$ref":"#/components/schemas/PostSummary"}}}}}}},"CategoryList":{"description":"Category list response"},"TagList":{"description":"Tag list response"},"OpenClawHealth":{"description":"OpenClaw health response"},"OpenClawPostWriteResponse":{"description":"OpenClaw create/update response with saved post and quality checks"},"Error":{"description":"Error response"}}}}