Discover/Marksandspencer API
live

Marksandspencer APImarksandspencer.com

Access M&S UK food products, nutrition info, ingredients, allergens, and category listings via 4 structured endpoints.

Endpoint health
verified 3d ago
search_food_products
get_food_catalogue_categories
get_product_details
get_category_products
4/4 passing latest checkself-healing
Endpoints
4
Updated
26d ago

What is the Marksandspencer API?

The Marks & Spencer Food Catalogue API covers 4 endpoints that expose M&S UK food product data including category navigation, product listings, keyword search, and full product details. The get_product_details endpoint returns nutrition tables, ingredients, allergen information, storage instructions, and product images for any individual item. Category and search responses include product weight, brand, labels, and SEO URLs used to drill into product-level detail.

Try it

No input parameters required.

api.parse.bot/scraper/f50bd5ad-301e-4278-8cf4-a5ef67ba5897/<endpoint>
Ready to send
Fill in the parameters and hit sign in to send to see live response data here.
Call it over HTTPgrab a free API key at signup
curl -X GET 'https://api.parse.bot/scraper/f50bd5ad-301e-4278-8cf4-a5ef67ba5897/get_food_catalogue_categories' \
  -H 'X-API-Key: $PARSE_API_KEY'
Python SDK · recommended

Typed, relational, agent-ready

A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.

  • Fully typed · autocompletes
  • Objects link to objects
  • Typed errors & pagination

Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:

uv add parse-sdk
uv run parse init
uv run parse add --marketplace marksandspencer-com-api

uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.

from parse_apis.marks_spencer_food_api import MarksAndSpencer, CategorySlug, Category, ProductSummary, Product

ms = MarksAndSpencer()

# Browse products in a specific category using the enum
dairy = ms.category(CategorySlug.DAIRY)
for product in dairy.products(limit=5):
    print(product.title, product.weight, product.brand)

# Search for products by keyword
for item in ms.productsummaries.search(query="chocolate", limit=3):
    print(item.title, item.weight, item.seo_url)
    # Navigate to full product details
    detail = item.details()
    print(detail.product_name, detail.description, detail.storage)
    print(detail.nutrition.categories, detail.nutrition.values)
    for img in detail.images:
        print(img.asset_id, img.type)

# List all categories
for category in ms.categories.list():
    print(category.name, category.slug)
All endpoints · 4 totalmissing one? ·

Get the top-level food categories from the M&S food catalogue. Returns category names, URLs, and URL slugs that can be used with get_category_products to browse products within each category.

Input

No input parameters required.

Response
{
  "type": "object",
  "fields": {
    "categories": "array of category objects with name, url, and slug"
  },
  "sample": {
    "data": {
      "categories": [
        {
          "url": "https://www.marksandspencer.com/food/l/fruit-and-vegetables",
          "name": "Fruit & Vegetables",
          "slug": "fruit-and-vegetables"
        },
        {
          "url": "https://www.marksandspencer.com/food/l/meat",
          "name": "Meat",
          "slug": "meat"
        },
        {
          "url": "https://www.marksandspencer.com/food/l/dairy",
          "name": "Dairy",
          "slug": "dairy"
        }
      ]
    },
    "status": "success"
  }
}

About the Marksandspencer API

Category Navigation and Product Listings

The get_food_catalogue_categories endpoint returns the top-level food category tree — each entry includes a name, url, and slug. Those slugs feed directly into get_category_products, which accepts a required category_slug plus optional subcategory_slug and sub_subcategory_slug parameters to navigate up to three levels of hierarchy (for example, fruit-and-vegetablesfresh-fruitberries-and-cherries). The listing response includes products, subcategories, filters, total_items, total_pages, and current_page for full pagination control.

Search and Product Discovery

search_food_products accepts a query string (e.g. 'milk', 'chocolate cake') and an optional page integer. Results mirror the listing shape: an array of product objects each carrying id, title, weight, brand, labels, seoUrl, and imageUrl. The search_term field in the response echoes back the query used, which is useful when logging or caching results.

Full Product Detail

get_product_details takes a product_id (the numeric segment from the seoUrl after fdp) and a product_slug. It returns the deepest data available: a nutrition object with a categories array and a values array, an ingredients string, a storage string, breadcrumbs for category context, labels such as 'Eat Well' or 'New In', and an images array. The ingredients field may be empty for unprocessed fresh produce where M&S does not publish ingredient declarations.

Reliability & maintenanceVerified

The Marksandspencer API is a managed, monitored endpoint for marksandspencer.com — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when marksandspencer.com changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.

This isn't an official marksandspencer.com API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.

Last verified
3d ago
Latest check
4/4 endpoints passing
Maintenance
Monitored & self-healing
Will this API break when the source site changes?+
It's built not to. Every endpoint is health-checked on a schedule with automated test probes. When the source site changes and a check fails, the API is automatically queued for repair and re-verified — that's the self-healing layer. Each API page shows when its endpoints were last verified. And because marketplace APIs are shared, any fix reaches everyone using it.
Is this an official API from the source site?+
No — Parse APIs are independent, managed REST wrappers over publicly available data. That is the point: where a site has no official API (or only a limited one), Parse gives you a maintained, monitored endpoint for that data and keeps it working as the site changes — so you get a stable contract over a source that never promised one.
Can I fix or extend this API myself if I need a new endpoint or field?+
Yes — and you don't have to wait on us. This API was generated by the Parse agent, which stays attached. Describe the change in plain English ("add an endpoint that returns reviews", "fix the price field") in the revise box on the API page or via the revise_api MCP tool, and the agent rebuilds it against the live site in minutes. Contributing the change back to the public API is free.
What happens if I call an endpoint that has an issue?+
Errors are machine-readable: a bad call returns a clean status with the list of available endpoints and a repair hint, so an agent (or you) can recover or trigger a fix instead of failing silently. Confirmed failures feed the automatic repair queue.
Common use cases
  • Build a grocery comparison tool using weight, brand, and nutrition data from get_product_details.
  • Aggregate allergen and ingredient data across the M&S food range for dietary filtering apps.
  • Crawl the full product catalogue hierarchically using get_food_catalogue_categories then get_category_products subcategory slugs.
  • Power a meal-planning feature that displays calorie and macro data from the nutrition response field.
  • Monitor product label changes (e.g. 'New In', 'Eat Well') across categories for market trend tracking.
  • Index M&S food product images and descriptions for a visual search or product catalog application.
  • Search for specific products by keyword with search_food_products and surface results with pricing context from a parallel data source.
Pricing & limitsSee full pricing →
TierPriceCredits/monthRate limit
Free$0/mo1005 req/min
Hobby$30/mo1,00020 req/min
Developer$100/mo5,000100 req/min

One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.

Frequently asked questions
Does Marks & Spencer have an official public developer API?+
Marks & Spencer does not publish a public developer API for its food catalogue. This Parse API provides structured access to the product, nutrition, and category data available on marksandspencer.com.
What does `get_product_details` return beyond basic product info?+
It returns a nutrition object (with categories and values arrays), an ingredients string, storage instructions, labels, breadcrumbs, and an images array. The ingredients field may be empty for fresh unprocessed items where M&S does not publish an ingredients declaration.
Does the API cover customer reviews or star ratings for M&S food products?+
Not currently. The API covers product listings, nutrition, ingredients, allergens, storage, labels, and images. You can fork it on Parse and revise to add an endpoint targeting product review data.
Does the API return pricing for M&S food products?+
Not currently. The product objects returned by get_category_products and search_food_products include title, weight, brand, labels, and imageUrl, but not price fields. You can fork the API on Parse and revise it to add a pricing field to the product detail endpoint.
How does pagination work across endpoints?+
Both get_category_products and search_food_products accept an optional page integer. Responses include current_page, total_pages, and total_items, so you can iterate through the full result set programmatically. get_food_catalogue_categories and get_product_details are single-response endpoints with no pagination.
Page content last updated . Spec covers 4 endpoints from marksandspencer.com.
Related APIs in Food DiningSee all →
sainsburys.co.uk API
Access Sainsbury's grocery catalogue: search products by keyword, browse the full category hierarchy, retrieve detailed product information, and discover trending searches.
tesco.com API
Search and browse Tesco's complete grocery catalog to find products with detailed nutritional information, ingredient lists, and customer reviews. Explore product suggestions via autocomplete and browse items organized by category to make informed shopping decisions.
morrisons.com API
Search and browse Morrisons grocery products, view detailed information like reviews and pricing, discover active promotions, and get personalized product recommendations. Find exactly what you're looking for with category browsing, search suggestions, and similar product recommendations.
ocado.com API
Search and browse Ocado UK's grocery catalog, view detailed product information including nutritional data, and discover related items to add to your cart. Get instant search suggestions and manage your shopping cart contents all in one place.
woolworths.co.za API
Browse Woolworths South Africa's food categories and search for specific products while accessing detailed nutritional information and weight-based pricing. Find store locations across the country by province and suburb to check availability and plan your shopping trips.
migros.com.tr API
Search and browse Migros supermarket products by category, view detailed product information including pricing, and discover current discounts and promotional campaigns. Easily find specific items and explore what's on sale at Migros.com.tr.
asda.com API
Access data from asda.com.
mango.com API
Access Mango's complete product catalog, including categories, detailed product information, search functionality, and new arrivals to discover and browse clothing and fashion items. Find similar products and explore the full range of Mango's store inventory programmatically.