The JokeAPI is not only capable of getting jokes, you can also create new jokes. It would be interesting if the CLI was extended to also add jokes using the submit endpoint.
In order to do this we would have to update the current CLI command, possibly by using the @click.group() decorator like this:
@click.group()
def jokes():
...
@jokes.command() # @jokes not @click
def get():
...
@jokes.command() # @jokes not @click
def add():
...
Steps
[x] Split main method into multiple commands (jokes and add), making jokes the group command
[x] Add new submit request and corresponding command
Jokes API has turned off the ability to submit jokes "for the foreseeable future", and all work related to this was removed in #29, so closing this until the functionality comes back.
The JokeAPI is not only capable of getting jokes, you can also create new jokes. It would be interesting if the CLI was extended to also add jokes using the submit endpoint.
In order to do this we would have to update the current CLI command, possibly by using the
@click.group()
decorator like this:Steps
jokes
andadd
), makingjokes
the group command