def to_json(self):
        payload = {
            "btc_addr": self.btc_addr,
            "payout_addr": self.payout_addr,
            "last_seen": (datetime.utcnow() - self.last_seen).seconds,
            "height": self.height
        }
        return json.dumps(payload)
Object to JSON payload.
dataset/ETHPy150Open Storj/dataserv/dataserv/Farmer.py/Farmer.to_json