USDA Agricultural Research Service (ARS) Foods API

Retrieve food records by FDC ID

Operations 5

GET /food/{fdcId} Get Food by FDC ID #
GET /foods Get Multiple Foods by FDC IDs #
POST /foods Get Multiple Foods by FDC IDs (POST) #
GET /foods/list List Foods (Paginated Abridged Format) #
POST /foods/list List Foods (POST) #

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/usda-agricultural-research-service-ars--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

usda-agricultural-research-service-ars--foods-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: USDA FoodData Central Foods API
  description: The USDA FoodData Central (FDC) API provides access to an integrated data system with extended nutritional and food component data. Data types include Foundation Foods, SR Legacy, Survey Foods (FNDDS), Branded Foods, and Experimental Foods. Requires a free data.gov API key.
  version: '1.0'
  contact:
    name: USDA National Agricultural Library - FoodData Central
    url: https://fdc.nal.usda.gov/api-guide/
  license:
    name: CC0 1.0 Universal
    url: https://creativecommons.org/publicdomain/zero/1.0/
servers:
- url: https://api.nal.usda.gov/fdc/v1
security:
- ApiKeyQuery: []
tags:
- name: Foods
  description: Retrieve food records by FDC ID
paths:
  /food/{fdcId}:
    get:
      tags:
      - Foods
      operationId: getFood
      summary: Get Food by FDC ID
      description: Retrieves detailed nutritional data for a single food identified by its FoodData Central ID (fdcId).
      parameters:
      - name: fdcId
        in: path
        required: true
        description: The unique FoodData Central ID
        schema:
          type: integer
        example: 534358
      - name: format
        in: query
        description: Optional format. Default is abridged; 'full' returns all nutrient data for the food.
        schema:
          type: string
          enum:
          - abridged
          - full
          default: abridged
      - name: nutrients
        in: query
        description: Optional list of nutrient numbers to return
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: api_key
        in: query
        description: Your data.gov API key (can also be passed as X-Api-Key header)
        schema:
          type: string
      responses:
        '200':
          description: Food details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FoodItem'
        '404':
          description: Food not found
        '429':
          description: Rate limit exceeded
  /foods:
    get:
      tags:
      - Foods
      operationId: getFoodsGet
      summary: Get Multiple Foods by FDC IDs
      description: Retrieves details for multiple foods specified by FDC IDs.
      parameters:
      - name: fdcIds
        in: query
        required: true
        description: List of FDC IDs (comma-separated, max 20)
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: format
        in: query
        schema:
          type: string
          enum:
          - abridged
          - full
      - name: nutrients
        in: query
        schema:
          type: array
          items:
            type: integer
        style: form
        explode: false
      - name: api_key
        in: query
        schema:
          type: string
      responses:
        '200':
          description: List of food items
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/FoodItem'
    post:
      tags:
      - Foods
      operationId: getFoodsPost
      summary: Get Multiple Foods by FDC IDs (POST)
      description: Retrieves details for multiple foods. POST variant allows larger ID lists.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                fdcIds:
                  type: array
                  items:
                    type: integer
                  description: List of FDC IDs (max 20)
                format:
                  type: string
                  enum:
                  - abridged
                  - full
                nutrients:
                  type: array
                  items:
                    type: integer
      responses:
        '200':
          description: List of food items
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/FoodItem'
  /foods/list:
    get:
      tags:
      - Foods
      operationId: getFoodsListGet
      summary: List Foods (Paginated Abridged Format)
      description: Returns a paginated list of foods in abridged format.
      parameters:
      - name: dataType
        in: query
        description: Filter by data type
        schema:
          type: array
          items:
            type: string
            enum:
            - Foundation
            - Branded
            - Survey (FNDDS)
            - SR Legacy
            - Experimental
        style: form
        explode: false
      - name: pageSize
        in: query
        description: Number of results per page (max 200)
        schema:
          type: integer
          default: 50
          maximum: 200
      - name: pageNumber
        in: query
        description: Page number for pagination
        schema:
          type: integer
          default: 1
      - name: sortBy
        in: query
        description: Sort field
        schema:
          type: string
          enum:
          - dataType.keyword
          - lowercaseDescription.keyword
          - fdcId
          - publishedDate
      - name: sortOrder
        in: query
        schema:
          type: string
          enum:
          - asc
          - desc
      - name: api_key
        in: query
        schema:
          type: string
      responses:
        '200':
          description: Paginated list of foods
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AbridgedFoodItem'
    post:
      tags:
      - Foods
      operationId: getFoodsListPost
      summary: List Foods (POST)
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                dataType:
                  type: array
                  items:
                    type: string
                pageSize:
                  type: integer
                  default: 50
                pageNumber:
                  type: integer
                  default: 1
                sortBy:
                  type: string
                sortOrder:
                  type: string
      responses:
        '200':
          description: Paginated list of foods
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AbridgedFoodItem'
components:
  schemas:
    AbridgedFoodNutrient:
      type: object
      properties:
        nutrientId:
          type: integer
        nutrientName:
          type: string
        nutrientNumber:
          type: string
        unitName:
          type: string
        value:
          type: number
    AbridgedFoodItem:
      type: object
      description: Abridged food record
      properties:
        fdcId:
          type: integer
        description:
          type: string
        dataType:
          type: string
        publishedDate:
          type: string
          format: date
        brandOwner:
          type:
          - string
          - 'null'
        foodNutrients:
          type: array
          items:
            $ref: '#/components/schemas/AbridgedFoodNutrient'
    FoodItem:
      type: object
      description: Detailed food record with nutrients
      properties:
        fdcId:
          type: integer
          description: FoodData Central ID
        description:
          type: string
          description: Food description/name
        dataType:
          type: string
          enum:
          - Foundation
          - Branded
          - Survey (FNDDS)
          - SR Legacy
          - Experimental
        publishedDate:
          type: string
          format: date
        foodNutrients:
          type: array
          items:
            $ref: '#/components/schemas/FoodNutrient'
        foodCategory:
          type:
          - string
          - 'null'
        brandOwner:
          type:
          - string
          - 'null'
          description: Brand owner (Branded Foods only)
        ingredients:
          type:
          - string
          - 'null'
          description: Ingredient list (Branded Foods only)
        servingSize:
          type:
          - number
          - 'null'
        servingSizeUnit:
          type:
          - string
          - 'null'
        modifiedDate:
          type: string
          format: date
    FoodNutrient:
      type: object
      description: Nutrient data for a food
      properties:
        nutrientId:
          type: integer
        nutrientName:
          type: string
        nutrientNumber:
          type: string
        unitName:
          type: string
          description: Measurement unit (g, mg, kcal, IU, etc.)
        value:
          type: number
          description: Nutrient amount per 100g
        derivationCode:
          type: string
        derivationDescription:
          type: string
  securitySchemes:
    ApiKeyQuery:
      type: apiKey
      in: query
      name: api_key
      description: data.gov API key. Register at https://api.data.gov/signup/
    ApiKeyHeader:
      type: apiKey
      in: header
      name: X-Api-Key