Interface CreateMetricRequest.Builder

  • Method Details

    • appId

      The ID of the app the metric belongs to.

      Parameters:
      appId - The ID of the app the metric belongs to.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • name

      A human-readable display name for the metric (for example, Riddles Solved).

      Parameters:
      name - A human-readable display name for the metric (for example, Riddles Solved).
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • description

      CreateMetricRequest.Builder description(String description)

      A description of what the metric measures.

      Parameters:
      description - A description of what the metric measures.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • eventType

      CreateMetricRequest.Builder eventType(String eventType)

      The event type this metric aggregates. Must match the eventType sent on PutEvent.

      Parameters:
      eventType - The event type this metric aggregates. Must match the eventType sent on PutEvent.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • unitName

      CreateMetricRequest.Builder unitName(String unitName)

      The unit of measure for the metric (for example, "requests" or "tokens").

      Parameters:
      unitName - The unit of measure for the metric (for example, "requests" or "tokens").
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • definition

      The aggregation definition: filters, aggregation function, grouping, and period.

      Parameters:
      definition - The aggregation definition: filters, aggregation function, grouping, and period.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • definition

      The aggregation definition: filters, aggregation function, grouping, and period.

      This is a convenience method that creates an instance of the MetricDefinition.Builder avoiding the need to create one manually via MetricDefinition.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to definition(MetricDefinition).

      Parameters:
      definition - a consumer that will call methods on MetricDefinition.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • clientToken

      CreateMetricRequest.Builder clientToken(String clientToken)

      A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, the service ignores the request but does not return an error.

      Parameters:
      clientToken - A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, the service ignores the request but does not return an error.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • tags

      Optional tags to add to the metric when it is created. Tagging on create also requires permission for appmonetization:TagResource.

      Parameters:
      tags - Optional tags to add to the metric when it is created. Tagging on create also requires permission for appmonetization:TagResource.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • overrideConfiguration

      CreateMetricRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration)
      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      overrideConfiguration - The override configuration.
      Returns:
      This object for method chaining.
    • overrideConfiguration

      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      builderConsumer - A Consumer to which an empty AwsRequestOverrideConfiguration.Builder will be given.
      Returns:
      This object for method chaining.