Publishing API

8TML > Reference

Test draft

This API is being tested by an 8TML editor and a reference server to find what works and what doesn’t. Anything here may still change, also in ways that break older programs. When it has settled, a publishing package will be released for everyone. See Publishing pages.

The publishing API is an HTTP interface that creates, replaces, deletes and lists the files of an 8TML site. It is not part of the 8TML language, and reading pages stays ordinary HTTP.

Design

  • Every request is HTTP/1.0 GET or POST, and every reply is short ASCII text of key: value lines, read like an 8TML page header. An 8-bit client needs no JSON, cookies or other HTTP methods.
  • A client publishes either signed, over plain HTTP (the key never travels) or over HTTPS with the key itself, possibly through a local HTTPS proxy (no signing code needed).

Words used here

  • Site: a folder of files served over plain HTTP, such as a T8wn plot or a folder on your own server.
  • Endpoint: the server program that implements the API for one or more sites.
  • Client: a program that publishes: an editor or a command-line tool.