Skip to content

feat(blog): goal-driven keyword planning and article approval - #37

Merged
alihesari merged 3 commits into
mainfrom
feature/blog-planning-pipeline
Oct 18, 2026
Merged

alihesari merged 3 commits into
mainfrom
feature/blog-planning-pipeline

Conversation

@alihesari

@alihesari alihesari commented Oct 17, 2026 •

Copy link
Copy Markdown
Member

What changed

  • blog.suggest_seeds(workspace_id, *, seeds=None, prompt=None) → POST /v1/blog/keywords/suggest (ai scope, PaymentRequiredError on an empty balance), returns the list of seeds.
  • blog.submit_article(workspace_id, article_id) → POST /v1/blog/articles/{id}/submit (posts scope), moves a draft, failed or rejected article to in_review; 409 otherwise.
  • BlogSettings: new goal, focus_topics, avoid_topics, plan_run (new BlogPlanRun model); update_settings takes goal, focus_topics, avoid_topics. BlogKeyword.fit_reason. in_review added to BlogArticleStatus / BLOG_ARTICLE_STATUSES; new BlogGoal / BLOG_GOALS.
  • Docstrings: plan_keywords no longer fills the calendar, setting a keyword to planned picks it, publish_article / publish_at need an article in review, review_hold_days meaning.
  • README blog section and CHANGELOG Unreleased entry. No version bump.

Live contract

The blog resource now matches the live API contract (openapi.json, tag Blog):

  • The workspace travels as workspace_id on every query string (settings read, keyword and article lists, every per-id keyword and article call).
  • Request bodies are unchanged and match the spec's camelCase request schemas.
  • Responses are read as the wire's snake_case: bare single resources, { data: [...] } lists, website_secret on the settings PATCH and from rotate_website_secret, and BlogWebsiteTest.http_status from test_website (a refusal raises the 502 website_test_failed).

Breaking

auto_publish is removed from BlogSettings and from blog.update_settings. BlogWebsiteTest is now http_status only; the blog resource is unreleased, so nothing published changes.

Tested

uv run ruff check ., uv run ruff format --check ., uv run mypy, uv run pytest (199 passed; fixtures in the real wire format, assertions on the workspace_id query param).

Depends on

The fopost/fopost feature/blog-planning-pipeline change (merged and deployed).

@alihesari
alihesari merged commit 7cfea32 into main Oct 18, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant