Coupons

Select Coupons of a customer matching product IDs

This endpoint allows to match a set of Product-IDs against the current Coupons attributed to a customer.

Only Rabattcoupons and Bonuscoupons in the state Available or Activated are matched. Partnercoupons, Preview Coupons and Coupons that have been Redeemed already are not returned.

Like in the other endpoints working with Product IDs this endpoint also operates with the IDs of actual, buyable products as well as the corresponding “Sammler” products.

The response contains a map of Coupon GTINs that are applicable to at least one of the given products. The map entries contain the UserCoupon data, whether this Coupon matches the whole sortiment and the actual IDs matched.

Unlike the product matching endpoints on unpersonalised coupons this endpoint only provides the POST variant.

post
https://api-qual.migros.ch/migros/customers/coupons/v3/users/{cumulus}/matches

Path Parameters

cumulusstringrequired

Cumulus number.

Match pattern:^\d{13}$

>= 13 characters<= 13 characters

Example:2099123456789

Body

application/x-www-form-urlencoded

Product IDs to check, provided as (multiple) id form parameter(s).

idstringrequired

Response

application/json

Map of GTINs to coupon and product data

object
post/migros/customers/coupons/v3/users/{cumulus}/matches

Body

{ "id": "id" }
 
application/json

Statistics about available/activated Coupons and UCBs.

This endpoint returns aggregate summary data of a users Coupons and UCBs.

Note that a single ‘Coupons’ can be attributed to a customer several times in which case the Quantity field is larger than 1. The dirac… fields in the response honour Quantity and count such Coupons multiple times while the coupons… field(s) count Coupon types ignoring their Quantity.

get
https://api-qual.migros.ch/migros/customers/coupons/v3/users/{cumulus}/stats

Path Parameters

cumulusstringrequired

Cumulus number.

Match pattern:^\d{13}$

>= 13 characters<= 13 characters

Example:2099123456789

Response

application/json

Summary data.

Stats

Aggregate statistics about Coupons and UCBs of a user.

couponsActivatedintegerrequired

Number of activated Coupons (ignoring Quantity).

Example:3

diracActiveCountintegerrequired

Total number of activated Coupons (counting Quantity).

Example:4

diracAvailableCountintegerrequired

Number of non-redeem Coupons (ignoring Quantity)

Example:7

ucbActiveSumintegerrequired

Sum of all activated UCBs in CHF

Example:30

ucbAvailableSumintegerrequired

Sum of all non-redeemed UCBs in CHF.

Example:75

get/migros/customers/coupons/v3/users/{cumulus}/stats
 
application/json

List of all UCBs attributed to a customer

This endpoint returns the set of all UCBs (aka “Blaue Bons” aka “Cumulus Bons”) attributed to a certain customer, identified by the Cumulus number.

get
https://api-qual.migros.ch/migros/customers/coupons/v3/users/{cumulus}/ucbs

Path Parameters

cumulusstringrequired

Cumulus number.

Match pattern:^\d{13}$

>= 13 characters<= 13 characters

Example:2099123456789

Response

application/json

Lists of UCBs attributed to the customer.

Personalized UCB information of a user based on ReTi.

balanceintegerrequired

Value of this UCB in CHF.

Allowed values:51020

Example:5

expirystring

Valid until (including) this date.

Example:2025-09-30+02:00

idstringrequired

The actual UCB-ID that identifies the individual UCB. This ID is the number/barcode printed on the UCB.

Example:778400003621541383

publishedstring

Valid from (including) this date.

Example:2023-07-18+02:00

redeemedstring

Date and time of redemption.

Example:2015-05-27T08:27:27+02:00

statusintegerrequired

1 = available, 2 = activated, 3 = redeemed.

Allowed values:123

ucbobject

Static data of an UCB (Blauer Bon/Coupon Bon).

Show Child Parameters
get/migros/customers/coupons/v3/users/{cumulus}/ucbs
 
application/json

Activate or deactivate an UCB

Only non-redeem UCBs can be activated or deactivated. It’s okay to activate an already active UCB as it is okay to deactivate an already inactive UCB.

Note that no more than 50 UCBss can be in state ‘activated’ for a single Cumulus number. Trying to activate more results in a 409 error.

Note: The parameters can be sent as query parameters in the URL or as application/x-www-form-urlencoded in the request body (or any combination, it just doesn’t matter.)

post
https://api-qual.migros.ch/migros/customers/coupons/v3/users/{cumulus}/ucbs/{ucbid}:{state}

Path Parameters

cumulusstringrequired

Cumulus number.

Match pattern:^\d{13}$

>= 13 characters<= 13 characters

Example:2099123456789

ucbidstringrequired

ID (barcode) of a UCB. Its a string as it is often longer than what integers can represent (especially in toy languages).

Match pattern:^\d+$

statestringrequired

The action to perform.

Allowed values:activatedeactivate

Example:activate

Response

Successful activated/deactivated

post/migros/customers/coupons/v3/users/{cumulus}/ucbs/{ucbid}:{state}
 

Audit