ruLog in to Senler

Cancel a booking

Configure a For dialogs automation that asks for the client’s confirmation and cancels a previously selected YCLIENTS visit. First, connect a branch.

What to prepare

You need the booking ID and saved visit details. In the booking workflow, save the record_id result to a numeric dialog variable such as dialog.yclients_record_id, and the date and time to dialog.yclients_datetime. These values remain available after the booking workflow ends. A run.* process variable is available only in the current run.

The current editor accepts a specific number in Booking ID. Enter the required booking’s ID when configuring the step. This field does not yet offer a variable selector, so this example is for a visit whose ID is known in advance. To cancel different bookings during a conversation, use the agent tool.

If the client has several bookings, identify the required one first. The number in the action settings and the details in the confirmation message must refer to the same visit.

1. Open the automation

In the project, select Automations (1) and open the required automation (2). To create one, click Add, choose For dialogs, enter “Cancel a YCLIENTS booking” and click Create. On a phone, open the left menu first.

Opening the editor: 1 — Automations; 2 — the required automation

Add an Incoming message starting step and set a trigger phrase such as “cancel my booking”. Connect it to the confirmation message described next. Incoming message settings.

2. Ask for confirmation

In the editor, click Add step (1) and select Message.

Adding a message: 1 — Add step

Show the client the service, date and time of the selected visit. In the message settings, add two continuation buttons: “Yes, cancel” and “Keep my booking”. Leave Allow repeated button clicks disabled. Adding message buttons.

Connect the “Yes, cancel” button output to the cancellation action. Connect “Keep my booking” to a message confirming that the visit remains booked. The main output after sending the message must not start cancellation: continuation must wait for the client’s choice.

3. Add the cancellation action

Click Add step again. In the YCLIENTS group, find Cancel YCLIENTS booking — with branches. Under Inputs (1), enter its numeric ID in Booking ID. If needed, scroll down to Step result and select result variables.

Cancelling a visit: 1 — input booking ID

The screenshot uses a demonstration number. Replace it with your booking’s ID.

Click Save (1) at the bottom of the panel. Then connect the action input to the confirmation button output.

Saving the action: 1 — Save

4. Handle the result

  • From Booking cancelled, send a cancellation confirmation. Then clear the saved details of that cancelled visit.
  • From Booking not found, explain that cancellation could not be confirmed and refer the issue to an administrator.
  • If access or connectivity fails, check the branch connection. Send the success message only from the successful output.

For fields and outputs, see the cancellation step reference.

5. Test and enable the automation

Click Testing (1), choose a test dialog and use an agreed test booking to check confirmed cancellation, keeping the booking and an unknown booking ID. Before each check, enter the corresponding test booking’s ID in the step settings. Verify the outcome in the YCLIENTS calendar.

Testing and activation: 1 — Testing; 2 — Publish

After testing, click Publish (2) and confirm the action. For live runs, open the status control at the top of the editor and choose Enable if the automation is disabled.

Automations · Troubleshooting.