Product

Default API version now V3

The product update that announced the changes from v2 to v3 in Mailgun's API. Read more –

PUBLISHED ON

PUBLISHED ON

This was originally announced on March 23, 2015.

We’ve made several performance and stability enhancements to our API recently. Because of the significance of the changes and also to keep our API consistent, we’re changing the default base URL to /v3.

https://api.mailgun.net/v3/

v3 is backward compatible with v2

No need to change your endpoints. All existing API methods remain backward compatible and keep the same request/response format. However, there will be some behavioral changes in a few of them.

Suppressions API (bounces, unsubscribes and complaints)

We made some significant changes to our suppressions API, which manages your bounces, unsubscribes and complaints.

Everything mentioned below for “bounces” is true for “unsubscribes” and “complaints” as well.

Changes related to /v2

  • The current GET /v2/<domain>/bounces method preserves the same request/response format but effectively becomes an alias for the Events API so will be able to return bounces occurred in the past 30 days only. Due to the way the Events API works, total_count returned via this API call will no longer be accurate and preserved for backward compatibility purposes only.

What’s new in /v3

  • The new GET /v3/<domain>/bounces method used for iterating over all domain’s bounces returns bounce addresses in alphabetical order, so can no longer be used for polling for the most recent bounces. It is also much faster and more stable than its /v2 counterpart when iterating over large lists.

  • The new batch upload method lets you upload many bounces in a single API call.

  • Tweaks to request/response formats of other suppressions API methods that make for cleaner API in general.

New suppressions API docs available here.

What does this mean for me?

If you’re currently using /v2/<domain>/bounces API to poll for most recently occurred bounces, you can continue using it but do not rely on total_count. If, however, you need to reliably pull all domain’s bounces, please use /v3/<domain>/bounces API call.

Most of our customers should be unaffected by these changes. If anything you should experience a performance upgrade with our APIs. If this does affect you feel free to contact our Support team with any questions.

Happy Sending!

Sign Up

It's easy to get started. And it's free.

See what you can accomplish with the world’s best email delivery platform.

Related readings

Forrester TEI study reveals Sinch Mailgun ROI and outcomes

When an enterprise starts working with Sinch Mailgun, what’s the financial impact that choice has on the business? It’s a good question – but not exactly an easy one to answer...

Read more

Here’s how to track email opens in Gmail with email tracking

Sending email campaigns doesn’t have to feel like you’re throwing darts into a black hole. Email analytics are a great way to determine the health of your ecommerce campaign and...

Read more

Everything you need to know about sending email with APIs

Are you creating an e-commerce web page that needs to send transactional emails to customers? A developer building a web application that needs to send messages to email...

Read more

Popular posts

Email inbox.

Build Laravel 10 email authentication with Mailgun and Digital Ocean

When it was first released, Laravel version 5.7 added a new capability to verify user’s emails. If you’ve ever run php artisan make:auth within a Laravel app you’ll know the...

Read more

Mailgun statistics.

Sending email using the Mailgun PHP API

It’s been a while since the Mailgun PHP SDK came around, and we’ve seen lots of changes: new functionalities, new integrations built on top, new API endpoints…yet the core of PHP...

Read more

Statistics on deliverability.

Here’s everything you need to know about DNS blocklists

The word “blocklist” can almost seem like something out of a movie – a little dramatic, silly, and a little unreal. Unfortunately, in the real world, blocklists are definitely something you...

Read more

See what you can accomplish with the world's best email delivery platform. It's easy to get started.Let's get sending
CTA icon