update watchlist
This commit is contained in:
@@ -5,6 +5,7 @@ import { useState, useEffect, useCallback } from 'react';
|
||||
import type { Dispatch, SetStateAction } from 'react';
|
||||
import axios from 'axios';
|
||||
import { MessageTypes, type Message } from '../constants/messageTypes';
|
||||
import { getApiBase } from '@utils/apiConfig';
|
||||
|
||||
/**
|
||||
* 会话数据结构
|
||||
@@ -94,7 +95,7 @@ export const useAgentSessions = ({
|
||||
|
||||
setIsLoadingSessions(true);
|
||||
try {
|
||||
const response = await axios.get('/mcp/agent/sessions', {
|
||||
const response = await axios.get(`${getApiBase()}/mcp/agent/sessions`, {
|
||||
params: { user_id: String(user.id), limit: 50 },
|
||||
});
|
||||
|
||||
@@ -133,7 +134,7 @@ export const useAgentSessions = ({
|
||||
if (!sessionId) return;
|
||||
|
||||
try {
|
||||
const response = await axios.get(`/mcp/agent/history/${sessionId}`, {
|
||||
const response = await axios.get(`${getApiBase()}/mcp/agent/history/${sessionId}`, {
|
||||
params: { limit: 100 },
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user