Add support for kwargs

Cf minimalKB for the required protocol changes