asset_inspect
Auto-generated from the Python tool registry. Do not hand-edit outside
<!-- examples:start --><!-- examples:end -->blocks — the generator (tools/generate_docs_reference.py) will overwrite them.
Group: core · Module: services.registry.capability_adapter
Maturity: stable (support status; independent of enabled state, readiness and permissions).
Description
Search assets or inspect their metadata and components.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
action | Literal['search', 'get_info', 'get_components'] | yes | Feature action to perform. |
path | str | None | — | Asset path required for asset operations; search defaults to Assets. Ignored for bundle assignment inspection. |
asset_type | str | None | — | Asset type (e.g., 'Material', 'Folder') - required for 'create'. Note: For ScriptableObjects, use manage_scriptable_object. |
generate_preview | bool | — | Generate previews up to 256 pixels per edge and 256 KiB PNG each; search allows at most 32 results and 4 MiB aggregate base64. |
search_pattern | str | None | — | Search pattern (e.g., '*.prefab' or AssetDatabase filters like 't:MonoScript'). Recommended: put queries like 't:MonoScript' here and set path='Assets'. |
filter_type | str | None | — | Filter type for search |
filter_date_after | str | None | — | Date after which to filter |
page_size | int | str | None | — | Page size: search 1-1000 (default 50), previews 1-32 (default 32), bundle inspection 1-100 (default 50). |
page_number | int | str | None | — | Page number for pagination (1-based). |
metadata_only | bool | — | Search only: return metadata with instanceID=0 and a bounded 60-second Editor-session snapshot; no explicit object/preview loads. Default false preserves legacy behavior. |
search_snapshot | str | None | — | Search only: opaque token from metadata_only=true; repeat the effective query and page_size. |
unity_instance | str | int | None | — | Target Unity instance for this call: Name@hash or hash prefix; an integer selects only that exact port over stdio and is rejected over HTTP. Read mcpforunity://instances for available targets. Omit to use the legacy active selection or the sole available instance. |
Returns
A dict containing the Unity response. The exact shape depends on the action.
Examples
Find the first 20 C# script assets under Assets/Scripts without loading previews. If the response includes a search snapshot, reuse it with the same query and page size for subsequent pages.
MCP arguments
{
"action": "search",
"path": "Assets/Scripts",
"search_pattern": "t:MonoScript",
"metadata_only": true,
"page_size": 20,
"page_number": 1
}