mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-29 09:44:47 +00:00
feat: user openai account
This commit is contained in:
@@ -42,13 +42,14 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
|
||||
await connectToDatabase();
|
||||
|
||||
/* user auth */
|
||||
const { userId } = await authUser({ req });
|
||||
const { userId, user } = await authUser({ req, authBalance: true });
|
||||
|
||||
/* start process */
|
||||
const { responseData } = await dispatchModules({
|
||||
res,
|
||||
modules: modules,
|
||||
variables,
|
||||
user,
|
||||
params: {
|
||||
history: gptMessage2ChatType(history),
|
||||
userChatInput: prompt
|
||||
|
Reference in New Issue
Block a user