🔥 Remove streamer Pages API endpoint

This commit is contained in:
Baptiste Arnaud
2023-10-06 16:34:10 +02:00
parent b232a9495e
commit bf1f657642
31 changed files with 145 additions and 231 deletions

View File

@@ -7,8 +7,8 @@ import {
forbidden,
methodNotAllowed,
notAuthenticated,
encrypt,
} from '@typebot.io/lib/api'
import { encrypt } from '@typebot.io/lib/api/encryption/encrypt'
const handler = async (req: NextApiRequest, res: NextApiResponse) => {
const user = await getAuthenticatedUser(req, res)

View File

@@ -3,10 +3,11 @@ import { Prisma } from '@typebot.io/prisma'
import prisma from '@typebot.io/lib/prisma'
import { googleSheetsScopes } from './consent-url'
import { stringify } from 'querystring'
import { badRequest, encrypt, notAuthenticated } from '@typebot.io/lib/api'
import { badRequest, notAuthenticated } from '@typebot.io/lib/api'
import { oauth2Client } from '@/lib/googleSheets'
import { getAuthenticatedUser } from '@/features/auth/helpers/getAuthenticatedUser'
import { env } from '@typebot.io/env'
import { encrypt } from '@typebot.io/lib/api/encryption/encrypt'
const handler = async (req: NextApiRequest, res: NextApiResponse) => {
const user = await getAuthenticatedUser(req, res)

View File

@@ -2,7 +2,6 @@ import prisma from '@typebot.io/lib/prisma'
import { NextApiRequest, NextApiResponse } from 'next'
import { getAuthenticatedUser } from '@/features/auth/helpers/getAuthenticatedUser'
import {
decrypt,
methodNotAllowed,
notAuthenticated,
notFound,
@@ -10,6 +9,7 @@ import {
import { isReadWorkspaceFobidden } from '@/features/workspace/helpers/isReadWorkspaceFobidden'
import { WhatsAppCredentials } from '@typebot.io/schemas/features/whatsapp'
import got from 'got'
import { decrypt } from '@typebot.io/lib/api/encryption/decrypt'
const handler = async (req: NextApiRequest, res: NextApiResponse) => {
if (req.method === 'GET') {