Commit Graph

83 Commits

Author SHA1 Message Date
Baptiste Arnaud
6f289f647f
🔒️ Upgrade vulnerable deps (ai v5, nodemailer v8, otel sdk-node 0.217) (#2491)
## Summary

Fixes 18 open Dependabot alerts and migrates affected code to the new
major versions:

- `@opentelemetry/sdk-node` → `^0.217.0` (Prometheus exporter DoS,
GHSA-q7rr-3cgh-j5r3)
- `nodemailer` → `^8.0.5` across all manifests + root override
(GHSA-vvjj-xcjg-gr5g, GHSA-c7w3-x93f-qmm8)
- `ai` → `^5.0.52` (GHSA-rwvc-j5jr-mgvh); legacy 3.x dep removed from
`packages/deprecated/legacy` and replaced with a small in-tree
`OpenAIStream` + `StreamingTextResponse` shim
- Provider SDKs aligned to v5 peer: `@ai-sdk/openai`, `anthropic`,
`groq`, `mistral`, `perplexity`, `deepseek`, `togetherai`, `openRouter`,
`dify-ai-provider`

### AI SDK v4 → v5 migration

- `parseTools`: `parameters` renamed to `inputSchema`
- `runChatCompletion` / `runChatCompletionStream`: `maxSteps` replaced
by `stopWhen(stepCountIs(maxSteps))`;
`usage.{prompt,completion,total}Tokens` replaced by
`totalUsage.{input,output,total}Tokens`
- New `toLegacyDataStream` helper that re-emits the v4 data-stream
protocol (`0:text`, `3:error`, `9:tool_call`, …) so existing consumers
in `embeds/js` and the OpenAI `askAssistant` / `askModel` handlers keep
working
- `compatibility: "strict"` removed from `createOpenAI` (option dropped
in v5)
- `formatDataStreamPart` / `processDataStream` imports moved to
`@ai-sdk/ui-utils` (legacy package pinned at 1.2.11)

### E2E test follow-up

Second commit fixes Playwright tests that broke once the env-resolved
URLs / new SDK surface kicked in:
- `fileUpload`: assert exported URL contains `parseS3PublicBaseUrl()`
(not `S3_ENDPOINT`) so it works with `S3_PUBLIC_CUSTOM_DOMAIN`; verify
post-deletion via cache-busted `request.get` instead of a CDN-cached new
tab.
- `ssrf`: assert on the actual "Security validation failed" log emitted
by the pre-flight check; fixture now maps `response.statusCode` into a
`Status` variable so `Status: …` assertions resolve.
- Root `dev` script includes `@typebot.io/partykit` so the webhook
listener e2e test can hit PartyKit on `:1999`.

Also fixes a pre-existing broken anchor link in `whatsapp-ai-agent.mdx`
that blocked the landing-page link checker.

## Test plan

- [ ] `bunx nx test` passes
- [ ] `bunx nx typecheck` passes
- [ ] `bunx nx affected -t
format-and-lint,lint-repo,check-broken-links,test --parallel=4` passes
(pre-commit)
- [ ] `bun run dev` boots builder, viewer, workflows **and** PartyKit
- [ ] Viewer Playwright suite: `fileUpload.spec.ts`, `ssrf.spec.ts`,
`webhookListener.spec.ts` all green
- [ ] Manual smoke: OpenAI `askAssistant` block streams correctly in the
embed (v4 data-stream protocol preserved)
- [ ] Manual smoke: Anthropic / Mistral / Groq blocks still execute
end-to-end
- [ ] Manual smoke: send a test email through a workspace SMTP block
(nodemailer v8)

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 16:30:36 +02:00
Baptiste Arnaud
7d432813a9
🐛 Fix space icon picking and optimistic updates 2026-03-26 16:33:46 +01:00
Baptiste Arnaud
acd2f2971b
🔧 Remove "baseUrl": "." from tsconfigs 2026-03-25 16:40:12 +01:00
Baptiste Arnaud
e9186003a6
🔧 Upgrade Effect packages 2026-03-24 14:51:38 +01:00
Baptiste Arnaud
92a33129e4
🔧 Upgrade effect and fix workflows ci build 2026-03-23 10:23:08 +01:00
Baptiste Arnaud
9cf506c5d1
🔧 Add feature-flags service 2026-03-20 17:58:25 +01:00
Baptiste Arnaud
0a91fd269c
🐛 Keep email templates compatible with tsx JSX runtime 2026-03-20 16:48:55 +01:00
Baptiste Arnaud
a9b2af116d
🐛 Fix code scanning findings 2026-03-19 10:21:03 +01:00
Baptiste Arnaud
c2b251c7e5
♻️ Migrate to NX (#2418) 2026-03-18 15:29:32 +00:00
Baptiste Arnaud
14ec3a2598
🔧 Enable PR2 Biome rules and mechanical autofixes 2026-03-13 11:46:28 +01:00
Baptiste Arnaud
516b33b8a1
🔧 Enable PR1 Biome rules and prefer implicit undefined returns 2026-03-13 11:27:15 +01:00
Baptiste Arnaud
09b2446d04
🔧 Migrate workflows stack to Effect 4 beta
Switch the workflows, RPC clients, and shared service layers to the new Effect 4 APIs so the export and onboarding flows use a consistent runtime model. This also raises the background export threshold to keep smaller exports on the simpler path.
2026-03-11 18:05:25 +01:00
Baptiste Arnaud
ae5ea1f328
🔧 Fix Prisma scripts and refresh dependencies (#2389)
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
Deploy Workflows (Fly.io) / deploy (push) Has been cancelled
- Update workspace dependencies across apps and packages to align with
new lint/Effect expectations
- Adjust Prisma scripts and configs (db push, studio, adapters, read
replicas) for the latest CLI flags and tracing helpers
- Refresh generated locks and helper modules (emails, bot engine,
telemetry, rich text, scripts)
2026-02-12 12:45:01 +01:00
Baptiste Arnaud
5e0de89911
🔧 Add forward WA errors and campaign statuses option 2026-02-11 16:46:35 +01:00
Baptiste Arnaud
24722e94ee
🔧 add rpc retries and email divider (#2376)
Add a retry policy for workflows RPC HTTP calls to make onboarding
best-effort on transient failures. Include a small onboarding email
divider for readability.
2026-01-27 17:20:42 +01:00
Baptiste Arnaud
406ef51b07
Add onboarding email workflow and unsubscribe flow (#2370)
Adds onboarding email workflow with delayed send and suppression checks.
Introduces unsubscribe/resubscribe UI and API endpoints. Wires workflows
RPC config changes for user onboarding.
2026-01-26 14:09:08 +01:00
Baptiste Arnaud
81b5970a1c
🔧 Add Resend webhook bounce handler (#2366) 2026-01-23 16:51:04 +01:00
Baptiste Arnaud
5d6769dfb2
🐛 Fix workflows SendEmail react mismatch error
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
Deploy Workflows (Fly.io) / deploy (push) Has been cancelled
2026-01-22 18:37:02 +01:00
Baptiste Arnaud
8febf1a4bd
Introduce Effect-based workflow system (#2345) 2026-01-15 10:35:22 +01:00
Baptiste Arnaud
ae1a35c314
💚 Fix build fail react-emails
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
2026-01-08 17:01:57 +01:00
Baptiste Arnaud
b0326406f8
🛂 Automatically detect and take down abusing workspace usage 2026-01-08 16:10:21 +01:00
Baptiste Arnaud
d99a858cd0
💚 Fix CI not sending email due to React not defined 2026-01-08 15:23:47 +01:00
Baptiste Arnaud
0b14a21b37
⬆️ Upgrade Next.js and react 2025-12-12 10:28:27 +01:00
Baptiste Arnaud
7014069f5f
⬆️ Upgrade Next.js and react 2025-12-07 08:58:27 +01:00
Baptiste Arnaud
6a02a5b919
⬆️ Upgrade to React 19
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
2025-12-01 16:42:23 +01:00
Baptiste Arnaud
dd82c4d318
♻️ Migrate to Bun test 2025-11-27 12:08:31 +01:00
Baptiste Arnaud
27c9bf12e8
🧱 (results) Process results export in the background for big exports 2025-11-18 18:15:08 +01:00
Baptiste Arnaud
408ed327fe
🔨 Add sendEmailCampaign script 2025-10-21 10:40:26 +02:00
Baptiste Arnaud
022a4803a3
🚸 Set guest email to replyTo field on invitation emails
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
2025-10-09 08:34:04 +02:00
Baptiste Arnaud
9688a297ad
🔧 Revert to carret version pinning 2025-10-03 10:51:27 +02:00
Baptiste Arnaud
e928987623
⬆️ Upgrade tooling
TS v5.9, Biome v2 + fixes
2025-09-09 10:32:38 +02:00
Baptiste Arnaud
bec4a19aa1
♻️ Migrate mjml to react-email
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
2025-09-04 12:38:09 +02:00
Baptiste Arnaud
415180422f
🚸 Add replyTo host email for guest and workspace invitations
Closes #2065
2025-03-21 18:12:01 +01:00
Baptiste Arnaud
c83cfbcb4c
⬆️ Upgrade Tanstack and React 2025-02-26 14:18:27 +01:00
Baptiste Arnaud
aae6caaa0a
Revert "build: add ts references for better DX"
This reverts commit b8ffad0159.
2025-01-29 17:44:06 +01:00
Baptiste Arnaud
b8ffad0159
build: add ts references for better DX 2025-01-25 14:57:01 +01:00
Baptiste Arnaud
06e6faa9d5
feat: integrate new brand (#1935) 2025-01-23 13:25:47 +01:00
Baptiste Arnaud
1d6eca4c0c
🐛 Add explicit react import in emails package to avoid not found bug in CI
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
related to GH action report email not sending #1910
2024-12-01 19:31:14 +01:00
Baptiste Arnaud
c19d208f54
🐛 Attempt to fix "react not found" in ci script
related to #1910
2024-12-01 18:57:52 +01:00
Baptiste Arnaud
a7a15fd4d5
📈 Add limit warning email telemetry events
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
2024-11-26 10:20:28 +01:00
Baptiste Arnaud
698eda7079
🔧 Add version filed in package json files 2024-10-09 08:31:03 +02:00
Baptiste Arnaud
d3a869498e
️ (auth) Attempt to fix issue with link openers in corporate setups (#1819)
Also add option to provide type the login code instead of link-only
option Closes #1817
2024-10-04 18:26:30 +02:00
Baptiste Arnaud
10750f54d1
♻️ Use bun, biome, better ts config, new license and remove all barrel files (#1801)
Closes [#1754](https://github.com/baptisteArno/typebot.io/issues/1754)
2024-09-25 14:50:13 +02:00
Baptiste Arnaud
bec9cb68ca
⬆️ Upgrade chakra version 2024-06-17 14:12:14 +02:00
Baptiste Arnaud
0eacbebbbe
📄 Add Commercial License for ee folder (#1532) 2024-05-23 10:42:23 +02:00
Baptiste Arnaud
2fcf83c529
Introduce a new high-performing standalone chat API (#1200)
Closes #1154

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
	- Added authentication functionality for user sessions in chat API.
- Introduced chat-related API endpoints for starting, previewing, and
continuing chat sessions, and streaming messages.
- Implemented WhatsApp API webhook handling for receiving and processing
messages.
- Added environment variable `NEXT_PUBLIC_CHAT_API_URL` for chat API URL
configuration.

- **Bug Fixes**
	- Adjusted file upload logic to correctly determine the API host.
	- Fixed message streaming URL in chat integration with OpenAI.

- **Documentation**
- Updated guides for creating blocks, local installation, self-hosting,
and deployment to use `bun` instead of `pnpm`.

- **Refactor**
	- Refactored chat API functionalities to use modular architecture.
- Simplified client log saving and session update functionalities by
using external functions.
	- Transitioned package management and workflow commands to use `bun`.

- **Chores**
- Switched to `bun` for package management in Dockerfiles and GitHub
workflows.
	- Added new Dockerfile for chat API service setup with Bun framework.
	- Updated `.prettierignore` and documentation with new commands.

- **Style**
	- No visible changes to end-users.

- **Tests**
	- No visible changes to end-users.

- **Revert**
	- No reverts in this release.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-03-21 10:23:23 +01:00
Baptiste Arnaud
c2fc2df735 ♻️ Remove references to old s3 URLs 2023-12-06 07:30:47 +01:00
Baptiste Arnaud
3e06d89873 💚 Fix send email in CI "React is not defined" 2023-10-17 14:39:10 +02:00
Baptiste Arnaud
6b0c263f88 🚑 (billing) Fix chats pricing tiers incremental flat amou… 2023-10-17 08:32:41 +02:00
Baptiste Arnaud
797751b418
(billing) Automatic usage-based billing (#924)
BREAKING CHANGE: Stripe environment variables simplified. Check out the
new configs to adapt your existing system.

Closes #906





<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
### Summary by CodeRabbit

**New Features:**
- Introduced a usage-based billing system, providing more flexibility
and options for users.
- Integrated with Stripe for a smoother and more secure payment process.
- Enhanced the user interface with improvements to the billing,
workspace, and pricing pages for a more intuitive experience.

**Improvements:**
- Simplified the billing logic, removing additional chats and yearly
billing for a more streamlined user experience.
- Updated email notifications to keep users informed about their usage
and limits.
- Improved pricing and currency formatting for better clarity and
understanding.

**Testing:**
- Updated tests and specifications to ensure the reliability of new
features and improvements.

**Note:** These changes aim to provide a more flexible and user-friendly
billing system, with clearer pricing and improved notifications. Users
should find the new system more intuitive and easier to navigate.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2023-10-17 08:03:30 +02:00