add support for the sleep API