-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
⚡ (webhook) Enable advanced config for Zapier and Make.com
- Loading branch information
1 parent
5bda556
commit c1a636b
Showing
9 changed files
with
479 additions
and
328 deletions.
There are no files selected for viewing
18 changes: 2 additions & 16 deletions
18
apps/builder/src/features/blocks/integrations/makeCom/components/MakeComContent.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 2 additions & 16 deletions
18
apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectContent.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
92 changes: 92 additions & 0 deletions
92
apps/builder/src/features/blocks/integrations/pabbly/components/PabblyConnectSettings.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
import { Alert, AlertIcon, Button, Link, Stack, Text } from '@chakra-ui/react' | ||
import { ExternalLinkIcon } from '@/components/icons' | ||
import { useTypebot } from '@/features/editor' | ||
import { PabblyConnectBlock, Webhook, WebhookOptions } from 'models' | ||
import React, { useEffect, useState } from 'react' | ||
import { byId, env } from 'utils' | ||
import { WebhookAdvancedConfigForm } from '../../webhook/components/WebhookAdvancedConfigForm' | ||
import { useDebouncedCallback } from 'use-debounce' | ||
import { TextInput } from '@/components/inputs' | ||
|
||
const debounceWebhookTimeout = 2000 | ||
|
||
type Props = { | ||
block: PabblyConnectBlock | ||
onOptionsChange: (options: WebhookOptions) => void | ||
} | ||
|
||
export const PabblyConnectSettings = ({ | ||
block: { webhookId, id: blockId, options }, | ||
onOptionsChange, | ||
}: Props) => { | ||
const { webhooks, updateWebhook } = useTypebot() | ||
|
||
const [localWebhook, _setLocalWebhook] = useState( | ||
webhooks.find(byId(webhookId)) | ||
) | ||
|
||
const updateWebhookDebounced = useDebouncedCallback( | ||
async (newLocalWebhook) => { | ||
await updateWebhook(newLocalWebhook.id, newLocalWebhook) | ||
}, | ||
env('E2E_TEST') === 'true' ? 0 : debounceWebhookTimeout | ||
) | ||
|
||
const setLocalWebhook = (newLocalWebhook: Webhook) => { | ||
_setLocalWebhook(newLocalWebhook) | ||
updateWebhookDebounced(newLocalWebhook) | ||
} | ||
|
||
useEffect( | ||
() => () => { | ||
updateWebhookDebounced.flush() | ||
}, | ||
[updateWebhookDebounced] | ||
) | ||
|
||
const handleUrlChange = (url: string) => | ||
localWebhook && | ||
setLocalWebhook({ | ||
...localWebhook, | ||
url, | ||
}) | ||
|
||
return ( | ||
<Stack spacing={4}> | ||
<Alert status={localWebhook?.url ? 'success' : 'info'} rounded="md"> | ||
<AlertIcon /> | ||
{localWebhook?.url ? ( | ||
<>Your scenario is correctly configured 🚀</> | ||
) : ( | ||
<Stack> | ||
<Text>Head up to Pabbly Connect to get the webhook URL:</Text> | ||
<Button | ||
as={Link} | ||
href="https://www.pabbly.com/connect/integrations/typebot/" | ||
isExternal | ||
colorScheme="blue" | ||
> | ||
<Text mr="2">Pabbly.com</Text> <ExternalLinkIcon /> | ||
</Button> | ||
</Stack> | ||
)} | ||
</Alert> | ||
<TextInput | ||
placeholder="Paste webhook URL..." | ||
defaultValue={localWebhook?.url ?? ''} | ||
onChange={handleUrlChange} | ||
withVariableButton={false} | ||
debounceTimeout={0} | ||
/> | ||
{localWebhook && ( | ||
<WebhookAdvancedConfigForm | ||
blockId={blockId} | ||
webhook={localWebhook} | ||
options={options} | ||
onWebhookChange={setLocalWebhook} | ||
onOptionsChange={onOptionsChange} | ||
/> | ||
)} | ||
</Stack> | ||
) | ||
} |
Oops, something went wrong.
c1a636b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
viewer-v2 – ./apps/viewer
ns8.vn
1stop.au
yobot.me
klujo.com
me.cr8.ai
247987.com
8jours.top
aginap.com
ai.mprs.in
bee.cr8.ai
bot.aws.bj
bot.bbc.bj
cat.cr8.ai
finplex.be
nepkit.com
pig.cr8.ai
sat.cr8.ai
bot.aipr.kr
bot.joof.it
bull.cr8.ai
docs.cr8.ai
minipost.uk
mole.cr8.ai
team.cr8.ai
wolf.cr8.ai
cinecorn.com
help.taxt.co
kusamint.com
rhino.cr8.ai
sheep.cr8.ai
snake.cr8.ai
svhm.mprs.in
tiger.cr8.ai
video.cr8.ai
yoda.riku.ai
zebra.cr8.ai
bergamo.store
bot.krdfy.com
bot.tvbeat.it
cgcassets.com
cnvhub.com.br
facelabko.com
filmylogy.com
goldorayo.com
rabbit.cr8.ai
signup.cr8.ai
start.taxt.co
turkey.cr8.ai
vhpage.cr8.ai
bot.winglabs.com.br
chat.marius.digital
chatbot.matthesv.de
chatbot.repplai.com
demo.botscientis.us
newsletter.itshcormeos.com
tarian.theiofoundation.org
ted.meujalecobrasil.com.br
type.dericsoncalari.com.br
bot.pinpointinteractive.com
bot.polychromes-project.com
bot.seidinembroseanchetu.it
chatbot.berbelanjabiz.trade
designguide.techyscouts.com
jcapp.virtuesocialmedia.com
liveconvert2.kandalearn.com
presente.empresarias.com.mx
sell.sellthemotorhome.co.uk
anamnese.odontopavani.com.br
austin.channelautomation.com
bot.marketingplusmindset.com
bot.seidibergamoseanchetu.it
desabafe.sergiolimajr.com.br
download.venturemarketing.in
jc-app.virtuesocialmedia.com
piazzatorre.barrettamario.it
type.cookieacademyonline.com
upload.atlasoutfittersk9.com
bot.brigadeirosemdrama.com.br
forms.escoladeautomacao.com.br
onboarding.libertydreamcare.ie
type.talitasouzamarques.com.br
agendamento.sergiolimajr.com.br
anamnese.clinicamegasjdr.com.br
bookings.littlepartymonkeys.com
bot.comercializadoraomicron.com
elevateyourmind.groovepages.com
viewer-v2-typebot-io.vercel.app
yourfeedback.comebackreward.com
gerador.verificadordehospedes.com
personal-trainer.barrettamario.it
preagendamento.sergiolimajr.com.br
studiotecnicoimmobiliaremerelli.it
download.thailandmicespecialist.com
register.thailandmicespecialist.com
bot.studiotecnicoimmobiliaremerelli.it
pesquisa.escolamodacomproposito.com.br
anamnese.clinicaramosodontologia.com.br
chrome-os-inquiry-system.itschromeos.com
viewer-v2-git-main-typebot-io.vercel.app
main-menu-for-itschromeos.itschromeos.com
c1a636b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
docs – ./apps/docs
docs-typebot-io.vercel.app
docs.typebot.io
docs-git-main-typebot-io.vercel.app
c1a636b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
landing-page-v2 – ./apps/landing-page
typebot.io
landing-page-v2-git-main-typebot-io.vercel.app
www.get-typebot.com
www.typebot.io
landing-page-v2-typebot-io.vercel.app
get-typebot.com
c1a636b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
builder-v2 – ./apps/builder
builder-v2-git-main-typebot-io.vercel.app
app.typebot.io
builder-v2-typebot-io.vercel.app