@overmap-ai/core 1.0.48-add-agent-response-rating.0 → 1.0.48-add-agent-response-rating.2

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.
@@ -4251,10 +4251,20 @@ function runMiddleware(action) {
4251
4251
  var _a2;
4252
4252
  return (_a2 = allMiddleware[0]) == null ? void 0 : _a2.run(action);
4253
4253
  }
4254
- const discardStatuses = [400, 409, 403, 404];
4254
+ const discardStatuses = [400, 409, 403, 404, 405, 500];
4255
4255
  const statusMessages = {
4256
4256
  403: { title: "Forbidden", description: "You are not authorized to perform this action.", severity: "danger" },
4257
- 404: { title: "Not found", description: "The requested resource was not found.", severity: "danger" }
4257
+ 404: { title: "Not found", description: "The requested resource was not found.", severity: "danger" },
4258
+ 405: {
4259
+ title: "Not supported",
4260
+ description: "It's not you. It's us. Sorry for the inconvenience.",
4261
+ severity: "danger"
4262
+ },
4263
+ 500: {
4264
+ title: "Server error",
4265
+ description: "Our server seems to be experiencing problems at the moment. We have been alerted and will fix the problem as soon as possible.",
4266
+ severity: "danger"
4267
+ }
4258
4268
  };
4259
4269
  function discard(reason, action, retries = 0) {
4260
4270
  var _a2;
@@ -7517,7 +7527,7 @@ class AgentService extends BaseApiService {
7517
7527
  async rate(responseId, rating) {
7518
7528
  return this.enqueueRequest({
7519
7529
  description: "Rate agent response",
7520
- method: HttpMethod.POST,
7530
+ method: HttpMethod.PUT,
7521
7531
  url: `/agents/responses/${responseId}/rate/`,
7522
7532
  payload: { rating },
7523
7533
  blockers: ["rate"],