fatsecret Foods API

Search and retrieve food nutrition data

Operations 4

GET /foods/search/v5 Search foods #
GET /foods/autocomplete/v2 Autocomplete food search #
GET /food/barcode/find-by-id/v1 Find food by barcode #
GET /food/v4 Get food by id #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/fatsecret-foods-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

fatsecret-foods-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: fatsecret Foods API
  description: The fatsecret Platform API provides programmatic access to a global food nutrition database covering more than 1.9 million verified food items across 56 countries. It supports food and recipe search, barcode scanning, image recognition, natural language processing, and full profile-based food diary, exercise diary, and weight tracking management.
  version: '3.0'
  contact:
    name: fatsecret Platform
    url: https://platform.fatsecret.com/platform-api
servers:
- url: https://platform.fatsecret.com/rest
  description: REST endpoint for URL-based and method-based integration
security:
- oauth2: []
- oauth1: []
tags:
- name: Foods
  description: Search and retrieve food nutrition data
paths:
  /foods/search/v5:
    get:
      tags:
      - Foods
      summary: Search foods
      description: Search the fatsecret food database for foods matching a query string.
      operationId: searchFoods
      parameters:
      - name: search_expression
        in: query
        required: true
        schema:
          type: string
      - name: page_number
        in: query
        schema:
          type: integer
          default: 0
      - name: max_results
        in: query
        schema:
          type: integer
          default: 20
      responses:
        '200':
          description: Matching foods
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FoodSearchResults'
  /foods/autocomplete/v2:
    get:
      tags:
      - Foods
      summary: Autocomplete food search
      operationId: autocompleteFoods
      parameters:
      - name: expression
        in: query
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Suggestions
  /food/barcode/find-by-id/v1:
    get:
      tags:
      - Foods
      summary: Find food by barcode
      operationId: findFoodByBarcode
      parameters:
      - name: barcode
        in: query
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Matching food
  /food/v4:
    get:
      tags:
      - Foods
      summary: Get food by id
      operationId: getFood
      parameters:
      - name: food_id
        in: query
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Food details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Food'
components:
  schemas:
    Food:
      type: object
      properties:
        food_id:
          type: string
        food_name:
          type: string
        brand_name:
          type: string
        food_type:
          type: string
          enum:
          - Generic
          - Brand
        food_url:
          type: string
          format: uri
        servings:
          type: object
    FoodSearchResults:
      type: object
      properties:
        foods:
          type: object
          properties:
            food:
              type: array
              items:
                $ref: '#/components/schemas/Food'
            max_results:
              type: integer
            page_number:
              type: integer
            total_results:
              type: integer
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://oauth.fatsecret.com/connect/token
          scopes:
            basic: Basic access to food and recipe data
            premier: Premier access including image recognition and NLP
    oauth1:
      type: http
      scheme: oauth
      description: OAuth 1.0a request signing