anchor.diff:        Rev = r.Rev
         Ok = Option.ofNullable r.Ok |> Option.defaultValue false }
   
  -let private asyncMap (fn: 't -> 'u) task = async {
  +let asyncMap (fn: 't -> 'u) task = async {
       let! result = task
   
       return fn result
   }
   
  -let private asyncMapSeq (fn: 't -> 'u) task = async {
  +let asyncMapSeq (fn: 't -> 'u) task = async {
       let! result = task
   
       return Seq.map fn result
   }
  +
  +/// Creates a sequence with a length of one out of the object given.
  +let toSeq x = Seq.ofList [x]
  +
  +/// Used to create a DesignDoc view.
  +let mapFunction func = { defaultViewProps() with map = Some func }
  +
  +/// Used to create a DesignDoc view.
  +let reduceFunction func props = { props with reduce = Some func }
  +
  +/// Creates a DesignDoc view object.
  +let view name (props: ViewProps) =
  +    let v = View()
  +    v.Name <- name
  +    v.MapFunction <- Option.toObj props.map
  +    v.ReduceFunction <- Option.toObj props.reduce
  +    v
  +
  +/// Creates a DesignDoc object for use with the `configureDatabase` and `createDesignDocs` functions.
  +let designDoc name (views: View seq) =
  +    let d = DesignDocConfig()
  +    d.Name <- name
  +    d.Views <- views
  +    d
   
   let database name couchUrl =
       { defaultCouchProps() with databaseName = name; couchUrl = couchUrl }
  
positive.code:     |> Async.AwaitTask
  
  /// Executes the view with the given designDocName and viewName.
  let view<'returnType> designDocName viewName (viewOptions: ViewOptions option) props =
      let client = toClient props
      let options = Option.toObj viewOptions
  
      client.ViewAsync(designDocName, viewName, options)
      |> Async.AwaitTask
  
  /// Gets the document with the given id. If a revision is given, that specific version will be returned.
  
negative.code:     onWarning: (IEvent<EventHandler<string>,string> -> unit) option
  }
  
  type ViewProps = private {
      map: string option
      reduce: string option
  }
  
  let private defaultCouchProps() = {
          username = None
          password = None
  