mirror of
https://github.com/SociallyDev/Spaces-API.git
synced 2025-08-19 21:03:44 -07:00
v2: Updates
* Simplifies & beautifies everything * Introduces a new Class system. * Errors are defaulted to AWS's handler. * New function names & more efficient handling. * Should fix a majority of the errors. Please read the README for more!
This commit is contained in:
parent
ad0726e41e
commit
e6d7753dc8
1095 changed files with 45088 additions and 2911 deletions
|
@ -2,8 +2,10 @@
|
|||
namespace Aws\Sts;
|
||||
|
||||
use Aws\AwsClient;
|
||||
use Aws\Result;
|
||||
use Aws\CacheInterface;
|
||||
use Aws\Credentials\Credentials;
|
||||
use Aws\Result;
|
||||
use Aws\Sts\RegionalEndpoints\ConfigurationProvider;
|
||||
|
||||
/**
|
||||
* This client is used to interact with the **AWS Security Token Service (AWS STS)**.
|
||||
|
@ -16,6 +18,8 @@ use Aws\Credentials\Credentials;
|
|||
* @method \GuzzleHttp\Promise\Promise assumeRoleWithWebIdentityAsync(array $args = [])
|
||||
* @method \Aws\Result decodeAuthorizationMessage(array $args = [])
|
||||
* @method \GuzzleHttp\Promise\Promise decodeAuthorizationMessageAsync(array $args = [])
|
||||
* @method \Aws\Result getAccessKeyInfo(array $args = [])
|
||||
* @method \GuzzleHttp\Promise\Promise getAccessKeyInfoAsync(array $args = [])
|
||||
* @method \Aws\Result getCallerIdentity(array $args = [])
|
||||
* @method \GuzzleHttp\Promise\Promise getCallerIdentityAsync(array $args = [])
|
||||
* @method \Aws\Result getFederationToken(array $args = [])
|
||||
|
@ -25,6 +29,37 @@ use Aws\Credentials\Credentials;
|
|||
*/
|
||||
class StsClient extends AwsClient
|
||||
{
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* In addition to the options available to
|
||||
* {@see \Aws\AwsClient::__construct}, StsClient accepts the following
|
||||
* options:
|
||||
*
|
||||
* - sts_regional_endpoints:
|
||||
* (Aws\Sts\RegionalEndpoints\ConfigurationInterface|Aws\CacheInterface\|callable|string|array)
|
||||
* Specifies whether to use regional or legacy endpoints for legacy regions.
|
||||
* Provide an Aws\Sts\RegionalEndpoints\ConfigurationInterface object, an
|
||||
* instance of Aws\CacheInterface, a callable configuration provider used
|
||||
* to create endpoint configuration, a string value of `legacy` or
|
||||
* `regional`, or an associative array with the following keys:
|
||||
* endpoint_types (string) Set to `legacy` or `regional`, defaults to
|
||||
* `legacy`
|
||||
*
|
||||
* @param array $args
|
||||
*/
|
||||
public function __construct(array $args)
|
||||
{
|
||||
if (
|
||||
!isset($args['sts_regional_endpoints'])
|
||||
|| $args['sts_regional_endpoints'] instanceof CacheInterface
|
||||
) {
|
||||
$args['sts_regional_endpoints'] = ConfigurationProvider::defaultProvider($args);
|
||||
}
|
||||
parent::__construct($args);
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates credentials from the result of an STS operations
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue