You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

19 lines
404 B

<?php
require('../../vendor/autoload.php');
use Volc\Service\Sts;
$client = Sts::getInstance();
$client->setAccessKey("your ak");
$client->setSecretKey("your sk");
$query = [
"query" => [
"DurationSeconds" => "900",
"RoleSessionName" => "just_for_test",
"RoleTrn" => "trn:iam::yourAccountID:role/yourRole",
]
];
$response = $client->assumeRole($query);
echo $response;