From adf50b241953469ee7addf82447a19d096dd3c62 Mon Sep 17 00:00:00 2001 From: Lauris Skraucis Date: Mon, 14 Jul 2025 11:46:21 +0200 Subject: [PATCH] docs: v2 workflows and disable on prefill booking fields (#22445) * wip * docs: booking fields prefilling * docs: wofklows * fix: guests docs --- .../org-team-workflows.controller.ts | 2 +- .../workflows/inputs/create-workflow.input.ts | 61 +- .../workflows/inputs/update-workflow.input.ts | 57 +- apps/api/v2/swagger/documentation.json | 1484 ++++++++++++++++- docs/api-reference/v2/openapi.json | 1225 +++++++++++++- .../inputs/booking-fields.input.ts | 55 +- 6 files changed, 2709 insertions(+), 175 deletions(-) diff --git a/apps/api/v2/src/modules/organizations/teams/workflows/controllers/org-team-workflows.controller.ts b/apps/api/v2/src/modules/organizations/teams/workflows/controllers/org-team-workflows.controller.ts index 7baf973f9c..7be286cf0c 100644 --- a/apps/api/v2/src/modules/organizations/teams/workflows/controllers/org-team-workflows.controller.ts +++ b/apps/api/v2/src/modules/organizations/teams/workflows/controllers/org-team-workflows.controller.ts @@ -93,7 +93,7 @@ export class OrganizationTeamWorkflowsController { @Patch("/:workflowId") @UseGuards(IsWorkflowInTeam) - @ApiOperation({ summary: "Update workflow" }) + @ApiOperation({ summary: "Update organization team workflow" }) @Roles("TEAM_ADMIN") @PlatformPlan("SCALE") async updateWorkflow( diff --git a/apps/api/v2/src/modules/workflows/inputs/create-workflow.input.ts b/apps/api/v2/src/modules/workflows/inputs/create-workflow.input.ts index d309a9ac43..a1c362d1a3 100644 --- a/apps/api/v2/src/modules/workflows/inputs/create-workflow.input.ts +++ b/apps/api/v2/src/modules/workflows/inputs/create-workflow.input.ts @@ -1,4 +1,4 @@ -import { ApiProperty, ApiPropertyOptional, getSchemaPath } from "@nestjs/swagger"; +import { ApiExtraModels, ApiProperty, ApiPropertyOptional, getSchemaPath } from "@nestjs/swagger"; import { Type } from "class-transformer"; import { IsBoolean, @@ -74,6 +74,24 @@ export type TriggerDtoType = | OnCancelTriggerDto | OnAfterCalVideoGuestsNoShowTriggerDto | OnAfterCalVideoHostsNoShowTriggerDto; + +@ApiExtraModels( + OnBeforeEventTriggerDto, + OnAfterEventTriggerDto, + OnCancelTriggerDto, + OnCreationTriggerDto, + OnRescheduleTriggerDto, + OnAfterCalVideoGuestsNoShowTriggerDto, + OnAfterCalVideoHostsNoShowTriggerDto, + WorkflowEmailAddressStepDto, + WorkflowEmailAttendeeStepDto, + WorkflowEmailHostStepDto, + WorkflowPhoneWhatsAppAttendeeStepDto, + WorkflowPhoneWhatsAppNumberStepDto, + WorkflowPhoneNumberStepDto, + WorkflowPhoneAttendeeStepDto, + BaseWorkflowTriggerDto +) export class CreateWorkflowDto { @ApiProperty({ description: "Name of the workflow", example: "Platform Test Workflow" }) @IsString() @@ -86,17 +104,15 @@ export class CreateWorkflowDto { @ApiProperty({ description: "Trigger configuration for the workflow", - items: { - oneOf: [ - { $ref: getSchemaPath(OnBeforeEventTriggerDto) }, - { $ref: getSchemaPath(OnAfterEventTriggerDto) }, - { $ref: getSchemaPath(OnCancelTriggerDto) }, - { $ref: getSchemaPath(OnCreationTriggerDto) }, - { $ref: getSchemaPath(OnRescheduleTriggerDto) }, - { $ref: getSchemaPath(OnAfterCalVideoGuestsNoShowTriggerDto) }, - { $ref: getSchemaPath(OnAfterCalVideoHostsNoShowTriggerDto) }, - ], - }, + oneOf: [ + { $ref: getSchemaPath(OnBeforeEventTriggerDto) }, + { $ref: getSchemaPath(OnAfterEventTriggerDto) }, + { $ref: getSchemaPath(OnCancelTriggerDto) }, + { $ref: getSchemaPath(OnCreationTriggerDto) }, + { $ref: getSchemaPath(OnRescheduleTriggerDto) }, + { $ref: getSchemaPath(OnAfterCalVideoGuestsNoShowTriggerDto) }, + { $ref: getSchemaPath(OnAfterCalVideoHostsNoShowTriggerDto) }, + ], }) @ValidateNested() @Type(() => BaseWorkflowTriggerDto, { @@ -124,17 +140,16 @@ export class CreateWorkflowDto { @ApiProperty({ description: "Steps to execute as part of the workflow", - items: { - oneOf: [ - { $ref: getSchemaPath(WorkflowEmailAddressStepDto) }, - { $ref: getSchemaPath(WorkflowEmailAttendeeStepDto) }, - { $ref: getSchemaPath(WorkflowEmailHostStepDto) }, - { $ref: getSchemaPath(WorkflowPhoneWhatsAppAttendeeStepDto) }, - { $ref: getSchemaPath(WorkflowPhoneWhatsAppNumberStepDto) }, - { $ref: getSchemaPath(WorkflowPhoneNumberStepDto) }, - { $ref: getSchemaPath(WorkflowPhoneAttendeeStepDto) }, - ], - }, + oneOf: [ + { $ref: getSchemaPath(WorkflowEmailAddressStepDto) }, + { $ref: getSchemaPath(WorkflowEmailAttendeeStepDto) }, + { $ref: getSchemaPath(WorkflowEmailHostStepDto) }, + { $ref: getSchemaPath(WorkflowPhoneWhatsAppAttendeeStepDto) }, + { $ref: getSchemaPath(WorkflowPhoneWhatsAppNumberStepDto) }, + { $ref: getSchemaPath(WorkflowPhoneNumberStepDto) }, + { $ref: getSchemaPath(WorkflowPhoneAttendeeStepDto) }, + ], + type: "array", }) @ValidateNested({ each: true }) @ArrayMinSize(1, { message: "Your workflow must contain at least one step." }) diff --git a/apps/api/v2/src/modules/workflows/inputs/update-workflow.input.ts b/apps/api/v2/src/modules/workflows/inputs/update-workflow.input.ts index af16adbcc5..7d70e7e742 100644 --- a/apps/api/v2/src/modules/workflows/inputs/update-workflow.input.ts +++ b/apps/api/v2/src/modules/workflows/inputs/update-workflow.input.ts @@ -1,4 +1,4 @@ -import { ApiProperty, ApiPropertyOptional, getSchemaPath } from "@nestjs/swagger"; +import { ApiExtraModels, ApiProperty, ApiPropertyOptional, getSchemaPath } from "@nestjs/swagger"; import { Type } from "class-transformer"; import { IsNumber, IsString, IsOptional, ValidateNested, ArrayMinSize } from "class-validator"; @@ -113,6 +113,23 @@ export class UpdateWhatsAppAttendeePhoneWorkflowStepDto extends WorkflowPhoneWha id?: number; } +@ApiExtraModels( + OnBeforeEventTriggerDto, + OnAfterEventTriggerDto, + OnCancelTriggerDto, + OnCreationTriggerDto, + OnRescheduleTriggerDto, + OnAfterCalVideoGuestsNoShowTriggerDto, + OnAfterCalVideoHostsNoShowTriggerDto, + UpdateEmailAddressWorkflowStepDto, + UpdateEmailAttendeeWorkflowStepDto, + UpdateEmailHostWorkflowStepDto, + UpdatePhoneAttendeeWorkflowStepDto, + UpdatePhoneWhatsAppNumberWorkflowStepDto, + UpdateWhatsAppAttendeePhoneWorkflowStepDto, + UpdatePhoneNumberWorkflowStepDto, + BaseWorkflowTriggerDto +) export class UpdateWorkflowDto { @ApiPropertyOptional({ description: "Name of the workflow", example: "Platform Test Workflow" }) @IsString() @@ -128,6 +145,20 @@ export class UpdateWorkflowDto { @IsOptional() activation?: WorkflowActivationDto; + @ApiPropertyOptional({ + description: "Trigger configuration for the workflow", + oneOf: [ + { $ref: getSchemaPath(OnBeforeEventTriggerDto) }, + { $ref: getSchemaPath(OnAfterEventTriggerDto) }, + { $ref: getSchemaPath(OnCancelTriggerDto) }, + { $ref: getSchemaPath(OnCreationTriggerDto) }, + { $ref: getSchemaPath(OnRescheduleTriggerDto) }, + { $ref: getSchemaPath(OnAfterCalVideoGuestsNoShowTriggerDto) }, + { $ref: getSchemaPath(OnAfterCalVideoHostsNoShowTriggerDto) }, + ], + }) + @IsOptional() + @ValidateNested() @Type(() => BaseWorkflowTriggerDto, { discriminator: { property: "type", @@ -142,7 +173,7 @@ export class UpdateWorkflowDto { ], }, }) - trigger!: + trigger?: | OnAfterEventTriggerDto | OnBeforeEventTriggerDto | OnCreationTriggerDto @@ -150,19 +181,19 @@ export class UpdateWorkflowDto { | OnCancelTriggerDto | OnAfterCalVideoGuestsNoShowTriggerDto | OnAfterCalVideoHostsNoShowTriggerDto; + @ApiPropertyOptional({ description: "Steps to execute as part of the workflow", - items: { - oneOf: [ - { $ref: getSchemaPath(UpdateEmailAddressWorkflowStepDto) }, - { $ref: getSchemaPath(UpdateEmailAttendeeWorkflowStepDto) }, - { $ref: getSchemaPath(UpdateEmailHostWorkflowStepDto) }, - { $ref: getSchemaPath(UpdatePhoneAttendeeWorkflowStepDto) }, - { $ref: getSchemaPath(UpdatePhoneWhatsAppNumberWorkflowStepDto) }, - { $ref: getSchemaPath(UpdateWhatsAppAttendeePhoneWorkflowStepDto) }, - { $ref: getSchemaPath(UpdatePhoneNumberWorkflowStepDto) }, - ], - }, + oneOf: [ + { $ref: getSchemaPath(UpdateEmailAddressWorkflowStepDto) }, + { $ref: getSchemaPath(UpdateEmailAttendeeWorkflowStepDto) }, + { $ref: getSchemaPath(UpdateEmailHostWorkflowStepDto) }, + { $ref: getSchemaPath(UpdatePhoneAttendeeWorkflowStepDto) }, + { $ref: getSchemaPath(UpdatePhoneWhatsAppNumberWorkflowStepDto) }, + { $ref: getSchemaPath(UpdateWhatsAppAttendeePhoneWorkflowStepDto) }, + { $ref: getSchemaPath(UpdatePhoneNumberWorkflowStepDto) }, + ], + type: "array", }) @ValidateNested({ each: true }) @ArrayMinSize(1, { message: "Your workflow must contain at least one step." }) diff --git a/apps/api/v2/swagger/documentation.json b/apps/api/v2/swagger/documentation.json index 4c8e941a64..d1d88400fc 100644 --- a/apps/api/v2/swagger/documentation.json +++ b/apps/api/v2/swagger/documentation.json @@ -5556,7 +5556,7 @@ }, "patch": { "operationId": "OrganizationTeamWorkflowsController_updateWorkflow", - "summary": "Update workflow", + "summary": "Update organization team workflow", "parameters": [ { "name": "Authorization", @@ -14530,7 +14530,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{phone: '+37122222222'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14572,7 +14572,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{address: 'mainstreat 10, new york'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14614,7 +14614,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `who-referred-you` and the URL contains query parameter `&who-referred-you=bob`, the text field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `friend` and the URL contains query parameter `&friend=bob`, the text field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{friend: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14656,7 +14656,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories-per-day` and the URL contains query parameter `&calories-per-day=3000`, the number field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories` and the URL contains query parameter `&calories=3000`, the number field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{calories: 3000}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14698,7 +14698,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `dear-diary` and the URL contains query parameter `&dear-diary=Today I shipped a feature`, the text area will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `reflection` and the URL contains query parameter `&reflection=Today I shipped a feature`, the text area will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{reflection: 'Today i shipped a feature'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14750,7 +14750,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14799,7 +14799,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and the URL contains query parameter `&language=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: ['en', 'it']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14841,7 +14841,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{consultants: ['alice@gmail.com', 'bob@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14889,7 +14889,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify-me` and the URL contains query parameter `¬ify-me=true`, the checkbox will be selected and the checkbox field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14937,7 +14937,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14974,7 +14974,8 @@ "type": "boolean" }, "disableOnPrefill": { - "type": "boolean" + "type": "boolean", + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15015,7 +15016,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `video-url` and the URL contains query parameter `&video-url=https://youtube.com/abc`the url field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `videourl` and the URL contains query parameter `&videourl=https://youtube.com/abc`the url field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{videourl: 'https://caltube.com/123'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15341,7 +15342,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled. In case of Booker atom need to pass 'name' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{name: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-fields" } }, "required": [ @@ -15374,7 +15375,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled. In case of Booker atom need to pass 'email' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{email: 'bob@gmail.com'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": [ @@ -15406,7 +15407,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&title=journey`, the title field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&title=journey`, the title field will be prefilled with this value and disabled. In case of Booker atom need to pass 'title' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{title: 'very important meeting'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": [ @@ -15452,7 +15453,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `¬es=journey`, the notes field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `¬es=journey`, the notes field will be prefilled with this value and disabled. In case of Booker atom need to pass 'notes' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notes: 'bring notebook and paper'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": [ @@ -15482,7 +15483,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&guests=bob@cal.com`, the guests field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&guests=bob@cal.com`, the guests field will be prefilled with this value and disabled. In case of Booker atom need to pass 'guests' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{guests: ['bob@gmail.com', 'alice@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": [ @@ -15512,7 +15513,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&rescheduleReason=travel`, the rescheduleReason field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&rescheduleReason=travel`, the rescheduleReason field will be prefilled with this value and disabled. In case of Booker atom need to pass 'rescheduleReason' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{rescheduleReason: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": [ @@ -16098,7 +16099,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled. In case of Booker atom need to pass 'email' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{email: 'bob@gmail.com'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "isDefault": { "type": "object", @@ -16150,7 +16151,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled. In case of Booker atom need to pass 'name' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{name: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-fields" }, "isDefault": { "type": "object", @@ -16452,7 +16453,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{address: 'mainstreat 10, new york'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16511,7 +16512,8 @@ "type": "boolean" }, "disableOnPrefill": { - "type": "boolean" + "type": "boolean", + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16581,7 +16583,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify-me` and the URL contains query parameter `¬ify-me=true`, the checkbox will be selected and the checkbox field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16646,7 +16648,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{consultants: ['alice@gmail.com', 'bob@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16716,7 +16718,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and the URL contains query parameter `&language=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: ['en', 'it']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16781,7 +16783,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `video-url` and the URL contains query parameter `&video-url=https://youtube.com/abc`the url field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `videourl` and the URL contains query parameter `&videourl=https://youtube.com/abc`the url field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{videourl: 'https://caltube.com/123'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16845,7 +16847,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories-per-day` and the URL contains query parameter `&calories-per-day=3000`, the number field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories` and the URL contains query parameter `&calories=3000`, the number field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{calories: 3000}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16907,7 +16909,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{phone: '+37122222222'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16977,7 +16979,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -17052,7 +17054,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -17117,7 +17119,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `dear-diary` and the URL contains query parameter `&dear-diary=Today I shipped a feature`, the text area will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `reflection` and the URL contains query parameter `&reflection=Today I shipped a feature`, the text area will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{reflection: 'Today i shipped a feature'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -17181,7 +17183,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `who-referred-you` and the URL contains query parameter `&who-referred-you=bob`, the text field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `friend` and the URL contains query parameter `&friend=bob`, the text field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{friend: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -21873,6 +21875,741 @@ "data" ] }, + "WorkflowTriggerOffsetDto": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Time value for offset before/after event trigger", + "example": 24 + }, + "unit": { + "type": "object", + "description": "Unit for the offset time", + "example": "hour" + } + }, + "required": [ + "value", + "unit" + ] + }, + "OnBeforeEventTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "beforeEvent", + "description": "Trigger type for the workflow", + "example": "beforeEvent" + } + }, + "required": [ + "offset", + "type" + ] + }, + "OnAfterEventTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterEvent", + "description": "Trigger type for the workflow", + "example": "afterEvent" + } + }, + "required": [ + "offset", + "type" + ] + }, + "OnCancelTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "eventCancelled", + "description": "Trigger type for the workflow" + } + }, + "required": [ + "type" + ] + }, + "OnCreationTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "newEvent", + "description": "Trigger type for the workflow" + } + }, + "required": [ + "type" + ] + }, + "OnRescheduleTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "rescheduleEvent", + "description": "Trigger type for the workflow" + } + }, + "required": [ + "type" + ] + }, + "OnAfterCalVideoGuestsNoShowTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterGuestsCalVideoNoShow", + "description": "Trigger type for the workflow", + "example": "afterGuestsCalVideoNoShow" + } + }, + "required": [ + "offset", + "type" + ] + }, + "OnAfterCalVideoHostsNoShowTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterHostsCalVideoNoShow", + "description": "Trigger type for the workflow", + "example": "afterHostsCalVideoNoShow" + } + }, + "required": [ + "offset", + "type" + ] + }, + "HtmlWorkflowMessageDto": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the message", + "example": "Reminder: Your Meeting {EVENT_NAME} - {EVENT_DATE_ddd, MMM D, YYYY h:mma} with Cal.com" + }, + "html": { + "type": "string", + "description": "HTML content of the message (used for Emails)", + "example": "

This is a reminder from {ORGANIZER} of {EVENT_NAME} to {ATTENDEE} starting here {LOCATION} {MEETING_URL} at {START_TIME_h:mma} {TIMEZONE}.

" + } + }, + "required": [ + "subject", + "html" + ] + }, + "WorkflowEmailAddressStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_address", + "description": "Action to perform, send an email to a specific email address", + "example": "email_address" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedEmailId": { + "type": "number", + "description": "Email address if recipient is EMAIL, required for action EMAIL_ADDRESS", + "example": "31214", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-an-email-for-an-org-team" + } + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedEmailId", + "includeCalendarEvent", + "message" + ] + }, + "WorkflowEmailAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_attendee", + "description": "Action to perform, send an email to the attendees of the event", + "example": "email_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "WorkflowEmailHostStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_host", + "description": "Action to perform, send an email to the host of the event", + "example": "email_host" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "TextWorkflowMessageDto": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the message", + "example": "Reminder: Your Meeting {EVENT_NAME} - {EVENT_DATE_ddd, MMM D, YYYY h:mma} with Cal.com" + }, + "text": { + "type": "string", + "description": "Text content of the message (used for SMS)", + "example": "This is a reminder message from {ORGANIZER} of {EVENT_NAME} to {ATTENDEE} starting here {LOCATION} {MEETING_URL} at {START_TIME_h:mma} {TIMEZONE}." + } + }, + "required": [ + "subject", + "text" + ] + }, + "WorkflowPhoneWhatsAppAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_attendee", + "description": "Action to perform", + "example": "whatsapp_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Message content for this step, send a text message via whatsapp to the phone numbers of the attendees", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "message" + ] + }, + "WorkflowPhoneWhatsAppNumberStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_number", + "description": "Action to perform, send a text message via whatsapp to a specific phone number", + "example": "whatsapp_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedPhoneId", + "message" + ] + }, + "WorkflowPhoneNumberStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_number", + "description": "Action to perform, send a text message to a specific phone number", + "example": "sms_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedPhoneId", + "message" + ] + }, + "WorkflowPhoneAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_attendee", + "description": "Action to perform, send a text message to the phone numbers of the attendees", + "example": "sms_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + }, + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "message" + ] + }, + "BaseWorkflowTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "object", + "description": "Trigger type for the workflow" + } + }, + "required": [ + "type" + ] + }, "WorkflowActivationDto": { "type": "object", "properties": { @@ -21915,40 +22652,59 @@ ] }, "trigger": { - "type": "object", "description": "Trigger configuration for the workflow", + "oneOf": [ + { + "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCancelTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCreationTriggerDto" + }, + { + "$ref": "#/components/schemas/OnRescheduleTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + } + ] + }, + "steps": { + "type": "array", + "description": "Steps to execute as part of the workflow", "items": { "oneOf": [ { - "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailAddressStepDto" }, { - "$ref": "#/components/schemas/OnAfterEventTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailAttendeeStepDto" }, { - "$ref": "#/components/schemas/OnCancelTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailHostStepDto" }, { - "$ref": "#/components/schemas/OnCreationTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneWhatsAppAttendeeStepDto" }, { - "$ref": "#/components/schemas/OnRescheduleTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneWhatsAppNumberStepDto" }, { - "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneNumberStepDto" }, { - "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneAttendeeStepDto" } ] } - }, - "steps": { - "description": "Steps to execute as part of the workflow", - "items": { - "type": "object" - }, - "type": "array" } }, "required": [ @@ -21958,6 +22714,576 @@ "steps" ] }, + "UpdateEmailAddressWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_address", + "description": "Action to perform, send an email to a specific email address", + "example": "email_address" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedEmailId": { + "type": "number", + "description": "Email address if recipient is EMAIL, required for action EMAIL_ADDRESS", + "example": "31214", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-an-email-for-an-org-team" + } + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedEmailId", + "includeCalendarEvent", + "message" + ] + }, + "UpdateEmailAttendeeWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_attendee", + "description": "Action to perform, send an email to the attendees of the event", + "example": "email_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "UpdateEmailHostWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_host", + "description": "Action to perform, send an email to the host of the event", + "example": "email_host" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "UpdatePhoneAttendeeWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_attendee", + "description": "Action to perform, send a text message to the phone numbers of the attendees", + "example": "sms_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + }, + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "message" + ] + }, + "UpdatePhoneWhatsAppNumberWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_number", + "description": "Action to perform, send a text message via whatsapp to a specific phone number", + "example": "whatsapp_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedPhoneId", + "message" + ] + }, + "UpdateWhatsAppAttendeePhoneWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_attendee", + "description": "Action to perform", + "example": "whatsapp_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Message content for this step, send a text message via whatsapp to the phone numbers of the attendees", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "message" + ] + }, + "UpdatePhoneNumberWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_number", + "description": "Action to perform, send a text message to a specific phone number", + "example": "sms_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": [ + "const", + "attendee", + "email", + "phone_number" + ] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": [ + "reminder", + "custom", + "rescheduled", + "completed", + "rating", + "cancelled" + ] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedPhoneId", + "message" + ] + }, "UpdateWorkflowDto": { "type": "object", "properties": { @@ -21974,20 +23300,62 @@ } ] }, + "trigger": { + "description": "Trigger configuration for the workflow", + "oneOf": [ + { + "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCancelTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCreationTriggerDto" + }, + { + "$ref": "#/components/schemas/OnRescheduleTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + } + ] + }, "steps": { + "type": "array", "description": "Steps to execute as part of the workflow", "items": { - "type": "object" - }, - "type": "array" - }, - "trigger": { - "type": "object" + "oneOf": [ + { + "$ref": "#/components/schemas/UpdateEmailAddressWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateEmailAttendeeWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateEmailHostWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneAttendeeWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneWhatsAppNumberWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateWhatsAppAttendeePhoneWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneNumberWorkflowStepDto" + } + ] + } } - }, - "required": [ - "trigger" - ] + } }, "StripConnectOutputDto": { "type": "object", diff --git a/docs/api-reference/v2/openapi.json b/docs/api-reference/v2/openapi.json index 5ab2292de7..8da3102952 100644 --- a/docs/api-reference/v2/openapi.json +++ b/docs/api-reference/v2/openapi.json @@ -5323,7 +5323,7 @@ }, "patch": { "operationId": "OrganizationTeamWorkflowsController_updateWorkflow", - "summary": "Update workflow", + "summary": "Update organization team workflow", "parameters": [ { "name": "Authorization", @@ -13790,7 +13790,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{phone: '+37122222222'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -13825,7 +13825,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{address: 'mainstreat 10, new york'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -13860,7 +13860,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `who-referred-you` and the URL contains query parameter `&who-referred-you=bob`, the text field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `friend` and the URL contains query parameter `&friend=bob`, the text field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{friend: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -13895,7 +13895,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories-per-day` and the URL contains query parameter `&calories-per-day=3000`, the number field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories` and the URL contains query parameter `&calories=3000`, the number field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{calories: 3000}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -13930,7 +13930,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `dear-diary` and the URL contains query parameter `&dear-diary=Today I shipped a feature`, the text area will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `reflection` and the URL contains query parameter `&reflection=Today I shipped a feature`, the text area will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{reflection: 'Today i shipped a feature'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -13972,7 +13972,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14010,7 +14010,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and the URL contains query parameter `&language=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: ['en', 'it']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14045,7 +14045,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{consultants: ['alice@gmail.com', 'bob@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14083,7 +14083,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify-me` and the URL contains query parameter `¬ify-me=true`, the checkbox will be selected and the checkbox field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14121,7 +14121,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14151,7 +14151,8 @@ "type": "boolean" }, "disableOnPrefill": { - "type": "boolean" + "type": "boolean", + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14186,7 +14187,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `video-url` and the URL contains query parameter `&video-url=https://youtube.com/abc`the url field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `videourl` and the URL contains query parameter `&videourl=https://youtube.com/abc`the url field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{videourl: 'https://caltube.com/123'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -14452,7 +14453,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled. In case of Booker atom need to pass 'name' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{name: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-fields" } }, "required": ["type", "label", "placeholder"] @@ -14481,7 +14482,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled. In case of Booker atom need to pass 'email' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{email: 'bob@gmail.com'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": ["type", "label", "placeholder"] @@ -14509,7 +14510,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&title=journey`, the title field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&title=journey`, the title field will be prefilled with this value and disabled. In case of Booker atom need to pass 'title' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{title: 'very important meeting'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": ["slug"] @@ -14551,7 +14552,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `¬es=journey`, the notes field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `¬es=journey`, the notes field will be prefilled with this value and disabled. In case of Booker atom need to pass 'notes' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notes: 'bring notebook and paper'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": ["slug"] @@ -14579,7 +14580,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&guests=bob@cal.com`, the guests field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&guests=bob@cal.com`, the guests field will be prefilled with this value and disabled. In case of Booker atom need to pass 'guests' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{guests: ['bob@gmail.com', 'alice@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": ["slug"] @@ -14607,7 +14608,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&rescheduleReason=travel`, the rescheduleReason field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&rescheduleReason=travel`, the rescheduleReason field will be prefilled with this value and disabled. In case of Booker atom need to pass 'rescheduleReason' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{rescheduleReason: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" } }, "required": ["slug"] @@ -15161,7 +15162,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&email=bob@gmail.com`, the email field will be prefilled with this value and disabled. In case of Booker atom need to pass 'email' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{email: 'bob@gmail.com'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "isDefault": { "type": "object", @@ -15209,7 +15210,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if URL contains query parameter `&name=bob`, the name field will be prefilled with this value and disabled. In case of Booker atom need to pass 'name' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{name: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-fields" }, "isDefault": { "type": "object", @@ -15460,7 +15461,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`, the address field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{address: 'mainstreat 10, new york'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15512,7 +15513,8 @@ "type": "boolean" }, "disableOnPrefill": { - "type": "boolean" + "type": "boolean", + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15572,7 +15574,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify-me` and the URL contains query parameter `¬ify-me=true`, the checkbox will be selected and the checkbox field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`, the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15629,7 +15631,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`, the these emails will be added and none more can be added. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{consultants: ['alice@gmail.com', 'bob@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15689,7 +15691,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `consultants` and the URL contains query parameter `&consultants=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and the URL contains query parameter `&language=en&language=it`, the 'en' and 'it' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: ['en', 'it']}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15746,7 +15748,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `video-url` and the URL contains query parameter `&video-url=https://youtube.com/abc`the url field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `videourl` and the URL contains query parameter `&videourl=https://youtube.com/abc`the url field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{videourl: 'https://caltube.com/123'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15803,7 +15805,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories-per-day` and the URL contains query parameter `&calories-per-day=3000`, the number field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `calories` and the URL contains query parameter `&calories=3000`, the number field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{calories: 3000}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15858,7 +15860,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`, the phone field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{phone: '+37122222222'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15918,7 +15920,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' radio button will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -15982,7 +15984,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`, the 'italian' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16039,7 +16041,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `dear-diary` and the URL contains query parameter `&dear-diary=Today I shipped a feature`, the text area will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `reflection` and the URL contains query parameter `&reflection=Today I shipped a feature`, the text area will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{reflection: 'Today i shipped a feature'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -16096,7 +16098,7 @@ }, "disableOnPrefill": { "type": "boolean", - "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `who-referred-you` and the URL contains query parameter `&who-referred-you=bob`, the text field will be prefilled with this value and disabled." + "description": "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value. For example, if the slug is `friend` and the URL contains query parameter `&friend=bob`, the text field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{friend: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field" }, "hidden": { "type": "boolean", @@ -20153,6 +20155,598 @@ }, "required": ["status", "data"] }, + "WorkflowTriggerOffsetDto": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Time value for offset before/after event trigger", + "example": 24 + }, + "unit": { + "type": "object", + "description": "Unit for the offset time", + "example": "hour" + } + }, + "required": ["value", "unit"] + }, + "OnBeforeEventTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "beforeEvent", + "description": "Trigger type for the workflow", + "example": "beforeEvent" + } + }, + "required": ["offset", "type"] + }, + "OnAfterEventTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterEvent", + "description": "Trigger type for the workflow", + "example": "afterEvent" + } + }, + "required": ["offset", "type"] + }, + "OnCancelTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "eventCancelled", + "description": "Trigger type for the workflow" + } + }, + "required": ["type"] + }, + "OnCreationTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "newEvent", + "description": "Trigger type for the workflow" + } + }, + "required": ["type"] + }, + "OnRescheduleTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "string", + "default": "rescheduleEvent", + "description": "Trigger type for the workflow" + } + }, + "required": ["type"] + }, + "OnAfterCalVideoGuestsNoShowTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterGuestsCalVideoNoShow", + "description": "Trigger type for the workflow", + "example": "afterGuestsCalVideoNoShow" + } + }, + "required": ["offset", "type"] + }, + "OnAfterCalVideoHostsNoShowTriggerDto": { + "type": "object", + "properties": { + "offset": { + "description": "Offset before/after the trigger time; required for BEFORE_EVENT and AFTER_EVENT only", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowTriggerOffsetDto" + } + ] + }, + "type": { + "type": "string", + "default": "afterHostsCalVideoNoShow", + "description": "Trigger type for the workflow", + "example": "afterHostsCalVideoNoShow" + } + }, + "required": ["offset", "type"] + }, + "HtmlWorkflowMessageDto": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the message", + "example": "Reminder: Your Meeting {EVENT_NAME} - {EVENT_DATE_ddd, MMM D, YYYY h:mma} with Cal.com" + }, + "html": { + "type": "string", + "description": "HTML content of the message (used for Emails)", + "example": "

This is a reminder from {ORGANIZER} of {EVENT_NAME} to {ATTENDEE} starting here {LOCATION} {MEETING_URL} at {START_TIME_h:mma} {TIMEZONE}.

" + } + }, + "required": ["subject", "html"] + }, + "WorkflowEmailAddressStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_address", + "description": "Action to perform, send an email to a specific email address", + "example": "email_address" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedEmailId": { + "type": "number", + "description": "Email address if recipient is EMAIL, required for action EMAIL_ADDRESS", + "example": "31214", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-an-email-for-an-org-team" + } + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedEmailId", + "includeCalendarEvent", + "message" + ] + }, + "WorkflowEmailAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_attendee", + "description": "Action to perform, send an email to the attendees of the event", + "example": "email_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "WorkflowEmailHostStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_host", + "description": "Action to perform, send an email to the host of the event", + "example": "email_host" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "TextWorkflowMessageDto": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the message", + "example": "Reminder: Your Meeting {EVENT_NAME} - {EVENT_DATE_ddd, MMM D, YYYY h:mma} with Cal.com" + }, + "text": { + "type": "string", + "description": "Text content of the message (used for SMS)", + "example": "This is a reminder message from {ORGANIZER} of {EVENT_NAME} to {ATTENDEE} starting here {LOCATION} {MEETING_URL} at {START_TIME_h:mma} {TIMEZONE}." + } + }, + "required": ["subject", "text"] + }, + "WorkflowPhoneWhatsAppAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_attendee", + "description": "Action to perform", + "example": "whatsapp_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Message content for this step, send a text message via whatsapp to the phone numbers of the attendees", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "message"] + }, + "WorkflowPhoneWhatsAppNumberStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_number", + "description": "Action to perform, send a text message via whatsapp to a specific phone number", + "example": "whatsapp_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "verifiedPhoneId", "message"] + }, + "WorkflowPhoneNumberStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_number", + "description": "Action to perform, send a text message to a specific phone number", + "example": "sms_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "verifiedPhoneId", "message"] + }, + "WorkflowPhoneAttendeeStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_attendee", + "description": "Action to perform, send a text message to the phone numbers of the attendees", + "example": "sms_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + }, + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "message"] + }, + "BaseWorkflowTriggerDto": { + "type": "object", + "properties": { + "type": { + "type": "object", + "description": "Trigger type for the workflow" + } + }, + "required": ["type"] + }, "WorkflowActivationDto": { "type": "object", "properties": { @@ -20191,44 +20785,519 @@ ] }, "trigger": { - "type": "object", "description": "Trigger configuration for the workflow", + "oneOf": [ + { + "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCancelTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCreationTriggerDto" + }, + { + "$ref": "#/components/schemas/OnRescheduleTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + } + ] + }, + "steps": { + "type": "array", + "description": "Steps to execute as part of the workflow", "items": { "oneOf": [ { - "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailAddressStepDto" }, { - "$ref": "#/components/schemas/OnAfterEventTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailAttendeeStepDto" }, { - "$ref": "#/components/schemas/OnCancelTriggerDto" + "$ref": "#/components/schemas/WorkflowEmailHostStepDto" }, { - "$ref": "#/components/schemas/OnCreationTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneWhatsAppAttendeeStepDto" }, { - "$ref": "#/components/schemas/OnRescheduleTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneWhatsAppNumberStepDto" }, { - "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneNumberStepDto" }, { - "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + "$ref": "#/components/schemas/WorkflowPhoneAttendeeStepDto" } ] } - }, - "steps": { - "description": "Steps to execute as part of the workflow", - "items": { - "type": "object" - }, - "type": "array" } }, "required": ["name", "activation", "trigger", "steps"] }, + "UpdateEmailAddressWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_address", + "description": "Action to perform, send an email to a specific email address", + "example": "email_address" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedEmailId": { + "type": "number", + "description": "Email address if recipient is EMAIL, required for action EMAIL_ADDRESS", + "example": "31214", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-an-email-for-an-org-team" + } + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "verifiedEmailId", + "includeCalendarEvent", + "message" + ] + }, + "UpdateEmailAttendeeWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_attendee", + "description": "Action to perform, send an email to the attendees of the event", + "example": "email_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "UpdateEmailHostWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "email_host", + "description": "Action to perform, send an email to the host of the event", + "example": "email_host" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "includeCalendarEvent": { + "type": "object", + "default": false, + "description": "Whether to include a calendar event in the notification, can be included with actions email_host, email_attendee, email_address", + "example": true + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/HtmlWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": [ + "action", + "stepNumber", + "recipient", + "template", + "sender", + "includeCalendarEvent", + "message" + ] + }, + "UpdatePhoneAttendeeWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_attendee", + "description": "Action to perform, send a text message to the phone numbers of the attendees", + "example": "sms_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + }, + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "message"] + }, + "UpdatePhoneWhatsAppNumberWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_number", + "description": "Action to perform, send a text message via whatsapp to a specific phone number", + "example": "whatsapp_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "verifiedPhoneId", "message"] + }, + "UpdateWhatsAppAttendeePhoneWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "whatsapp_attendee", + "description": "Action to perform", + "example": "whatsapp_attendee" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "message": { + "description": "Message content for this step, send a text message via whatsapp to the phone numbers of the attendees", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "message"] + }, + "UpdatePhoneNumberWorkflowStepDto": { + "type": "object", + "properties": { + "action": { + "type": "string", + "enum": [ + "email_host", + "email_attendee", + "email_address", + "sms_attendee", + "sms_number", + "whatsapp_attendee", + "whatsapp_number" + ], + "default": "sms_number", + "description": "Action to perform, send a text message to a specific phone number", + "example": "sms_number" + }, + "stepNumber": { + "type": "number", + "description": "Step number in the workflow sequence", + "example": 1 + }, + "recipient": { + "type": "string", + "description": "Recipient type", + "example": "attendee", + "enum": ["const", "attendee", "email", "phone_number"] + }, + "template": { + "type": "string", + "description": "Template type for the step", + "example": "reminder", + "enum": ["reminder", "custom", "rescheduled", "completed", "rating", "cancelled"] + }, + "sender": { + "type": "string", + "description": "Displayed sender name." + }, + "verifiedPhoneId": { + "type": "number", + "description": "Phone number if recipient is PHONE_NUMBER, required for actions SMS_NUMBER and WHATSAPP_NUMBER", + "example": "3243434", + "externalDocs": { + "url": "https://cal.com/docs/api-reference/v2/organization-team-verified-resources/verify-a-phone-number-for-an-org-team" + } + }, + "message": { + "description": "Message content for this step", + "allOf": [ + { + "$ref": "#/components/schemas/TextWorkflowMessageDto" + } + ] + }, + "id": { + "type": "number", + "description": "Unique identifier of the step you want to update, if adding a new step do not provide this id", + "example": 67244 + } + }, + "required": ["action", "stepNumber", "recipient", "template", "sender", "verifiedPhoneId", "message"] + }, "UpdateWorkflowDto": { "type": "object", "properties": { @@ -20245,18 +21314,62 @@ } ] }, + "trigger": { + "description": "Trigger configuration for the workflow", + "oneOf": [ + { + "$ref": "#/components/schemas/OnBeforeEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterEventTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCancelTriggerDto" + }, + { + "$ref": "#/components/schemas/OnCreationTriggerDto" + }, + { + "$ref": "#/components/schemas/OnRescheduleTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoGuestsNoShowTriggerDto" + }, + { + "$ref": "#/components/schemas/OnAfterCalVideoHostsNoShowTriggerDto" + } + ] + }, "steps": { + "type": "array", "description": "Steps to execute as part of the workflow", "items": { - "type": "object" - }, - "type": "array" - }, - "trigger": { - "type": "object" + "oneOf": [ + { + "$ref": "#/components/schemas/UpdateEmailAddressWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateEmailAttendeeWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateEmailHostWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneAttendeeWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneWhatsAppNumberWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdateWhatsAppAttendeePhoneWorkflowStepDto" + }, + { + "$ref": "#/components/schemas/UpdatePhoneNumberWorkflowStepDto" + } + ] + } } - }, - "required": ["trigger"] + } }, "StripConnectOutputDto": { "type": "object", diff --git a/packages/platform/types/event-types/event-types_2024_06_14/inputs/booking-fields.input.ts b/packages/platform/types/event-types/event-types_2024_06_14/inputs/booking-fields.input.ts index 7558406f8e..04917926b0 100644 --- a/packages/platform/types/event-types/event-types_2024_06_14/inputs/booking-fields.input.ts +++ b/packages/platform/types/event-types/event-types_2024_06_14/inputs/booking-fields.input.ts @@ -50,7 +50,7 @@ export class NameDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&name=bob`,\ - the name field will be prefilled with this value and disabled.", + the name field will be prefilled with this value and disabled. In case of Booker atom need to pass 'name' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{name: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-fields", }) disableOnPrefill?: boolean; } @@ -96,7 +96,7 @@ export class SplitNameDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&firstName=bob&lastName=jones`,\ - the first name and last name fields will be prefilled with this value and disabled. In case of Booker atom need to pass firstName and lastName to defaultFormValues prop or pass name prop but as a string containing name and surname.", + the first name and last name fields will be prefilled with this value and disabled. In case of Booker atom need to pass 'firstName' and 'lastName' to defaultFormValues prop e.g. `defaultFormValues={{firstName: 'bob', lastName: 'doe'}}` or pass 'name' prop but as a string containing name and surname e.g. `defaultFormValues={{name: 'bob doe'}}`. See guide https://cal.com/docs/platform/guides/booking-fields", }) disableOnPrefill?: boolean; } @@ -144,7 +144,7 @@ export class EmailDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&email=bob@gmail.com`,\ - the email field will be prefilled with this value and disabled.", + the email field will be prefilled with this value and disabled. In case of Booker atom need to pass 'email' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{email: 'bob@gmail.com'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; } @@ -184,7 +184,7 @@ export class TitleDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&title=journey`,\ - the title field will be prefilled with this value and disabled.", + the title field will be prefilled with this value and disabled. In case of Booker atom need to pass 'title' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{title: 'very important meeting'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; } @@ -239,7 +239,7 @@ export class NotesDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `¬es=journey`,\ - the notes field will be prefilled with this value and disabled.", + the notes field will be prefilled with this value and disabled. In case of Booker atom need to pass 'notes' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notes: 'bring notebook and paper'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; } @@ -279,7 +279,7 @@ export class GuestsDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&guests=bob@cal.com`,\ - the guests field will be prefilled with this value and disabled.", + the guests field will be prefilled with this value and disabled. In case of Booker atom need to pass 'guests' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{guests: ['bob@gmail.com', 'alice@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; } @@ -322,7 +322,7 @@ export class RescheduleReasonDefaultFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if URL contains query parameter `&rescheduleReason=travel`,\ - the rescheduleReason field will be prefilled with this value and disabled.", + the rescheduleReason field will be prefilled with this value and disabled. In case of Booker atom need to pass 'rescheduleReason' to defaultFormValues prop with the desired value e.g. `defaultFormValues={{rescheduleReason: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; } @@ -360,7 +360,7 @@ export class PhoneFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if the slug is `phone` and the URL contains query parameter `&phone=1234567890`,\ - the phone field will be prefilled with this value and disabled.", + the phone field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{phone: '+37122222222'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -407,7 +407,7 @@ export class AddressFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if the slug is `address` and the URL contains query parameter `&address=1234 Main St, London`,\ - the address field will be prefilled with this value and disabled.", + the address field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{address: 'mainstreat 10, new york'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -453,8 +453,8 @@ export class TextFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `who-referred-you` and the URL contains query parameter `&who-referred-you=bob`,\ - the text field will be prefilled with this value and disabled.", + For example, if the slug is `friend` and the URL contains query parameter `&friend=bob`,\ + the text field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{friend: 'bob'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -500,7 +500,8 @@ export class UrlFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `video-url` and the URL contains query parameter `&video-url=https://youtube.com/abc`the url field will be prefilled with this value and disabled.", + For example, if the slug is `videourl` and the URL contains query parameter `&videourl=https://youtube.com/abc`the url field will be prefilled with this value and disabled. \ + In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{videourl: 'https://caltube.com/123'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -546,8 +547,8 @@ export class NumberFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `calories-per-day` and the URL contains query parameter `&calories-per-day=3000`,\ - the number field will be prefilled with this value and disabled.", + For example, if the slug is `calories` and the URL contains query parameter `&calories=3000`,\ + the number field will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{calories: 3000}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -593,8 +594,8 @@ export class TextAreaFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `dear-diary` and the URL contains query parameter `&dear-diary=Today I shipped a feature`,\ - the text area will be prefilled with this value and disabled.", + For example, if the slug is `reflection` and the URL contains query parameter `&reflection=Today I shipped a feature`,\ + the text area will be prefilled with this value and disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{reflection: 'Today i shipped a feature'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -645,7 +646,7 @@ export class SelectFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`,\ - the 'italian' will be selected and the select field will be disabled.", + the 'italian' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -689,8 +690,8 @@ export class MultiSelectFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `consultants` and the URL contains query parameter `&consultants=en&language=it`,\ - the 'en' and 'it' will be selected and the select field will be disabled.", + For example, if the slug is `language` and the URL contains query parameter `&language=en&language=it`,\ + the 'en' and 'it' will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: ['en', 'it']}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -737,7 +738,7 @@ export class MultiEmailFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if the slug is `consultants` and the URL contains query parameter `&consultants=alice@gmail.com&consultants=bob@gmail.com`,\ - the these emails will be added and none more can be added.", + the these emails will be added and none more can be added. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{consultants: ['alice@gmail.com', 'bob@gmail.com']}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -781,8 +782,8 @@ export class CheckboxGroupFieldInput_2024_06_14 { type: Boolean, description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ - For example, if the slug is `notify-me` and the URL contains query parameter `¬ify-me=true`,\ - the checkbox will be selected and the checkbox field will be disabled.", + For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`,\ + the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -827,7 +828,7 @@ export class RadioGroupFieldInput_2024_06_14 { description: "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ For example, if the slug is `language` and options of this select field are ['english', 'italian'] and the URL contains query parameter `&language=italian`,\ - the 'italian' radio button will be selected and the select field will be disabled.", + the 'italian' radio button will be selected and the select field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{language: 'italian'}}`. See guide https://cal.com/docs/platform/guides/booking-field", }) disableOnPrefill?: boolean; @@ -863,7 +864,13 @@ export class BooleanFieldInput_2024_06_14 { @IsBoolean() @IsOptional() - @DocsPropertyOptional({ type: Boolean }) + @DocsPropertyOptional({ + type: Boolean, + description: + "Disable this booking field if the URL contains query parameter with key equal to the slug and prefill it with the provided value.\ + For example, if the slug is `notify` and the URL contains query parameter `¬ify=true`,\ + the checkbox will be selected and the checkbox field will be disabled. In case of Booker atom need to pass slug you used for this booking field to defaultFormValues prop with the desired value e.g. `defaultFormValues={{notify: true}}`. See guide https://cal.com/docs/platform/guides/booking-field", + }) disableOnPrefill?: boolean; @IsBoolean()