Struct aws_sdk_ecr::client::fluent_builders::GetAuthorizationToken
source · pub struct GetAuthorizationToken { /* private fields */ }
Expand description
Fluent builder constructing a request to GetAuthorizationToken
.
Retrieves an authorization token. An authorization token represents your IAM authentication credentials and can be used to access any Amazon ECR registry that your IAM principal has access to. The authorization token is valid for 12 hours.
The authorizationToken
returned is a base64 encoded string that can be decoded and used in a docker login
command to authenticate to a registry. The CLI offers an get-login-password
command that simplifies the login process. For more information, see Registry authentication in the Amazon Elastic Container Registry User Guide.
Implementations§
source§impl GetAuthorizationToken
impl GetAuthorizationToken
sourcepub async fn customize(
self
) -> Result<CustomizableOperation<GetAuthorizationToken, AwsResponseRetryClassifier>, SdkError<GetAuthorizationTokenError>>
pub async fn customize(
self
) -> Result<CustomizableOperation<GetAuthorizationToken, AwsResponseRetryClassifier>, SdkError<GetAuthorizationTokenError>>
Consume this builder, creating a customizable operation that can be modified before being sent. The operation’s inner http::Request can be modified as well.
sourcepub async fn send(
self
) -> Result<GetAuthorizationTokenOutput, SdkError<GetAuthorizationTokenError>>
pub async fn send(
self
) -> Result<GetAuthorizationTokenOutput, SdkError<GetAuthorizationTokenError>>
Sends the request and returns the response.
If an error occurs, an SdkError
will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
sourcepub fn registry_ids(self, input: impl Into<String>) -> Self
👎Deprecated: This field is deprecated. The returned authorization token can be used to access any Amazon ECR registry that the IAM principal has access to, specifying a registry ID doesn’t change the permissions scope of the authorization token.
pub fn registry_ids(self, input: impl Into<String>) -> Self
Appends an item to registryIds
.
To override the contents of this collection use set_registry_ids
.
A list of Amazon Web Services account IDs that are associated with the registries for which to get AuthorizationData objects. If you do not specify a registry, the default registry is assumed.
sourcepub fn set_registry_ids(self, input: Option<Vec<String>>) -> Self
👎Deprecated: This field is deprecated. The returned authorization token can be used to access any Amazon ECR registry that the IAM principal has access to, specifying a registry ID doesn’t change the permissions scope of the authorization token.
pub fn set_registry_ids(self, input: Option<Vec<String>>) -> Self
A list of Amazon Web Services account IDs that are associated with the registries for which to get AuthorizationData objects. If you do not specify a registry, the default registry is assumed.
Trait Implementations§
source§impl Clone for GetAuthorizationToken
impl Clone for GetAuthorizationToken
source§fn clone(&self) -> GetAuthorizationToken
fn clone(&self) -> GetAuthorizationToken
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more