question

Rafael Souza avatar image
Rafael Souza asked

Get players info from server

Hey there!

I'm going to use Playfab Client API from a server to get players data using they given login token, the same code I'm using at the clients, I'm using at the server and it works fine right now, but, with tons of player(max 500) connected and Playfab receiving lots of request from the same ip adress using client code, won't it be blocked?

Note: each request uses the corresponding user login token.

10 |1200

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

1 Answer

·
Sarah Zhang avatar image
Sarah Zhang answered

In the case of a large number of requests, your server may be throttled for the reason that “The client exceeds the maximum API request rate”. Because the rate-limiting is on a per-IP basis at the moment. In other words, The Client API calls from one IP address will be regarded as from one client. You can refer to this thread The client has exceeded maximum api requests for a discussion about such questions.

Could you please tell us what is your demand? If you only want to get player data, Server API GetUserData can be used to get player data on server and Server API has higher limits of request rate.

4 comments
10 |1200

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

Rafael Souza avatar image Rafael Souza commented ·

Hard to say how many calls the server will be making.

Can you tell me the limits? and if I find out they are not enough could I get more?

0 Likes 0 ·
Sarah Zhang avatar image Sarah Zhang Rafael Souza commented ·

>> Can you tell me the limits? and if I find out they are not enough could I get more?

We mean it is not recommended to call clients API on the server-side. The client API rate limits are on a per-player basis, and are designed to prevent any one title from causing a service impact across all titles in the shared service. While we can provide far higher limits in private verticals as part of an Enterprise agreement, we cannot increase limits beyond the defined safety levels in the shared service. We currently allow an upper bound of 100 API calls from an individual client IP in 2 minutes. If you're exceeding that, a client sending from that IP is going to be throttled for a little while before being allowed to send again.

If it’s Server API, PlayFab doesn’t provide a clear limit of the rate. Generally, it can meet customers’ needs.

0 Likes 0 ·
Rafael Souza avatar image Rafael Souza commented ·

1 more doubt, if I call a cloud script method from the server and this method make 3, 5 or more api requests, does it still count as 1?

0 Likes 0 ·
Sarah Zhang avatar image Sarah Zhang Rafael Souza commented ·

>> 1 more doubt, if I call a cloud script method from the server and this method make 3, 5 or more api requests, does it still count as 1?

In the server you make one API call ExecuteCloudScript, but in the CouldScript you make multiple API calls. In terms of results, it doesn’t count 1. And about “Cloud Script execution API requests issued”, there is a clear limit, you can navigate to https://developer.playfab.com/en-US/[YourTitleId]/limits to check the limit. For Free tier, it will be 15, in other words, the number of PlayFab API requests made from a Cloud Script function called by the ExecuteCloudScript API can’t exceed 15.

0 Likes 0 ·

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.