Hi,
so im new to the cloud scripting thing, and my knowledge of JavaScript isnt the best, and i more C# friendly, i have a working azure function that i can execute from both the azure console and the playfab scheduled task. but only the arguments in azure go through, and the playfab doesn't. could anyone tell me what im doing wrong.
thanks
[FunctionName("X")] public static async Task<IActionResult> Run( [HttpTrigger(AuthorizationLevel.Anonymous, "get", "post", Route = null)] HttpRequest req, ILogger log) { string responseMessage = ""; int rate; PlayFabSettings.staticSettings.TitleId = "X"; PlayFabSettings.staticSettings.DeveloperSecretKey = "X"; GetPlayersInSegmentRequest request = new GetPlayersInSegmentRequest() { SegmentId = "X" }; var getAllPlayersResult = await PlayFabServerAPI.GetPlayersInSegmentAsync(request); try{rate = int.Parse(req.Query["Rate"]); catch{rate = 375;} responseMessage += "\nrate is set to " + rate; log.LogInformation("C# HTTP trigger function processed a request."); // removed cause i couldnt get it to work /* string requestBody = await new StreamReader(req.Body).ReadToEndAsync(); PostData data = (PostData)JsonConvert.DeserializeObject(requestBody); responseMessage += "\nDatarate is set to " + data.Rate; */ return new OkObjectResult(responseMessage); } }