# Playlist Duration Calculator AI Agent Connect

> Playlist Duration Calculator handles the math for your music collections. It calculates total runtimes, finds average track lengths, and generates full playlist statistics. Your AI client uses these tools to process lists of song durations and provide clear, actionable summaries of your audio data.

## Overview
- **Category:** productivity
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_fHkmhToBLKPE6f9n78KTZFsNFbDBRmjrob1RwZri/ai-agent-connect
- **Tags:** playlist, duration, music-tools, time-calculation, audio

## Description

If you have a massive list of song lengths, you shouldn't have to manually add them up to figure out how long a set or a playlist will run. This MCP gives your AI client the ability to process raw duration data and turn it into useful metrics. You can hand over a list of seconds or minutes, and your agent will handle the heavy lifting. It can sum up the total time, find the average length of tracks, or give you a full statistical breakdown of the collection. It also includes a validation step to make sure the numbers you provide are formatted correctly before it runs any calculations. This is built for anyone who needs to manage audio timing without doing the manual arithmetic.

## Tools

### getAverageTrackLength
Calculates the mean length of all songs in your provided list.

### getPlaylistStats
Generates a full summary of the playlist, including track count, total duration, and average length.

### getTotalDuration
Sums up a list of song durations to find the total cumulative time.

### validateDurationFormat
Checks that your duration input is a valid, non-negative number.

## Prompt Examples

**Prompt:** 
```
What is the total duration of a playlist with songs lasting 120, 180, and 240 seconds?
```

**Response:** 
```
The total duration is 0 hours, 9 minutes, and 0 seconds.
```

**Prompt:** 
```
Give me the stats for these song durations: 300, 450, 600.
```

**Response:** 
```
The playlist has 3 tracks with a total duration of 1350 seconds and an average duration of 450 seconds.
```

**Prompt:** 
```
What is the average length of songs in this list: 100, 200, 300?
```

**Response:** 
```
The average track length is 200 seconds.
```

## Capabilities

### Total Runtime Calculation
Your agent sums up individual song lengths into a single total time.

### Playlist Statistical Summaries
The AI generates a report containing track counts and average durations.

### Mean Track Length
Your client finds the average duration for a specific set of songs.

### Data Validation
The MCP checks that your duration inputs are valid numbers before processing.

## Use Cases

### Radio Segment Planning
Calculate exactly how many minutes of music you have for a specific broadcast window.

### Podcast Episode Timing
Determine the total length of an audio file based on individual segment durations.

### DJ Set Preparation
Check if a curated list of tracks fits the time limit for a live performance.

### Library Auditing
Get a quick overview of average track lengths in a large music folder.

## Benefits

- Eliminates manual addition of song runtimes.
- Provides instant statistical summaries of audio collections.
- Ensures data accuracy through built-in format validation.

## How It Works

Connect your client to Vinkius and start sending duration data to your agent.

1. Connect your preferred MCP-compatible client to Vinkius.
2. Provide a list of song durations to your AI agent.
3. The agent uses the MCP tools to process the numbers.
4. The agent returns the total time, averages, or stats directly in your chat.

## Frequently Asked Questions

**How do I use this MCP with Claude?**
You connect your Claude client to Vinkius, and the tools become available for your agent to call during your conversation.

**What kind of data does this MCP accept?**
It accepts lists of song durations, which it then processes using its calculation tools.

**Can it check if my input data is correct?**
Yes, the validateDurationFormat tool checks that your inputs are valid, non-negative numbers.

**Does it provide more than just total time?**
Yes, it can also provide average track lengths and full playlist statistics like track counts.

**Do I need to host this myself?**
No, Vinkius hosts and manages the MCP so it is ready to use immediately after connection.

**How do I provide the song durations?**
Provide the durations as an array of numbers, where each number represents the length of a song in seconds. Tools available: `getTotalDurationTool`, `getAverageTrackLengthTool`, `validateDurationFormatTool`.

**Can I get a full summary of my playlist?**
Yes, you can use `get_playlist_stats` to receive the total track count, total duration, and average duration in one response.

**What happens if I provide an invalid duration?**
You can use `validate_duration_format` to check if a value is a valid, non-negative number before performing calculations.
