Adjusting library API to match working documentation.