added a type parameter for the result of the commands