The analysis tools are the core of AI-assisted reverse engineering. They give you decompiled pseudocode, annotated disassembly, cross-reference graphs, call hierarchies, and basic-block control flow — individually or in bulk. All tools that accept multiple addresses take either a comma-separated string or a JSON array.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/mrexodia/ida-pro-mcp/llms.txt
Use this file to discover all available pages before exploring further.
decompile
Decompiles a single function using Hex-Rays and returns pseudocode with optional per-line address markers. When Hex-Rays is unavailable or the function cannot be decompiled, the error field is set and code is null.
Function address (hex) or name (e.g.
"main", "0x401000").Append
/*0xNNNN*/ address markers to each pseudocode line. Set to false to reduce token usage.DecompileResult
The input address/name as provided.
Decompiled pseudocode, or
null on failure.Named references (globals, strings, functions) found in the pseudocode ctree. Each entry has
addr, name, and optionally string.Present when decompilation fails.
Run
server_warmup with init_hexrays=True before calling decompile to avoid transient initialisation failures.disasm
Disassembles a function or a raw address range and returns structured output including arguments, return type, stack frame variables, and per-instruction labels, comments, and references. Supports offset/count pagination for very large functions.
Function address or name to disassemble.
Maximum number of instructions to return per call. Hard-capped at 50 000.
Skip the first N instructions (for pagination).
Compute the total instruction count for the function (adds latency for large functions).
DisasmResult
Input address as provided.
A
DisassemblyFunction record (see below), or null on error.Number of instructions returned in this page.
Total instruction count if
include_total was true.Pagination cursor:
{"next": N} when more instructions remain, {"done": true} at the end.Present when disassembly fails.
DisassemblyFunction fields:
Function name.
Start address in hex.
Segment name.
Return type string from type information.
List of
{name, type} argument records.List of
{name, offset, size, type} stack frame variables.Instruction lines, each with
addr, instruction, and optional label, comments, and refs.xrefs_to
Returns all cross-references pointing to one or more addresses or named symbols. Results are capped per target; when the cap is reached more is set to true.
Addresses or names to look up (e.g.
"0x11a9", "check_pw", ["main", "0x401000"]).Maximum cross-references per address. Hard-capped at 1 000.
list[XrefsToResult]
Input address/name.
List of
Xref records: {addr, type, fn}. type is "code" or "data". fn is the enclosing Function or null.true when more cross-references exist beyond the limit.Present on failure.
xref_query
Structured cross-reference queries with direction, type, deduplication, sorting, and pagination. More capable than xrefs_to when you need to filter or page through large xref sets.
One or more query objects.
list[XrefQueryResult] — each result has target, resolved_addr, direction, xref_type, data (list of XrefQueryRow), next_offset, total, and optional error.
xrefs_to_field
Returns cross-references to a specific field within a named structure. Useful for finding all code that accesses a particular struct member.
One or more
{struct, field} query objects.list[StructFieldXrefsResult] — each result has struct, field, xrefs (list of Xref), and optional error.
callees
Returns the unique set of functions called by one or more functions. Each result is capped by limit; more is set when additional callees exist.
Function addresses or names (e.g.
"main", ["0x1234", "sub_5678"]).Maximum callees per function. Hard-capped at 500.
list[CalleesResult]
Input address.
List of
{addr, name, type} records. type is "internal" or "external".true when results were capped.Present on failure.
basic_blocks
Returns the control-flow graph (CFG) basic blocks for one or more functions, including successor and predecessor addresses for each block.
Function addresses or names.
Maximum blocks per function per page. Hard-capped at 10 000.
Pagination offset (blocks to skip).
list[BasicBlocksResult]
Input address.
List of
BasicBlock records: {start, end, size, type, successors, predecessors}.Number of blocks returned.
Total blocks in the function.
{"next": N} when more blocks remain, {"done": true} at the end.Present on failure.
callgraph
Builds a bounded call graph starting from one or more root functions. The graph is returned as a flat node+edge list; traversal stops when any configured limit is reached.
Root function addresses to start traversal from.
Maximum call depth from each root.
Maximum total nodes. Hard-capped at 100 000.
Maximum total edges. Hard-capped at 200 000.
Maximum edges emitted from any single function. Hard-capped at 5 000.
list[CallGraphResult]
The root address as provided.
List of
{addr, name, depth} node records.List of
{from, to, type} edge records. type is always "call".The effective depth limit used.
true when a node, edge, or per-function limit was hit."nodes", "edges", or null when truncated.analyze_function
Compact single-function analysis: pseudocode, strings, constants, callers, callees, cross-references, and basic-block summary — all in one call.
Function address or name.
Include full disassembly text. Omit when you only need the pseudocode to save tokens.
AnalyzeFunctionResult — a single dict with addr, name, prototype, size, decompiled, assembly, strings, constants, callees, callers, xrefs, comments, basic_blocks, and error.
analyze_batch
Comprehensive per-function analysis with individually selectable sections. Each query in the batch can enable or disable decompilation, disassembly, cross-references, callers, callees, strings, constants, and basic blocks independently.
One or more analysis requests.
list[AnalyzeBatchResult] — each result has target, addr, name, analysis (an AnalyzeBatchDetails object), and optional error.
func_profile
Lightweight function profiling that returns summary metrics — instruction count, basic block count, caller/callee counts, string/constant counts — without performing decompilation. Supports batch queries and pagination across the entire function database.
One or more profiling queries.
list[FuncProfileResult] — each result has target, data (list of FuncProfileItem), next_offset, and optional error.
export_funcs
Exports one or more functions in a structured format suitable for further processing or documentation.
Function addresses or names to export.
Export format:
"json"— full record with address, name, prototype, size, assembly, pseudocode, comments, and cross-references."c_header"— a C header file string with all function prototypes."prototypes"— a list of{name, prototype}pairs.
format:
json→{format: "json", functions: [...]}where each function hasaddr,name,prototype,size,comments,asm,code,xrefs.c_header→{format: "c_header", content: "// Auto-generated...\nfunc1(...);\n..."}.prototypes→{format: "prototypes", functions: [{name, prototype}, ...]}.