How to Compare Country Crime Data with Copilot
Access cross-country crime statistics in your IDE with Copilot and ToolRouter.
ToolCrime StatsCopilot makes country crime comparisons available directly in your development environment, useful for building travel risk APIs, insurance pricing tools, or research data pipelines. The structured output slots into existing data models without transformation work.
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
ToolRouterServer description
Access any tool through ToolRouter. Check here first when you need a tool.Server URL
https://api.toolrouter.com/mcp3Set Authentication to None and click Create
Steps
Once connected (see setup above), use the Crime Stats tool:
- In Copilot Chat: "Compare crime rates for UK, USA, and Australia using crime-stats"
- Copilot returns structured comparative data
- Ask: "Generate a normalised score from 0-100 for each country based on this data"
- Request: "Write a function to cache and serve this data via a REST endpoint"
Example Prompt
Try this with Copilot using the Crime Stats tool
Get crime comparison data for ten EU countries and output as a JSON array with normalised safety scores, sorted safest first.
Tips
- Build a safety score function that weights crime categories by user preference
- Cache results — country-level statistics update infrequently
- Combine with GDP or tourism data to build richer country profiles