Commit Graph

28 Commits

Author SHA1 Message Date
96b36a3caa 0.0.30 2025-09-09 10:30:38 +02:00
8eedaba9ed 0.0.29 2025-09-09 10:13:04 +02:00
3e9ff10076 0.0.28 2025-09-08 20:54:58 +02:00
0fb23cb425 0.0.27 2025-09-08 20:46:15 +02:00
a8ae877039 0.0.26 2025-09-08 20:35:50 +02:00
ab5b26c42c Fix field name clashing with namespaced virtual field names
- Prefix built-in trigger fields with __builtin_ namespace
- Prefix custom trigger fields with __trigger_{slug}_ namespace
- Completely eliminates field name conflicts between triggers
- Maintains backward compatibility with existing workflows
- Virtual fields transparently handle the namespacing

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-07 17:15:22 +02:00
c47197223c Add trigger builder helpers to improve DX for custom triggers
- Add createTrigger() and createAdvancedTrigger() helpers
- Add preset builders: webhookTrigger, cronTrigger, eventTrigger, etc.
- Implement virtual fields with JSON backing for trigger parameters
- Eliminate 90% of boilerplate when creating custom triggers
- Add /helpers export path for trigger builders
- Fix field name clashing between built-in and custom trigger parameters
- Add comprehensive examples and documentation
- Maintain backward compatibility with existing triggers

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-07 15:30:10 +02:00
0a036752ea 0.0.23 2025-09-04 18:03:59 +02:00
74217d532d Implement independent error storage system and comprehensive improvements
Major Features:
• Add persistent error tracking for timeout/network failures that bypasses PayloadCMS output limitations
• Implement smart error classification (timeout, DNS, connection, network) with duration-based detection
• Add comprehensive test infrastructure with MongoDB in-memory testing and enhanced mocking
• Fix HTTP request handler error preservation with detailed context storage
• Add independent execution tracking with success/failure status and duration metrics

Technical Improvements:
• Update JSONPath documentation to use correct $.trigger.doc syntax across all step types
• Fix PayloadCMS job execution to use runByID instead of run() for reliable task processing
• Add enhanced HTTP error handling that preserves outputs for 4xx/5xx status codes
• Implement proper nock configuration with undici for Node.js 22 fetch interception
• Add comprehensive unit tests for WorkflowExecutor with mocked PayloadCMS instances

Developer Experience:
• Add detailed error information in workflow context with URL, method, timeout, attempts
• Update README with HTTP error handling patterns and enhanced error tracking examples
• Add test helpers and setup infrastructure for reliable integration testing
• Fix workflow step validation and JSONPath field descriptions

Breaking Changes: None - fully backward compatible

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-04 18:03:30 +02:00
397559079f 0.0.22 2025-09-03 19:15:58 +02:00
cd85f90ef1 0.0.21 2025-09-01 21:25:47 +02:00
dfcc5c0fce 0.0.20 2025-09-01 21:13:01 +02:00
8ff65ca7c3 0.0.19 2025-09-01 21:05:25 +02:00
3c54f00f57 0.0.18 2025-09-01 20:57:37 +02:00
46c9f11534 0.0.17 2025-09-01 20:47:41 +02:00
c24610b3d9 0.0.16 2025-09-01 20:32:03 +02:00
a711fbdbea 0.0.15 2025-09-01 19:42:25 +02:00
f3f18d5b4c 0.0.14 2025-09-01 18:02:25 +02:00
6397250045 Fix JSON circular reference serialization and use PayloadCMS generated types
- Replace duplicate type definitions with PayloadCMS generated types
- Fix workflow context serialization with safeSerialize() method
- Resolve type mismatches (id: string vs number)
- Update all imports to use PayloadWorkflow type
- Ensure workflow runs are created successfully without serialization errors

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-01 18:02:21 +02:00
964b11c0c9 0.0.13 2025-09-01 10:33:02 +02:00
7686495283 0.0.12 2025-08-31 20:35:13 +02:00
c5b2e6f286 Release v0.0.11 - Fix ES module bundling issues
- Separated server-side and client-safe exports
- Main export now contains only types to prevent bundling server code
- Updated documentation with new import structure

🤖 Generated with [Claude Code](https://claude.ai/code)
2025-08-31 18:09:52 +02:00
75ec74270c 0.0.10 2025-08-31 18:06:45 +02:00
cadb40e401 Fix client-side bundling by separating server and client exports
- Create dedicated /server export for server-side functions and plugin
- Main export now contains only types (client-safe)
- Remove problematic /steps export that exposed server functions
- Update README with correct import structure
- Fix tests to use /server export

This prevents server-side code from being bundled in client JavaScript,
eliminating the "require is not defined in ES module scope" runtime error.

Breaking change: workflowsPlugin must now be imported from '/server':
import { workflowsPlugin } from '@xtr-dev/payload-automation/server'

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-31 18:06:39 +02:00
19b9566df6 0.0.9 2025-08-31 17:58:56 +02:00
7affbd26c4 0.0.8 2025-08-31 17:14:40 +02:00
592536f61a Rename 'collection' field to 'collectionSlug' to avoid PayloadCMS reserved field conflicts
- Updated Workflow collection trigger field from 'collection' to 'collectionSlug'
- Updated all document operation steps (create, read, update, delete) to use 'collectionSlug'
- Updated corresponding handlers to destructure 'collectionSlug' instead of 'collection'
- Removed debug console.log statements from logger configLogger methods
- Fixed collection hook debug logs to use 'slug' instead of reserved 'collection' field

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-31 17:14:35 +02:00
2d84f535f4 Initial commit 2025-08-29 18:11:36 +02:00