Breadcrumbs

Book parking spots for appointments

When a customer books an appointment, they can specify how many parking spots they need. Parking bookings are created automatically and include a 30-minute buffer before and after the appointment.

image-20260618-194153.png
Example of a Customer Appointment JSM request



Requirements

  • Advanced Edition of Apwide Booking, which includes Automated Resource Selection.

  • Booking Flow configured for parking spots.

  • JSM request configured for your Customer Appointments, using a Single Select custom field for the number of Parking Spots to be booked.

  • Access to Jira Automation.

  • Familiarity with creating automation flows and using smart values.



Configuration

For this use case, we'll need three Jira Automation rules:

  1. Parking Spot Booking (Start) - When a new Customer Appointment request includes parking spots, add a comment to inform the customer that parking availability is being checked.

  2. Parking Spot Booking (Each) - Each time a comment is added to the ticket, create a Parking Spot booking request and decrement the number of parking spots remaining to be booked in an issue property.

  3. Parking Spot Booking (Approval) - Each time a Parking Spot booking request is approved or rejected, add a comment to the linked Customer Appointment request.



1- Jira Automation: Parking Spot Booking (Start)

When a new Customer Appointment request includes parking spots, add a comment to inform the customer that parking availability is being checked.

image-20260618-195056.png
First Jira Automation Configuration

Trigger: Work item created

The flow will be triggered when the Customer Appointment request is created.

image-20260618-195637.png

JQL Example

project = BP and "Request Type" = "Customer Appointment"


Condition: {{smart values}} condition

We check if the Parking Spots field value is greater than 0.

image-20260618-195820.png

First value

{{issue."Parking Spots".value}}


Action: Set entity property

We initialize an issue entity property with the number of parking spots to book.

image-20260618-200126.png

Property key

parking_spots_to_book

Property value

{{issue."Parking Spots".value}}


Action: Comment on work item

We add a comment on the work item, that will trigger the next Jira Automation.

image-20260618-200348.png

Comment

Thank your for your appointment request.

We are currently checking parking availability and will attempt to reserve {{issue."Parking Spots".value}} parking spot(s) for you.




2- Jira Automation: Parking Spot Booking (Each)

Each time a comment is added to the ticket, create a Parking Spot booking request and decrement the number of parking spots remaining to be booked in an issue property.

image-20260618-201105.png
Second Jira Automation Configuration


Trigger: Work item commented

The flow will be triggered when the Customer Appointment work item is commented.

image-20260618-201210.png

JQL

project = BP and type = "Parking Spot Booking"


Condition: {{smart values}} condition

We check if the parking_spots_to_book issue property is greater than 0.

image-20260618-201437.png

First value

{{issue.properties.parking_spots_to_book}}


Action: Create Apwide Booking

We create a Parking Spot booking with a randomly selected available resource and a 30-minute buffer before and after the appointment.

image-20260618-201900.png

Summary

Parking Spot Booking ({{#=}}{{issue."Parking Spots".value}} - {{issue.properties.parking_spots_to_book}} + 1{{/}}/{{issue."Parking Spots".value}})

Booking start

{{issue.customfield_10156.minusMinutes(30)}}

Booking end

{{issue.customfield_10155.plusMinutes(30)}}


Condition: If block

We check if the booking was successfully created.

image-20260618-202151.png

First value

{{createdJiraBooking.success}}


If the booking was successfully created, we link it to the current work item.

image-20260618-202319.png

Linked work item

{{createdJiraBooking.issueKey}}


Action: Set work item property

If the booking is successfully created, we decrement the issue property by 1.

image-20260618-202444.png

Property key

parking_spots_to_book

Property value

{{issue.properties.parking_spots_to_book.minus(1)}}


Condition: Else block

If the booking was not successfully created.

image-20260618-202706.png

Action: Comment on work item

image-20260618-202816.png

Comment

Unfortunately, we could not book more parking spots for you.

*From*: {{triggerIssue.customfield_10156.minusMinutes(30).convertToTimeZone("Europe/Zurich").format("EEE, dd MMM yyyy HH:mm z")}}
*Until*: {{triggerIssue.customfield_10155.plusMinutes(30).convertToTimeZone("Europe/Zurich").format("EEE, dd MMM yyyy HH:mm z")}}

Please contact the parking manager for assistance.


Action: Set entity property

image-20260618-202849.png

Property key

parking_spots_to_book




3- Jira Automation: Parking Spot Booking (Approval)

Each time a Parking Spot booking request is approved or rejected, add a comment to the linked Customer Appointment request.

image-20260618-195300.png
Third Jira Automation Configuration


Trigger: Work item transitioned

The flow will be triggered when the Parking Spot Booking is approved or rejected.

image-20260618-203031.png

JQL

project = BP and type = "Parking Spot Booking"


We create a branch for the Customer Appointment linked to the Parking Spot Booking.

image-20260618-203252.png


Action: Comment on work item

We add a comment to the Customer Appointment request, which triggers the creation of the next Parking Spot booking, if required.

image-20260618-203430.png




Need Assistance?

For support with Jira Automation with Booking, reach out to our Customer Portal.