---
title: "Nutrient"
url: "https://developer-qual.migros.ch/apis/products-related-8/versions/051741b6-0319-4b5e-b1f1-6bdbc778acb6/schemas/Nutrient"
---

> Full API specification: https://developer-qual.migros.ch/apis/products-related-8/versions/051741b6-0319-4b5e-b1f1-6bdbc778acb6.md

# Nutrient

Represents an entry in the nutrition facts.

## OpenAPI definition

```yaml
openapi: 3.0.0
info:
  title: Products Related
  version: "8"
servers:
  - description: Public Kong Gateway URL
    url: https://api-qual.migros.ch
components:
  schemas:
    NutrientQuantity:
      properties:
        alternate:
          description: Alternate quantity information.
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/ValueWithUnit"
        numeric_value:
          example: 0.1
          format: float
          type: number
        unit:
          example: g
          nullable: true
          type: string
        value:
          description: >-
            Quantity of the nutrient.


            To display the information, "value" is preferred to respect the
            regulated precision.
          example: 0.10 g
          type: string
      type: object
    NutrientRating:
      description: Nutrition guidance about a nutrient.
      properties:
        hex_color:
          description: The hexadecimal color code for this rating that is also used in the
            icon.
          nullable: true
          type: string
        icon:
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/Image"
        text:
          type: string
        value:
          description: The icon
          type: integer
      required:
        - value
        - text
        - hex_color
      type: object
    NutrientRda:
      description: Represents an entry in the nutrition facts.
      properties:
        operator:
          description: Recommended daily allowance operator.
          nullable: true
          type: string
        percent:
          description: Recommended daily allowance in percent.
          format: float
          type: number
        quantity:
          description: Quantity information.
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/ValueWithUnit"
      required:
        - percent
      type: object
    ValueWithUnit:
      properties:
        numeric_value:
          description: Value as number for calculation or custom display.
          format: float
          nullable: true
          type: number
        unit:
          description: Unit of the value.
          nullable: true
          type: string
        value:
          description: Value as a string for display.
          nullable: true
          type: string
      type: object
    Image:
      description: An image and its properties.
      properties:
        code:
          deprecated: true
          description: Code for the image, useful for pictograms.
          nullable: true
          type: string
        custom:
          deprecated: true
          description: Image URL with placeholders for {width} and {height}.
          type: string
        description:
          deprecated: true
          description: Image description, useful for example as alt attribute.
          nullable: true
          type: string
        end_date:
          deprecated: true
          description: End date of the validity.
          format: date-time
          nullable: true
          type: string
        hash:
          deprecated: true
          description: Sha1 hash of original image.
          nullable: true
          type: string
        original:
          deprecated: true
          description: Full size image.
          type: string
        source:
          deprecated: true
          description: Source where the image comes from originally.
          nullable: true
          type: string
        stack:
          deprecated: true
          description: Image URL with a placeholder for a Rokka {stack}.
          type: string
        start_date:
          deprecated: true
          description: Start date of the validity.
          format: date-time
          nullable: true
          type: string
        tags:
          deprecated: true
          items:
            type: string
          type: array
      type: object
    Nutrient:
      description: Represents an entry in the nutrition facts.
      properties:
        category:
          description: |-
            Category of nutrient.

            Examples: "BIG9", "MINERALSTOFFE_SPURENELEMENTE" or "SONSTIGE"
          nullable: true
          type: string
        code:
          description: |-
            The MAPI nutrient code.

            See https://wiki.migros.net/spaces/MAPI/pages/355021332/Order+nutrition+facts for a full list of the codes and further documentation.
          type: string
        name:
          type: string
        operator:
          nullable: true
          type: string
        pictogram_name:
          description: Name of nutrient for display in the pictogram.
          nullable: true
          type: string
        quantity:
          description: Quantity information.
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/NutrientQuantity"
        rating:
          description: >-
            FSA rating information for this nutrient.


            This is only set on the "standard" nutrition facts (not "portion")
            and only for selected nutrients, e.g. sugar, salt, fat.
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/NutrientRating"
        rda:
          description: Information about Recommended Dietary Allowances (RDA).
          nullable: true
          oneOf:
            - $ref: "#/components/schemas/NutrientRda"
        source_code:
          description: |-
            Code from source system.

            Used for legacy version output and debugging.
          nullable: true
          type: string
      required:
        - code
        - name
      type: object
```
