I am trying to use Custom Search JSON API / Site Restricted JSON API.
Additional context: this is not a newly created Google account or newly created Cloud project. The Google Cloud project is from 2023 and already had an existing API key before I created API key 2 for testing. I am trying to determine whether this project should be treated as an existing Custom Search JSON API customer/project, or whether Google is now denying JSON API entitlement despite the older project and existing key.
Custom Search API is enabled in my Google Cloud project. Billing/free trial is active. I created a new API key in the same project. Requests made with that key appear in Custom Search API Metrics and count against quota.
The hosted Programmable Search Engine page works, so the cx/search engine exists and is functional outside the JSON API path
Evidence:
- Fake key returns API_KEY_INVALID, so the request path and API-key validation are working.
- Real key reaches customsearch.googleapis.com and appears in Metrics.
- The project is from 2023 and had an existing API key before this troubleshooting.
- I created API key 2 only to rule out a stale/bad key.
- Quotas are nonzero:
- Queries per day: 10,000
- Site Restricted Queries per day: Unlimited
- Queries per minute: Unlimited
- Site Restricted Queries per minute: Unlimited
- Both API methods fail:
- google.customsearch.v1.CustomSearchService.List
- google.customsearch.v1.CustomSearchService.SiteRestrictList
Endpoint results:
/customsearch/v1 returns:
“This project does not have the access to Custom Search JSON API.”
/customsearch/v1/siterestrict returns:
“The caller does not have permission.”
The hosted Programmable Search Engine page works:
Cloud support will not allow me to file a technical support case because the account is on the free trial, and Billing Support live chat/email is also unavailable on the free trial.
Can someone confirm whether this project needs Google-side entitlement/reactivation for Custom Search JSON API / Site Restricted JSON API access?