Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature suggestion] - Extended "order is ready" notifications #346

Open
nikdav opened this issue May 26, 2023 · 2 comments
Open

[Feature suggestion] - Extended "order is ready" notifications #346

nikdav opened this issue May 26, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@nikdav
Copy link
Contributor

nikdav commented May 26, 2023

Hi,

I think getting a notification at another point before or during the pickup time would be nice to have.
The timing of those reminders should be configurable and there can be multiple.
Also, the remaining pickup time and the time it takes to get to the item location could be taken into consideration.
The time it takes to get there with current traffic could be retrieved with the Google Maps Distance Matrix API Advanced.

The cost of that in the Google Maps Distance Matrix API Advanced would be negligible for a normal use case:

1 (magic bag per day) * 4 (possible modes of transportation) * 2 (reminders, for example when the pickup time starts and halfway through) * 30 (days) = 240 requests * 0,01 $ = 2,4 $ / month.
If you would only like to use one or two modes / just one reminder or don't buy a magic bag every day it could even be less. Anyways, the 200$ Maps API free contingent per month will not be exceeded.

Example message:
Your order is ready for pickup in 5 minutes!
Pickup time ends in 20 minutes.
Time it takes to get there with current traffic:

  • Driving: 6 minutes
  • Walking: 25 minutes (exceeds pickup time by 10 minutes)

Why?
The TGTG app only reminds you of picking up your order about one hour before the pickup time starts.
I recently found myself in a situation, where I got the 1-hour-before notification while I was doing something else.
Time flies and I almost forgot to pick up the magic bag because I don't take an hour to get there but just a few minutes.

@Der-Henning
Copy link
Owner

Der-Henning commented May 30, 2023

Hi @nikdav.
That's a nice feature.

A connection to the google maps API is already included in the code and will be part of the next release. At the moment it allows to include distance and duration information to be included in the regular notifications.

As I am very busy at the moment it may take some time until I can work on this feature. If you want you can try to code it yourself and create a pull request.

Edit: I didn't see that you made the PR for the google maps API :)

@Der-Henning Der-Henning added the enhancement New feature or request label Jun 1, 2023
@pershoot
Copy link

pershoot commented Jun 2, 2023

Looks good.

Snippet (using distance_walking and duration_walking); Telegram notify.

Pickup: ...
Walking distance (duration): 2.5 km (31 minutes), from home
Link: ...

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants