Skip to main content
Glama
wegitor
by wegitor

get_items_in_time_range

Retrieve all media items on a track within a specified time range. Returns both a positional index and a permanent ID for reliable item tracking.

Instructions

Get all items on a track within a time range.

Returns items with BOTH identification methods for each item:

  1. track_pos_idx (integer):

    • Simple sequential index: 0, 1, 2, 3...

    • Easy to use in loops and quick operations

    • Changes if items before it are deleted

  2. direct_item_id (string):

    • REAPER's permanent internal ID like "MediaItem*0x..."

    • Unique stable reference that never changes

    • Use this for reliable long-term item tracking

You can use either one in subsequent operations like add_midi_note.

Args: track_index: 0-based track index (0 = first track, 1 = second, etc.) start_time: Start position in seconds (optional if start_measure is provided) end_time: End position in seconds (optional if end_measure is provided) start_measure: Start position as "measure:beat,fraction" (optional if start_time is provided) end_measure: End position as "measure:beat,fraction" (optional if end_time is provided)

Returns: Each item includes: - track_pos_idx: Integer position index (0, 1, 2...) - direct_item_id: String internal ID ("MediaItem*...") - position: Item start time in seconds - length: Item duration in seconds

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
end_timeNo
start_timeNo
end_measureNo
track_indexYes
start_measureNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full disclosure burden. It provides valuable behavioral detail about the two identification methods (track_pos_idx vs. direct_item_id) and their stability characteristics. However, it does not disclose edge-case behaviors such as boundary inclusivity or what happens when no time range is provided.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with clear sections for the main action, ID semantics, arguments, and returns. Every sentence adds value, and the bulleted explanation of ID methods is concise yet informative.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers return format, parameter meanings, and usage guidance effectively. However, it omits some edge-case behavior (e.g., overlap vs. containment, missing range) that an agent might need to know for unambiguous invocation. Overall, it is fairly complete for a read-only tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It fully documents all five parameters, including the measure string format 'measure:beat,fraction' and the optionality relationships between time and measure arguments. This adds essential meaning beyond the raw schema types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states 'Get all items on a track within a time range' with a specific verb and resource scope. It clearly differentiates from sibling tools like get_selected_items or get_item_properties by specifying the track and time-range filtering.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains that returned IDs can be used in subsequent operations like add_midi_note, giving a concrete use case. However, it does not explicitly mention alternatives or when not to use this tool, though the context is strong enough to guide an agent.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/wegitor/reaper-reapy-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server