Node.js SDK to integrate MailChannels API into your JavaScript or TypeScript server-side applications.
npm install mailchannels-sdk[![npm version][npm-version-src]][npm-version-href]
[![npm downloads][npm-downloads-src]][npm-downloads-href]
[![codecov][codecov-coverage-src]][codecov-coverage-href]
Node.js SDK to integrate MailChannels API into your JavaScript or TypeScript server-side applications.
This library provides a simple way to interact with the MailChannels API. It is written in TypeScript and can be used in both JavaScript and TypeScript projects and in different runtimes.
> [!IMPORTANT]
> Disclaimer: This library is not associated with MailChannels Corporation.
- ✨ Release Notes
- 📖 Documentation
- 🚀 Features
- 📏 Requirements
- 🏃 Quick setup
- 🚧 Roadmap
- ⚖️ License
- 💻 Development
- Send transactional emails
- Check DKIM, SPF & Domain Lockdown
- Configure DKIM keys
- Webhook notifications
- Manage sub-accounts
- Retrieve metrics
- Handle suppressions
- Configure inbound domains
- Manage account and recipient lists
- Create a MailChannels account
- Create an API key
1. Add mailchannels-sdk dependency to your project
``shnpm
npm i mailchannels-sdk
⚖️ License
🚧 Roadmap
Already implemented features are marked with a checkmark. Please open an issue if you find any bugs or missing features.
> [!NOTE]
> Links below point to the official MailChannels API documentation, options and responses may differ slightly when using this SDK. Please refer to the documentation for the correct usage of each feature.
$3
- 📧 Emails
- ✅ Send an Email
- ✅ Send an Email Asynchronously
- ✅ DKIM, SPF & Domain Lockdown Check
- ✅ Create DKIM Key Pair
- ✅ Retrieve DKIM Keys
- ✅ Update DKIM Key Status
- ✅ Rotate DKIM Key Pair
- 📢 Webhooks
- ✅ Enroll for Webhook Notifications
- ✅ Retrieve Customer Webhooks
- ✅ Delete Customer Webhooks
- ✅ Retrieve Webhook Signing Key
- ✅ Validate Enrolled Webhook
- 🪪 Sub-accounts
- ✅ Create Sub-account
- ✅ Retrieve Sub-accounts
- ✅ Delete Sub-account
- ✅ Suspend Sub-account
- ✅ Activate Sub-account
- ✅ Create Sub-account API Key
- ✅ Delete Sub-account API Key
- ✅ Retrieve Sub-account API Keys
- ✅ Create Sub-account SMTP Password
- ✅ Delete Sub-account SMTP Password
- ✅ Retrieve Sub-account SMTP Passwords
- ✅ Retrieve Sub-account Limit
- ✅ Set Sub-account Limit
- ✅ Delete Sub-account Limit
- ✅ Retrieve Sub-account Usage Stats
- 📊 Metrics
- ✅ Retrieve Engagement Metrics
- ✅ Retrieve Performance Metrics
- ✅ Retrieve Recipient Behaviour Metrics
- ✅ Retrieve Usage Stats
- ✅ Retrieve Volume Metrics
- ✅ Retrieve Sender Metrics
- 🚫 Suppressions
- ✅ Create Suppression Entries
- ✅ Delete Suppression Entry
- ✅ Retrieve Suppression List
$3
- 🌐 Domains
- ✅ Provision domain
- ✅ Remove domain
- ✅ List domains
- ✅ Bulk provision domains
- ✅ Add domain list entry
- ✅ Get domain list entries
- ✅ Delete domain list entry
- ✅ Create login link
- ✅ Bulk create login links
- ✅ Set downstream address
- ✅ Fetch downstream addresses
- ✅ Update API key
- 📋 Lists
- ✅ Add item to customer list
- ✅ Delete item from customer list
- ✅ Get customer list entries
- 📥 Users
- ✅ Create a recipient
- ✅ Add item to recipient list
- ✅ Get recipient list entries
- ✅ Delete item from recipient list
- ⚙️ Service
- ✅ Retrieve the condition of the service
- ✅ Submit a false negative or false positive report
- ✅ Get a list of your subscriptions to MailChannels Inbound
💻 Development
Local development
`sh
Install dependencies
pnpm installBuild the package
pnpm buildRun ESLint
pnpm lintRun Vitest
pnpm test
pnpm test:watchRun typecheck
pnpm test:typesRelease new version
pnpm release
``
[npm-version-src]: https://img.shields.io/npm/v/mailchannels-sdk.svg?style=flat&colorA=070a30&colorB=35a047
[npm-version-href]: https://npmjs.com/package/mailchannels-sdk
[npm-downloads-src]: https://img.shields.io/npm/dm/mailchannels-sdk.svg?style=flat&colorA=070a30&colorB=35a047
[npm-downloads-href]: https://npmjs.com/package/mailchannels-sdk
[codecov-coverage-src]: https://img.shields.io/codecov/c/github/yizack/mailchannels?style=flat&colorA=070a30&token=HTSBRHSJ5M
[codecov-coverage-href]: https://codecov.io/gh/Yizack/mailchannels