Is there a scripting api for mitmproxy web?

I’d like to add two functionalities to mitmproxy web:

  1. stop recording / pause recording. which will be helpful for the second functionality -
  2. export all flows as har (using the har extension).

Moreover, any contribution guidance will be more then welcome :slight_smile: