"supplied key param cannot be coerced into a private key with google apis" Code Answer

4

First, you need to use openssl_pkcs12_read to read the key file, not file_get_contents. Second, I believe you want to leave off the second parameter to openssl_get_privatekey.

I highly recommend you use google-api-php-client for this, which has Google_P12Signer.php

By patilmadhuri2810-7d2dd5a99b4e on October 4 2022

Answers related to “supplied key param cannot be coerced into a private key with google apis”

Only authorized users can answer the search term. Please sign in first, or register a free account.