Google API invoice exceptional increasing - google-maps

Am using Google APIs(distance-matrix, places-details, and geo-coding)
and I always received an invoice by $12000/month
but suddenly the invoice increased to $60000 in one day
Can Anyone explain whats the error and how I can contact google support??

Related

Apps Script get User's Work Week Settings

I'm working on a script to automatically schedule certain tasks for some users at my company. When the tasks get scheduled will be based on the user's workweek and workday, which can be customized in Google Calendar. Most of us have a M-F work week, but we have flexible schedules so for some of us, their work day may be 7-3, others 8-4, or 9-5. Some may work 4 days a week, 10 hours a day so they work Mon-Thur, 7-5, 8-6, or 9-7. That's not counting second shift, third shift, etc. I don't want the tasks to be scheduled outside of their workdays.
How can I access these settings from Apps Script?
Unfortunately, it is currently not possible to get Working Hours information through Calendar API.
Although you can query whether there are conflicting events for a given calendar/time-frame using Freebusy.query(), this method will not return a “busy” response when querying for a time-frame out of working hours.
Additionally, there is currently a new Google API in alpha called Calendar User Availability API but it currently only exposes Working Location queries not Working Hours.
More information about Calendar User Availability API on this blog post
Alternatively, you can file a new Feature Request with Google using this template

Service invoked too many times per day: email

I have this issue. My google account is G-Suite and I'm entitled to 1500 email recipients per day.
I have calculated the email that I have sent within a day and it adds up to only 221 recipients per day.
13 Recipients * 17 emails per day.
Is there any other issue that may caused this problem? Can it be the time between the execution runs? If so, is there any way to make a gap for each of the execution?
Are you CC'ing or BCC'ing anyone in your script? Gmail counts every CC or BCC as a separate email and thus it counts towards your email quota.
Please note the following part of the documentation:
Note: Newly created G Suite domains are subject to the consumer limit
for the first billing cycle if they have six or more users, or several
billing cycles if they have fewer users. For more information, see the
Help Center page on sending limits.
This would explain why you are temporarily limited to the Consumer quota.
Be also aware of different quota for external accounts.
As I constantly troubleshoot, I have found out that by using Google Groups, the problem went away. I believe the reason for it would be I am technically sending only one email to an address. That email address will then branch out and send to the different email that I have within that Google Group that I have created. After monitoring it for a few days, I do not have this problem anymore.
Thank you for those who have helped me.

Send Google Pay request using Google Apps Script

I am trying to automate my monthly flow of doing some math and sending people Google Pay requests using Google Apps Script. Right now my script sends people email with what is due but I would like to also attach GPay request in the email or just send GPay request alone.
Background -
I receive an email from a phone service every month with the bill amount. I split that with a group of 4-5 people depending on their usage and any overages they may have. My script correctly finds out the email and parses to find out the total amount due and then also goes ahead and figures out who owes me how much. I pay the entire bill and then collect money from other people. In the end, the script sends each person an email with the amount they owe me each month.
Problem -
tbh, it is not a "problem" as such but this is an enhancement I would like to add. Gmail allows attaching Google Pay request in the email. (Please see screenshot). I would like to enhance my script so that I can attach such a Payment request in the email that this script sends out.
My question is if this is at all possible?
References
Google Apps Script
Google Apps Script Console
Google Pay API
For my use case, it does not have to be an email with Google Pay attachment. It can just be a Google Pay request.
Unfortunately the public Google Pay APIs aren't set up for this.
Unless you happen to also be registered as a merchant and are able receive payments I would avoid this.
If on the other hand you are an existing Google Pay merchant and you're interested in doing it for giggles, you could try the following:
Create a webpage that you can link to in your email
Have the webpage accept required query string parameters (like amount and description)
Render payment information (like amount and description) and integrate the Google Pay Button
Embed the link in your email
IMHO this isn't practical at all... it just depends on how desperate you are for giggle.

Google maps intermittent quota exceeded message

Since last friday, without having changed any code on my website or Google API Console, we started getting the following message:
"This site has exceeded its daily quota for maps. If you are the creator of this site, please visit the documentation to learn more".
What we can't explain is the following:
The Google API Console reports we are well under the maps daily quota
Users get this messages intermittently. If you get the message, for example, and reload the page, you probably wont get the message again.
We started getting an unrelated issue saying that the current site wasn't authorized to use the API. But the whole domain was authorized via the API console, has been authorized for over a year, we haven't touched that setting, this issue is also intermittent.
Any clue as to why is this happening and/or how to fix it?

Calendar REST API in Office 365 APIs Preview - not all events

I am building a JS Webapp with the new Office 365 REST Api. My problem is, that I am no getting all occurence events from a Roomcalendar.
Has anybody an Idea?
I am trying to receive all Events with this URL:
https://outlook.office365.com/EWS/OData/Users(room#exampledomain.com)/Events?$top=100&$filter=End%20ge%202014-08-20T22:30:00Z%20and%20Start%20le%202020-12-14T22:30:00Z
Thanks in advance
The server will page the results back to you in lots of 100 (AFIAK), your date range is quite large 2014-2020 if you have Recurring appointments with no End date your more then likely going to get pages of results. Check the Results you getting back for #odata.nextLink eg
"#odata.nextLink": "https://outlook.office365.com/EWS/OData/Users('user#domain.onmicrosoft.com')/Events/?%24top=100&%24filter=End+ge+2014-08-20T22%3a30%3a00Z+and+Start+le+2020-12-14T22%3a30%3a00Z&%24skip=100"
This is what you should use to the get the next page of results
Cheers
Glen