Class MetricPost


  • @Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
               date="2026-06-30T13:33:45.929090Z[Etc/UTC]",
               comments="Generator version: 7.18.0")
    public class MetricPost
    extends java.lang.Object
    MetricPost
    • Field Detail

      • SERIALIZED_NAME_KEY

        public static final java.lang.String SERIALIZED_NAME_KEY
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_NAME

        public static final java.lang.String SERIALIZED_NAME_NAME
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_DESCRIPTION

        public static final java.lang.String SERIALIZED_NAME_DESCRIPTION
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_KIND

        public static final java.lang.String SERIALIZED_NAME_KIND
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_SELECTOR

        public static final java.lang.String SERIALIZED_NAME_SELECTOR
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_URLS

        public static final java.lang.String SERIALIZED_NAME_URLS
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_IS_NUMERIC

        public static final java.lang.String SERIALIZED_NAME_IS_NUMERIC
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_UNIT

        public static final java.lang.String SERIALIZED_NAME_UNIT
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_EVENT_KEY

        public static final java.lang.String SERIALIZED_NAME_EVENT_KEY
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_SUCCESS_CRITERIA

        public static final java.lang.String SERIALIZED_NAME_SUCCESS_CRITERIA
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_TAGS

        public static final java.lang.String SERIALIZED_NAME_TAGS
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_RANDOMIZATION_UNITS

        public static final java.lang.String SERIALIZED_NAME_RANDOMIZATION_UNITS
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_ANALYSIS_UNITS

        public static final java.lang.String SERIALIZED_NAME_ANALYSIS_UNITS
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_MAINTAINER_ID

        public static final java.lang.String SERIALIZED_NAME_MAINTAINER_ID
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_UNIT_AGGREGATION_TYPE

        public static final java.lang.String SERIALIZED_NAME_UNIT_AGGREGATION_TYPE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_ANALYSIS_TYPE

        public static final java.lang.String SERIALIZED_NAME_ANALYSIS_TYPE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_PERCENTILE_VALUE

        public static final java.lang.String SERIALIZED_NAME_PERCENTILE_VALUE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_EVENT_DEFAULT

        public static final java.lang.String SERIALIZED_NAME_EVENT_DEFAULT
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_DATA_SOURCE

        public static final java.lang.String SERIALIZED_NAME_DATA_SOURCE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_FILTERS

        public static final java.lang.String SERIALIZED_NAME_FILTERS
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINDOW_START_OFFSET

        public static final java.lang.String SERIALIZED_NAME_WINDOW_START_OFFSET
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINDOW_END_OFFSET

        public static final java.lang.String SERIALIZED_NAME_WINDOW_END_OFFSET
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINSOR_LOWER_PERCENTILE

        public static final java.lang.String SERIALIZED_NAME_WINSOR_LOWER_PERCENTILE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINSOR_UPPER_PERCENTILE

        public static final java.lang.String SERIALIZED_NAME_WINSOR_UPPER_PERCENTILE
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINSOR_EXCLUDE_IMPUTED

        public static final java.lang.String SERIALIZED_NAME_WINSOR_EXCLUDE_IMPUTED
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_WINSOR_INCLUDE_IMPUTED

        public static final java.lang.String SERIALIZED_NAME_WINSOR_INCLUDE_IMPUTED
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_TRACE_QUERY

        public static final java.lang.String SERIALIZED_NAME_TRACE_QUERY
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_TRACE_VALUE_LOCATION

        public static final java.lang.String SERIALIZED_NAME_TRACE_VALUE_LOCATION
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_UNIT_AGGREGATION_FIELD

        public static final java.lang.String SERIALIZED_NAME_UNIT_AGGREGATION_FIELD
        See Also:
        Constant Field Values
      • SERIALIZED_NAME_DENOMINATOR

        public static final java.lang.String SERIALIZED_NAME_DENOMINATOR
        See Also:
        Constant Field Values
      • openapiFields

        public static java.util.HashSet<java.lang.String> openapiFields
      • openapiRequiredFields

        public static java.util.HashSet<java.lang.String> openapiRequiredFields
    • Constructor Detail

      • MetricPost

        public MetricPost()
    • Method Detail

      • key

        public MetricPost key​(@Nonnull
                              java.lang.String key)
      • getKey

        @Nonnull
        public java.lang.String getKey()
        A unique key to reference the metric
        Returns:
        key
      • setKey

        public void setKey​(@Nonnull
                           java.lang.String key)
      • name

        public MetricPost name​(@Nullable
                               java.lang.String name)
      • getName

        @Nullable
        public java.lang.String getName()
        A human-friendly name for the metric
        Returns:
        name
      • setName

        public void setName​(@Nullable
                            java.lang.String name)
      • description

        public MetricPost description​(@Nullable
                                      java.lang.String description)
      • getDescription

        @Nullable
        public java.lang.String getDescription()
        Description of the metric
        Returns:
        description
      • setDescription

        public void setDescription​(@Nullable
                                   java.lang.String description)
      • getKind

        @Nonnull
        public MetricPost.KindEnum getKind()
        The kind of event your metric will track
        Returns:
        kind
      • selector

        public MetricPost selector​(@Nullable
                                   java.lang.String selector)
      • getSelector

        @Nullable
        public java.lang.String getSelector()
        One or more CSS selectors. Required for click metrics only.
        Returns:
        selector
      • setSelector

        public void setSelector​(@Nullable
                                java.lang.String selector)
      • getUrls

        @Nullable
        public java.util.List<UrlPost> getUrls()
        One or more target URLs. Required for click and pageview metrics only.
        Returns:
        urls
      • setUrls

        public void setUrls​(@Nullable
                            java.util.List<UrlPost> urls)
      • isNumeric

        public MetricPost isNumeric​(@Nullable
                                    java.lang.Boolean isNumeric)
      • getIsNumeric

        @Nullable
        public java.lang.Boolean getIsNumeric()
        Whether to track numeric changes in value against a baseline (<code>true</code>) or to track a conversion when an end user takes an action (<code>false</code>). Required for custom and trace metrics only.
        Returns:
        isNumeric
      • setIsNumeric

        public void setIsNumeric​(@Nullable
                                 java.lang.Boolean isNumeric)
      • unit

        public MetricPost unit​(@Nullable
                               java.lang.String unit)
      • getUnit

        @Nullable
        public java.lang.String getUnit()
        The unit of measure. Applicable for numeric custom and trace metrics only.
        Returns:
        unit
      • setUnit

        public void setUnit​(@Nullable
                            java.lang.String unit)
      • eventKey

        public MetricPost eventKey​(@Nullable
                                   java.lang.String eventKey)
      • getEventKey

        @Nullable
        public java.lang.String getEventKey()
        The event key to use in your code. Required for custom conversion/binary and custom numeric metrics only.
        Returns:
        eventKey
      • setEventKey

        public void setEventKey​(@Nullable
                                java.lang.String eventKey)
      • getSuccessCriteria

        @Nullable
        public MetricPost.SuccessCriteriaEnum getSuccessCriteria()
        Success criteria. Required for custom and trace numeric metrics, optional for custom and trace conversion metrics.
        Returns:
        successCriteria
      • tags

        public MetricPost tags​(@Nullable
                               java.util.List<java.lang.String> tags)
      • addTagsItem

        public MetricPost addTagsItem​(java.lang.String tagsItem)
      • getTags

        @Nullable
        public java.util.List<java.lang.String> getTags()
        Tags for the metric
        Returns:
        tags
      • setTags

        public void setTags​(@Nullable
                            java.util.List<java.lang.String> tags)
      • randomizationUnits

        @Deprecated
        public MetricPost randomizationUnits​(@Nullable
                                             java.util.List<java.lang.String> randomizationUnits)
        Deprecated.
      • addRandomizationUnitsItem

        public MetricPost addRandomizationUnitsItem​(java.lang.String randomizationUnitsItem)
      • getRandomizationUnits

        @Deprecated
        @Nullable
        public java.util.List<java.lang.String> getRandomizationUnits()
        Deprecated.
        Deprecated, use <code>analysisUnits</code> instead.
        Returns:
        randomizationUnits
      • setRandomizationUnits

        @Deprecated
        public void setRandomizationUnits​(@Nullable
                                          java.util.List<java.lang.String> randomizationUnits)
        Deprecated.
      • analysisUnits

        public MetricPost analysisUnits​(@Nullable
                                        java.util.List<java.lang.String> analysisUnits)
      • addAnalysisUnitsItem

        public MetricPost addAnalysisUnitsItem​(java.lang.String analysisUnitsItem)
      • getAnalysisUnits

        @Nullable
        public java.util.List<java.lang.String> getAnalysisUnits()
        An array of analysis units allowed for this metric.
        Returns:
        analysisUnits
      • setAnalysisUnits

        public void setAnalysisUnits​(@Nullable
                                     java.util.List<java.lang.String> analysisUnits)
      • maintainerId

        public MetricPost maintainerId​(@Nullable
                                       java.lang.String maintainerId)
      • getMaintainerId

        @Nullable
        public java.lang.String getMaintainerId()
        The ID of the member who maintains this metric
        Returns:
        maintainerId
      • setMaintainerId

        public void setMaintainerId​(@Nullable
                                    java.lang.String maintainerId)
      • getUnitAggregationType

        @Nullable
        public MetricPost.UnitAggregationTypeEnum getUnitAggregationType()
        The method by which multiple unit event values are aggregated
        Returns:
        unitAggregationType
      • analysisType

        public MetricPost analysisType​(@Nullable
                                       java.lang.String analysisType)
      • getAnalysisType

        @Nullable
        public java.lang.String getAnalysisType()
        The method for analyzing metric events
        Returns:
        analysisType
      • setAnalysisType

        public void setAnalysisType​(@Nullable
                                    java.lang.String analysisType)
      • percentileValue

        public MetricPost percentileValue​(@Nullable
                                          java.lang.Integer percentileValue)
      • getPercentileValue

        @Nullable
        public java.lang.Integer getPercentileValue()
        The percentile for the analysis method. An integer denoting the target percentile between 0 and 100. Required when <code>analysisType</code> is <code>percentile</code>.
        Returns:
        percentileValue
      • setPercentileValue

        public void setPercentileValue​(@Nullable
                                       java.lang.Integer percentileValue)
      • getEventDefault

        @Nullable
        public MetricEventDefaultRep getEventDefault()
        Get eventDefault
        Returns:
        eventDefault
      • getFilters

        @Nullable
        public EventFilter getFilters()
        Get filters
        Returns:
        filters
      • setFilters

        public void setFilters​(@Nullable
                               EventFilter filters)
      • windowStartOffset

        public MetricPost windowStartOffset​(@Nullable
                                            java.lang.Long windowStartOffset)
      • getWindowStartOffset

        @Nullable
        public java.lang.Long getWindowStartOffset()
        Not yet implemented - The start of the measurement window, in milliseconds relative to the unit's first exposure to a flag variation
        Returns:
        windowStartOffset
      • setWindowStartOffset

        public void setWindowStartOffset​(@Nullable
                                         java.lang.Long windowStartOffset)
      • windowEndOffset

        public MetricPost windowEndOffset​(@Nullable
                                          java.lang.Long windowEndOffset)
      • getWindowEndOffset

        @Nullable
        public java.lang.Long getWindowEndOffset()
        Not yet implemented - The end of the measurement window, in milliseconds relative to the unit's first exposure to a flag variation
        Returns:
        windowEndOffset
      • setWindowEndOffset

        public void setWindowEndOffset​(@Nullable
                                       java.lang.Long windowEndOffset)
      • winsorLowerPercentile

        public MetricPost winsorLowerPercentile​(@Nullable
                                                java.math.BigDecimal winsorLowerPercentile)
      • getWinsorLowerPercentile

        @Nullable
        public java.math.BigDecimal getWinsorLowerPercentile()
        Lower winsorization percentile, expressed as a percent in the open interval (0, 100). When both bounds are set, defines a two-sided clamp range. Otherwise lower-only winsorization.
        Returns:
        winsorLowerPercentile
      • setWinsorLowerPercentile

        public void setWinsorLowerPercentile​(@Nullable
                                             java.math.BigDecimal winsorLowerPercentile)
      • winsorUpperPercentile

        public MetricPost winsorUpperPercentile​(@Nullable
                                                java.math.BigDecimal winsorUpperPercentile)
      • getWinsorUpperPercentile

        @Nullable
        public java.math.BigDecimal getWinsorUpperPercentile()
        Upper winsorization percentile, expressed as a percent in the open interval (0, 100). When both bounds are set, must be greater than winsorLowerPercentile.
        Returns:
        winsorUpperPercentile
      • setWinsorUpperPercentile

        public void setWinsorUpperPercentile​(@Nullable
                                             java.math.BigDecimal winsorUpperPercentile)
      • winsorExcludeImputed

        public MetricPost winsorExcludeImputed​(@Nullable
                                               java.lang.Boolean winsorExcludeImputed)
      • getWinsorExcludeImputed

        @Nullable
        public java.lang.Boolean getWinsorExcludeImputed()
        Deprecated and ignored. Use winsorIncludeImputed instead.
        Returns:
        winsorExcludeImputed
      • setWinsorExcludeImputed

        public void setWinsorExcludeImputed​(@Nullable
                                            java.lang.Boolean winsorExcludeImputed)
      • winsorIncludeImputed

        public MetricPost winsorIncludeImputed​(@Nullable
                                               java.lang.Boolean winsorIncludeImputed)
      • getWinsorIncludeImputed

        @Nullable
        public java.lang.Boolean getWinsorIncludeImputed()
        When true, the percentile bound calculation includes imputed zeros. Only meaningful when at least one bound is set and the metric includes units that didn't send events.
        Returns:
        winsorIncludeImputed
      • setWinsorIncludeImputed

        public void setWinsorIncludeImputed​(@Nullable
                                            java.lang.Boolean winsorIncludeImputed)
      • traceQuery

        public MetricPost traceQuery​(@Nullable
                                     java.lang.String traceQuery)
      • getTraceQuery

        @Nullable
        public java.lang.String getTraceQuery()
        The trace query to use for the metric. Required for trace metrics.
        Returns:
        traceQuery
      • setTraceQuery

        public void setTraceQuery​(@Nullable
                                  java.lang.String traceQuery)
      • traceValueLocation

        public MetricPost traceValueLocation​(@Nullable
                                             java.lang.String traceValueLocation)
      • getTraceValueLocation

        @Nullable
        public java.lang.String getTraceValueLocation()
        The location in the trace to use for numeric values. Required for numeric trace metrics.
        Returns:
        traceValueLocation
      • setTraceValueLocation

        public void setTraceValueLocation​(@Nullable
                                          java.lang.String traceValueLocation)
      • unitAggregationField

        public MetricPost unitAggregationField​(@Nullable
                                               java.lang.String unitAggregationField)
      • getUnitAggregationField

        @Nullable
        public java.lang.String getUnitAggregationField()
        The warehouse column to use for counting distinct values. Required when the unitAggregationType is count_distinct.
        Returns:
        unitAggregationField
      • setUnitAggregationField

        public void setUnitAggregationField​(@Nullable
                                            java.lang.String unitAggregationField)
      • getDenominator

        @Nullable
        public DenominatorPost getDenominator()
        Get denominator
        Returns:
        denominator
      • setDenominator

        public void setDenominator​(@Nullable
                                   DenominatorPost denominator)
      • putAdditionalProperty

        public MetricPost putAdditionalProperty​(java.lang.String key,
                                                java.lang.Object value)
        Set the additional (undeclared) property with the specified name and value. If the property does not already exist, create it otherwise replace it.
        Parameters:
        key - name of the property
        value - value of the property
        Returns:
        the MetricPost instance itself
      • getAdditionalProperties

        public java.util.Map<java.lang.String,​java.lang.Object> getAdditionalProperties()
        Return the additional (undeclared) property.
        Returns:
        a map of objects
      • getAdditionalProperty

        public java.lang.Object getAdditionalProperty​(java.lang.String key)
        Return the additional (undeclared) property with the specified name.
        Parameters:
        key - name of the property
        Returns:
        an object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

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

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • validateJsonElement

        public static void validateJsonElement​(com.google.gson.JsonElement jsonElement)
                                        throws java.io.IOException
        Validates the JSON Element and throws an exception if issues found
        Parameters:
        jsonElement - JSON Element
        Throws:
        java.io.IOException - if the JSON Element is invalid with respect to MetricPost
      • fromJson

        public static MetricPost fromJson​(java.lang.String jsonString)
                                   throws java.io.IOException
        Create an instance of MetricPost given an JSON string
        Parameters:
        jsonString - JSON string
        Returns:
        An instance of MetricPost
        Throws:
        java.io.IOException - if the JSON string is invalid with respect to MetricPost
      • toJson

        public java.lang.String toJson()
        Convert an instance of MetricPost to an JSON string
        Returns:
        JSON string