listing documents directly from the database via the API