Renamed get_ptr to get_ptr_async
Added sync counterpart
Added error_code param