tykeal / homeassistant-rental-control

Rental Control system for Home Assistant

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Please complet the doc

Vartkat opened this issue · comments

Hello,

Thanks you very much for Keymaster and this project but it lacks precision on the docs :
1 - Can you please provide examples such as the ICS URL
2- A complete event standard syntax (I'm even struggling testing if there should be a space after Last 4 Digits: )

As far as I understood... An event should follow this syntax :
Title = 'Reserved - ' followed by whatever we want, if the word Reserved is not there and the option Ignore events that are not standard reservations is checked the event won't be processed
Description =
' Guests: ' followed by number of guests
'Email : ' followed by a valid email address
'Phone : ' followed by a phone number including the + sign (not everybody is fluent in regex)
'Adults: ' followed by a number
'Children: ' ollowed by a number

This makes the following ics file content valid :
BEGIN:VEVENT CREATED:20231122T153822Z DTSTAMP:20231122T155600Z LAST-MODIFIED:20231122T155600Z SEQUENCE:5 UID:276f153e-0a06-4eea-84b0-5b963c8ee2f4 DTSTART;VALUE=DATE:20231123 DTEND;VALUE=DATE:20231124 STATUS:CONFIRMED SUMMARY:Reserved - John Doe arrival - 1 day DESCRIPTION:Guests: 1\nEmail : johndoe@gmail.com\nPhone : +13054567891\n Adults: 1\nChildren: 0\n END:VEVENT END:VCALENDAR

I noted that if the event is updated , the code is not even if the syntax is good on the update.

The guest email address is just for info purpose it doesn't trigger a message to the guest telling the code and when he is expected.

Is that right ?

Thanks for your help

V.

The documentation actually provides the regular expressions that are being used. Granted, not everyone understands a regular expression, but they're listed there ;)

Title: Bob
Description:

Last 4 Digits: 4444
Guests: 2
Email: foo@bar.com

Note that there is are no spaces before any : character ever. What you provided above has a space before the : which is causing you problems. You'll note that in my example above I do not used Reserved - I figure it's a little silly to do that when I'm making manual calendar entries.

Thanks.

Another dummy question : in case of 3 places to rent do I have to maintain 1 calendar per place ? Or can I put all the reservations in one calendar, and if it is one calendar (which I suspect) where goes the prefix you talk about in the doc ? In the event Title ? Then, just to be sure and clear, I have to add one integration per place but all will have the same ics ? Is that right ?

Hope I'm not bothering with question that seem obvious to you.

You need a calendar per rental. If you've got three rentals, then it's three calendars and 3 integrations. The prefix that is added by the integration should not be in your calendar entries as the integration will add it to the slot name.

So, if your title is Bob and the rental prefix is House 1 - then the managed slot would end up being House 1 - Bob

For instance, my house has 4 bedrooms that I let out via Airbnb. I have a lock on the front door and one on each of the rooms. I do this by creating 8 integration (yes 8) Each integration is configured with 5 sensors. There are 2 integrations per each calendar. One of each of those is configured to manage the front door lock for just 5 slots (each one manages 5 different slots), the other one of the pair manages the bedroom door.

I could get away with only having 4 Rental Control integrations at the cost of a lot of Keymaster integrations to handle the complex parent child setup that it would require. I don't want to do that as it's far easier and less complex to not use Keymaster's parent child system and just go with a doubling of the Rental Control configurations.