Update content type
Browse files- index.html +2 -2
index.html
CHANGED
@@ -136,7 +136,7 @@
|
|
136 |
// Make a POST request to the chatbot API
|
137 |
const response = await fetch("https://sds-bosch-movadoapi.hf.space/predict", {
|
138 |
method: "POST",
|
139 |
-
headers: { "Content-Type": "
|
140 |
body: JSON.stringify({
|
141 |
input_text: [input],
|
142 |
})
|
@@ -144,7 +144,7 @@
|
|
144 |
|
145 |
// Extract the chatbot response from the JSON data
|
146 |
const data = await response.json();
|
147 |
-
const responseText = data.data
|
148 |
|
149 |
// Update the output textarea with the chatbot response
|
150 |
$('.message.loading').remove();
|
|
|
136 |
// Make a POST request to the chatbot API
|
137 |
const response = await fetch("https://sds-bosch-movadoapi.hf.space/predict", {
|
138 |
method: "POST",
|
139 |
+
headers: { "Content-Type": "text/plain" },
|
140 |
body: JSON.stringify({
|
141 |
input_text: [input],
|
142 |
})
|
|
|
144 |
|
145 |
// Extract the chatbot response from the JSON data
|
146 |
const data = await response.json();
|
147 |
+
const responseText = data.data;
|
148 |
|
149 |
// Update the output textarea with the chatbot response
|
150 |
$('.message.loading').remove();
|