1. I think this should have an optional "id" field. This will allow one webhook service to handle multiple machines. For example if you create a wake on LAN webhook the id would be the MAC address.
2. We require unit tests for all branches to land.
3. MAAS uses Twisted[1] for HTTP calls. This allows MAAS to perform other tasks while waiting for the response.
4. See other comments below
If Twisted looks to complicated you can skip 2 and 3 and I'll Twistify it and add unit tests in a follow up branch.
Thanks for the patch! Couple of things
1. I think this should have an optional "id" field. This will allow one webhook service to handle multiple machines. For example if you create a wake on LAN webhook the id would be the MAC address.
2. We require unit tests for all branches to land.
3. MAAS uses Twisted[1] for HTTP calls. This allows MAAS to perform other tasks while waiting for the response.
4. See other comments below
If Twisted looks to complicated you can skip 2 and 3 and I'll Twistify it and add unit tests in a follow up branch.
[1] https:/ /twistedmatrix. com/documents/ current/ web/howto/ client. html