API Documentation
RESTful API documentation for developers
https://api.lots.blogAPI Key (Bearer token or X-API-Key header)
28
Authentication
All API requests require authentication using an API key. You can create an API key from your dashboard.
curl -H "Authorization: Bearer YOUR_API_KEY" \
https://api.lots.blog/api/v1/lotsblog/blogs/:blog_id/domain/checkcontent
/api/v1/lotsblog/blogs/:blog_id/domain/checkCheck Domain
check_domainCheck the owned blog custom domain verification and HTTPS certificate state. Returns exact DNS records and a plain-language next step. Does not change the user DNS records.
/api/v1/lotsblog/blogs/:blog_id/images/completeComplete Image Upload
complete_image_uploadVerify the uploaded image size and magic bytes before using it in an article. Call after PUT to the URL returned by create_image_upload. Return a public CDN URL.
/api/v1/lotsblog/blogs/:blog_id/domainConnect Domain
connect_domainConnect the blog owner custom hostname and return exact required CNAME and optional TXT DNS records. Ask the user to set records at their DNS provider, then call check_domain. Owner-only; requires a plan with custom domains. Does not change DNS automatically or replace an existing different domain.
/api/v1/lotsblog/blogs/:blog_id/images/uploadCreate Image Upload
create_image_uploadPrepare a local image upload without passing base64 through MCP. Return a 15-minute presigned PUT URL, headers and file_key. PUT the local bytes then call complete_image_upload. JPEG, PNG, WebP or GIF, at most 25 MB. Requires the blog owner plan and create permission. Uploaded images are public.
/api/v1/lotsblog/blogs/:blog_id/images/deleteDelete Media
delete_mediaPermanently delete an unused image belonging to this blog, only under the user instruction. Images referenced by article content, covers or blog appearance cannot be deleted.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_id/quality-checkIndependent Article Review
run_post_quality_checkOptional paid article quality check requested by the user. Charges the blog owner token-based LotsTech Credits for model input and output; cost varies with article length and usage. Set authorize_charge=true for a requested paid quality check; no separate resource funding consent is required. Never guarantees rankings or gates publication. Maximum 45000 characters; unchanged-revision retries reuse execution.
/api/v1/lotsblog/blogs/:blog_id/imagesList Media
list_mediaList a bounded page of image keys and CDN URLs for this blog. Use next_cursor to continue. Images uploaded through MCP are publicly accessible.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_id/unpublishUnpublish Post
unpublish_postMove a published or scheduled article back to a private draft under user instructions. Clears publication time and any pending schedule. The public URL stops serving the article.
billing
/api/v1/lotsblog/fundingCheck product funding
get_funding_statusCheck plan coverage, credit funding and current capacity rates. Plan coverage is used first; capacity beyond it is paid from the owner's credits automatically, charged daily (free credits first, then plan credits, then purchased). If credits run low, give the returned settings_url so the owner can top up or choose a plan.
General
/api/v1/lotsblog/blogsCreate Blog
create_blogCreate a hosted blog. A plan covers its included blogs; each extra blog costs that plan's own per-blog rate, and without a plan each blog is $9 a month. Capacity is paid from the owner's credits automatically, charged daily. Use get_funding_status for current rates and balance. If credits are insufficient, return the owner settings link so they can top up or choose a plan. Returns the blog and hosting URL.
/api/v1/lotsblog/blogs/:blog_idGet Blog Details
get_blogRead the blog, current user role, hosting URL and private Markdown blog_guide. Call list_blogs first to select the blog. Read the guide before writing; it is optional and must not be copied into public articles.
/api/v1/lotsblog/blogsList Blogs
list_blogsRetrieves all blogs where the authenticated user is an owner or active member. Returns blogs with the user's role in each blog (owner, admin, editor, author, user). This is useful for displaying a blog selector in the UI or for determining which blogs the user can manage. Only active blog memberships are included (status='active' in blog_users table). Blogs are returned with their access URLs (either custom domain or subdomain URL).
/api/v1/lotsblog/blogs/:blog_idUpdate Blog Settings
update_blogUpdate the owned blog name, title, privacy or private Markdown blog guide. Only supplied fields change. Use connect_domain/check_domain for custom domains; appearance and team setup use the dashboard.
/api/v1/lotsblog/blogs/:blog_id/imagesUpload Blog Image
upload_blog_imageUpload an image from a public/signed image_url or small image_base64. For a local screenshot or larger image, prefer create_image_upload then complete_image_upload. Return the public CDN URL for featured_image in create_blog_post/update_blog_post or article Markdown. Requires the blog owner active plan and content-create permission; image URLs are public even for private blogs.
posts
/api/v1/lotsblog/blogs/:blog_id/postsCreate Blog Post
create_blog_postCreate an article with Markdown content, metadata, topics and optional matching supplemental JSON-LD such as FAQPage. Defaults to a private draft. Return preview_url to the user; sign-in is required for draft preview. Publish or schedule only under explicit user instructions. Use list_topics to choose topic_ids.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_idDelete Blog Post
delete_blog_postPermanently delete a post and all associated data (articles, list items, polls, comments, likes, etc.). Only owner and admin roles can delete posts. CASCADE constraints will automatically remove all related data. This action cannot be undone.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_idGet Blog Post
get_blog_postRead the saved article and metadata by blog_id and post_id. Call list_blog_posts to find post IDs. Use this to verify saved content and publication status before retrying an uncertain write.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_id/analyticsGet Post Analytics
get_post_analyticsRead traffic and engagement analytics for an article. Select blog_id from list_blogs and post_id from list_blog_posts. Traffic is not a ranking or AI-citation measurement.
/api/v1/lotsblog/blogs/:blog_id/postsList Blog Posts
list_blog_postsList all posts for a blog with optional filters by type, status, topic, and pagination. Returns posts ordered by creation date (newest first). Use this to display blog content, filter by draft/published status, or find posts of a specific type.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_id/publishPublish Post
publish_postPublish the saved post now, only when the user instructs publication. Select blog_id from list_blogs and post_id from list_blog_posts. Returns the saved publication status.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_id/scheduleSchedule Post
schedule_postSchedule the saved post under the user instructions. Use an ISO 8601 timestamp with timezone, at least five minutes in the future. Select post_id from list_blog_posts. A scheduled status is not confirmation that the article is already live.
/api/v1/lotsblog/blogs/:blog_id/posts/:post_idUpdate Blog Post
update_blog_postUpdate the existing article content, metadata, topics or publication status. Omitted fields are preserved; topic_ids=[] clears topics. Returns preview_url. Use the existing post_id rather than creating a duplicate. Publish or schedule only under user instructions.
topics
/api/v1/lotsblog/blogs/:blog_id/topicsCreate Topic
create_topicCreate an article topic/category in the selected blog. An explicit slug is preserved and must be unique within that blog; omit it to generate from the name. Returns the numeric topic ID for topic_ids in article create/update.
/api/v1/lotsblog/blogs/:blog_id/topics/:topic_idDelete Topic
delete_topicDelete a topic/category under user instructions. Articles remain intact; their association with this topic is removed. Topics with children must be handled first. Select the numeric topic_id from list_topics.
/api/v1/lotsblog/blogs/:blog_id/topics/:topic_idGet Topic
get_topicRetrieves details for a specific blog topic. IMPORTANT: Requires blog_id and topic_id — call list_blogs to get the blog UUID, then list_topics to get the topic_id.
/api/v1/lotsblog/blogs/:blog_id/topicsList Topics
list_topicsLists all topics/categories for a blog. IMPORTANT: Requires blog_id — call list_blogs first to get the blog UUID.
/api/v1/lotsblog/blogs/:blog_id/topics/:topic_idUpdate Topic
update_topicUpdate the topic name, description, slug or metadata. Omitted fields are preserved. Supplied slugs are kept and must be unique within the blog. Select topic_id from list_topics.
analytics
/api/v1/lotsblog/blogs/:blog_id/analyticsGet Blog Analytics
get_blog_analyticsRetrieves traffic and engagement analytics for a blog. IMPORTANT: Requires blog_id — call list_blogs first to get the blog UUID.