Scheduling where resources choose availibility

I need the ability for users to set blocks of time when they are available to be scheduled. For example user A is available on 5/3/18 from 8am to 11am and also 2pm to 5pm. From there, someone who wants to book that user for a 2 hours appointment could pick 8:00, 8:30, 9:00, 2:00, 2:30, or 3:00.
This all needs to be done in the bubble app via API, not directly through a scheduling site like Calendly.
The APIs I have looked at (i.e. Acuity, Timekit, etc.) either have basic schedule like m-f 9-5, or connect to the user’s calendar and assume that if their not booked, they are available.
Any ideas?

Did you look into the use of Google Calendars?

They provide a REST interface for interacting with their API’s so you could then use Bubble’s API connector to connect to the Google Calendar API…

Basically whenever a client wants to book a user…you can programmatically(using a Bubble workflow) connect to the Google Calendars, and then check if they are available for that time…and then appropriately book that time using the API

Also if I am not mistaken Calendly also provides an API…so theoretically you could use the above idea with Calendly…

@andrewjohnson56782 I understand that type of API. That’s not what I’m looking for. Those platforms assume implicitly that if the user’s schedule is open, then they can be scheduled within certain business hours. I’m looking for the opposite. I want the ability for users to explicitly specify blocks of time where they can be scheduled.

Oh okay…
I will keep a look out and if I do come across some third parties which provide this service…you will be the first to know:):grinning:

Hi @rybadger, i might be wrong but i think in terms of this functionality, calendly allows you to do that.
See snapshot below. You can specify on each day the exact block of times you want to be scheduled.

As you can see from the snapshot above, you can indicate the block of time you’re available using the + New Interval for any particular date.

1 Like

For your second requirement.

Assuming you’re using Calendly, you can integrate it into your bubble app using different methods such as inline, or different pop widgets. This way the user will be doing all the booking from inside your bubble application and doesn’t have to visit the calendly site.
One advantage of going this route is that you don’t have to build your own UI for the booking in bubble.

Calendly also supports integration through weebhooks.

Meaning that you can create api workflows in your bubble app that will be listening for events, e.g. when someone book an appointment you can be notified and save the appointment details into your bubble app.

I haven’t looked at the other services like Acuity, Timekit, etc, you mentioned.
Also note that i’m not trying to sell Calendly or any other service to you. In fact it will surprise you to know that this is the first time i’ve tried calendly, only signed up now so i could see what is available or not to answer your question.

1 Like

I’d like users to be be able to specify their availability from my app, not through the Calendly interface. I don’t think that Calendly has this capability enabled through their API.

Gotcha. I see what you mean now.
Sorry about my misunderstanding.

Technically speaking - it’s totally doable only using Bubble, no external services. Maybe just some Bubble plugin(s).
The thing is to create timeslots the moment service providers (like your user A) create their schedules.
It gets more complicated if you want to do recurring availability, eg. “each Monday from 8 till 18”.

But let’s think out of the box about the use of external services/APIs…

As you noticed - some of them explicitly assume you are available if not booked. But if this kind of service is behind your Bubble app - you can try using it to your advantage! How?

Imagine service provider (your user A) creating his schedule. The moment he does it - appointments are created in his calendar behind the scene. If you want to display his availability - you fetch those from the external service (eg. google calendar) through the api and you show them on your Bubble page as “A’s schedule”

Now comes user B - The Client.
He sees A’s schedule on your Bubble app, he can choose day and hour. Do the check against your database for existing appointments with A on that day to see real availability. Mark B’s appointment in your Bubble database. Done. User C will see A’s schedule but since B booked something - you just display the hole there, that comes from your database.

To summarize:

  1. GCalendar/whatever events = schedule of the service provider/resource; quite useful because GC’s API supports creation of the recurring events (eg. “Each Monday until 31 August”)
  2. Bubble database = booked appointments
  3. availability displayed on your page = 1+2

I neved did it, just thinking loudly.

1 Like

The way I think about Recurring/Repeating Events is to think about the patterns, not about the individual events.

So … “For example user A is available on 5/3/18 from 8am to 11am and also 2pm to 5pm.”

The obvious way to think about this is that there are 4 “slots” in the morning, and 4 slots in the afternoon. So we need to create 8 things in the database and get all iterative (which is now a lot more complex in Bubble).

The alternative is to think of these as two things that describe repeating patterns.

The first starts at 8am on 5/3/18 and repeats hourly 4 times.
The second starts at 2pm on 5/3/18 and repeats hourly 4 times.

This is a simplified version of the “repeat every x days/weeks/months” pattern that has been around for a long time.

When you display the schedule, you show the full pattern each time, then work out later if each one is booked.

On booking, you can then create a thing for the particular time, which will then prevent other over booking.

Makes it a LOT easier to manager changes to times etc

3 Likes