Commit Graph

318 Commits

Author SHA1 Message Date
Pranay Prakash 498bde261d New stream docs and imrpove serializaiton docs (#328) 2025-11-13 07:12:38 -08:00
Nathan Rajlich d113251548 Add 'Pass-by-Value Semantics' section to serialization docs (#254)
Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-12 17:52:29 -08:00
vercel[bot] 6419962496 Fix grammar errors in documentation (#320)
* Fix grammar errors in documentation

Fixed grammar errors in the documentation as requested.

## Changes Made

**Modified Files:**
- `CLAUDE.md` - Fixed 3 grammar errors:
  - "propogate" → "propagate" 
  - "changeset" → "changesets" (added missing plural)
  - "amke chagnesets" → "make changesets"
  - Added missing closing quote for "**BREAKING CHANGE**"

- `docs/content/docs/foundations/index.mdx` - Fixed 2 grammar errors:
  - "real world" → "real-world" (hyphenated compound adjective)
  - "go a long way in using workflows" → "go a long way in helping you use workflows effectively" (improved clarity and grammar)

- `docs/content/docs/foundations/workflows-and-steps.mdx` - Fixed 2 grammar errors:
  - "resume to workflow" → "resume the workflow" 
  - "each time, using" → "each time using" (removed unnecessary comma)
  - "workflows are run in" → "workflows run in" (improved verb form)

- `docs/content/docs/foundations/errors-and-retries.mdx` - Fixed 3 grammar errors:
  - Missing space: "RetryableError`](/docs...)and" → "RetryableError`](/docs...) and"
  - "we've learnt" → "we've learned" (consistent American English)
  - "Rolling back failed steps" → "Rolling Back Failed Steps" (proper title case)

- `packages/workflow/README.md` - Fixed 1 grammar error:
  - "engineers are" → "engineers are:" (added missing colon before list)

## Summary

Total of 11 grammar errors fixed across 5 documentation files. The fixes include:
- Spelling corrections (propogate → propagate, learnt → learned)
- Punctuation improvements (missing spaces, colons, quotes)
- Grammatical improvements (verb forms, compound adjectives)
- Style consistency (American English, title case)

All changes maintain the original meaning and formatting while improving readability and professional presentation of the documentation.

Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>

* Changeset

---------

Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com>
Co-authored-by: Peter Wielander <mittgfu@gmail.com>
2025-11-12 17:35:57 -08:00
Peter Wielander ed1c71f516 [docs] add o11y hint at the end of example code (#313) 2025-11-12 10:45:05 -08:00
Nathan Rajlich 6373ab5a1f resumeHook() now throws errors (#286)
Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-09 13:26:38 -08:00
Nathan Rajlich de04cea3dc Finish renaming "embedded" world to "local" in docs (#269)
Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-07 23:30:47 -08:00
Nathan Rajlich 120ae06115 Improvements to docs emphasizing the 'schema' property usage (#257)
Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-07 19:33:16 -08:00
Sébastien Chopin fb8153bec4 feat: add Nuxt module and documentation (#187)
* feat: add Nuxt module and documentation

* fix: add the prepare in the build command

* Apply suggestion from @vercel[bot]

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>

* chore: simplify usage without /nuxt

* wip

* Update nuxt.mdx

Co-Authored-By: Daniel Roe <daniel@roe.dev>

* add clean command and ignore prepare

* use @workflow/nitro

* Changeset

Added a Nuxt module and updated documentation accordingly.

* feat: enable typescript plugin in tsconfig

* chore: revert accordion value

* chore: use symlink

* fix: json parsing in trigger route for nitro-v2

* ci: add e2e tests for nuxt

* ci: add nuxt to test matrix

* chore: make sure to add /nuxt to avoid conflicts when importing entry-points

* chore: move typescriptPlugin option to Nitro

* chore: body is already parsed

* fix: use readRawBody

* fix: use rawBody in hook.post too

* chore: add missing import (but not required)

* chore: update pm

* Create resolve-symlinks.sh

* chore: add also node-rs/xxhash

* Update create-test-matrix.mjs

* update matrix

* Update create-test-matrix.mjs

* remove symlink to nitro-v2

---------

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Daniel Roe <daniel@roe.dev>
Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
Co-authored-by: Adrian Lam <me@adriandlam.com>
2025-11-08 01:10:59 +01:00
Adrian adf0cfeb91 feat: add getPort for detecting pid port (#233)
* feat: add getPort method for detecting pid port

* lockfile

* update tests and fix getPort usage

* changeset

* docs: update sveltekit getting started

* fix: use pid-port

* fix: not using config port env

* fix: remove unused getPort from world core

* remove unused stuff

* fix: world local config returning port 3000 as fallback

* changeset

* fix: rebase conflicts

* fix: util test missing http import

* changeset

* fix: wrong import for getPort in core runtime

* fix: getPort in @workflow/utils being imported into workflow runtime

* test: simplify sveltekit test

* fix missing import in test

* fix: async await stuff with getPort

* refactor: move getPort to @workflow/utils/get-port

* test: simplfiy getPort tests

* test: fix sveltekit ports
2025-11-07 14:36:36 -08:00
Nathan Rajlich 51e6d12d76 Simplify webhook 'Static Response' code example
Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-07 00:16:57 -08:00
Hayden Bleasel 353999c889 Restore code block animation on mobile (#246) 2025-11-06 17:08:11 -08:00
Nathan Rajlich 7013f29f46 Change RetryableError "retryAfter" option number value to represent milliseconds instead of seconds (#240)
Changed `RetryableError` to use milliseconds instead of seconds for numeric `retryAfter` values.

### What changed?

- Modified the `RetryableError` class to interpret numeric `retryAfter` values as milliseconds instead of seconds
- Updated documentation and examples to reflect this change
- Added dependency on `@workflow/utils` package to use the `parseDurationToDate` function
- Updated examples in documentation to show proper usage with:
  - Duration strings (e.g., "5m", "30s")
  - Millisecond values (e.g., 5000 for 5 seconds)
  - Date objects

### How to test?

1. Create a workflow that uses `RetryableError` with different `retryAfter` formats:
   ```typescript
   // With milliseconds
   throw new RetryableError("Test retry", { retryAfter: 5000 });
   
   // With duration string
   throw new RetryableError("Test retry", { retryAfter: "5m" });
   
   // With Date object
   throw new RetryableError("Test retry", { retryAfter: new Date(Date.now() + 10000) });
   ```
2. Verify that the retry behavior correctly respects the specified durations

### Why make this change?

Using milliseconds as the unit for numeric time values is more consistent with JavaScript conventions (like `setTimeout` and other timing functions). This change makes the API more intuitive for JavaScript developers and aligns with standard practices in the ecosystem.

Signed-off-by: Nathan Rajlich <n@n8.io>
2025-11-06 13:42:59 -08:00
Nathan Rajlich a28bc37e35 Make @standard-schema/spec be a regular dependency (#231)
* Make `@standard-schema/spec` be a regular dependency

The Standard Schema docs explicitly say that it should be a regular dep,
not a dev dep: https://standardschema.dev/#can-i-add-it-as-a-dev-dependency

* Support input/output types
2025-11-05 12:59:12 -08:00
Roman Popov 5c0268b8a4 feat: Add Standard Schema support and runtime validation to defineHook() (#144)
Signed-off-by: Roman Popov <atfpom4h@gmail.com>
2025-11-05 12:07:11 -08:00
Pranay Prakash 9f56434631 Make getWritable work inside steps (#222) 2025-11-05 09:54:13 -08:00
Nathan Rajlich 5b9a24a6bf [docs] Remove framework support callout (#220) 2025-11-04 23:07:31 -08:00
Copilot d792ff5063 Fix CLI flag documentation: --auth-token → --authToken (#213) 2025-11-04 16:09:55 -08:00
Paul Nodet f809294049 docs: invalid example for inspect example (#188)
Signed-off-by: Paul Nodet <5941125+pnodet@users.noreply.github.com>
2025-11-04 12:22:01 -08:00
Mahdi Bagheri 9a5d5a1f32 Updated postgres world doc (#178)
Removed Duplicate code snippet
2025-11-04 00:03:48 -08:00
Adrian f563585343 docs: add WorkflowReadableStreamOptions to start api reference (#100)
* export WorkflowReadableStreamOptions from workflow/api

* docs: add WorkflowReadableStreamOptions to start api reference

* changeset

* docs: update getRun api reference to show WorkflowReadableStreamOptions

* refactor: link to WorkflowReadableStreamOptions on getRun docs

* Apply suggestion from @TooTallNate

---------

Co-authored-by: Nathan Rajlich <n@n8.io>
2025-11-03 22:29:23 -08:00
Adrian 05714f7924 feat: add sveltekit support (#131)
* add workbench sveltekit

* add sveltekit package

* fix: use js for generated server routes in svelte

* add test routes for sveltekit workbench

* updates from debugging

* feat: add sveltekit build target

* update user sign up workflow workbench sveltekit

* fix: base builder missing GET route handler for sveltekit

* feat: add vercel builder and check for vercel env

* refactor: workflowPlugin for sveltekit

* ci: add tests to workbench sveltekit

* fix: no start command and vercel builder outputs

* fix: base builder conditions

* .

* add auto adapter sveltekit

* fix: disable checking origin for cross site ci stuff

* allow all trusted origins in svelte config

* fix: add catch for error thrown when waiting for ops

* fix: sveltekit workbench adapter

* test

* test

* refactor: move vercel builder on config resolved

* update package json

* add demo workflow trigger

* test letting sveltekit handle route generation

* fix: exclude git ignore for local builder outputs

* update config

* add debug logs

* update debug

* update turbo.json

* fix env check

* another output

* use top-level await

* ensure vercel functions are patched

* change hook

* update

* fix spread

* debug

* update

* chore: remove vercel builder

* chore: update comments in sveltekit workflow package

* chore: remove console comment

* refactor: workflow svelte plugin

* refactor: simplify local builder config

* chore: remove unused deps

* chore: add comment for workbench svelte app

* chore: add sveltekit export to workflow

* export sveltekit from workflow

* lockfile

* chore: remove unused deps svelte workbench

* update styling

* add sveltekit getting started docs

* update sveltekit docs getting started

* changeset

* Apply suggestion from @vercel[bot]

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>

* use proper env var

* Update packages/sveltekit/src/index.ts

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>

* Update docs/content/docs/getting-started/sveltekit.mdx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Document CSRF protection bypass in SvelteKit workbench config (#157)

* Initial plan

* docs: add CSRF security warning to svelte.config.js

Co-authored-by: adriandlam <93681064+adriandlam@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: adriandlam <93681064+adriandlam@users.noreply.github.com>

* refactor: deduplicate SvelteKit request conversion logic (#156)

* Initial plan

* refactor: extract duplicated SvelteKit request conversion to helper

Co-authored-by: adriandlam <93681064+adriandlam@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: adriandlam <93681064+adriandlam@users.noreply.github.com>

* docs: fix getting staretd sveltekit missing folder

* chore: cleanup sveltekit builder after rebase

* lockfile

* fix: sveltekit building logic in base builder

* refactor: move sveltekit builder logic to its own package

* fix: console log base builder

* changeset

* test

* feat: create hmr plugin

* fix: add initial build on load

* fix: check all files for workflows and steps

* add comments for plugin todo

* remove catching error

* fix: missing context for nodejs envs causing waitUntil to fail

* fix: setting global request conext in vercel environments

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
2025-11-03 21:15:33 -08:00
Serge the Lion eb78bfcdf9 feat: add NestJS to the list of upcoming supported frameworks (#175)
* feat: add NestJS to the list of upcoming supported frameworks

* Update docs/app/(home)/components/frameworks.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update docs/app/(home)/components/frameworks.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update docs/app/(home)/components/frameworks.tsx

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-03 14:36:10 -08:00
Pranay Prakash f973954bd3 Switching from MIT to Apache + DCO (#191)
* Switching from MIT to Apache + DCO

* Add DCO github app
2025-11-03 12:42:40 -08:00
Adrian 2e1e2f61dc docs: remove bun getting started card and add bun install command (#176) 2025-10-31 22:08:30 -07:00
Chris 61f022a773 Update use-cases-server.tsx (#173) 2025-10-31 13:39:16 -07:00
Adrian 50308ea82e fix: docs code block styling (#158) 2025-10-31 13:38:03 -07:00
Karthik Kalyanaraman 1223721d8c [docs] Improve the setup instructions for @workflow/world-postgres (#59) 2025-10-30 10:11:10 -07:00
Nathan Rajlich ec8b503352 Fix DurableAgent bad 'use step' docs example 2025-10-29 15:59:04 -07:00
Nathan Rajlich 9e0f7b0e0d Add DurableAgent and WorkflowChatTransport doc pages (#44)
Co-authored-by: Adrian <me@adriandlam.com>
2025-10-28 23:45:42 -07:00
Adrian 5fce21922a docs: update next logo and fix animating logos on landing (#122)
* docs: update next logo and fix animating logos on landing

* fix: kebab case on attributes in docs nextjs logo
2025-10-28 17:41:02 -07:00
Peter Wielander 0f845afb2a Alias workflow web to workflow inspect runs --web, update o11y doc image, hide trace viewer search for small runs (#124) 2025-10-28 17:19:39 -07:00
Mark Cotton 302d0552ec fix: correct proxy regex from Workflow docs setup (#114)
Fixes unbalanced regex pattern in proxy.ts matcher for Workflow setup documentation, resolving "Invalid source: Unbalanced pattern" error on dev server startup.
2025-10-28 17:01:21 -07:00
Adrian 88d0cfd5f8 docs: reorder templates in getting started (#121) 2025-10-28 16:52:21 -07:00
JJ Kasper 08ed58b060 Update withWorkflow and update docs (#123) 2025-10-28 14:18:33 -07:00
Adrian f0c8562504 docs: fix nested a tags in tsdoc comp (#102)
* docs: fix nested a tags in tsdoc comp

* docs: fix primary a tag color in api reference table
2025-10-28 12:50:11 -07:00
Adrian 25b8e882ff docs: add hono getting started page (#107)
* docs: add hono getting started page

* Update docs/content/docs/getting-started/hono.mdx

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>

* docs: add template nodejs to hono create command

* Update docs/content/docs/getting-started/hono.mdx

Co-authored-by: Pooya Parsa <pyapar@gmail.com>

* docs: add callout for nitro

* docs: update getting started nitro callout

* Update docs/content/docs/getting-started/hono.mdx

Co-authored-by: Pooya Parsa <pyapar@gmail.com>

---------

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Pooya Parsa <pyapar@gmail.com>
2025-10-28 12:38:23 -07:00
Malte Ubl a27a0b316d Make serving LLMs to agents actually work and give them an index to navigate (#108)
- The original code was rewriting in the wrong phase and with the wrong regex for Claude
- I noticed that LLMs need a way to discover other pages efficiently, so I made a sitemap in markdown and linked it from every MD page at the bottom
2025-10-27 17:57:49 -07:00
Alessandro (Ale) Segala 50b6061272 docs: Fix capitalization for IntelliSense & TypeScript (#103) 2025-10-27 15:53:01 -07:00
Anthony 6504e4285c Add bigint serialization support (#90) 2025-10-27 15:51:39 -07:00
Pranay Prakash 7bb7486d40 Docs Page on "Understanding Directives" (#89)
* Draft of Why Directives post

* Fix link

* Improvements

* Vercel comment fixes

* More grammar/flow/style fixes

* Rename to understanding directives

* fixes
2025-10-27 12:49:16 -07:00
Pranay Prakash b301b0a557 Add callout to directives guide (#75) 2025-10-26 09:50:51 -07:00
Yangshun Tay 109abcfbbc Fix typo in use cases (#78) 2025-10-26 09:50:15 -07:00
Malte Ubl e2889cd5f2 SEO improvements (#87) 2025-10-26 09:37:31 -07:00
Pranay Prakash b4d1a8de37 Docs: Small improvements to the How it works pages 2025-10-25 21:00:30 -07:00
Rhys Sullivan 804976d694 [docs]: explain how to build your own workflow handler (#50)
* wip

* almost good

* Update meta.json

* use mermaid diagram

* sdk -> dev kit

* fixes

* security explanation

* Update runtime-adapters.mdx

* move under how it works

* update how workflow build works

* fix file filtering + remove component 3

* dedup http handler info

* merge sections

* explain difference between bun framework and runtime

* runtime adapter -> framework integration

* framework integration

* bunfig instructions

* Pranay's edits

* Refactor to 2 pages

* Improve framework integrations doc

---------

Co-authored-by: Pranay Prakash <pranay.gp@gmail.com>
2025-10-25 18:44:44 -07:00
Adrian 3c3900fbff fix: style of mobile api fields table (#65) 2025-10-25 16:43:22 -07:00
Adrian a6eecc925e add llms full route to copy all docs (#62) 2025-10-25 16:39:45 -07:00
Allen Zhou c9b884e82f [docs] improve mobile navbar view (#63)
* show workflow logo on mobile

* Integrate GitHub link button in navbar

Add GitHub button to the navbar and adjust styles.

* add github icon

* .
2025-10-25 14:34:12 -07:00
Pranay Prakash cca70405a1 Add starting worklfow section to docs (#58) 2025-10-25 12:45:06 -07:00
Pranay Prakash 5e6789fc18 Move idempotency page down (#42) 2025-10-24 23:28:43 -07:00