Is it really not possible to set subscription status via the CRM API?

Hi,

After lots of research and checking through the CRM API, it seems that it is not possible to set the subscription via code to the create contact function. Is this correct? It seems a little strange that you can code so many other element but subscription? This is my code which creates the contact but won’t set the subscription. Any ideas?

To clarify, the code works and creates the contact, just won’t set the subscription. And no errors are thrown.


function saveCRMPrefrences() {
 let firstName = "Stephen"
 let lastName = "Test"
 let email = 'stephentest@hotmail.com'
 let phone = "444809256050"
 let label = "subscribed"
    wixCrm.createContact({
 "firstName": firstName,
 "lastName": lastName,
 "emails": [email],
 "phones": [phone],
 "subscription": label
        })
        .then((contactId) => {
            console.log('Create Contact - SUCCESS')
        })
        .catch((err) => {
                console.log("Error saving Create Contact");
                console.log(`${err}: Error`)
            });

}

Thank you :slight_smile:

CRM API does not provide ability to set subscription. I have tried to find workarounds in the past but no success till date. Only way you can do it right now is with Wix Forms.

Thanks @shan. Bit of a shame that really… It would save lots of manual work!

I’m sending this on to the relevant Product Manager for info.

1 Like

Thanks @Yisrael
When you send this over, could you mention that when you export the contacts list, then import to another site (I’m currently transferring to Editor X) the subscriptions are all reset to ‘Subscription not set’ So I now have over 120 subscriptions to change to ‘Subscribed’

Sigh…

Good news. They’re working on a new Contacts API and they’ll make sure that subscription can be changed.

You got to me too late about this, but no problem… The Wishlist Page is the new official platform for requesting new features.

Great News… I also need the ability to set the subscription for the user as well. Thank you.

1 Like

@yisrael-wix any development on this?

@stephenmccall The new API is still in development - no ETA.

@yisrael-wix Any news on this?

Hi, I’m looking for this functionality as well. Any update ?

Same - I’m looking for this functionality. Any updates?

@yisrael-wix it’s been almost 2 years… I do see that there’s now a CRM API. But I don’t think there’s a solution there - is there? I’m only looking for read capability, not even write. Is there some other solutio I’m missing?

Hi @Yisreal,

Is there further development on this feature?

Thanks :slight_smile:

It’s 2-1/2 years later and still no ability to set the subscription status?

It looks like they just (finally) added something, still in “developer preview” mode: https://dev.wix.com/api/rest/marketing/email-subscriptions/upsert-email-subscription

Thanks!

This function is still in developer preview, can I know when we are able to use this function?