get_storage_layout
Retrieve the storage slot layout of a Solidity contract, including slot numbers, byte offsets, and variable sizes, for upgrade safety analysis or storage collision detection.
Instructions
Computes the storage slot layout for a contract showing slot numbers, byte offsets, and variable sizes. Use this for upgrade safety analysis, storage collision detection, or understanding how variables are packed. Returns ordered slot assignments following Solidity's packing rules. Excludes constants and immutables (not in storage). Can include or exclude inherited storage. Supports pagination.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| request | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| success | Yes | ||
| has_more | No | True if there are more results beyond this page | |
| total_count | No | Total number of storage variables | |
| contract_key | No | The contract analyzed | |
| error_message | No | ||
| storage_slots | No | Storage slot assignments | |
| total_slots_used | No | Total storage slots used |