As of the Bourne, UK sprints last August, bin/cli.php has been completely re-written for 4.1.
If you are an integrator or user, you might not have noticed this file. It used to be a PHP class that was used by many of the individual scripts in the bin directory.
Now, it's a command line program designed to be run directly.
With cli.php you can run any function defined in the API version 3.
If you run the script without any arguments, you'll get a usage statement explaining how it works: