Skip to main content
Glama

get_session_info_tool

Retrieve comprehensive details about the current Ableton Live session, enabling real-time insights and efficient management of project elements through integration with the Model Context Protocol.

Instructions

Get detailed information about the current Ableton session

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • MCP tool handler for get_session_info_tool, registered with @mcp.tool(). Calls the get_session_info helper function to execute the logic.
    @mcp.tool() def get_session_info_tool(ctx: Context) -> str: """Get detailed information about the current Ableton session""" return get_session_info(ctx)
  • Helper function that handles the Ableton communication for session info by sending a 'get_session_info' command and returning formatted JSON response.
    def get_session_info(ctx: Context) -> str: """Get detailed information about the current Ableton session""" try: ableton = get_ableton_connection() result = ableton.send_command("get_session_info") return json.dumps(result, indent=2) except Exception as e: logger.error(f"Error getting session info from Ableton: {str(e)}") return f"Error getting session info: {str(e)}"
  • Backend implementation in the Ableton remote script that collects and returns detailed session information including tempo, time signature, track counts, and master track details.
    def get_session_info(self) -> dict[str, Any]: """Get information about the current session""" try: result = { "tempo": self._song.tempo, "signature_numerator": self._song.signature_numerator, "signature_denominator": self._song.signature_denominator, "track_count": len(self._song.tracks), "return_track_count": len(self._song.return_tracks), "master_track": { "name": "Master", "volume": self._song.master_track.mixer_device.volume.value, "panning": self._song.master_track.mixer_device.panning.value, }, } return result except Exception as e: self.log_message("Error getting session info: " + str(e)) raise

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/chaudepark/ableton-mcp'

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