 apiServer = restService {name: "mockableHttpServer"}
 apiServer.methods {
   "routes": {
-    docs: "",
+    docs: """
+    Manages the list of all known routes.
+
+    GET returns object, where key is a route ID and value is content
+      that was previously passed to POST /routes.
+
+    POST creates a new route, and returns new route ID.
+
+    Route's content:
+    * path: string
+      REQUIRED. Regexp of URL to match.
+    * times: uint
+      OPTIONAL. The route will expire after these number of calls.
+    * method:  string
+      OPTIONAL. Matches only specified method. If absent, all methods are matched.
+    * log: true
+      OPTIONAL. If present, you can issue http://127.0.0.1:31337/log/{route_id} to receive logged request.
+    * priority: int
+      REQUIRED. Priority of the route. Routes with higher priority are processed first.
+    * response:
+      REQUIRED, conflicts with forward. This action will send predefined static response.
+        code: uint. HTTP code to send.
+        body: string. Body of HTTP response.
+    * forward:
+      REQUIRED, conflicts with response.
+      Will silently relay HTTP request to specified server. And relay back the response.
+      * host: string
+      * port: uint
+
+    Example request body:
+      ```
+      {
+          path: '^ajax$',
+          times: 1,
+          priority: 99,
+          log: true,
+          method: 'POST'
+          response:
+          {
+              code: 500,
+              body: 'Internal server error'
+          }
+      }
+      ```
+
+    DELETE removes all routes.
+
+    @param {object} data: Route's content.
+    """,
     url: "/routes",
 
     get: () ->

      mockableHttpServer.methodRouteDelete(id)
  },
  "logs": {
    docs: "",
    url: "/logs",

    get: () ->
      return mockableHttpServer.methodLogsGet()
  }
  "log": {
    docs: "",
    url: "/log/:id?timeout=:timeout",

    get: (id, timeout) ->

      return mockableHttpServer.methodRoutesDelete()
  },
  "route": {
    docs: """
    Manages a specific route.

    * GET returns the route's content.

    POST replaces route's content with given one.

    DELETE removes the route.

    @param {string} id: Route's ID.
    @param {object} data: Route's content.
    """,
    url: "/route/:id",

    get: (id) ->
