muesli / beehive

A flexible event/agent & automation system with lots of bees 🐝
GNU Affero General Public License v3.0
6.27k stars 320 forks source link

Embedding API #309

Open rubiojr opened 4 years ago

rubiojr commented 4 years ago

Highlights:

This makes it easier to:

Clients embedding Beehive's don't have a built-in HTTP API server started by default, which is probably desirable and safer if you're programming your own chains, as opposed to using the GUI to create them.

I've included an example that demonstrates embedding. Also implemented the Hello bee action the example is using.

In future iterations, we could expose an interface to start/stop the API server also, maybe add a few functions that wrap the event, action and chain creation while adding some safety.

rubiojr commented 4 years ago

A slightly more complex example that demonstrates using an out-of-tree bee in an external repo: https://github.com/rubiojr/commit-monitor

coveralls commented 4 years ago

Coverage Status

Coverage remained the same at 72.705% when pulling e098b31f25ce1e9c9a198401aa5d605da700b476 on reactor into f8fd3de0f4be68c5b4d1c1083734546b5f838e61 on master.