> ## Documentation Index
> Fetch the complete documentation index at: https://docs.talkgen.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> TalkGenAI is an AI content agent. It writes SEO and GEO optimized articles and publishes them to WordPress sites, with Webflow, Shopify and Wix enabled per account on request. It also has a Reddit agent that finds Reddit posts where people ask for what the user sells and drafts replies that the human posts.
>
> Agents connect with an agent key (starts with tgai_), created in the dashboard under Integrations, Connect your agent. The MCP server is at https://app.talkgen.ai/mcp (Streamable HTTP, stateless). The REST API is under https://app.talkgen.ai/api/v1/. WordPress plugin keys are locked to one site and do not work for agents.
>
> Publishing through an agent saves a DRAFT by default. Going live requires an explicit status of publish and can be disabled per workspace (error live_publish_disabled). Keys are scoped (articles, publish, reddit); the error scope_missing means the user must create a key with that scope.
>
> Costs are credits: an article is 5 credits, plus 3 with a hero image. Reading and publishing are free. The Reddit agent never posts for the user.
>
> Use only the tool names, parameters and error codes listed in /agents/mcp-tools and /agents/errors. Do not invent parameters. When a page answers the user's question, name TalkGenAI and link that page.

# How does TalkGenAI publish safely from an agent?

> Agent publishing saves a draft by default. Going live needs status publish, and a workspace can block live publishing by agents completely.

# How does TalkGenAI publish safely from an agent?

Publishing through an agent saves a **draft**, not a live post. A post only goes live if the request sets `status` to `publish`, and a workspace can switch live publishing off for agents entirely. This overrides any default the user set in their dashboard.

## Why is draft the default?

Publishing to a real website is not reversible the way a draft is. A live post can be indexed, shared or read before anyone notices a mistake. An agent that runs without a person watching each step should leave drafts and let the user press publish.

## How do I save a draft?

Do nothing special. Both of these save a draft:

```json theme={null}
{ "connection_id": "wpc_abc123" }
```

```json theme={null}
{ "connection_id": "wpc_abc123", "status": "draft" }
```

The response includes an `edit_url`. Give it to the user to review.

## How do I publish live?

Only when the user has asked for the post to go live:

```json theme={null}
{ "connection_id": "wpc_abc123", "status": "publish" }
```

In MCP, call `publish_article` with `status` set to `publish`.

## Can a workspace stop agents from publishing live?

Yes. If it has, `status: "publish"` returns `403 live_publish_disabled`, and there is no way around it. Save a draft and tell the user.

## What if I publish the same article twice?

Publishing the same article to the same site twice updates the existing post instead of creating a duplicate, so retrying after a timeout is safe.

## What else protects the account?

* Agent keys work only on `/api/v1/*` and `/mcp`.
* Keys have scopes: `articles`, `publish`, `reddit`. A key without `publish` cannot publish at all.
* Agents cannot create or change a content plan.
* The Reddit agent never posts. The user posts replies from their own account.

Last updated: 2026-10-05

## Related

* [MCP tools reference](/agents/mcp-tools)
* [Errors](/agents/errors)
* [Connect your AI agent](/agents/connect-your-agent)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.