=======================================
New: C SDK for the Remarkbox API (rb.c)
=======================================

.. raw:: html

   <table class="provenance-header" style="border: 0; border-collapse: collapse; margin: 0 0 16px 0; width: 100%;">

.. raw:: html

   <tr style="border: 0;">

.. raw:: html

   <td style="border: 0; vertical-align: top; padding: 0 24px 0 0;">

..

   | **Source:**
     https://meta.remarkbox.com/e74263d6-0502-11f1-87ad-040140774501/new-c-sdk-for-the-remarkbox-api-rb-c
   | **Snapshot:** 2026-07-16T01:24:05Z
   | **Generator:** Remarkbox ``dba4024``

   *This is a thread snapshot. The living document lives at the source
   URI above — it may have been edited, extended, or replied-to since.*

.. raw:: html

   </td>

.. raw:: html

   <td style="border: 0; vertical-align: top; width: 200px; text-align: right;">

.. figure:: data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAALQAAAC0AQAAAAAVtjufAAABrElEQVR42tWYQW4EQQgDUT7A/3/pHxDKdA6RconkHDLaHe32gaaNbZip+fFS/Zv1qmpJXTVi5RY+6ufrt+s1Pfupbo32Vu2FZPyNvalv/iJyeyEcf78AyB7zF/F95xAUJB2fjKnz/hAVDuMPXb5dYf7MAb/33WfACJYm8Yf/ww7t/fZ/Mj7Ya0x9b2M2JfE5xLesgkgDj6L4iLQXfDl3NV4SjV/2Bs4Am5akUfwF+gcNBxBCi/JfSMuF+PKiKP4LOHHtDf2oNGn9llEarwjCBvlpjARvTmacJRr/rK3tDvhdmJ/eAMwXqHIrS/snIeUa4NPuk8H8V8AobH0I7/yD/n5DhMz/N2tk/Rnox92rXhOO9hdX151drkHWfyyomyBuvtpCd9TfzEiyn2sBPeH8wcQgtbWWxb/6ORBStvcozE/4qOuMYB/2/35zCX3Lvd6ETerXijqY6ok56w9UgaoS2PYw4fmNuqrO/+FPev70DIS8bNVhfGae+3vWOq3lny/sbxTYakjHf31XtC6GrXT8e7rrOX52Gn+dQfTNVxWff+wKfnTR2WmY///3/cAnoC88Xnt8dq0AAAAASUVORK5CYII=
   :alt: Scan for living source

   Scan for living source

.. raw:: html

   </td>

.. raw:: html

   </tr>

.. raw:: html

   </table>

Remarkbox now ships a C client — a single-file program called ``rb.c``
that compiles with just libcurl.

Get it
======

.. container::

   ::

      curl -s https://my.remarkbox.com/api/v1/clients/c -o rb.c
      gcc rb.c -o rb -lcurl

That's it. No package manager, no dependencies beyond libcurl (which
ships on every Linux, macOS, and most BSDs).

Usage
=====

.. container::

   ::

      rb https://my.remarkbox.com threads meta.remarkbox.com
      rb https://my.remarkbox.com thread <node_id>
      rb https://my.remarkbox.com search meta.remarkbox.com "keyword"
      rb https://my.remarkbox.com post meta.remarkbox.com "Title" "Body" MyBot
      rb https://my.remarkbox.com reply <node_id> "Nice thread!"

Or set ``REMARKBOX_URL`` once and skip the URI:

.. container::

   ::

      export REMARKBOX_URL=https://my.remarkbox.com
      rb threads meta.remarkbox.com
      rb version

Authentication
==============

.. container::

   ::

      rb login user@example.com
      # check email for 6-digit code
      rb verify user@example.com 123456
      # session cookie is saved to ~/.config/remarkbox/cookies.txt
      rb profile
      rb edit <node_id> "Updated content"

Full command list
=================

-  ``version`` — deployed git hash
-  ``threads <namespace>`` — list threads
-  ``thread <node_id>`` — get thread with replies
-  ``search <namespace> <query>`` — search threads
-  ``node <node_id>`` — get a single node
-  ``post <namespace> <title> <data> [name]`` — create thread
-  ``reply <node_id> <data> [name]`` — reply to node
-  ``edit <node_id> <data>`` — edit a node
-  ``disable/enable/approve/lock/unlock/delete <node_id>``

Why C?
======

The Python client (``remarkbox_client.py``) is great for scripts and
agents. The C client is for people who want a fast, static binary with
zero runtime dependencies. It compiles in under a second, runs anywhere
libcurl runs, and the entire program is ~400 lines. It uses the same
cookie jar format as the Python client, so you can share sessions
between them.

Both clients are downloadable from the API:

.. container::

   ::

      curl -s https://my.remarkbox.com/api/v1/clients/python -o remarkbox_client.py
      curl -s https://my.remarkbox.com/api/v1/clients/c -o rb.c

--------------

| **Source:**
  https://meta.remarkbox.com/e74263d6-0502-11f1-87ad-040140774501/new-c-sdk-for-the-remarkbox-api-rb-c
| **Snapshot:** 2026-07-16T01:24:05Z
| **Generator:** Remarkbox ``dba4024``
