> ## Documentation Index
> Fetch the complete documentation index at: https://confidence.spotify.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Execute GetMandatoryMetric

> Executes the getMandatoryMetrics function.



## OpenAPI

````yaml /api/experiments/rollout.openapi.json post /v1/workflows/rollout/instances/{instance}:getmandatorymetrics
openapi: 3.1.0
info:
  title: Confidence Rollout API
  version: 1.0.0
  description: API documentation for rollout
servers: []
security: []
paths:
  /v1/workflows/rollout/instances/{instance}:getmandatorymetrics:
    post:
      summary: Execute GetMandatoryMetric
      description: Executes the getMandatoryMetrics function.
      operationId: GetMandatoryMetric.execute
      parameters:
        - name: instance
          in: path
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                parameters:
                  type: object
                  description: Parameters for the function.
        required: true
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  metadata:
                    type: array
                    items:
                      type: object
                      properties:
                        displayName:
                          type: string
                          description: The metric display name
                        metric:
                          type: string
                          description: The metric name
                      required:
                        - metric
                    description: Metadata for the mandatory metrics
                  metrics:
                    type: array
                    items:
                      type: object
                      properties:
                        calculation:
                          type: string
                          description: >-
                            A resource name on the format
                            scheduledMetricCalculations/abc/metricCalculations/def
                        metric:
                          type: string
                          description: A resource name on the format metrics/abc
                        metricRole:
                          type: object
                          properties:
                            metricKind:
                              type: string
                              enum:
                                - METRIC_KIND_UNSPECIFIED
                                - UNKNOWN
                                - SUCCESS
                                - GUARDRAIL
                              description: The metric kind (success)
                            minimumDetectableEffect:
                              type: number
                              description: >-
                                The minimum detectable effect for this success
                                metric
                            nonInferiorityMargin:
                              type: number
                              description: >-
                                The non-inferiority margin for this guardrail
                                metric
                          required:
                            - metricKind
                          description: The metric role (success or guardrail)
                        preferredDirection:
                          type: string
                          enum:
                            - PREFERRED_DIRECTION_UNSPECIFIED
                            - INCREASE
                            - DECREASE
                            - ANY
                          description: The preferred direction for the metric
                        schedule:
                          type: string
                          description: >-
                            A resource name on the format
                            scheduledMetricCalculations/abc
                        surface:
                          type: string
                          description: A resource name on the format surfaces/abc
                        surfaceOnly:
                          type: boolean
                          description: Whether this metric is only from a surface
                      required:
                        - metric
                    description: The list of mandatory metrics
                required:
                  - metadata
                  - metrics
      security:
        - admin: []
      servers:
        - url: https://experiments.confidence.dev
        - url: https://experiments.eu.confidence.dev
        - url: https://experiments.us.confidence.dev
components:
  securitySchemes:
    admin:
      type: http
      scheme: bearer

````