I've used a similar service (aivren/poloniexlendingbot) but to be honest the interest rates available on poloniex are total garbage, so not worthwhile. Not looked at margin lending rates on bitfinex, but I doubt it's much better.
They are much better.