updated the doc and the api