Declare Struct
declare_structDeclares or updates a struct in the local IDA type library, enabling reverse engineers to define and maintain binary data structures during analysis.
Instructions
Declare or update a struct in the local type library.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"decl": "<decl>"
},
"name": "declare_struct"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| decl | Yes | Struct declaration text (e.g. 'struct Name { ... };') | |
| timeout | No | Timeout in seconds | |
| instance_id | No | REQUIRED whenever more than one database is open (from open_database's result or list_databases()); optional only while exactly one instance is live. |