added API documentation