question

huhund avatar image
huhund asked

Can I batch playfab command?

My use case is that I want my game client to login and then execute a cloud script for session control. Currently I do this as two separate posts, hence I wait for the login to answer before asking for the session. My question is can I combine these two calls into one - to preserve network bandwidth?

I'm pretty sure I will bump into other cases as well where it would be more optimal to send two ore more commands in the same request. Is there a good way for handling this?

Best, Hu

CloudScript
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

·
brendan avatar image
brendan answered

The way to have logic which is triggered off other logic is by using PlayStream (https://api.playfab.com/docs/tutorials#landing-automation). You can trigger actions based upon events, like https://api.playfab.com/playstream/events/player_logged_in. The logic for this is that when the event occurs, any rules triggered by the event are run, which can include Cloud Scripts.

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.