<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.chuk.dev/index.php?action=history&amp;feed=atom&amp;title=Chuk_Chat_Backend_and_API</id>
	<title>Chuk Chat Backend and API - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.chuk.dev/index.php?action=history&amp;feed=atom&amp;title=Chuk_Chat_Backend_and_API"/>
	<link rel="alternate" type="text/html" href="https://wiki.chuk.dev/index.php?title=Chuk_Chat_Backend_and_API&amp;action=history"/>
	<updated>2026-04-15T01:54:52Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.1</generator>
	<entry>
		<id>https://wiki.chuk.dev/index.php?title=Chuk_Chat_Backend_and_API&amp;diff=25&amp;oldid=prev</id>
		<title>AI-Assistant: Add user-friendly backend and API architecture documentation</title>
		<link rel="alternate" type="text/html" href="https://wiki.chuk.dev/index.php?title=Chuk_Chat_Backend_and_API&amp;diff=25&amp;oldid=prev"/>
		<updated>2026-03-13T18:09:09Z</updated>

		<summary type="html">&lt;p&gt;Add user-friendly backend and API architecture documentation&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= Chuk Chat Backend and API =&lt;br /&gt;
&lt;br /&gt;
This page explains the backend in practical terms.&lt;br /&gt;
&lt;br /&gt;
== Base backend URL ==&lt;br /&gt;
https://api.chuk.chat&lt;br /&gt;
&lt;br /&gt;
== Authentication model ==&lt;br /&gt;
Most endpoints require a Bearer token from your signed-in account session.&lt;br /&gt;
&lt;br /&gt;
== Key endpoint groups ==&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Health&amp;#039;&amp;#039;&amp;#039;: service status&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Chat streaming&amp;#039;&amp;#039;&amp;#039;: SSE and WebSocket chat endpoints&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Model/config endpoints&amp;#039;&amp;#039;&amp;#039;: list models and configuration&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Media endpoints&amp;#039;&amp;#039;&amp;#039;: image generation, audio transcription, file conversion&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;User endpoints&amp;#039;&amp;#039;&amp;#039;: status, billing, and account actions&lt;br /&gt;
&lt;br /&gt;
== Streaming protocols ==&lt;br /&gt;
=== SSE (HTTP) ===&lt;br /&gt;
* Endpoint: POST /v1/ai/chat&lt;br /&gt;
* Great compatibility for browser-style request/response streaming&lt;br /&gt;
&lt;br /&gt;
=== WebSocket ===&lt;br /&gt;
* Endpoint: /v1/ai/chat/ws&lt;br /&gt;
* Better for long-lived sessions and mobile stability&lt;br /&gt;
&lt;br /&gt;
== Typical chat response events ==&lt;br /&gt;
* content chunks&lt;br /&gt;
* reasoning chunks (for reasoning-capable models)&lt;br /&gt;
* usage/tokens&lt;br /&gt;
* provider/model metadata&lt;br /&gt;
* done marker&lt;br /&gt;
&lt;br /&gt;
== Rate limit examples ==&lt;br /&gt;
The backend includes request limits to protect stability, including separate limits for chat, audio transcription, and image generation.&lt;br /&gt;
&lt;br /&gt;
== Billing-related backend flows ==&lt;br /&gt;
* checkout session creation&lt;br /&gt;
* customer portal session creation&lt;br /&gt;
* subscription sync endpoint&lt;br /&gt;
&lt;br /&gt;
== Why this backend design exists ==&lt;br /&gt;
* Fast streaming UX&lt;br /&gt;
* Multi-provider AI routing&lt;br /&gt;
* Security and privacy controls&lt;br /&gt;
* Clear separation of chat, media, and billing responsibilities&lt;br /&gt;
&lt;br /&gt;
== Related pages ==&lt;br /&gt;
* [[How Chuk Chat Works]]&lt;br /&gt;
* [[Chuk Chat Architecture]]&lt;br /&gt;
* [[Chuk Chat AI Providers and Services]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Chuk Chat]]&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>AI-Assistant</name></author>
	</entry>
</feed>