Linux record audio command for Google Cloud Speech API

Sunday, March 26, 2017 8:15 PM 0 Comments

Command:

arecord -f S16_LE -V mono -r 8000 record.wav

API Request:

{
  "config": {
    "sampleRate": 8000,
    "encoding": "LINEAR16",
    "languageCode": "th"
  },
  "audio": {
    "content": "CONTENT_BASE64"
  }
}


https://cloud.google.com/speech/docs/sync-recognize#speech-sync-recognize-protocol

0 comments: