question

Lucas [not provided] avatar image
Lucas [not provided] asked

Get all Players IDs? SendPush to all?

I can't seem to find a method in any API to get the full list of registered players for my titles. Is that not possible?

I ask because I plan on sending push notifications to my users when some important updates come along, so how could I do that?

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image
brendan answered

Push Notifications to groups are indeed supported via Segmented Push, and we'll be adding One Signal to our Add-ons marketplace, to help with this.

However, a query that grabs every person in the entire system for a game (millions of entries, for some games) is a very inefficient operation, which is why we make all that data available via the GetDataReport call you highlighted. Both Segment and Appuri currently provide options for collecting all the data concerning your users via events, and we'll be expanding on our data offerings in the near future.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

My Game Studio avatar image
My Game Studio answered

I've been keeping a local (non-playfab) list of playerIds that register via the website or in-app. This let's me get a complete listing of player ID's and keep a local cache of data outside of playfab but with the ability to correlate. I also recount the data against a daily cron job against GetDataReport() to find any inconsistency. Worse case is my local cache may not catch a deleted account but that's a very edge case for me as I don't delete accounts.

 

May not be the best solution but I can't believe playfab will allow a method to get all playerids as the restful API/enviorment is not well suited to such large downloads. Another solution would be allow for blank or a special token (ALL_ACCOUNTS) to be passed into recipients aray to accommodate a mass push.

 

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

My Game Studio avatar image
My Game Studio answered

I forgot to mention there may be a solution involved with analytics and segments - I believe you can configure a "All Active users" segment to collect the playfabIDs.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Lucas [not provided] avatar image
Lucas [not provided] answered

They could probably rate limit (a lot, like once a day!) and paginate these sorts of requests.

I don't think Segment would exactly solve it, unless I could filter by the "Push Enabled" attribute, which also seems to not be exposed in any API (I could be wrong, I'm completely new here).

Of course a MassSendPushNotification method would fix the problem as well, but I do think we should have _some_ way to peruse the full database of our users, no?

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Lucas [not provided] avatar image
Lucas [not provided] answered

Just an update: It doesn't seem Segments gets the PlayFabID nor the "PushEnabled" attribute from the users.

It does seem though GetDataReport() might be the solution for me, I'd have to just run it daily or weekly or whatever and keep a duplicate database updated. That does sound like a little too much work for such a simple task though.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.