Google Compute Engine - pricing in what currency? - google-compute-engine

When you're creating a new VM from Google Compute Engine, from top right of Google Console: "You have $12345 free trial credits remaining"
That looks in local currency (i.e. not USD)
I looked up and down cant find a confirmation of this?
Thanks

1) under Billing section, charges in local CCy HKD for example,
2) Create new VM instance - estimates are in USD

Related

How to fix "You must enable Billing on the Google Cloud Project" on a Project will Billing enabled? [duplicate]

This question already has answers here:
Enable Billing on the Google Cloud Project
(9 answers)
Closed 1 year ago.
I'm trying to replace the API key for a website I made that takes a given address and renders it in Google maps. When I try and use it I get this
and this
You must enable Billing on the Google Cloud Project at https://console.cloud.google.com/project/_/billing/enable Learn more at https://developers.google.com/maps/gmp-get-started
When I click the link to add billing, nothing changes. When I check on my billing account to see if it's attached to the project housing the key, it is connected. When I check the project itself to see if it has billing, it says it does.
The other person who asked a very similar question had people saying to create a brand new project and a brand new billing account. I tried this and I'm still having the problem. I also tried to create a new billing account as a "Google Maps Platform" as another user suggested
(His screenshot) but that option does not exist for me.
(My Screenshot on the same page)
I'm at a complete loss here. Are there any other solutions people have found for this issue?
This error often means there is a problem with the Google Payments account associated with the billing account. Double-check that your payment information is correct. Some credit/debit cards do not work with Google payments.
You can test that your card works by making a small prepayment on your account. However, success does not mean that the credit/debit card can be used for recurring payments (that is an issue with some countries) but the prepayment will allow you to use the account (in most cases).
Google Payments Account
Another item to double-check is the type of billing account. There are two: Google Cloud Platform and Google Maps Platform. In the Google Billing Accounts page, look for Enabled Google service., It should show Google Maps Platform.
Google Maps Platform Billing
From your screenshot, I see that you are in India. Most credit/debit cards from India refuse Google payments. If this is the case, you will need to use a different credit/debit card or you will need to prepay your account. Other options are to switch to invoiced billing or set up an account with a Google partner.
(Customers in India) Automatic payments declined due to Reserve Bank of India (RBI) regulations
The following links provide options:
Make a manual payment or pay early
Apply for monthly invoiced billing
Find the right Google Cloud partner

Monitor Google API usage programmatically?

https://console.cloud.google.com/apis/dashboard
If we open google console we see how many requests per every service has been done. Is there any way to export these counters? I was not able to find any API which is responsible for these counters.
Get google maps api usage info
Detect Google Maps Javascript API limit for map loads
Many years passed, still no way to setup alerting for API usage? If there is no programmatic access may be there is some way to setup alerts when API usage is above threshold?
As mentioned by the first answer, there's no such API to monitor these usages but there are couple of ways to monitor your usage which are:
Setup Budget Alerts, this will trigger notification if you've reached a certain amount of your specified budget for a month, but please note that this will only notify you and will not actually stop the usage after the specified amount.
If you would like to monitor or get an overview of your daily usage, you may implement what we call channels with the help of BigQuery Export. This will give you a breakdown report of daily usage. The standard SQL code you can use to retrieve such report using the BigQuery export is:
SELECT Date(usage_start_time, "America/Los_Angeles") AS billing_day,
invoice.month AS invoice_month,
service.description AS service,
sku.description AS sku,
(
SELECT l.value
FROM Unnest(labels) AS l
WHERE l.KEY = 'goog-maps-channel' ) AS goog_maps_channel,
Round(Sum(usage.amount), 2) AS usage_amount,
usage.unit AS usage_unit,
Round(Sum(cost), 2) AS cost,
cost_type,
currency
FROM `PROJECT_ID.DATASET_NAME.gcp_billing_export_v1_BILLING_ACCOUNT_ID`
WHERE invoice.month = '201906' -- Change the invoice month with the same format as the example.
GROUP BY billing_day,
invoice_month,
service,
sku,
goog_maps_channel,
usage_unit,
cost_type,
currency
ORDER BY billing_day,
service,
sku
You may learn more on how to setup the BigQuery export here.
If you want to restrict your usage up to a certain amount per day, you may also implement the Capping of API usage wherein it will only allow an API to call a specific amount of requests per day.
If you would ever need help in the correct calculation of requests per day for each API to be on a certain budget, you may reach to the support team of the Google Maps Platform APIs here.

Google Map Address Geocoding API not working

I am new to the GCP. I have created a project in the Google Cloud Platform and enabled Geocoding API and Static Map API.
I had free trial but when more requests come, Geocoding API shows OVER_QUERY_LIMIT reached. Therefore, I enabled the billing to that project so it is solved but the billing account has own its some quota or threshold for the requests.
Because if I reached over that threshold, it says again OVER_QUERY_LIMIT. How can I extend this with having current billing (no extra charges)?
If this is not possible, what the billing account means.
And I received many time 403 response code in the GCP Geocoding API Logs rather than 200 response code. And I don't know why it is happening.
it counts the per second query limits. consider that.
Please note that you have $300 (usable for GCP Products) one time credit upon activating your Billing account plus monthly recurring of $200 credit (exclusive for Maps API only), if you haven't exhausted this credit then maybe you just need to adjust your quota higher in order to avoid OVER_QUERY_LIMIT, but if your project is already in production, then you might need to upgrade your billing account.
Upgrading your billing account will allow you to exceed your quota, however extra charges will occur, but you can set limit to your API usage to prevent excess bill.
You may refer to this link to learn on how to edit your quota and learn on Capping API Usage.

How to compute cost of Google API calls?

Like everyone else, I received an email saying that I need to activate billing to continue using the Google Maps API, and so I did. Now I try to understand what the cost my API usage will be – and I’m lost.
On Google Cloud Platform API / API and services I can see that there are 1 635 Maps Elevation API calls and 1157 Maps Java Script API calls at noon today.
At the same time, under IAM and administration / Quotas I see : 123 / 2500 requests per day.
What is the relation between the 1635+1157 API calls and the 123 requests?
I used 63 842 Elevation API calls and 36 023 Maps Java Script calls during the last 30 days – according to the price sheet google cloud price sheet.
This would cost 63842*5/1000+36023/1000*7 $ = 571 $ - yet the price shown is $0 for now.
It’s a free website - if I have to pay this kind of money it will be down next month…
Sorry if this is not the right place to ask, but I do this as a hobby. Thanks.
Just a little summary, now that the new cost scheme is in effect:
The Google Cloud Platform API / API and services section is the reference for computing API usage cost
The IAM and administration / Quotas section ‘may take more time to update’ (according to Google support) and was off by a factor of 10 in my case. I could never figure out the details (maybe something about the time zone ?), but I understand that you are not supposed to use it to check usage on a daily basis (use 1. For that)
Even if the mail from Google says API usage will ‘probably continue to be free’ in your case, now is a good time to check (half way through the first month): in my case, the actual cost would have roughly been 500 $ (-$ 200 free offer).
My solution to the problem on my free website was to remove the google maps from it. :-(
Thanks to all who tried to help.

Shopify updating of shipping/delivery free programmatically during checkout

Can shopify delivery/shipping fee be updated programatically during checkout? What I want to do for longer distance deliveries is use the Google API to calculate the distance difference between the my store and customer and increase the delivery fee if it is more than x miles (probably 10 miles).
You can use Shopify's carrier service API for this. When a customer checks out, Shopify will provide your app with the line items and shipping address and your app can send back the shipping options and prices.
You can use the Carrier Service API for that but you have to be on the Shopify Advanced plan.
A possible hack would be to add a surcharge to the cart as a product. You'd have to get the customer to register/login in the cart and keep them from going to the checkout until you have a shipping address and then add the surcharge product via script.
You may need an app for that but the $220/month difference between Shopify and Advanced Shopify offers some incentive to look for alternatives.