Repository navigation
Description
Summary
droid-sdk-python==0.1.2 does not expose several RPC methods and request fields supported by the current Droid CLI and by @factory/droid-sdk==0.6.0. Applications must access the private DroidClient._protocol object to use these capabilities.
Tested on 2026-07-27 with:
- Droid CLI
0.180.0 droid-sdk-python==0.1.2@factory/droid-sdk==0.6.0
Missing request fields
droid.initialize_session
The Python initialize_session() method supports enabled_tool_ids, but not
disabled_tool_ids. enabledToolIds augments the default tool set and is not
an allowlist, so enabled_tool_ids=[] leaves default native tools enabled.
The protocol and TypeScript SDK support:
{
"enabledToolIds": [],
"disabledToolIds": ["read-cli", "execute-cli"]
}droid.add_user_message
The Python add_user_message() method does not accept outputFormat.
The current protocol supports JSON Schema structured output:
{
"text": "Return an answer.",
"outputFormat": {
"type": "json_schema",
"schema": {
"type": "object",
"properties": {
"answer": {"type": "integer"}
},
"required": ["answer"]
}
}
}Missing methods
The current CLI accepts these RPC methods, and the TypeScript SDK exposes
typed equivalents:
| RPC method | TypeScript SDK method |
|---|---|
droid.close_session |
closeSession() |
droid.list_tools |
listTools() |
droid.list_commands |
Low-level client support |
droid.compact_session |
compactSession() |
droid.fork_session |
forkSession() |
droid.get_context_stats |
getContextStats() |
droid.get_context_breakdown |
Protocol support |
droid.rename_session |
renameSession() |
droid.get_rewind_info |
getRewindInfo() |
droid.execute_rewind |
executeRewind() |
droid.list_tools is particularly important for security-sensitive clients.
It returns the actual CLI tool IDs plus defaultAllowed and
currentlyAllowed, which lets a client discover the current catalog, disable
every tool, and verify the result before sending a prompt.
Reproduction
The public Python method cannot express structured output:
await client.add_user_message(
text="Return JSON.",
output_format={ # Unexpected keyword argument
"type": "json_schema",
"schema": {"type": "object"},
},
)The same operation currently requires private access:
protocol = client._ensure_protocol()
await protocol.send_request(
method="droid.add_user_message",
params={
"text": "Return JSON.",
"outputFormat": {
"type": "json_schema",
"schema": {"type": "object"},
},
},
)Likewise, reliably disabling native tools requires private RPC calls:
catalog = await protocol.send_request("droid.list_tools", {})
tool_ids = [tool["id"] for tool in catalog["result"]["tools"]]
await protocol.send_request(
"droid.update_session_settings",
{"enabledToolIds": [], "disabledToolIds": tool_ids},
)Expected behavior
Please add typed Python APIs and schemas for the current protocol surface, including:
disabled_tool_idson session initialization and settings updates.output_formaton user messages.- Tool discovery.
- Session close, compact, fork, rename, context, and rewind methods.
- Current notification and result variants for structured output.
The public SDK should not require applications to access _protocol or _ensure_protocol().
Activity