question

junpei.tamai@hautecouture.jp avatar image
junpei.tamai@hautecouture.jp asked

TimeOut Error

The code that calls the API is created using Cloud Scrtipt(legacy).

The implemented code makes the call using ExecuteCloudScript. It was working fine until a few days ago, when suddenly I started getting CloudScriptHTTPRequestError. When we checked the Log, it seemed to be causing a TimeOut error.

So, as a test, I selected a user from the Playfab dashboard and called the same code directly. It worked fine and no TimeOut error occurred.

Is there any internal difference between calling the code directly from the dashboard and calling it with ExecuteCloudScript?

Here is the code we are implementing

handlers.logTest2 = function (args, context) { var url = https://zipcloud.ibsnet.co.jp/api/search; var method = "get"; var contentBody = ""; var contentType = "application/json"; var headers = {}; var response = {}

         response = JSON.parse(http.request(url, method, contentBody, contentType, headers, true));
         return { responseContent: response }
     };
CloudScript
1 comment
10 |1200

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

The code that calls the API is created using Cloud Scrtipt(legacy).

The implemented code makes the call using ExecuteCloudScript. It was working fine until a few days ago, when suddenly I started getting CloudScriptHTTPRequestError. When we checked the Log, it seemed to be causing a TimeOut error. So, as a test, I selected a user from the Playfab dashboard and called the same code directly. It worked fine and no TimeOut error occurred.

Is there any internal difference between calling the code directly from the dashboard and calling it with ExecuteCloudScript?

Here is the code we are implementing.

 handlers.logTest2 = function (args, context) {
         var url = `https://zipcloud.ibsnet.co.jp/api/search`;
         var method = "get";
         var contentBody = "";
         var contentType = "application/json";
         var headers = {
                
         };
    
         var response = {}
         response = JSON.parse(http.request(url, method, contentBody, contentType, headers, true));
         return { responseContent: response }
     };
0 Likes 0 ·

1 Answer

·
Infer Wang avatar image
Infer Wang answered

You can use https://learn.microsoft.com/en-us/gaming/playfab/features/automation/cloudscript-af/ instead of Cloud Script for it can provide you much longer-running, asynchronous and free from the API count limit calls, and that’s also the method we recommend to use.

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.