---
title: ToolRouter — Agent Use Case Guide
description: Step-by-step guide for completing a task with a specific AI agent using ToolRouter.
url: https://toolrouter.com/tools/currency-exchange/use-cases/calculate-cross-border-costs/copilot
---
# How to Calculate Cross-Border Costs with Copilot

Copilot calculates cross-border costs and helps you build payment optimization tools. Fetch market rates, generate cost calculation functions with configurable spread and fee parameters, and create comparison logic showing users the true cost of international transfers in your payment platform.

## Setup

{"mcpServers":{"toolrouter":{"command":"npx","args":["-y","toolrouter-mcp"]}}}

## Steps

1. Add ToolRouter to Copilot MCP config
2. In Copilot Chat: "Convert $10,000 to EUR and show the market rate"
3. Copilot returns the conversion details
4. Ask: "Generate a cost calculation function that adds a configurable FX spread"
5. Use the logic in your international payment system

## Example Prompt

```
Convert $10,000 to EUR and generate a TypeScript function that calculates cross-border payment cost with configurable spread and wire fee parameters.
```

## Tips

- Build cross-border cost calculators with real market rate data
- Copilot can generate the pricing comparison logic for payment providers
- Use for building international payment cost transparency features
