duplicate_time_range
Copy and paste audio or MIDI items within a specified time range to repeat sections in REAPER projects. Use this tool to extend song forms by duplicating choruses, verses, or outros multiple times.
Instructions
Copy all items overlapping [start_time, end_time) and paste them immediately after end_time, repeating repeat_count times. Useful for extending song form (repeating a chorus, creating an outro).
start_time / end_time: seconds
repeat_count: how many copies to paste (default 1) Returns the new project end time after pasting.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| start_time | Yes | ||
| end_time | Yes | ||
| repeat_count | No |
Implementation Reference
- src/reaper_mcp/server.py:886-908 (handler)The tool 'duplicate_time_range' is registered as an MCP tool and calls the adapter method.
def duplicate_time_range( start_time: float, end_time: float, repeat_count: int = 1, ) -> dict[str, Any]: """ Copy all items overlapping [start_time, end_time) and paste them immediately after end_time, repeating repeat_count times. Useful for extending song form (repeating a chorus, creating an outro). - start_time / end_time: seconds - repeat_count: how many copies to paste (default 1) Returns the new project end time after pasting. """ try: return _wrap( adapter.duplicate_time_range( start_time=start_time, end_time=end_time, repeat_count=repeat_count, ) ) except Exception as exc: return _err(exc) - The adapter method 'duplicate_time_range' that makes the call to the underlying BridgeClient.
def duplicate_time_range( self, start_time: float, end_time: float, repeat_count: int = 1, ) -> dict[str, Any]: return self._client.call( "duplicate_time_range", start_time=start_time, end_time=end_time, repeat_count=repeat_count, )