| Stockholders' equity - Common Stock and Receivable from Shareholder (Details) - shares | May 18, 2017 | Dec. 31, 2018 | Dec. 31, 2017 | Feb. 13, 2013 | 
|---|---|---|---|---|
| Class of Stock [Line Items] | ||||
| Shares issued in acquisition (shares) | 4,662,937 | |||
| Common stock, shares outstanding | 24,824,746 | 24,766,892 | ||
| Preferred stock, shares authorized | 10,000,000 | |||
| American DG Energy | ||||
| Class of Stock [Line Items] | ||||
| Outstanding common shares acquired (percent) | 100.00% | 
| X | ||||||||||
| 
- Definition Number of shares of equity interests issued or issuable to acquire entity. Reference 1: http://www.xbrl.org/2003/role/presentationRef 
 | 
| X | ||||||||||
| 
- Definition Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table. No definition available. 
 | 
| X | ||||||||||
| 
- Definition Number of shares of common stock outstanding. Common stock represent the ownership interest in a corporation. Reference 1: http://www.xbrl.org/2003/role/presentationRef 
 | 
| X | ||||||||||
| 
- Definition The maximum number of nonredeemable preferred shares (or preferred stock redeemable solely at the option of the issuer) permitted to be issued by an entity's charter and bylaws. Reference 1: http://www.xbrl.org/2003/role/presentationRef 
 | 
| X | ||||||||||
| 
- Definition Percentage of subsidiary's or equity method investee's stock owned by parent immediately after all stock transactions. No definition available. 
 | 
| X | ||||||||||
| 
- Details 
 |