@runnerpro/backend 1.4.4 → 1.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -173,14 +173,19 @@ const sendMessage = (req, res, { sendNotification, firebaseMessaging, query, isC
173
173
  body: `Rubén: ${textPreferredLanguage || textSpanish}`,
174
174
  url: '/chat',
175
175
  });
176
- // Enviar el mensaje a la IA de vuelta para que aprenda que mensaje a acabado enviando el entrenador
177
- yield axios_1.default.put(`${process.env.BACKEND_IA_URL}/api/chat/suggestion`, { userId: idCliente }, {
178
- headers: {
179
- 'ngrok-skip-browser-warning': true, // working with ngrok
180
- 'Content-Type': 'application/json',
181
- Authorization: `Bearer ${process.env.IA_ACCESS_TOKEN}`,
182
- },
183
- });
176
+ // Enviar el mensaje a la IA de vuelta para que aprenda que mensaje ha acabado enviando el entrenador
177
+ try {
178
+ yield axios_1.default.put(`${process.env.BACKEND_IA_URL}/api/chat/suggestion`, { userId: idCliente }, {
179
+ headers: {
180
+ 'ngrok-skip-browser-warning': true, // working with ngrok
181
+ 'Content-Type': 'application/json',
182
+ Authorization: `Bearer ${process.env.IA_ACCESS_TOKEN}`,
183
+ },
184
+ });
185
+ }
186
+ catch (error) {
187
+ console.error(error);
188
+ }
184
189
  }
185
190
  console.log(4);
186
191
  res.send({ status: 'ok' });
@@ -1 +1 @@
1
- {"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../../../src/chat/api/conversation.ts"],"names":[],"mappings":"AAWA,QAAA,MAAM,iBAAiB,0BAA2B,GAAG,SAmBpD,CAAC;AAmTF,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
1
+ {"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../../../src/chat/api/conversation.ts"],"names":[],"mappings":"AAWA,QAAA,MAAM,iBAAiB,0BAA2B,GAAG,SAmBpD,CAAC;AAyTF,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@runnerpro/backend",
3
- "version": "1.4.4",
3
+ "version": "1.4.6",
4
4
  "description": "A collection of common backend functions",
5
5
  "exports": {
6
6
  ".": "./lib/cjs/index.js"