wix-marketing-backend API | createCoupon() | appliesToSubscriptions always set to false

Hi,

I’m using the createCoupon method from the wix-marketing-backend API to create new coupons for a specific pricing plan from the backend of my site. Pretty much everything is working ok, but I can’t seem to get the coupon to apply to only the first billing cycle. Here is how I create the coupon info:

let couponInfo = {
“name”: “someName”,
“code”: “someUniqueCode”,
“startTime”: new Date(),
“active”: false,
“scope”: {
“namespace”: “pricingPlans”,
“group”: {
“name”: “plan”,
“entityId”: “thePlanID”
}
},
“percentOffRate”: 10,
“appliesToSubscriptions”: true,
“discountedCycleCount”: 1
}

From what I can tell looking at the collection, for some reason appliesToSubscriptions is always set to false, so discountedCycleCount is empty and the coupon applies to all plans.

Can anyone tell me what I’m doing wrong please?