Skip to content

Build on Treechat

Treechat App Connect lets your app act for a Treechat member after they approve it. Your app sends people to Treechat to sign in, they choose to allow it, and your app gets an access token. With that token it can post, reply, start branches, upload media and read threads through a JSON REST API. Nobody shares a password with you.

Examples: a video tool that posts each new episode, a scheduler, a bot that answers in a channel, a reader app.

How Treechat content is shaped

Treechat is a tree of conversations, not a flat feed.

TermMeaning
PostOne message: text, images, audio or video.
ThreadA conversation: a first post and the replies under it.
BranchA thread that grows out of one post. Any post can start a branch, so a conversation can split into side topics.
UpvalueA paid upvote in Bitcoin SV, sent from reader to creator.

Read endpoints return Treechat’s existing JSON, which uses older names: a thread is a quest and a post is an answer.

What an app can and can’t do

An app can:

  • start a thread, reply in a thread, or reply in a post’s branch (treechat:write)
  • upload images, audio and video to attach to posts (uploads:write)
  • read threads and posts the member can see (treechat:read)
  • read the member’s ID and username (account:read)

An app can’t spend the member’s money, send upvalue, or change their account. Posts it makes show “via your app name”. Members can disconnect your app at any time.

Addresses

WhatURL
Register an apphttps://api.treechat.com/developers/apps
Authorization server (issuer)https://api.treechat.com
OAuth discoveryhttps://api.treechat.com/.well-known/oauth-authorization-server
REST API basehttps://api.treechat.com/api/apps/v1
OpenAPI 3.1 descriptionhttps://api.treechat.com/api/apps/v1/openapi.json
MCP server (same tokens)https://api.treechat.com/mcp

Next steps

  1. Quickstart: register, connect and post in a few minutes.
  2. Authentication: OAuth details, permissions and tokens.
  3. API reference: every endpoint, field and response.
  4. Limits and errors: rate limits, error codes and retries.

For AI agents and tools

These docs are published in forms an agent can read directly:

  • /llms.txt: an index of every page, with a one-line summary each.
  • /llms-full.txt: every page in one plain Markdown file.
  • Any page as Markdown: add .md to its path, for example /developers/api-reference.md.
  • https://api.treechat.com/api/apps/v1/openapi.json: the REST API as OpenAPI 3.1, for code generators and tool definitions.

If your agent speaks MCP, it can skip the REST API and connect to https://api.treechat.com/mcp instead. See treechat.com/mcp.