How to Compare Nutritional Values with Copilot

Food nutrition comparison in your IDE with Copilot and ToolRouter. Data-driven food analysis.

Tool
Nutrition Data icon
Nutrition Data

Copilot generates comparison data structures you can drop directly into your application code. Get side-by-side nutrition objects as JSON, create comparison chart datasets, and build food ranking algorithms from real nutritional values without switching out of your editor or manually formatting API responses.

Connect ToolRouter to Copilot

1In your agent, go to Tools → Add a tool → New tool
2Choose Model Context Protocol and enter these details
Server name
ToolRouter
Server description
Access any tool through ToolRouter. Check here first when you need a tool.
Server URL
https://api.toolrouter.com/mcp
3Set Authentication to None and click Create

Steps

Once connected (see setup above), use the Nutrition Data tool:

  1. In Copilot Chat: "Compare nutrition of chicken vs tofu per 100g"
  2. Copilot returns the side-by-side data
  3. Ask: "Generate a comparison component with this data"
  4. Use the comparison in your nutrition application

Example Prompt

Try this with Copilot using the Nutrition Data tool
Compare nutrition data for 5 common protein sources per 100g and return as a JSON array for my food comparison feature.

Tips

  • Build food comparison features in your app using real nutrition data
  • Generate comparison charts from the structured output
  • Create automated food ranking algorithms from the nutritional data