From 8523af13854b0a073bbf55ac24542915f1490255 Mon Sep 17 00:00:00 2001 From: Richard van der Hoff Date: Wed, 12 Oct 2016 10:29:53 +0100 Subject: [PATCH] Document convention of using underscores in APIs Everybody has agreed to it. Now we just have to remember to do it. --- specification/client_server_api.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/specification/client_server_api.rst b/specification/client_server_api.rst index d95164c5..1b4aac3f 100644 --- a/specification/client_server_api.rst +++ b/specification/client_server_api.rst @@ -72,6 +72,15 @@ MUST be encoded as UTF-8. Clients are authenticated using opaque ``access_token`` strings (see `Client Authentication`_ for details), passed as a query string parameter on all requests. +The names of the API endponts for the HTTP transport follow a convention of +using underscores to separate words (for example ``/delete_devices``). + +.. NOTE:: + There are a few historical exceptions to this rule, such as + ``/createRoom``. A future version of this specification will address the + inconsistency. + + Any errors which occur at the Matrix API level MUST return a "standard error response". This is a JSON object which looks like: