question

max avatar image
max asked

Cloud Script Logs - Server/Events Only (don't send to client)

Is it possible to log in Cloud Script, so that the logs are not sent to the Client that called the script, but have the logs visible in the PlayStream Event that was triggered by this Cloud Script?

That would be really cool, so if a player is facing an error, we can look up the logs - but the player's don't have access to our logging and it won't take bandwidth.

CloudScriptPlayStream
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

·
pfnathan avatar image
pfnathan answered

No, this is not possible since you cannot distinguish logging to PlayStream separately from logging to the response.

However, to accomplish your scenario, you can use Server.WritePlayerEvent() to write events to PlayStream which the player won't be able to see.

Here is the API call reference:

https://api.playfab.com/documentation/server/method/WritePlayerEvent

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.