Hi,
I saw in documentation that there is a function BanUsers in Server APIs.
How can I call it from cloud script? I mean.. which syntax does it requires?
Thank you.
Hi,
I saw in documentation that there is a function BanUsers in Server APIs.
How can I call it from cloud script? I mean.. which syntax does it requires?
Thank you.
There's a complete guide to using Cloud Script here (https://api.playfab.com/docs/using-cloud-script), and we have a number of examples in our GitHub, including the basic sample that is automatically added as revision 1 in all new titles here (https://github.com/PlayFab/CloudScriptSamples/blob/master/BasicSample/basic_sample.js). In both cases, we demonstrate using Server API calls from Cloud Script. Simply put, the parameters for the call are exactly the same as they would be if you were making the call from your own custom game server code, or from a tool like Postman.
In the case of BanUsers, the required parameter is an array of BanRequests, each of which must have at least the PlayFabId of the user to be banned. The API documentation shows an example of this (https://api.playfab.com/Documentation/Server/method/BanUsers).
1 Person is following this question.