Testing facebook instant game from local server

84 views Asked by At

Everyone I am very new to Facebook instant game, please help me solve this problem. I tried to test my game through local server as mentioned in the page https://developers.facebook.com/docs/games/build/instant-games/get-started/test-publish-share

This kind of error occurs :

enter image description here

For testing the url I have used this link : https://www.facebook.com/embed/instantgames/YOUR_GAME_ID/player?game_url=https://localhost:8080

where I have replaced the YOUR_GAME_ID with my actual game id.

Here is the screen short of my app dashboard of game: enter image description here

And for now I only have index.html file in my root folder with the ssl key and certficate file : index.html file looks like this :

<!DOCTYPE html>
<html>
    <head>
        <title>Test Facebook Instant Game</title>
        <script src="https://connect.facebook.net/en_US/fbinstant.6.3.js"></script>
    </head>
    <body>
        <h1>Facebook Instant Game Test</h1>
        <script type="text/javascript">
            console.log("The console log")

            FBInstant.initializeAsync() 
              .then(function() {
              // Start loading game assets here
              console.log("loaded")
            });

        </script>
    </body>
</html>

Please help me to run the the instant game on local server.

0

There are 0 answers