---
title: "Ratings"
url: "https://developer.migros.ch/apis/ratings-8/versions/47f7210f-ae8e-42fc-b41c-393bebe224ae"
---

# Ratings

OpenAPI specification document.

```json
{"components":{"parameters":{"Accept-Language":{"description":"Defines the language (de/fr/it/en) for this request as request header. Either use the query param \"lang\" or header \"Accept-Language\", not both.","in":"header","name":"Accept-Language","schema":{"default":"de","enum":["de","fr","it","en"],"type":"string"}},"lang":{"description":"Defines the language (de/fr/it/en) for this request as query parameter. Either use the query param \"lang\" or header \"Accept-Language\", not both.","in":"query","name":"lang","schema":{"default":"de","enum":["de","fr","it","en"],"type":"string"}}},"responses":{},"schemas":{"AbstractCollection":{"description":"A generic collection of elements."},"RatingSummary":{"description":"Aggregation with count and average of ratings for a given object.\n\nThis model is used to save ratings in the database and to display ratings of items (product, etc.) in the API.","properties":{"average":{"format":"float","type":"number"},"count":{"type":"integer"},"item_id":{"type":"string"},"modified":{"description":"Last modified date.","format":"date-time","type":"string"},"type":{"description":"Average rating on the given item.","type":"string"}},"required":["itemId","type"],"type":"object"},"RatingSummaryCollection":{"allOf":[{"$ref":"#/components/schemas/AbstractCollection"},{"properties":{"rating_summaries":{"items":{"$ref":"#/components/schemas/RatingSummary"},"type":"array"}},"type":"object"}],"description":"A collection rating summaries.","required":["rating_summaries"],"type":"object"}},"securitySchemes":{"Kong-Api-Key":{"description":"Kong key-auth authentication","in":"header","name":"X-Api-Key","type":"apiKey"},"basicAuth":{"scheme":"basic","type":"http"}}},"info":{"contact":{"email":"arg_mgb-udp-products-services@mgb.ch","name":"MGB-UDP-Products-Services"},"description":"Fetch rating information. <a href=\"https://wiki.migros.net/display/MAPI/Ratings\">See Wiki</a>","title":"Ratings","version":"8"},"openapi":"3.0.0","paths":{"/migros/products/v8/ratings/{type}/items":{"get":{"description":"Returns the aggregated rating summaries for multiple items of a given type.\n\nSimilar to <code>/ratings/{type}/{item_id}</code> but supports fetching multiple item ratings in a single request.","operationId":"get-rating-items-by-type","parameters":[{"description":"Type of the item","in":"path","name":"type","required":true,"schema":{"type":"string"}},{"description":"Comma separated list of item IDs you want the ratings from","in":"query","name":"item_ids","required":false,"schema":{"type":"string"}},{"$ref":"#/components/parameters/lang"},{"$ref":"#/components/parameters/Accept-Language"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RatingSummaryCollection"}}},"description":"Returned when successful"}},"summary":"List all aggregated ratings of a given type","tags":["Ratings"]}},"/migros/products/v8/ratings/{type}/{item_id}":{"get":{"description":"Returns the aggregated rating for a single item.\n\nAn item is composed composed of a type and an ID.","operationId":"get-rating","parameters":[{"description":"Type of the item, e.g. PRODUCT or MIGROS_SERVICE_PRODUCT","in":"path","name":"type","required":true,"schema":{"type":"string"}},{"description":"ID of the item","in":"path","name":"item_id","required":true,"schema":{"pattern":"^(?!items)[^/\\.]+$","type":"string"}},{"$ref":"#/components/parameters/lang"},{"$ref":"#/components/parameters/Accept-Language"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RatingSummary"}}},"description":"Returned when successful"}},"summary":"Get the aggregated rating for a single item","tags":["Ratings"]}}},"security":[{"Kong-Api-Key":[],"basicAuth":[]}],"servers":[{"description":"Public Kong Gateway URL","url":"https://api.migros.ch"}],"tags":[{"name":"Ratings"},{"name":"mapi"}],"x-active-from":"01-01-2024","x-company":"migros","x-edm-domain":"products","x-eol":"31-12-2049","x-headmatter":{"readable_by":"*"},"x-kong-route-defaults":{"protocols":["https"],"strip_path":false},"x-kong-service-defaults":{"connect_timeout":5000,"read_timeout":15000,"retries":1,"write_timeout":5000},"x-leanix-id":"350641a5-55a2-4641-8332-76d32846eb56","x-link-get-access":"https://forms.office.com/e/zhzbEqAQ26","x-link-get-support":"https://teams.microsoft.com/l/channel/19%3Aa7851e50d0194268ba0c7a0d7a63403b%40thread.tacv2/2.%20Support%20%F0%9F%92%A1?groupId=58b919a5-7d36-47f3-a77a-03cfd051098a&tenantId=35aa8c5b-ac0a-4b15-9788-ff6dfa22901f"}
```
