HTTP request not working with google TTS API

I want to get audio from text using Google text-to-speech API. I am using the following structure for the POST request.

URL: https://texttospeech.googleapis.com/v1/text:synthesize?key=XXXXXXXXXXX_TNMBuH5YXXXXXXX5hV3MMhGn8

                 "audioConfig": { 
                         "audioEncoding": "MP3", "pitch": "0.00", "speakingRate": "1.00"
                           }, 
                 "input": { 
                         "text": "Hello World" 
                           }, 
                  "voice": { 
                          "languageCode": "en-US", "name": "en-US-Wavenet-E"
                           }
               }

It works fine when testing in Postman. When testing the app I get Error “unknown” . Am missing on something or it is a bug?