---
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/image-ops/use-cases/batch-resize-images/copilot
---
# How to Batch Resize Images with Copilot

Copilot integrates image resizing directly into your development workflow. Resize assets for your web application without leaving the IDE, and Copilot can help write build scripts, responsive image components, or pre-commit hooks that enforce size standards automatically as part of your development pipeline.

## Setup

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

## Steps

1. Add ToolRouter to your Copilot MCP configuration
2. In Copilot Chat: "Resize this image to 400x300 for our card component"
3. Review the resized output
4. Ask Copilot to write a script for batch resizing all images in a directory
5. Integrate image resizing into your build pipeline

## Example Prompt

```
Resize all images in our /assets folder to 2x and 1x versions for responsive design.
```

## Tips

- Copilot can generate build scripts that resize images during deployment
- Great for creating responsive image variants for your web application
- Automate image resizing as a pre-commit hook or CI step
