I am making a call to the google indexing API for job postings:
private $client;
private $httpClient;
public function initClient($kernel)
{
$this->cl
Make sure that you have added the service account as an Owner in Google Search Console as described here: https://developers.google.com/search/apis/indexing-api/v3/prereqs#verify-site.
My problem was that we had multiple entries for the domain in the Search Console (with and without www and with and without https); after adding the service account as an owner to all 4 entries it's working.