mirror of
https://github.com/xtr-dev/payload-automation.git
synced 2025-12-10 00:43:23 +00:00
- 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>
25 lines
849 B
TypeScript
25 lines
849 B
TypeScript
// Main export contains only types and client-safe utilities
|
|
// Server-side functions are exported via '@xtr-dev/payload-automation/server'
|
|
|
|
// Pure types only - completely safe for client bundling
|
|
export type {
|
|
CustomTriggerOptions,
|
|
TriggerResult,
|
|
ExecutionContext,
|
|
WorkflowsPluginConfig
|
|
} from './types/index.js'
|
|
|
|
export type {
|
|
PayloadWorkflow as Workflow,
|
|
WorkflowStep,
|
|
WorkflowTrigger
|
|
} from './core/workflow-executor.js'
|
|
|
|
// Server-side functions are NOT re-exported here to avoid bundling issues
|
|
// Import server-side functions from the /server export instead
|
|
|
|
// Server functions and plugin should be imported from '/server':
|
|
// import { workflowsPlugin } from '@xtr-dev/payload-automation/server'
|
|
// UI components should be imported from '/client':
|
|
// import { TriggerWorkflowButton } from '@xtr-dev/payload-automation/client'
|