Issue with consent api

Hi there,
I’m from the Ecwid team and working on integration of the Ecwid cookie consent functionality with the Wix consent API (e.g. using Wix.Utils.getCurrentConsentPolicy and Wix.Utils.getCurrentConsentPolicy).It looks like there is an issue in the Wix consent response.
Specifically with the defaultPolicy field:
“defaultPolicy”: false, // True = this policy is the default policy for the site as defined by the site owner. False = the user actively accepted / set this policy.

When the user accepts all the policies by default, the defaultPolicy is expected to be True.But, both in the event of a callback or a direct request for the value with getCurrentConsentPolicy, the output is False.
And after refreshing the page, and following refreshing, the output is as expected defaultPolicy = true.Here is the screencast [ recordit . co/mvJY6YvQlD ]

Is there any explanation for this?

The idea behind the defaultPolicy param is to say whether the policy chosen by this user is the default policy of the site (as chosen by the site owner) or if there was any change.

So for example, if the site owner has set to load only essential cookies and a visitor clicked Accept- defaultPolicy will be false, because the the visitor’s policy is different from the policy set by the site owner.

‘false‘ is only in case the site visitor has a cookie set which he chose. All other cases should be true.
Essentially, this doesn’t matter for Applications trying to comply, they should just read the actual policy. And the best way is by using the JS SDK, since updates will not change the URL.

Sorry, I didn’t get it

So if the user didn’t customize a cookie set manually and just clicked Allow, what will be expected in defaultPolicy: false or true?
And why after page refreshing defaultPolicy state changed - from false to true in my flow case?

@kruz Any time a user sets a policy (by accepting or customizing options) the policy turns to defaultPolicy:false . This is permitted by a cookie and should remain constant as long as the policy is not reset, the cookie is not erased and a year has not passed from the date of setting the policy.

If you have a consent-policy cookie + you get back defaultPolicy=true after refresh => that would be a bug and we would definitely want to take a look at it. Please provide us with a site and a way to reproduce the issue. Please make sure you have cookies enabled on your browser.

Here is the link to screencast [ recordit . co/mvJY6YvQlD]
(avoid spaces around dot)

Hi Alexander,
Thanks for your patience. The team is currently investigating the issue. Please note that most of our Israel office is on holiday this week, so we may not be back in touch with an answer until next week.

Hi Alexander,
The team was unable to reproduce the issue. Are you still experiencing the problem? If so, please let me know the best way to contact you so I can connect you with one of our developers. Thanks.

Hi Marlowe

After your recent post, I thought we might have an old version of the Wix js SDK.
We are using 1.425.0, but next and the latest is 1.537.0.
But in the latest version it is reproduced exactly the same.
There is the fresh screencast https://recordit . co/9m6tt8WK7z (avoid spaces around dot)
It is interesting that the fields ‘advertising’, ‘analytics’, ‘functional’ change their state immediately as expected, but ‘defaultPolicy’ only after refreshing the page (refer to screencast).

You can contact me by email from my profile. I can provide a test site where issue happens.