pass document in every call