Class TokenClaimOrExpressionMapping

  • All Implemented Interfaces:
    io.fabric8.kubernetes.api.builder.Editable<TokenClaimOrExpressionMappingBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource, Serializable

    @Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator")
    public class TokenClaimOrExpressionMapping
    extends Object
    implements io.fabric8.kubernetes.api.builder.Editable<TokenClaimOrExpressionMappingBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
    TokenClaimOrExpressionMapping allows specifying either a JWT token claim or CEL expression to be used when mapping claims from an authentication token to cluster identities.
    See Also:
    Serialized Form
    • Constructor Detail

      • TokenClaimOrExpressionMapping

        public TokenClaimOrExpressionMapping()
        No args constructor for use in serialization
      • TokenClaimOrExpressionMapping

        public TokenClaimOrExpressionMapping​(String claim,
                                             String expression)
    • Method Detail

      • getClaim

        public String getClaim()
        claim is an optional field for specifying the JWT token claim that is used in the mapping. The value of this claim will be assigned to the field in which this mapping is associated.


        Precisely one of claim or expression must be set. claim must not be specified when expression is set. When specified, claim must be at least 1 character in length and must not exceed 256 characters in length.

      • setClaim

        public void setClaim​(String claim)
        claim is an optional field for specifying the JWT token claim that is used in the mapping. The value of this claim will be assigned to the field in which this mapping is associated.


        Precisely one of claim or expression must be set. claim must not be specified when expression is set. When specified, claim must be at least 1 character in length and must not exceed 256 characters in length.

      • getExpression

        public String getExpression()
        expression is an optional field for specifying a CEL expression that produces a string value from JWT token claims.


        CEL expressions have access to the token claims through a CEL variable, 'claims'. 'claims' is a map of claim names to claim values. For example, the 'sub' claim value can be accessed as 'claims.sub'. Nested claims can be accessed using dot notation ('claims.foo.bar').


        Precisely one of claim or expression must be set. expression must not be specified when claim is set. When specified, expression must be at least 1 character in length and must not exceed 4096 characters in length.

      • setExpression

        public void setExpression​(String expression)
        expression is an optional field for specifying a CEL expression that produces a string value from JWT token claims.


        CEL expressions have access to the token claims through a CEL variable, 'claims'. 'claims' is a map of claim names to claim values. For example, the 'sub' claim value can be accessed as 'claims.sub'. Nested claims can be accessed using dot notation ('claims.foo.bar').


        Precisely one of claim or expression must be set. expression must not be specified when claim is set. When specified, expression must be at least 1 character in length and must not exceed 4096 characters in length.

      • getAdditionalProperties

        public Map<String,​Object> getAdditionalProperties()
      • setAdditionalProperty

        public void setAdditionalProperty​(String name,
                                          Object value)
      • setAdditionalProperties

        public void setAdditionalProperties​(Map<String,​Object> additionalProperties)