Skip to content

Synthesizer gives 403 error when getting MP3 Data #40

@mayukhnair

Description

@mayukhnair

java.io.IOException: Server returned HTTP response code: 403 for URL: http://translate.google.com/translate_a/t?client=thello+world

You should look into this.

Code:

String language = "auto";
Synthesiser synth = new Synthesiser(language);
try {
InputStream is = synth.getMP3Data(output);
AudioStream audioStream = new AudioStream(is);
AudioPlayer.player.start(audioStream);
//TODO Use any Java MP3 Implementation to play back the AudioFile from the InputStream.
}
catch (Exception e) {
// TODO Auto-generated catch block
System.out.println("Error");
e.printStackTrace();
return;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions