Class CodeArtifactCredentials

java.lang.Object
ai.clarity.codeartifact.CodeArtifactCredentials

public final class CodeArtifactCredentials extends Object
Static AWS credentials of a service account, used to request the CodeArtifact authorization token without relying on a local AWS profile.

A session token can be supplied for temporary credentials, and must be omitted for the long lived access keys of an IAM user.

  • Method Details

    • of

      public static CodeArtifactCredentials of(String accessKeyId, String secretAccessKey)
    • of

      public static CodeArtifactCredentials of(String accessKeyId, String secretAccessKey, String sessionToken)
    • of

      public static CodeArtifactCredentials of(Map<?,?> values)
      Builds the credentials from a map, which is the shape the Groovy DSL passes them in, as in codeartifact(url, [accessKeyId: '...', secretAccessKey: '...']).
    • getAccessKeyId

      public String getAccessKeyId()
    • getMaskedAccessKeyId

      public String getMaskedAccessKeyId()
      The access key id with its middle section hidden, safe to write to the build log.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Redacted on purpose: these credentials end up in build logs and in Gradle error messages.
      Overrides:
      toString in class Object