Skip to main content
Glama
cbxss
by cbxss

list_sessions

List all active Frida sessions, supporting multi-device workflows to monitor hooked processes and scripts during Android security testing.

Instructions

List all active Frida sessions. Supports multi-device workflows.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Public handler function that delegates to the session registry's list_sessions method.
    def list_sessions() -> list[dict]:
        """List all active Frida sessions."""
        return registry.list_sessions()
  • Core implementation: SessionRegistry.list_sessions() returns a list of dicts with id, target, pid, device, active, and alive status.
    def list_sessions(self) -> list[dict]:
        """List all sessions with their info."""
        with self._lock:
            return [
                {
                    "id": fs.id,
                    "target": fs.target,
                    "pid": fs.pid,
                    "device": fs.device.name,
                    "active": fs.id == self._active_id,
                    "alive": fs.is_alive(),
                }
                for fs in self._sessions.values()
            ]
  • Tool schema definition: name='list_sessions', description='List all active Frida sessions. Supports multi-device workflows.', inputSchema with no required properties.
    Tool(
        name="list_sessions",
        description="List all active Frida sessions. Supports multi-device workflows.",
        inputSchema={"type": "object", "properties": {}, "required": []},
    ),
  • Dispatcher registration: routes 'list_sessions' tool calls to device.list_sessions().
    elif name == "list_sessions":
        return device.list_sessions()
  • Global SessionRegistry singleton instance used by the handler.
    # Global session registry
    registry = SessionRegistry()
Behavior4/5

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

With no annotations, the description carries full burden. It accurately describes a read-only listing operation, which is behaviorally transparent. However, it could mention whether sessions are ephemeral or if any state is affected.

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?

Two sentences with no wasted words. The first sentence states purpose, the second adds a feature. Front-loaded and efficient.

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

Completeness3/5

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

Given no output schema, the description could add details on what attributes each session returns (e.g., device, PID). As is, it leaves the agent guessing about the response format.

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

Parameters4/5

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

No parameters exist, so baseline 4 applies. The description does not add parameter details, but none are needed.

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 clearly states the tool's action ('List') and resource ('all active Frida sessions'), with a distinct purpose that differentiates it from sibling tools focusing on Android activities, hooks, files, etc.

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

Usage Guidelines3/5

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

The description provides some context by mentioning 'Supports multi-device workflows', but lacks explicit guidance on when to use this tool versus alternatives or when not to use it.

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/cbxss/frida-mcp'

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