Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@Yizack
Copy link
Owner

@Yizack Yizack commented Sep 12, 2025

MailChannels introduced some changes and new endpoints to the email API

Current version: 0.7.0
Target version: 0.11.0

Email API

New endpoints:

Updated endpoints:

  • 📧 Emails
  • 📢 Webhooks
  • 🪪 Sub-accounts
    • Create Sub-account
      Sub-account creation now requires a company name parameter
      // Before
      subAccounts.create('validhandle123')
      // Now
      subAccounts.create('My Company', 'validhandle123')

In this PR docs must be updated accordingly and fix any type issues

@Yizack Yizack self-assigned this Sep 12, 2025
@Yizack Yizack added the enhancement New feature or request label Sep 12, 2025
@codecov
Copy link

codecov bot commented Sep 12, 2025

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

Thanks for integrating Codecov - We've got you covered ☂️

@Yizack Yizack changed the title feat: support mailchannels email api 0.11.0 feat!: support mailchannels email api 0.11.0 Sep 13, 2025
Sub-account creation now requires a company name parameter, validated to be 3-128 characters. Documentation, types, implementation, and tests have been updated to support and verify this change.
@Yizack Yizack changed the title feat!: support mailchannels email api 0.11.0 feat!: update to mailchannels email api 0.11.0 Sep 13, 2025
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Sep 15, 2025

Deploying mailchannels with  Cloudflare Pages  Cloudflare Pages

Latest commit: 5440475
Status: ✅  Deploy successful!
Preview URL: https://d1f05a3e.mailchannels-1ac.pages.dev
Branch Preview URL: https://email-api-update.mailchannels-1ac.pages.dev

View logs

@Yizack Yizack marked this pull request as ready for review September 16, 2025 12:05
@Yizack Yizack requested a review from Copilot September 16, 2025 12:13
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the MailChannels Email API from version 0.7.0 to 0.11.0, implementing new endpoints and updating existing ones according to the breaking changes in the API specification.

  • Adds new modules for Metrics and Suppressions functionality
  • Updates Sub-accounts module with limit management and usage statistics endpoints
  • Enhances Webhooks module with validation endpoint and endpoint length restrictions
  • Updates Emails module with new campaignId and transactional options

Reviewed Changes

Copilot reviewed 48 out of 76 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/modules/webhooks.ts Adds validate method and endpoint length validation for webhook enrollment
src/modules/suppressions.ts New module implementing suppression list management endpoints
src/modules/sub-accounts.ts Enhanced with limit management, usage stats, and updated create method requiring company name
src/modules/metrics.ts New module for retrieving engagement, performance, volume and usage metrics
src/modules/emails.ts Adds campaignId and transactional options to email sending
src/utils/errors.ts Enhanced error handling for different response data types
test/ files Comprehensive test coverage for all new functionality
docs/ files Updated documentation for all new endpoints and changes
playground/ files Example scripts for testing new endpoints

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@Yizack Yizack merged commit be9b6e3 into main Sep 16, 2025
9 checks passed
@Yizack Yizack deleted the email-api-update branch September 16, 2025 12:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants