mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-11-08 01:57:31 +01:00
Merge current upstream schema into Boat feature branch
* commit '2c09c8c16da3d605fc043c745535a7e65f961bb9': perf(chat): wake action queues from commits and deadlines (#15808) chore(lockfile): refresh pnpm-lock.yaml (#15820) feat: add company fast-response acknowledgements (#15748) ci: move the Grok public-install verification off Canary Dry Run (#15213)
This commit is contained in:
commit
3081b7480f
107 files changed
+8418
-57028
No files matched your search
@@ -0,0 +1,36 @@
|
||||
import type {
|
||||
FastResponseSettingsResponse,
|
||||
FastResponseSettings,
|
||||
FastResponseTestResult,
|
||||
FastResponseHistoryEntry,
|
||||
UpdateFastResponse,
|
||||
} from "@paperclipai/shared";
|
||||
import { api } from "./client";
|
||||
export const fastResponsesApi = {
|
||||
settings: (companyId: string) =>
|
||||
api.get<FastResponseSettingsResponse>(
|
||||
`/companies/${companyId}/fast-response`,
|
||||
),
|
||||
update: (companyId: string, settings: UpdateFastResponse) =>
|
||||
api.put<FastResponseSettings>(
|
||||
`/companies/${companyId}/fast-response`,
|
||||
settings,
|
||||
),
|
||||
models: (companyId: string, connectionId: string) =>
|
||||
api.get<Array<{ id: string; label?: string }>>(
|
||||
`/companies/${companyId}/fast-response/models?connectionId=${encodeURIComponent(connectionId)}`,
|
||||
),
|
||||
test: (companyId: string) =>
|
||||
api.post<FastResponseTestResult>(
|
||||
`/companies/${companyId}/fast-response/test`,
|
||||
{},
|
||||
),
|
||||
history: (companyId: string, from?: string, to?: string) => {
|
||||
const params = new URLSearchParams();
|
||||
if (from) params.set("from", from);
|
||||
if (to) params.set("to", to);
|
||||
return api.get<FastResponseHistoryEntry[]>(
|
||||
`/companies/${companyId}/fast-response/history?${params}`,
|
||||
);
|
||||
},
|
||||
};
|
||||
Reference in new issue
Block a user