Back to ChangelogBack to Changelog

API stats filtering and coupon fixes

Campaign and automation statistics API endpoints now support date filtering, three fixes for discount coupons (validity date display, sent coupon export, CSV import), fix for sending templates with an unavailable product, and fix for loading contact names from Ecwid.

IMPROVEMENT

API: campaign and automation statistics can be filtered by date

The GET /campaigns/{id}/stats and GET /pipelines/{id}/stats endpoints now support optional from_date and to_date parameters in YYYY‑MM-DD format. The same parameters were also added to the stats‑detail endpoints, where previously only from_date worked. Filtering lets you retrieve statistics day by day without loading the full history.

FIX

Discount coupons: three fixes for display, export and import

The merge tag for the validity date of the last sent discount coupon was not displayed in automation emails ‑ fixed. The export of sent coupons in a folder was not sent after clicking the button ‑ fixed, the export is now delivered reliably. Importing coupons from a CSV file could fail in certain cases ‑ fixed.

FIX

Automations: templates with an unavailable product are now sent

If a template in an automation contained a product condition (e.g. last purchased product) that was not available in the feed or did not meet the specified condition, the email was not sent and the automation failed without an error message. The template is now sent even when the product condition is not met ‑ the product is omitted from the email, but the rest of the template is delivered.

FIX

Ecwid: contact name now loads correctly

The Ecwid integration was loading the contact name from an API field that Ecwid stopped populating. We switched to the current field per Ecwid's corrected documentation.

newsletterStay up to date

Once in a while, we will send a summary of new features, improvements, and fixes to your inbox. No spam, no marketing – just product updates from Ecomail.