How in PHP using Google API to change the signatures of users?

I want to automate the changing of the signatures. There is the PHP client, there is a description of the API for this.
Try this:
require_once "google-api-php-client/src/Google_Client.php";
$client = new Google_Client();
$client->setApplicationName( 'Signature creator' );
$client->setClientId( CLIENT_ID );
$client->setAccessType( 'offline_access');
$client->setAssertionCredentials(
 new Google_AssertionCredentials(
SERVICE_EMAIL,
array(
 '<a href="https://apps-apis.google.com/a/feeds/emailsettings/">https://apps-apis.google.com/a/feeds/emailsettings/</a>',
 '<a href="https://apps-apis.google.com/a/feeds/groups/">https://apps-apis.google.com/a/feeds/groups/</a>',
 '<a href="https://apps-apis.google.com/a/feeds/alias/">https://apps-apis.google.com/a/feeds/alias/</a>',
"),
 file_get_contents( KEY_FILE_PATH )
)
);
$client->setUseObjects( true );

$domain = "domen.ru";
$user = rawurlencode("user");

$req = new Google_HttpRequest("");
$resp = $client::getIo()->authenticatedRequest($req);
print "Signature:" . $resp->getResponseBody();


Issues:
Signature:
You are not authorized to access this API.
Error 403

In the security domain CLIENT_ID said:
<a href="https://apps-apis.google.com/a/feeds/alias/">https://apps-apis.google.com/a/feeds/alias/</a> 
<a href="https://apps-apis.google.com/a/feeds/emailsettings/">https://apps-apis.google.com/a/feeds/emailsettings/</a> 
Provisioning Groups <a href="https://apps-apis.google.com/a/feeds/groups/">https://apps-apis.google.com/a/feeds/groups/</a> 
User Provisioning 
October 3rd 19 at 01:33
1 answer
October 3rd 19 at 01:35
Solution
I like to reply to myself :)
Did

Find more questions by tags APIGmailGooglePHP