@multiplayer-app/ai-agent-react 0.1.0-beta.41 → 0.1.0-beta.42

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.
@@ -1158,7 +1158,7 @@ class ra {
1158
1158
  }
1159
1159
  async listChats(t) {
1160
1160
  const n = new URLSearchParams();
1161
- t?.contextKey && n.set("contextKey", t.contextKey), t?.skip != null && n.set("skip", String(t.skip)), t?.limit && n.set("limit", String(t.limit)), t?.userId && n.set("userId", t.userId), t?.sortField && n.set("sortField", t.sortField), t?.sortOrder && n.set("sortOrder", t.sortOrder);
1161
+ t?.contextKey && n.set("contextKey", t.contextKey), t?.skip != null && n.set("skip", String(t.skip)), t?.limit && n.set("limit", String(t.limit)), t?.sortField && n.set("sortField", t.sortField), t?.sortOrder && n.set("sortOrder", t.sortOrder);
1162
1162
  const r = await this.request(`/chats?${n.toString()}`);
1163
1163
  return { cursor: r.cursor, data: r.data };
1164
1164
  }
@@ -1166,8 +1166,8 @@ class ra {
1166
1166
  return await this.request(`/chats/${t}`);
1167
1167
  }
1168
1168
  async getMessages(t, n) {
1169
- const r = new URLSearchParams({ chatId: t });
1170
- return n?.limit != null && r.set("limit", String(n.limit)), n?.before && r.set("before", n.before), this.request(`/messages?${r.toString()}`);
1169
+ const r = new URLSearchParams({});
1170
+ return n?.limit != null && r.set("limit", String(n.limit)), n?.before && r.set("before", n.before), this.request(`/chats/${t}/messages?${r.toString()}`);
1171
1171
  }
1172
1172
  deleteChat(t) {
1173
1173
  return this.request(`/chats/${t}`, { method: "DELETE" });