   #
   # docName - The name of the document to retrieve.
   #
-  # data = {v, snapshot, type}. Snapshot == null and v = 0 if the document doesn't exist.
-  #
-  # Calls callback with (null, data) upon sucesss. Otherwise it calls callback with (error)
+  # Calls callback('Document does not exist') if no document exists.
+  # Calls callback(error) on failure.
+  # Calls callback(null, { v:int, snapshot:string, type:typename, meta:string }) on success.
   @getSnapshot = (docName, callback) ->
     async.auto(
       get_snapshot: (cb) ->

        callback?()
    )

  # Public: Get all ops with version = start to version = end. Noninclusive.
  # end is trimmed to the size of the document.
  #
  # If any documents are passed to the callback, the first one has v = start
  # end can be null. If so, returns all documents from start onwards.
  #
  # Each document returned is in the form {op:o, meta:m, v:version}.
  #
  # docName - Name of the document
  # start   - The noninclusive starting version.
  # end     - The noninclusive ending version.
  #
  # Calls callback(null, data) on success and otherwise calls the callback with
  # just the error.
  @getOps = (docName, start, end, callback) ->
    end = 2147483648 unless end?
    return callback("Start must be less than end", []) if start >= end

  # Public: Creates a new document.
  #
  # docName - The unique name of the new document.
  # docData - { snapshot:string, type:string, v:int, meta:string }
  #
  # Calls callback('Document already exists') if the document already exists.
  # Calls callback(error) on failure.
  # Calls callback() on success.
  @create = (docName, docData, callback) ->
    async.auto(
      write_metadata: (cb) ->
