aszlig / hetzner

A high-level Python API for accessing the Hetzner robot.
https://pypi.python.org/pypi/hetzner
Other
128 stars 36 forks source link

Pull SubCommands into libraries #17

Open eljobe opened 8 years ago

eljobe commented 8 years ago

I'd like to make a command-line tool very similar in structure to the hetznerctl tool you have. But, it would have different SubCommand instances specific to the needs of my organization. It would be great to extract the definitions of the commands and the generic parts of the main function into libraries which would make it easy for my tool to use some of the same SubCommand instances, plus some new ones of my own design.

If you think this is a good idea, I'd be happy to provide you a pull-request refactoring the code for better reuse. (For now, I've just copied and pasted the parts I actually want from the hetznerctl tool.

Let me know.

almereyda commented 3 years ago

The subcommands could vaguely refer to the object types presented at https://robot.your-server.de/doc/webservice/de.html

Currently these are:

of which some are already available here. A complete API client implementation could also profit from a Hetzner Robot OpenAPI definition, which does not seem to be available at this point.

8 will be helpful in patching things up here.