Skip to main content
Answer

Is it possible to update push consent via React Native SDK or Node API?

  • April 18, 2025
  • 1 reply
  • 77 views

Forum|alt.badge.img

Hello! We’re currently setting up push notifications for our users, and it seems that currently there’s no straightforward way for a user to opt out of Klaviyo push notifications specifically. Our app uses multiple push services, so directing users to turn off all notifications from our app isn’t a viable option if they only want to turn off Klaviyo.

I understand there’s an endpoint to unregister a push token, but for users with multiple devices this would entail collecting all their push tokens and then looping over them to make sure they’re all unregistered. I’ve also seen mention of using the Segments API somehow to manage their consent. Would one of these approaches be better as a workaround than the other?

Thanks!

Best answer by whereisjad

@jashton I recommend utilizing the following endpoint to retrieve push tokens for a specific profile: https://developers.klaviyo.com/en/reference/get_push_tokens_for_profile

Please note that you will need to first make a request to this endpoint: https://developers.klaviyo.com/en/reference/get_profiles in order to obtain the profile ID.

The GET request can be configured as follows:

https://a.klaviyo.com/api/profiles/?filter=equals(email,"<email>")

Assuming you have the email address associated with the profile, you may also utilize the phone number as a filter by using the `phone_number` parameter instead of the email.

1 reply

whereisjad
Expert Problem Solver IV
Forum|alt.badge.img+16
  • Expert Problem Solver IV
  • Answer
  • April 18, 2025

@jashton I recommend utilizing the following endpoint to retrieve push tokens for a specific profile: https://developers.klaviyo.com/en/reference/get_push_tokens_for_profile

Please note that you will need to first make a request to this endpoint: https://developers.klaviyo.com/en/reference/get_profiles in order to obtain the profile ID.

The GET request can be configured as follows:

https://a.klaviyo.com/api/profiles/?filter=equals(email,"<email>")

Assuming you have the email address associated with the profile, you may also utilize the phone number as a filter by using the `phone_number` parameter instead of the email.