<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: XRPLWin</title>
    <description>The latest articles on DEV Community by XRPLWin (@xrplwin).</description>
    <link>https://dev.to/xrplwin</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F12936%2F9aa3792b-0464-4fbd-ac7b-9a4d699078c0.jpg</url>
      <title>DEV Community: XRPLWin</title>
      <link>https://dev.to/xrplwin</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/xrplwin"/>
    <language>en</language>
    <item>
      <title>HookState Data Viewer: Browse On-Chain State, Build Projections, and Publish Your Hook Manifest</title>
      <dc:creator>zgrguric</dc:creator>
      <pubDate>Sun, 26 Apr 2026 08:00:00 +0000</pubDate>
      <link>https://dev.to/xrplwin/hookstate-data-viewer-browse-on-chain-state-build-projections-and-publish-your-hook-manifest-54p9</link>
      <guid>https://dev.to/xrplwin/hookstate-data-viewer-browse-on-chain-state-build-projections-and-publish-your-hook-manifest-54p9</guid>
      <description>&lt;p&gt;&lt;em&gt;Part two of our HookState series. In &lt;a href="https://dev.to/xrplwin/hook-state-converter-decode-xahau-hookstate-abi-without-the-guesswork-7j2"&gt;part one&lt;/a&gt; we covered why raw HookState bytes are hard to read and how the Hook State Converter lets you decode them into a typed ABI schema. This article picks up where that one ended: what you do with that schema once you have it.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  From a JSON segment to something useful
&lt;/h2&gt;

&lt;p&gt;At the end of part one, you had a JSON ABI definition — a typed map of your HookState key and value bytes. The article closed with a promise: a dedicated projection builder UI exists that uses that schema to automatically decode HookState entries on the explorer.&lt;/p&gt;

&lt;p&gt;It does three things. It lets you browse any hook's raw on-chain state by namespace. It lets you build projections — readable, filterable tables that decode state entries according to your ABI. And it lets you publish a hook manifest, so those projections are available to everyone visiting your hook on the explorer, permanently, without anyone needing to convert themselves.&lt;/p&gt;

&lt;h2&gt;
  
  
  Browsing namespaces
&lt;/h2&gt;

&lt;p&gt;Every Xahau account can have multiple hooks installed, and each hook stores state under its own namespace — a 32-byte identifier derived from the hook hash. The Data Viewer &lt;strong&gt;exposes this structure directly&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Open the tool and navigate to any account. The left panel lists all namespaces active on that account, each showing how many total state entries it contains. Clicking a namespace loads its content into the main panel as a set of tabs.&lt;/p&gt;

&lt;p&gt;If a manifest has already been published for that hook, the namespace label resolves from a raw hash to a human-readable hook name, and the hook's projections appear as named tabs alongside the raw view. If no manifest exists yet, the namespace shows as a truncated hash and only the raw tab is available — which is your cue to build one.&lt;/p&gt;

&lt;p&gt;A namespace can contain state from more than one hook. In that case each hook gets its own tab group within the namespace, with its projections listed beneath it in the sidebar.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdkmk6wsb7cxpn9avlqqz.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdkmk6wsb7cxpn9avlqqz.webp" alt="Data Viewer Sidebar with projection list" width="800" height="353"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  All states (raw)
&lt;/h3&gt;

&lt;p&gt;The first tab in every namespace is &lt;strong&gt;All states (raw)&lt;/strong&gt;. This is the unfiltered view of everything stored in the namespace, with no decoding applied.&lt;/p&gt;

&lt;p&gt;The table shows four columns: &lt;code&gt;HookStateKey&lt;/code&gt;, &lt;code&gt;HookStateData&lt;/code&gt;, &lt;code&gt;Flags&lt;/code&gt;, and &lt;code&gt;OwnerNode&lt;/code&gt; — exactly as they exist on the ledger. Keys and values are displayed as full hex strings. This is the ground truth view: no interpretation, no type assumptions, nothing inferred.&lt;/p&gt;

&lt;p&gt;It's most useful when you're first exploring an unfamiliar hook and want to see the raw shape of its state before building any projections, when you suspect a projection is missing entries and want to verify against the full set, or when you're debugging a key encoding issue and need to compare raw bytes directly.&lt;/p&gt;

&lt;p&gt;The raw table is fully searchable, sortable, and exports to &lt;strong&gt;CSV and Excel&lt;/strong&gt; — so you can pull the complete state of any namespace into a spreadsheet for offline analysis without writing a single API call.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7trq56rynbr89ubwwbyz.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7trq56rynbr89ubwwbyz.webp" alt="Viewing all states (raw)" width="800" height="388"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Hooks and their projections
&lt;/h2&gt;

&lt;p&gt;Below the raw tab, each hook installed in the namespace gets its own section. If a manifest exists for the hook, its name appears as the tab label and its projections are listed beneath it in the sidebar — each one a named, filtered view into a subset of that hook's state entries.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://xahau.xrplwin.com/hook/B0B11C2179638C3EFF12D52454AD46DBB22AB89DBBDB0497028AA7FA88677678/C09D2D8F00025359" rel="noopener noreferrer"&gt;Evernode Governor Hook&lt;/a&gt;, for instance, carries over 25,000 state entries across projections ranging from single-entry config values like &lt;code&gt;Issuer Address&lt;/code&gt; and &lt;code&gt;Mint Limit&lt;/code&gt;, to large paginated sets like &lt;code&gt;Host Address&lt;/code&gt; (12,029 entries) and &lt;code&gt;Token Id&lt;/code&gt; (12,086 entries). All decoded, all browsable, all exportable — because a manifest exists for it. Without the manifest, you'd be looking at 25,000 rows of raw hex.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhhtkm122nb9bikk5isny.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhhtkm122nb9bikk5isny.webp" alt="Evernode projections" width="800" height="519"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The projection
&lt;/h2&gt;

&lt;p&gt;A projection is a &lt;strong&gt;named view&lt;/strong&gt; over a subset of a hook's HookState entries. It defines how to decode the key bytes and the value bytes into typed columns, applies optional filters to scope which entries appear, and gives each column a human-readable label.&lt;/p&gt;

&lt;p&gt;You can think of it as a schema-driven query: &lt;em&gt;show me all HookState entries where the key matches this pattern, decode them as these types, and display the result as a table.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;One important detail: a projection doesn't claim exclusive ownership of the HookState entries it targets. The same state entry can appear in multiple projections simultaneously, and this is intentional. A hook might expose one projection showing all fields of a record for technical auditing, and a second projection scoped to the same entries presenting only the fields relevant to a specific integration — different column selections, different filters, different renderers, same underlying state. This is how a single hook with a complex storage schema can surface multiple clean, purpose-built views without duplicating any data on-chain.&lt;/p&gt;

&lt;p&gt;Each hook manifest can contain as many projections as needed, and several of them can deliberately overlap on shared state keys by design.&lt;/p&gt;

&lt;h2&gt;
  
  
  Building a projection
&lt;/h2&gt;

&lt;p&gt;To create a projection, click &lt;strong&gt;Add projection&lt;/strong&gt; in the Data Viewer. This opens the Edit Projection modal.&lt;/p&gt;

&lt;p&gt;At the top you select which hook this projection belongs to and give it a name and optional description.&lt;/p&gt;

&lt;p&gt;The modal has four tabs: &lt;code&gt;HookStateKey&lt;/code&gt;, &lt;code&gt;HookStateData&lt;/code&gt;, &lt;code&gt;Projection preview&lt;/code&gt;, and &lt;code&gt;ABI&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Defining the key (HookStateKey tab)
&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;HookState&lt;/code&gt; key bytes appear as a row of clickable hex buttons. You select a span of bytes by clicking — selecting byte N means you've selected bytes 1 through N as a single segment. As you do, the UI immediately shows how many state entries in the namespace match that byte pattern so far. This live match count updates in real time as you narrow the key definition, giving you instant feedback on whether your filter is scoping entries correctly before you've committed to anything.&lt;/p&gt;

&lt;p&gt;Once you've selected a span, the type picker appears showing every ABI type that fits that exact byte length. The Suggest button runs the same autoscan as the Hook State Converter — it scans across all supported types simultaneously and surfaces the most plausible matches with decoded values shown inline.&lt;/p&gt;

&lt;p&gt;After selecting a type, a segment options panel appears. When you have unapplied changes the panel is highlighted with an orange border and a "You have unapplied changes" warning — a useful guardrail against navigating away mid-edit without realising you haven't committed a segment:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Column title&lt;/strong&gt; — the label shown in the projection table header.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Description&lt;/strong&gt; — optional documentation for the field.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Exclude from view&lt;/strong&gt; — mark this segment as hidden. Useful for padding bytes, fixed sentinel values, or type prefix bytes you're using only for filtering.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Filtering rule&lt;/strong&gt; — define a literal term or pattern (with encoding: ASCII, hex, etc.) that this segment must match for an entry to appear in the projection. A single type-byte filter is often all it takes to scope a projection from thousands of total namespace entries down to precisely the records you want.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Render as&lt;/strong&gt; — controls display format for timestamps, amounts, account IDs, and other types with multiple meaningful representations.&lt;/p&gt;

&lt;p&gt;Hit &lt;em&gt;Apply&lt;/em&gt; to lock-in the segment.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8483ixh0700iq0dq3n4m.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8483ixh0700iq0dq3n4m.webp" alt="Edit projection interface" width="800" height="589"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Defining the value (HookStateData tab)
&lt;/h3&gt;

&lt;p&gt;The value bytes follow exactly the same flow. Select a span, pick a type, configure segment options, apply. Repeat until all bytes are accounted for and the tab is marked &lt;strong&gt;Solved&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;To give a sense of scale: the &lt;em&gt;Host Address&lt;/em&gt; projection in the &lt;em&gt;Evernode Governor&lt;/em&gt; manifest decodes 22 typed fields from each entry's raw value bytes — registration ledger, fee, instance counts, heartbeat index, version, timestamps, reputation, lease amount, and more. All of it packed into raw bytes on-chain; all of it &lt;strong&gt;readable in the projection table&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Saving and publishing
&lt;/h3&gt;

&lt;p&gt;Once both tabs are &lt;strong&gt;Solved&lt;/strong&gt;, hit Update to save the projection locally. The projection now appears in the sidebar and in the main hook view — but it is &lt;strong&gt;not yet live&lt;/strong&gt;. The main hook view shows a Publish changes button that becomes active whenever you have locally saved projections that haven't been pushed to the manifest yet. This two-step flow lets you build and iterate on multiple projections before making any of them public.&lt;/p&gt;

&lt;h2&gt;
  
  
  Publishing a hook manifest
&lt;/h2&gt;

&lt;p&gt;A manifest is the &lt;strong&gt;container that holds all your projections&lt;/strong&gt; plus metadata about the hook itself. Publishing one makes everything visible to everyone — not just to you in the Data Viewer, but to anyone who navigates to that hook anywhere on the explorer.&lt;/p&gt;

&lt;p&gt;Click on green "Publish changes" buttom to make your manifest version live. In next step you will have change to idenfity hook, give it name, icon, description...&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Hook name&lt;/strong&gt; — the display name that replaces the raw namespace hash across the explorer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hook icon&lt;/strong&gt; — a square image, minimum 256×256px, provided as a URL or direct file upload.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Short description&lt;/strong&gt; — one or two sentences shown in the manifest header.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Readme&lt;/strong&gt; — a full markdown field rendered in the About tab on the hook's manifest page. Use it for documentation, storage schema explanation, version history, or anything useful to auditors and integrators coming to the hook cold.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Repository URL&lt;/strong&gt; — renders as a "Source code" link directly on the hook page.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;License&lt;/strong&gt; — a standard identifier (MIT, GPL-3.0, Apache-2.0) or leave blank for unlicensed.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Publishers&lt;/strong&gt; — one or more entries, each with a type (Individual or Organization), a name, and an optional URL. Multiple publishers can be added to the same manifest. Publishers are displayed in the manifest header and their combined account weight determines how this version is ranked against others.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ABI&lt;/strong&gt; — the aggregate JSON of all your projection definitions, auto-populated from your saved projections. A "View/Edit JSON manifest ABI (advanced)" button opens a full editor for direct manipulation when needed.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Hit Publish. The manifest is stored and associated with the hook hash. From this point on, anyone visiting that hook on &lt;a href="https://xahau.xrplwin.com" rel="noopener noreferrer"&gt;xahau.xrplwin.com&lt;/a&gt; sees the decoded namespace name, the projections as tabs, and the full manifest metadata.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3e3n1q2x79ynggy1g69f.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3e3n1q2x79ynggy1g69f.webp" alt="Publishing Hook Manifest" width="800" height="605"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Community manifests and version weight
&lt;/h2&gt;

&lt;p&gt;Anyone with an account on XPLWin can publish a manifest for any hook — not just the hook author. If a hook is deployed and widely used but the author hasn't published a manifest, a community member, an auditor, or an integration builder can step in and create one.&lt;/p&gt;

&lt;p&gt;This openness creates an obvious question: if multiple people publish manifests for the same hook, which version does the explorer show by default?&lt;/p&gt;

&lt;p&gt;The answer is account weight. Each website account carries a weight value, and when multiple manifest versions exist for the same hook, the explorer sorts them by the combined weight of their publishers. The highest-weight version is shown as the default. Users can switch between available versions at any time using the version selector on the hook page — so no version is hidden, just ranked.&lt;/p&gt;

&lt;p&gt;The Evernode Governor Hook is a practical example: built and deployed by Evernode Labs, manifest created and published by XRPLWin. The "Manifest by xrplwin" badge on the hook page reflects this — hook author and manifest author are different entities, and the system handles that cleanly.&lt;/p&gt;

&lt;p&gt;In practice this means the hook author, or an established community member with a higher-weight account, will naturally surface at the top. But a lower-weight account can still contribute a manifest — their version remains accessible and switchable. The system accommodates multiple valid interpretations of the same hook's storage schema coexisting without conflict.&lt;/p&gt;

&lt;h2&gt;
  
  
  The full loop
&lt;/h2&gt;

&lt;p&gt;Part one covered the decoding problem and the &lt;a href="https://xahau.xrplwin.com/tools/hook/abi-conversion-helper" rel="noopener noreferrer"&gt;Converter&lt;/a&gt; that solves it for a single hex string. This article covers what comes after.&lt;/p&gt;

&lt;p&gt;The intended flow is:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Write and deploy your hook&lt;/li&gt;
&lt;li&gt;Grab a sample &lt;code&gt;HookState&lt;/code&gt; key + value from the explorer or your test environment&lt;/li&gt;
&lt;li&gt;Run it through the &lt;a href="https://xahau.xrplwin.com/tools/hook/abi-conversion-helper" rel="noopener noreferrer"&gt;Hook State Converter&lt;/a&gt; to produce typed &lt;code&gt;ABI segments&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Open the HookState Data Viewer, navigate to your hook's namespace, and build projections — watching the live match count confirm your key patterns as you go&lt;/li&gt;
&lt;li&gt;Save projections locally, verify in the Projection preview tab, then hit Publish changes&lt;/li&gt;
&lt;li&gt;Fill in the manifest metadata and publish — or build on a community-contributed version if one already exists&lt;/li&gt;
&lt;li&gt;Anyone visiting your hook on the explorer now sees decoded, human-readable state — not raw hex&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For a hook storing configuration values across dozens of keys, a single afternoon with these two tools produces a manifest that makes it permanently auditable. For something at the scale of Evernode's Governor Hook — 25,000+ entries, community-maintained manifest — it's the clearest demonstration of what this system is designed to enable.&lt;/p&gt;

&lt;p&gt;See it in action &lt;a href="https://www.youtube.com/watch?v=G86IRZNfNH8" rel="noopener noreferrer"&gt;https://www.youtube.com/watch?v=G86IRZNfNH8&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;XRPLWin is a explorer for XRPL and Xahau. We build tools for the Xahau ecosystem.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>xahau</category>
      <category>namespaces</category>
      <category>blockchain</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Hook State Converter: Decode Xahau HookState ABI Without the Guesswork</title>
      <dc:creator>zgrguric</dc:creator>
      <pubDate>Sun, 12 Apr 2026 23:07:14 +0000</pubDate>
      <link>https://dev.to/xrplwin/hook-state-converter-decode-xahau-hookstate-abi-without-the-guesswork-7j2</link>
      <guid>https://dev.to/xrplwin/hook-state-converter-decode-xahau-hookstate-abi-without-the-guesswork-7j2</guid>
      <description>&lt;p&gt;If you've built Hooks on Xahau, you've been here: staring at a raw HookState entry like &lt;code&gt;5852504C57696E&lt;/code&gt; and trying to figure out what it actually means.&lt;/p&gt;

&lt;p&gt;Is it a &lt;code&gt;UInt32&lt;/code&gt;? A &lt;code&gt;VarString&lt;/code&gt;? A timestamp? A ledger index? Big-endian or little-endian?&lt;/p&gt;

&lt;p&gt;You either write a throwaway script, crack open a hex calculator, or just guess. None of these are great when you're in the middle of debugging a Hook at 2am.&lt;/p&gt;

&lt;p&gt;That's exactly why we built the &lt;strong&gt;&lt;a href="https://xahau.xrplwin.com/tools/hook/abi-conversion-helper" rel="noopener noreferrer"&gt;Hook State Converter&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;But before we get into the tool, let's talk about why HookState data is so hard to read in the first place — because understanding the problem makes the solution a lot more useful.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why HookState data is hard to read
&lt;/h2&gt;

&lt;p&gt;Xahau Hooks are small programs that run directly on the ledger. They can read and write persistent state using a key-value store called &lt;code&gt;HookState&lt;/code&gt;. Each entry has a 32-byte key and an arbitrary-length value, both stored as raw binary data on the ledger.&lt;/p&gt;

&lt;p&gt;That last part is the catch: &lt;em&gt;raw binary data&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Unlike a database where you define a schema upfront and the engine enforces types, &lt;code&gt;HookState&lt;/code&gt; has no built-in type system. A Hook author decides how to encode data — as a little-endian &lt;code&gt;UInt32&lt;/code&gt;, as an &lt;code&gt;XFL&lt;/code&gt; float, as a packed struct of multiple fields — and that decision lives only in the Hook's source code. The ledger just stores bytes.&lt;/p&gt;

&lt;p&gt;When you look at an account's HookState on an explorer, you see something like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Key:   637373746F6D65725F6163636F756E74000000000000000000000000000000000000
Value: 05A528BCFA2189C8E2E7813775ED71B2C4BE349F`
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What does the key mean? What type is the value? Is it an &lt;code&gt;AccountID&lt;/code&gt;? A &lt;code&gt;hash&lt;/code&gt;? A packed amount and timestamp? There is no metadata attached to the entry. The ledger doesn't know and doesn't care — it just stores and retrieves bytes on demand.&lt;/p&gt;

&lt;p&gt;This creates a real problem for anyone who isn't the original Hook author:&lt;/p&gt;

&lt;p&gt;Auditors trying to verify what state a Hook is reading and writing Developers debugging why a Hook behaved unexpectedly Integration builders trying to read HookState from an external app Explorer users who just want to understand what they're looking at. Even if you are the original author, coming back to a Hook months later and trying to remember your own encoding scheme is painful. And if the Hook is open source but the ABI schema isn't documented anywhere, you're left reading C source code and mentally simulating byte offsets.&lt;/p&gt;




&lt;h2&gt;
  
  
  The encoding rabbit hole
&lt;/h2&gt;

&lt;p&gt;To illustrate how quickly this gets complicated, consider a simple HookState key that encodes a string like customer_account padded to 32 bytes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;637573746F6D65725F6163636F756E740000000000000000000000000000000000000000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To decode this manually you would:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Split the hex into byte pairs: 63 75 73 74 6F 6D 65 72 5F 61 63 63 ...&lt;/li&gt;
&lt;li&gt;Convert each byte from hex to ASCII: c u s t o m e r _ a c c o u n t \0 \0 ...&lt;/li&gt;
&lt;li&gt;Recognize it as a null-padded ASCII string&lt;/li&gt;
&lt;li&gt;Figure out where the meaningful content ends and the padding begins&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That's a relatively simple case. Now imagine the value is a packed struct: &lt;code&gt;05A528BCFA2189C8E2E7813775ED71B2C4BE349F&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Is that 20 bytes? Yes. So it could be a &lt;code&gt;Hash160&lt;/code&gt; or an &lt;code&gt;AccountID&lt;/code&gt;. Both are 20 bytes. How do you know which one? You go read the Hook source code. If you're lucky it's commented. Usually it isn't.&lt;/p&gt;

&lt;p&gt;Now multiply this across a Hook that stores 10 or 15 different state keys, each with a different encoding scheme, and you start to understand why debugging HookState is one of the more tedious parts of Xahau development.&lt;/p&gt;




&lt;h2&gt;
  
  
  What the Hook State Converter does
&lt;/h2&gt;

&lt;p&gt;The Hook ABI Conversion Helper is our answer to this problem. It gives you an interactive UI to paste hex, decode it visually, and export a reusable ABI schema — all without writing a single line of code.&lt;/p&gt;

&lt;p&gt;The tool accepts three inputs:&lt;br&gt;
HookState key + value pairs — the most common case HookParameter pairs — named parameters passed into Hook invocations Invoke blobs — raw binary payloads attached to Invoke transactions.&lt;/p&gt;
&lt;h2&gt;
  
  
  Paste hex. Get answers.
&lt;/h2&gt;

&lt;p&gt;Paste your hex into the input fields and the UI immediately does three things:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Splits the hex into individual byte buttons&lt;/li&gt;
&lt;li&gt;Marks the key as Solved or Unsolved depending on whether it matches a known schema&lt;/li&gt;
&lt;li&gt;Runs an automatic scan and populates suggestions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each byte is a clickable button. You select bytes by clicking — selecting byte 5 means you've selected bytes 1 through 5 as a single segment. The UI updates in real time to show you every ABI type that fits that exact byte length.&lt;/p&gt;


&lt;h2&gt;
  
  
  Smart suggestions first
&lt;/h2&gt;

&lt;p&gt;You don't need to know the type upfront. The Suggest button scans your hex across all supported ABI types simultaneously and surfaces the most plausible matches as clickable buttons — each showing the type name and the decoded value inline.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fprjpd7f6mn5iaxc3w6pi.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fprjpd7f6mn5iaxc3w6pi.webp" alt="ABI Conversion Helper Suggestions" width="700" height="139"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For example, paste &lt;code&gt;5852504C57696E&lt;/code&gt; and you'll instantly see:&lt;br&gt;
&lt;strong&gt;VarString&lt;/strong&gt; XRPLWin&lt;br&gt;
&lt;strong&gt;UInt64&lt;/strong&gt; 32075751449710680&lt;br&gt;
&lt;strong&gt;Blob&lt;/strong&gt; 5852504C57696E&lt;/p&gt;

&lt;p&gt;One click to confirm. The tool locks that interpretation and moves on to the remaining bytes. The scan is smart about filtering noise — it suppresses leading null bytes from Null suggestions since those are almost always padding, surfaces VarString matches only when the bytes decode to printable UTF-8, and collapses partial string matches so you see the longest valid string, not every sub-sequence.&lt;/p&gt;


&lt;h2&gt;
  
  
  Manual byte picking for complex states
&lt;/h2&gt;

&lt;p&gt;If autoscan doesn't nail it, or you're working with a tightly packed multi-field state, the byte picker gives you full control.&lt;/p&gt;

&lt;p&gt;Click any byte button to select from byte 1 up to that point. The result panel shows every ABI type that fits that exact byte length — &lt;code&gt;UInt16&lt;/code&gt;, &lt;code&gt;UInt16&lt;/code&gt; (BE),  &lt;code&gt;Int16&lt;/code&gt; , &lt;code&gt;Timestamp&lt;/code&gt;, &lt;code&gt;LedgerIndex&lt;/code&gt; — each with the decoded value shown.&lt;/p&gt;

&lt;p&gt;Select the type that matches your Hook's logic. The tool locks that segment, advances to the remaining bytes, and a new engine appears for the next segment. You repeat the process until every byte is accounted for.&lt;/p&gt;

&lt;p&gt;This chained engine approach means you can decode a 32-byte key that encodes, say, a 4-byte &lt;code&gt;UInt32&lt;/code&gt; flag, a 20-byte &lt;code&gt;AccountID&lt;/code&gt;, and 8 bytes of NULL padding — step by step, segment by segment, without losing track of where you are in the buffer.&lt;/p&gt;


&lt;h2&gt;
  
  
  20+ ABI types supported
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Category&lt;/th&gt;
&lt;th&gt;Types&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Integers&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;UInt8/16/32/64&lt;/code&gt;, &lt;code&gt;Int8/16/32/64&lt;/code&gt; (LE &amp;amp; BE)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Floats&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;XFL&lt;/code&gt; (LE &amp;amp; BE)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amounts&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;Amount&lt;/code&gt;, &lt;code&gt;NativeAmount&lt;/code&gt;, &lt;code&gt;IOUAmount&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Strings&lt;/td&gt;
&lt;td&gt;&lt;code&gt;VarString&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Hashes&lt;/td&gt;
&lt;td&gt;&lt;code&gt;Hash128/160/256/512&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Identity&lt;/td&gt;
&lt;td&gt;&lt;code&gt;AccountID&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ledger&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;Timestamp&lt;/code&gt;, &lt;code&gt;LedgerIndex&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Raw&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;Blob&lt;/code&gt;, &lt;code&gt;Null&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;
&lt;h2&gt;
  
  
  Both little-endian and big-endian variants are available for integer and float types, since Hooks developers sometimes store values in BE when interfacing with external systems.
&lt;/h2&gt;
&lt;h2&gt;
  
  
  Per-segment options
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frcgzxvju1f41zsnk3m99.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frcgzxvju1f41zsnk3m99.webp" alt="Segment options" width="700" height="365"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once you select a type, a small options panel appears for that segment. You can:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Rename the label&lt;/strong&gt; — give it a meaningful name like customer_account instead of VarString&lt;br&gt;
&lt;strong&gt;Add a description&lt;/strong&gt; — document what this field represents.&lt;br&gt;
&lt;strong&gt;Set a filtering rule&lt;/strong&gt; — define a literal pattern or regex that this segment must match for the decoding to be valid. Useful for sentinel bytes or magic values that identify the schema version.&lt;br&gt;
&lt;strong&gt;Exclude from view&lt;/strong&gt; — mark padding or fixed bytes as hidden so they don't clutter the final table.&lt;br&gt;
&lt;strong&gt;Set a renderer&lt;/strong&gt; — control how the decoded value is displayed, for example there are various Timestamp renderers.&lt;/p&gt;

&lt;p&gt;Hit &lt;strong&gt;Apply&lt;/strong&gt; and the finalized table updates immediately.&lt;/p&gt;


&lt;h2&gt;
  
  
  Export the ABI schema
&lt;/h2&gt;

&lt;p&gt;Once every byte is accounted for, the tool renders a full breakdown table with raw and rendered values side by side, and below it — the Segment ABI as JSON.&lt;/p&gt;

&lt;p&gt;A 32-byte key encoding the string customer_account produces:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[
  {
    "type": "VarString",
    "byteLength": 32,
    "label": "Customer Account"
  }
]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This JSON is the reusable schema and it's part of the Hook manifest format that XRPLWin uses internally. When a Hook manifest is registered with the explorer, it includes ABI definitions like this one — and XRPLWin uses them to automatically decode and display HookState entries in a human-readable way for anyone viewing that Hook on the explorer. You won't need to copy or paste anything manually — a dedicated projection builder UI is available that will use this conversion helper under the hood to generate manifest segments interactively.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;XRPLWin is a explorer for XRPL and Xahau. We build tools for the Xahau ecosystem at &lt;a href="https://xahau.xrplwin.com" rel="noopener noreferrer"&gt;xahau.xrplwin.com&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>xahau</category>
      <category>blockchain</category>
      <category>webdev</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
