java.lang.Object
org.elasticsearch.xpack.core.security.action.apikey.ApiKey
All Implemented Interfaces:
org.elasticsearch.xcontent.ToXContent, org.elasticsearch.xcontent.ToXContentObject

public final class ApiKey extends Object implements org.elasticsearch.xcontent.ToXContentObject
API key information
  • Field Details

    • CURRENT_API_KEY_VERSION

      public static final ApiKey.Version CURRENT_API_KEY_VERSION
  • Constructor Details

  • Method Details

    • getId

      public String getId()
    • getName

      public String getName()
    • getType

      public ApiKey.Type getType()
    • getCreation

      public Instant getCreation()
    • getExpiration

      public Instant getExpiration()
    • isInvalidated

      public boolean isInvalidated()
    • getInvalidation

      public Instant getInvalidation()
    • getUsername

      public String getUsername()
    • getRealm

      public String getRealm()
    • getRealmType

      @Nullable public String getRealmType()
    • getRealmIdentifier

      @Nullable public RealmConfig.RealmIdentifier getRealmIdentifier()
    • getMetadata

      public Map<String,Object> getMetadata()
    • getRoleDescriptors

      public List<RoleDescriptor> getRoleDescriptors()
    • getLimitedBy

      public RoleDescriptorsIntersection getLimitedBy()
    • toXContent

      public org.elasticsearch.xcontent.XContentBuilder toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException
      Specified by:
      toXContent in interface org.elasticsearch.xcontent.ToXContent
      Throws:
      IOException
    • innerToXContent

      public org.elasticsearch.xcontent.XContentBuilder innerToXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException
      Throws:
      IOException
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • fromXContent

      public static ApiKey fromXContent(org.elasticsearch.xcontent.XContentParser parser) throws IOException
      Throws:
      IOException