set_label
Assign or remove color label names to organize photos in Lightroom Classic for efficient catalog management and workflow automation.
Instructions
Set Lightroom color label name (or empty string to clear).
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | Yes | ||
| local_ids | No |
Implementation Reference
- The tool 'set_label' is registered using the @mcp.tool() decorator and its handler implementation directly calls the metadata.set_label MCP backend method.
@mcp.tool() async def set_label(label: str, local_ids: list[int] | None = None) -> dict[str, Any]: """Set Lightroom color label name (or empty string to clear).""" if label is None: raise ValueError("label must be a string") payload: dict[str, Any] = {"label": str(label)} ids = validate_local_ids(local_ids) if ids: payload["local_ids"] = ids return await _call("metadata.set_label", payload)