mailcow.js
v1.0.2
Published
A simple mailcow API Wrapper
Readme
Mailcow.js
The unofficial Mailcow nodejs wrapper
About
Mailcow.js is a simple and easy-to-use Node.js library designed to interact with the Mailcow email server API. With this library, you can effortlessly manage mailboxes, domains, aliases, sync jobs, and more, all through a clean and intuitive interface.
Installation
NPM
npm i TBD
Yarn
yarn add TBD
Client
const Mailcow = require('mailcow.js');
const mailcow = new Mailcow('https://mail.yourdomain.org/', {
readOnlyKey: 'XXXX-XXXX-XXXX-XXXX',
writeKey: 'XXXX-XXXX-XXXX-XXXX'
});
// Get user mailbox
mailcow.getUserMailBox('[email protected]')
.then(data => console.log(data))
.catch(err => console.error(err));
// Add a new domain
mailcow.addDomain({ domain: 'newdomain.org' })
.then(data => console.log(data))
.catch(err => console.error(err));
