Commit Graph

126 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
9cf506c5d1
🔧 Add feature-flags service 2026-03-20 17:58:25 +01:00
Baptiste Arnaud
f7f2e4a25e
🔧 Upgrade undici to fix package vulnerability 2026-03-19 10:21:02 +01:00
Baptiste Arnaud
c2b251c7e5
♻️ Migrate to NX (#2418) 2026-03-18 15:29:32 +00:00
Baptiste Arnaud
603fd903fb
🔧 Centralize runtime telemetry and Sentry reporting
Move builder, viewer, and workflows onto shared telemetry helpers so request logging, OTLP config, and workflow failures are reported consistently across runtimes.
2026-03-12 17:32:46 +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
80db9565cd
♻️ Upgrade to Zod v4 (#2355) 2026-01-19 10:51:20 +01:00
Baptiste Arnaud
ff728400d9
🔧 Upgrade bun and fix workflows ci 2026-01-16 13:22:27 +01:00
Baptiste Arnaud
a15673f5a6
♻️ Migrate builder from tRPC to oRPC (#2342) 2026-01-13 15:10:07 +01:00
Baptiste Arnaud
06110a8084
🔧 Fix @opentelemetry/winston-transport log error 2026-01-09 16:03:40 +01:00
Baptiste Arnaud
3d649886c2
♻️ Refacto viewer server handler to oRPC 2025-12-17 18:00:20 +01:00
Baptiste Arnaud
dd82c4d318
♻️ Migrate to Bun test 2025-11-27 12:08:31 +01:00
Baptiste Arnaud
7f58205f83
(openai) Add instructions field for gpt-4o-tts 2025-11-25 11:59:06 +01:00
Baptiste Arnaud
3b65b787ac
🔧 Fix bun.lock file not copied to Docker image
Closes #2293
2025-10-03 11:21:31 +02:00
Baptiste Arnaud
9688a297ad
🔧 Revert to carret version pinning 2025-10-03 10:51:27 +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
afdcde79c8
🔧 Add support for http requests proxy 2025-09-03 18:28:00 +02:00
Baptiste Arnaud
0af84b185c
🔧 Enabled logs capture in Sentry 2025-09-02 17:43:39 +02:00
Baptiste Arnaud
354b9e7893
♻️ Harmonize unit test execution across the workspace 2025-07-07 15:44:33 +02:00
Baptiste Arnaud
d182f422e8
💚 Fix vitest build error mismatch vite peer dep version 2025-07-04 15:08:06 +02:00
Baptiste Arnaud
045d62e566
🐛 Fix multiple choice parser not working with multiple indices 2025-06-23 16:06:48 +02:00
Baptiste Arnaud
90add8c56f
♻️ Upgrade to tRPC v11 and use Tanstack Query 2025-06-10 11:39:04 +02:00
Baptiste Arnaud
1217bd58e6
♻️ Migrate chat api schemas to its own package 2025-04-27 15:17:53 +02:00
Baptiste Arnaud
42d974f200
🐛 Tie globals object for each session
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
Closes #2029
2025-03-13 09:06:24 +01:00
Baptiste Arnaud
b61b5f5e4e
Add Cards Input
Some checks failed
Create Tag / create-tag (push) Has been cancelled
Deploy Partykit server / deploy (push) Has been cancelled
Closes #1987
2025-03-10 16:05:10 +01:00
Baptiste Arnaud
0a75534cce
Add missing deps 2025-02-19 11:02:21 +01:00
Baptiste Arnaud
6e81f1d038
⬆️ Upgrade trpc 2025-02-14 17:35:24 +01:00
Baptiste Arnaud
27366dde5a
💚 Add missing packages and clean up unused packages 2025-02-04 11:39:17 +01:00
Baptiste Arnaud
b4901fa04a
♻️ Upgrade ai SDK and refacto shared functions 2025-01-31 16:36:21 +01:00
Baptiste Arnaud
61615d8bd6
refactor: centralize credentials in credentials package 2025-01-25 17:32:26 +01:00
Baptiste Arnaud
846b8bcc0b
refactor: add chat-session package and migrate related files from bot-engine 2025-01-25 16:49:25 +01:00
Baptiste Arnaud
d97913ac15
refactor: move encryption functions to credentials package 2025-01-25 16:01:48 +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
6ec8f71cac
🔧 Upgrade Stripe API version and dependencies 2024-10-04 14:25:51 +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
77614f671f
⬆️ Upgrade ai package 2024-08-22 17:40:10 +02:00
Baptiste Arnaud
043f0054b0
⬆️ Upgrade AI SDK (#1641) 2024-07-15 14:32:42 +02:00
Baptiste Arnaud
5a3fd84214
⬆️ Upgrade pnpm, turbo, isolated-vm (#1609)
Closes https://github.com/baptisteArno/typebot.io/issues/1554
2024-07-11 16:09:49 +02:00
Baptiste Arnaud
1380e03b82
📝 Update high ticket lead template with Generate variable a… 2024-06-20 12:08:31 +02:00
Baptiste Arnaud
76fcf7ee93
Add "Generate variables" actions in AI blocks
Closes #1586
2024-06-18 12:13:00 +02:00
Baptiste Arnaud
bec9cb68ca
⬆️ Upgrade chakra version 2024-06-17 14:12:14 +02:00
Baptiste Arnaud
209cec34b9
🐛 Fix date parsing with european format 2024-06-10 15:32:06 +02:00
Baptiste Arnaud
6954aea488
Revert "⬆️ Upgrade isolated-vm"
This reverts commit 8c41d581ce.
2024-06-04 16:53:44 +02:00
Baptiste Arnaud
8c41d581ce
⬆️ Upgrade isolated-vm
Closes #1554
2024-06-04 15:42:44 +02:00
Baptiste Arnaud
8d66b52a39
🔒 Use isolated-vm 2024-05-22 12:12:02 +02:00
Baptiste Arnaud
15b2901f8a
♻️ (mistral) Use new ai sdk Mistral core 2024-05-21 16:08:35 +02:00
Baptiste Arnaud
40f21203b5
(setVariable) Add Transcription system var (#1507)
Closes #1484
2024-05-15 14:24:55 +02:00
Baptiste Arnaud
dc1929e15b
🐛 (openai) Fix ask assistant not correctly referencing uploaded f… (#1469)
…iles

Closes #1468, closes #1467, closes #1211
2024-04-24 16:11:06 +02:00