Wrap the actual doc object inside a doc key and allow for upsert option