feat: restore agent sessions from creation drafts

This commit is contained in:
2026-04-23 21:23:46 +08:00
parent 349a397888
commit 53a9cdd791
11 changed files with 949 additions and 18 deletions

View File

@@ -0,0 +1,29 @@
import type { BigFishWorksResponse } from '../../../packages/shared/src/contracts/bigFishWorkSummary';
import { type ApiRetryOptions, requestJson } from '../apiClient';
const BIG_FISH_WORKS_API_BASE = '/api/runtime/big-fish/works';
const BIG_FISH_WORKS_READ_RETRY: ApiRetryOptions = {
maxRetries: 1,
baseDelayMs: 120,
maxDelayMs: 360,
};
/**
* 读取当前用户的大鱼吃小鱼创作作品列表。
*/
export async function listBigFishWorks() {
return requestJson<BigFishWorksResponse>(
BIG_FISH_WORKS_API_BASE,
{
method: 'GET',
},
'读取大鱼吃小鱼作品列表失败',
{
retry: BIG_FISH_WORKS_READ_RETRY,
},
);
}
export const bigFishWorksClient = {
list: listBigFishWorks,
};

View File

@@ -0,0 +1 @@
export { bigFishWorksClient, listBigFishWorks } from './bigFishWorksClient';