30 days free. No credit card. Full access from the moment you connect your site.

Start free trial

List Coupons

store/list-coupons lists the discount coupons configured on the store: type, amount, expiry, how many times each has been used, and any limits or restrictions.

Drafts are included as well as published coupons.

At a glance

Abilitystore/list-coupons
ToolsetWooCommerce — toolset/woocommerce
GroupWooCommerce › Coupons
RequiresWooCommerce, active on the site
Capabilitymanage_options
SafetyRead-only — changes nothing
RepeatableIdempotent — running it twice leaves the same result
Ships inAcrossAI Abilities Manager 0.0.34 and later

How it works

Coupons accumulate. A shop that has been running for a few years has dozens, most expired, some with no expiry at all and no usage limit — and it is the ones with no expiry that matter, because a code from a 2019 campaign still works if nobody switched it off.

So the usage count and the limits come back together. A coupon used four hundred times against no limit is a different kind of problem from one used twice.

Drafts are included because a draft coupon still exists as a code, and shops routinely discover that a code someone assumed was inactive is simply unpublished — which, depending on how it was set up, is not the same as disabled.

Input

NameTypeRequiredWhat it is
limitintegerNoHow many coupons to return.

What comes back

NameTypeWhat it is
couponsarrayOne entry per coupon: code, type, amount, expiry, usage count, limits and restrictions.
countintegerHow many were returned.
successbooleanWhether the call completed.
messagestringA one-line summary of what happened, suitable for showing a human.
error_codestringPresent only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation.

Example

Ask your assistant:

What discount codes are live on this store?

It resolves to one call:

{
  "ability": "store/list-coupons",
  "parameters": {}
}

Worth knowing

  • Coupons with no expiry and no usage limit are the ones worth looking at.
  • Drafts are included.
  • The usage count is against the limit, so both come back.

Related abilities


Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager

Browse the rest: Every ability, by category


Keep reading