agentgui 1.0.384 → 1.0.385

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/server.js +5 -4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentgui",
3
- "version": "1.0.384",
3
+ "version": "1.0.385",
4
4
  "description": "Multi-agent ACP client with real-time communication",
5
5
  "type": "module",
6
6
  "main": "server.js",
package/server.js CHANGED
@@ -12,7 +12,8 @@ import { OAuth2Client } from 'google-auth-library';
12
12
  import express from 'express';
13
13
  import Busboy from 'busboy';
14
14
  import fsbrowse from 'fsbrowse';
15
- import { queries } from './database.js';
15
+ import { queries, db, prepare } from './database.js';
16
+ import { createACPQueries } from './acp-queries.js';
16
17
  import { runClaudeWithStreaming } from './lib/claude-runner.js';
17
18
  import { initializeDescriptors, getAgentDescriptor } from './lib/agent-descriptors.js';
18
19
 
@@ -2633,7 +2634,7 @@ const server = http.createServer(async (req, res) => {
2633
2634
  // GET /threads/{thread_id} - Get thread by ID
2634
2635
  const acpThreadMatch = pathOnly.match(/^\/api\/threads\/([a-f0-9-]{36})$/);
2635
2636
  if (acpThreadMatch && req.method === 'GET') {
2636
- const threadId = threadByIdMatch[1];
2637
+ const threadId = acpThreadMatch[1];
2637
2638
  try {
2638
2639
  const thread = queries.getThread(threadId);
2639
2640
  if (!thread) {
@@ -2649,7 +2650,7 @@ const server = http.createServer(async (req, res) => {
2649
2650
 
2650
2651
  // PATCH /threads/{thread_id} - Update thread metadata
2651
2652
  if (acpThreadMatch && req.method === 'PATCH') {
2652
- const threadId = threadByIdMatch[1];
2653
+ const threadId = acpThreadMatch[1];
2653
2654
  try {
2654
2655
  const body = await parseBody(req);
2655
2656
  const thread = queries.patchThread(threadId, body);
@@ -2666,7 +2667,7 @@ const server = http.createServer(async (req, res) => {
2666
2667
 
2667
2668
  // DELETE /threads/{thread_id} - Delete thread (fail if pending runs exist)
2668
2669
  if (acpThreadMatch && req.method === 'DELETE') {
2669
- const threadId = threadByIdMatch[1];
2670
+ const threadId = acpThreadMatch[1];
2670
2671
  try {
2671
2672
  queries.deleteThread(threadId);
2672
2673
  res.writeHead(204);