🐛 (whatsapp) Fix WA preview not starting and accept audio and documents messages
This commit is contained in:
@@ -10,15 +10,6 @@ import { OpenAI, ClientOptions } from 'openai'
|
||||
import { defaultOpenAIOptions } from '@typebot.io/schemas/features/blocks/integrations/openai/constants'
|
||||
|
||||
export const listModels = authenticatedProcedure
|
||||
.meta({
|
||||
openapi: {
|
||||
method: 'GET',
|
||||
path: '/openai/models',
|
||||
protect: true,
|
||||
summary: 'List OpenAI models',
|
||||
tags: ['OpenAI'],
|
||||
},
|
||||
})
|
||||
.input(
|
||||
z.object({
|
||||
credentialsId: z.string(),
|
||||
@@ -28,11 +19,6 @@ export const listModels = authenticatedProcedure
|
||||
type: z.enum(['gpt', 'tts']),
|
||||
})
|
||||
)
|
||||
.output(
|
||||
z.object({
|
||||
models: z.array(z.string()),
|
||||
})
|
||||
)
|
||||
.query(
|
||||
async ({
|
||||
input: { credentialsId, workspaceId, baseUrl, apiVersion, type },
|
||||
|
||||
@@ -8,31 +8,12 @@ import { ZemanticAiCredentials } from '@typebot.io/schemas/features/blocks/integ
|
||||
import got from 'got'
|
||||
|
||||
export const listProjects = authenticatedProcedure
|
||||
.meta({
|
||||
openapi: {
|
||||
method: 'GET',
|
||||
path: '/zemantic-ai/projects',
|
||||
protect: true,
|
||||
summary: 'List Zemantic AI projects',
|
||||
tags: ['ZemanticAi'],
|
||||
},
|
||||
})
|
||||
.input(
|
||||
z.object({
|
||||
credentialsId: z.string(),
|
||||
workspaceId: z.string(),
|
||||
})
|
||||
)
|
||||
.output(
|
||||
z.object({
|
||||
projects: z.array(
|
||||
z.object({
|
||||
label: z.string(),
|
||||
value: z.string(),
|
||||
})
|
||||
),
|
||||
})
|
||||
)
|
||||
.query(async ({ input: { credentialsId, workspaceId }, ctx: { user } }) => {
|
||||
const workspace = await prisma.workspace.findFirst({
|
||||
where: { id: workspaceId },
|
||||
|
||||
Reference in New Issue
Block a user