mirror of
https://github.com/twentyhq/twenty
synced 2026-04-21 13:37:22 +00:00
Closes [#1526](https://github.com/twentyhq/core-team-issues/issues/1526) --------- Co-authored-by: Félix Malfait <felix@twenty.com> Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
20 lines
824 B
TypeScript
20 lines
824 B
TypeScript
import { z } from 'zod';
|
|
import { baseTriggerSchema } from './base-trigger-schema';
|
|
|
|
export const workflowManualTriggerSchema = baseTriggerSchema
|
|
.extend({
|
|
type: z.literal('MANUAL'),
|
|
settings: z.object({
|
|
objectType: z.string().optional(),
|
|
outputSchema: z
|
|
.looseObject({})
|
|
.describe(
|
|
'Schema defining the output data structure. When a record is selected, it is accessible via {{trigger.record.fieldName}}. When no record is selected, no data is available.',
|
|
),
|
|
icon: z.string().optional(),
|
|
isPinned: z.boolean().optional(),
|
|
}),
|
|
})
|
|
.describe(
|
|
'Manual trigger that can be launched by the user. If a record is selected when launched, it is accessible via {{trigger.record.fieldName}}. If no record is selected, no data context is available.',
|
|
);
|