]> Sergey Matveev's repositories - paster.git/blobdiff - doc/protocol.texi
Texinfo documentation, website and asciicasts
[paster.git] / doc / protocol.texi
diff --git a/doc/protocol.texi b/doc/protocol.texi
new file mode 100644 (file)
index 0000000..12e0a4f
--- /dev/null
@@ -0,0 +1,16 @@
+@node Protocol
+@unnumbered Protocol
+
+Protocol is very simple: @url{https://en.wikipedia.org/wiki/Bencode,
+bencode}d dictionary is sent over TCP.
+
+@itemize
+@item @code{v} key contains the data you want to paste
+@item optional @code{e} key, holding the desired filename extension,
+    without the leading dot, up to 9 characters long
+@end itemize
+
+@example
+"hello world" => d1:v11:hello worlde
+"http://example.com/" and "url" extension => d1:e3:url1:v18:http://example.come
+@end example