updated
This commit is contained in:
@@ -43,7 +43,7 @@ local function playTTSFile(value)
|
||||
local headers = {
|
||||
["Content-Type"] = "application/x-www-form-urlencoded"
|
||||
}
|
||||
|
||||
|
||||
print("Sending HTTP POST request")
|
||||
local response = http.post({
|
||||
url = ttsRoute,
|
||||
@@ -55,7 +55,9 @@ local function playTTSFile(value)
|
||||
|
||||
print("HTTP POST request successful" )
|
||||
local data = response.readAll()
|
||||
print(data)
|
||||
local responseData = textutils.unserialiseJSON(data, { parse_null = true })
|
||||
print(data.MP3)
|
||||
print(data.URL)
|
||||
response.close()
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user