list_foods
Pack: usda-fdc · Endpoint: https://gateway.pipeworx.io/usda-fdc/mcp
Paginated browse of FDC foods.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
data_type | string | no | Filter to data type(s). Options: ${DATA_TYPES} |
page_size | number | no | 1-200 (default 50) |
page_number | number | no | 1-based page |
sort_by | string | no | |
sort_order | string | no |
Example call
Arguments
{
"data_type": "Survey (FNDDS)",
"page_number": 1,
"page_size": 50
}
curl
curl -X POST https://gateway.pipeworx.io/usda-fdc/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"list_foods","arguments":{"data_type":"Survey (FNDDS)","page_number":1,"page_size":50}}}'
TypeScript (@pipeworx/sdk)
import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();
const result = await pipeworx.call('list_foods', {
"data_type": "Survey (FNDDS)",
"page_number": 1,
"page_size": 50
});
More examples
{
"page_number": 2,
"page_size": 100,
"sort_by": "publishedDate",
"sort_order": "desc"
}
Response shape
| Field | Type | Description |
|---|---|---|
foods | array | Array of food items |
pageNumber | number | Current page number |
pageSize | number | Number of items per page |
Full JSON Schema
{
"type": "object",
"description": "Paginated list of FDC foods",
"properties": {
"foods": {
"type": "array",
"description": "Array of food items",
"items": {
"type": "object",
"properties": {
"fdcId": {
"type": "number",
"description": "FDC food identifier"
},
"description": {
"type": "string",
"description": "Food description"
},
"dataType": {
"type": "string",
"description": "Type of food data"
},
"publishedDate": {
"type": "string",
"description": "Date food was published"
}
}
}
},
"pageNumber": {
"type": "number",
"description": "Current page number"
},
"pageSize": {
"type": "number",
"description": "Number of items per page"
}
}
}
Connect
Add this to your MCP client config, or use one-click install buttons:
{
"mcpServers": {
"usda-fdc": {
"url": "https://gateway.pipeworx.io/usda-fdc/mcp"
}
}
}
See Getting Started for client-specific install steps.