<?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: gouri t</title>
    <description>The latest articles on DEV Community by gouri t (@ctsxzdenhayl).</description>
    <link>https://dev.to/ctsxzdenhayl</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fthepracticaldev.s3.amazonaws.com%2Fi%2F99mvlsfu5tfj9m7ku25d.png</url>
      <title>DEV Community: gouri t</title>
      <link>https://dev.to/ctsxzdenhayl</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ctsxzdenhayl"/>
    <language>en</language>
    <item>
      <title>Day 56 of #100DaysOfSolana</title>
      <dc:creator>gouri t</dc:creator>
      <pubDate>Sun, 14 Jun 2026 14:10:35 +0000</pubDate>
      <link>https://dev.to/ctsxzdenhayl/day-56-of-100daysofsolana-2432</link>
      <guid>https://dev.to/ctsxzdenhayl/day-56-of-100daysofsolana-2432</guid>
      <description>&lt;h1&gt;
  
  
  Building a Token-2022 Trilogy on Solana: Transfer Fees, Interest-Bearing Tokens, and Non-Transferable Assets
&lt;/h1&gt;

&lt;p&gt;Over the past week, I spent some time exploring Token-2022 on Solana as part of my #100DaysOfSolana journey.&lt;/p&gt;

&lt;p&gt;Before this challenge, I thought tokens were fairly simple: create a mint, issue tokens, and transfer them between accounts. Token-2022 completely changed that perspective.&lt;/p&gt;

&lt;p&gt;What surprised me most was that many advanced token behaviors can be configured directly through extensions without writing an entirely new token program.&lt;/p&gt;

&lt;p&gt;To understand what's possible, I built three different Token-2022 examples:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A token that charges fees on transfers&lt;/li&gt;
&lt;li&gt;A token that accrues interest over time&lt;/li&gt;
&lt;li&gt;A token that cannot be transferred at all&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here's what I learned.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Transfer Fee Token
&lt;/h2&gt;

&lt;p&gt;The first extension I explored was Transfer Fees.&lt;/p&gt;

&lt;p&gt;The idea is simple: whenever someone transfers tokens, a percentage of the transfer is automatically collected as a fee.&lt;/p&gt;

&lt;p&gt;Instead of building custom logic into an application, the token itself enforces the rule.&lt;/p&gt;

&lt;p&gt;This immediately made me think about real-world use cases:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Protocol revenue sharing&lt;/li&gt;
&lt;li&gt;Community treasuries&lt;/li&gt;
&lt;li&gt;Creator royalties&lt;/li&gt;
&lt;li&gt;Ecosystem funding mechanisms&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Creating the token was straightforward, but seeing the fee behavior enforced at the token level was the interesting part. Once configured, every transfer follows the same rules automatically.&lt;/p&gt;

&lt;p&gt;That was my first glimpse into how powerful Token-2022 can be.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Interest-Bearing Token
&lt;/h2&gt;

&lt;p&gt;Next, I experimented with the Interest-Bearing extension.&lt;/p&gt;

&lt;p&gt;This was probably the most interesting feature in the trilogy.&lt;/p&gt;

&lt;p&gt;Traditional reward systems often require additional programs, scheduled updates, or custom accounting logic. With Token-2022, interest can be represented directly through the token configuration itself.&lt;/p&gt;

&lt;p&gt;As I worked through the implementation, I started to see potential applications:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Savings products&lt;/li&gt;
&lt;li&gt;Loyalty systems&lt;/li&gt;
&lt;li&gt;Reward mechanisms&lt;/li&gt;
&lt;li&gt;Educational experiments in tokenized finance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What stood out most wasn't just the feature itself—it was how much complexity could be handled by the token standard rather than application code.&lt;/p&gt;

&lt;p&gt;The more I explored Token-2022, the more I realized that token design can influence application behavior in powerful ways.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Non-Transferable Token
&lt;/h2&gt;

&lt;p&gt;For the final experiment, I built a non-transferable token.&lt;/p&gt;

&lt;p&gt;At first this sounded strange.&lt;/p&gt;

&lt;p&gt;Why create a token that cannot be transferred?&lt;/p&gt;

&lt;p&gt;After spending some time thinking about it, the use cases became obvious:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Certificates&lt;/li&gt;
&lt;li&gt;Achievement badges&lt;/li&gt;
&lt;li&gt;Membership credentials&lt;/li&gt;
&lt;li&gt;Identity-related assets&lt;/li&gt;
&lt;li&gt;Course completion records&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In these situations, transferring ownership would actually defeat the purpose of the asset.&lt;/p&gt;

&lt;p&gt;Testing the transfer restrictions was a good reminder that not every token is meant to behave like money. Sometimes the value comes from proving ownership rather than enabling movement.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Learned About Token-2022
&lt;/h2&gt;

&lt;p&gt;Before this project, I viewed Token-2022 as an upgraded token program with a few extra features.&lt;/p&gt;

&lt;p&gt;After building these examples, I see it differently.&lt;/p&gt;

&lt;p&gt;Token-2022 feels more like a framework for composing token behavior.&lt;/p&gt;

&lt;p&gt;Instead of creating custom programs for every new requirement, developers can combine extensions to build assets with specific characteristics.&lt;/p&gt;

&lt;p&gt;A token can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Charge fees&lt;/li&gt;
&lt;li&gt;Earn interest&lt;/li&gt;
&lt;li&gt;Store metadata&lt;/li&gt;
&lt;li&gt;Restrict transfers&lt;/li&gt;
&lt;li&gt;Support additional extensions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All while remaining part of the same ecosystem.&lt;/p&gt;

&lt;p&gt;That flexibility opens the door to many new asset designs.&lt;/p&gt;

&lt;h2&gt;
  
  
  Final Thoughts
&lt;/h2&gt;

&lt;p&gt;This Token-2022 trilogy gave me a much deeper appreciation for how much functionality can live at the token layer.&lt;/p&gt;

&lt;p&gt;The transfer fee token showed me how economic rules can be embedded directly into an asset.&lt;/p&gt;

&lt;p&gt;The interest-bearing token demonstrated how value can evolve over time without complex application logic.&lt;/p&gt;

&lt;p&gt;The non-transferable token challenged my assumption that every token should be freely transferable.&lt;/p&gt;

&lt;p&gt;For anyone learning Solana, I highly recommend spending time with Token-2022 extensions. They're a great way to understand how token behavior can be customized without building everything from scratch.&lt;/p&gt;

&lt;p&gt;As I continue through #100DaysOfSolana, I'm excited to explore more extensions and see how they can be combined to create even more interesting on-chain assets.&lt;/p&gt;

&lt;p&gt;Thanks for reading.&lt;/p&gt;

&lt;h1&gt;
  
  
  Solana #Web3 #Blockchain #Token2022 #100DaysOfSolana
&lt;/h1&gt;

</description>
      <category>blockchain</category>
      <category>devjournal</category>
      <category>learning</category>
      <category>web3</category>
    </item>
    <item>
      <title>Write about the account model</title>
      <dc:creator>gouri t</dc:creator>
      <pubDate>Sat, 16 May 2026 17:29:43 +0000</pubDate>
      <link>https://dev.to/ctsxzdenhayl/write-about-the-account-model-1ihn</link>
      <guid>https://dev.to/ctsxzdenhayl/write-about-the-account-model-1ihn</guid>
      <description>&lt;p&gt;Solana’s account model can feel confusing at first. Terms like lamports, owners, and program accounts sound very blockchain-specific, and when you inspect a Solana account in the CLI or Explorer, the JSON output can look intimidating.&lt;/p&gt;

&lt;p&gt;But once you stop thinking about Solana like Ethereum and start thinking about it like a filesystem or database system, things begin to click.&lt;/p&gt;

&lt;p&gt;In this article, I’ll break down Solana’s account model in plain English for developers who have never worked with blockchain before.&lt;/p&gt;

&lt;p&gt;Everything on Solana Is an Account&lt;/p&gt;

&lt;p&gt;One of the biggest differences between Solana and Ethereum is how state is stored.&lt;/p&gt;

&lt;p&gt;In Ethereum, there are two main account types:&lt;/p&gt;

&lt;p&gt;Externally Owned Accounts (EOAs) → user wallets&lt;br&gt;
Contract Accounts → smart contracts&lt;/p&gt;

&lt;p&gt;Solana simplifies this idea.&lt;/p&gt;

&lt;p&gt;On Solana, everything is an account:&lt;/p&gt;

&lt;p&gt;Wallets&lt;br&gt;
Smart contracts (called programs)&lt;br&gt;
Token balances&lt;br&gt;
NFTs&lt;br&gt;
Application state&lt;/p&gt;

&lt;p&gt;All of them are stored using the same account structure.&lt;/p&gt;

&lt;p&gt;You can think of Solana like a giant key-value database:&lt;/p&gt;

&lt;p&gt;Key Value&lt;br&gt;
32-byte public address  Account data&lt;/p&gt;

&lt;p&gt;Each account lives at a unique public address and contains metadata plus optional data.&lt;/p&gt;

&lt;p&gt;A Web2 Analogy: Solana as a Filesystem&lt;/p&gt;

&lt;p&gt;The easiest way to understand Solana accounts is to compare them to files in an operating system.&lt;/p&gt;

&lt;p&gt;Imagine:&lt;/p&gt;

&lt;p&gt;Each account = a file&lt;br&gt;
The data field = file contents&lt;br&gt;
The owner = which program controls the file&lt;br&gt;
Programs = executable files&lt;br&gt;
Data accounts = documents/databases&lt;br&gt;
The System Program = operating system kernel&lt;/p&gt;

&lt;p&gt;Programs don’t directly “own” all their data internally. Instead, they read and write to separate accounts, similar to how a backend server interacts with a database.&lt;/p&gt;

&lt;p&gt;This design makes Solana extremely flexible and parallelizable.&lt;/p&gt;

&lt;p&gt;The Five Fields Every Account Has&lt;/p&gt;

&lt;p&gt;Every Solana account follows the same structure.&lt;/p&gt;

&lt;p&gt;Here are the five important fields:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Lamports&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Lamports are the smallest unit of SOL.&lt;/p&gt;

&lt;p&gt;1 SOL = 1,000,000,000 lamports&lt;/p&gt;

&lt;p&gt;This field stores the account’s SOL balance.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;"lamports": 2039280&lt;/p&gt;

&lt;p&gt;That means the account holds 0.00203928 SOL.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Data&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This is a byte array that stores arbitrary information.&lt;/p&gt;

&lt;p&gt;Programs use this field to save state such as:&lt;/p&gt;

&lt;p&gt;token balances&lt;br&gt;
NFT metadata&lt;br&gt;
game progress&lt;br&gt;
user profiles&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;"data": ["", "base64"]&lt;/p&gt;

&lt;p&gt;If the array is empty, the account stores no custom data.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Owner&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The owner field defines which program controls the account.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;"owner": "11111111111111111111111111111111"&lt;/p&gt;

&lt;p&gt;That address belongs to the System Program.&lt;/p&gt;

&lt;p&gt;The important rule is:&lt;/p&gt;

&lt;p&gt;Only the owner program can modify the account’s data.&lt;/p&gt;

&lt;p&gt;This is one of Solana’s core security mechanisms.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Executable&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This is a boolean value:&lt;/p&gt;

&lt;p&gt;true → the account contains executable program code&lt;br&gt;
false → normal data account&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;"executable": false&lt;/p&gt;

&lt;p&gt;Most accounts are non-executable.&lt;/p&gt;

&lt;p&gt;Program accounts are special because they store deployable smart contract code.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Rent Epoch&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This field is now deprecated and usually set to the maximum value.&lt;/p&gt;

&lt;p&gt;Historically, it tracked when rent payments were due.&lt;/p&gt;

&lt;p&gt;You’ll still see it in account output, but modern Solana apps rarely interact with it directly.&lt;/p&gt;

&lt;p&gt;Ownership Rules: Solana’s Security Model&lt;/p&gt;

&lt;p&gt;Solana’s ownership model is surprisingly simple.&lt;/p&gt;

&lt;p&gt;Rule 1:&lt;/p&gt;

&lt;p&gt;Only the owner program can:&lt;/p&gt;

&lt;p&gt;modify account data&lt;br&gt;
subtract lamports from the account&lt;br&gt;
Rule 2:&lt;/p&gt;

&lt;p&gt;Anyone can send lamports to any writable account.&lt;/p&gt;

&lt;p&gt;This is similar to how anyone can transfer money to your bank account, but only you can spend from it.&lt;/p&gt;

&lt;p&gt;Because ownership is enforced by the runtime itself, programs cannot randomly modify accounts they do not control.&lt;/p&gt;

&lt;p&gt;The Concept That Surprises Most Developers&lt;/p&gt;

&lt;p&gt;Here’s the part that usually shocks Web2 developers:&lt;/p&gt;

&lt;p&gt;Programs Don’t Store Their Own State&lt;/p&gt;

&lt;p&gt;In Ethereum, smart contracts usually contain both:&lt;/p&gt;

&lt;p&gt;code&lt;br&gt;
storage/state&lt;/p&gt;

&lt;p&gt;Solana separates them.&lt;/p&gt;

&lt;p&gt;A Solana program is mostly stateless.&lt;/p&gt;

&lt;p&gt;Instead:&lt;/p&gt;

&lt;p&gt;Program account → stores executable code&lt;br&gt;
Data accounts → store application state&lt;/p&gt;

&lt;p&gt;Think of it like this:&lt;/p&gt;

&lt;p&gt;Web2 Backend    Solana&lt;br&gt;
Express server  Program&lt;br&gt;
PostgreSQL database Data accounts&lt;/p&gt;

&lt;p&gt;The program reads and writes data from separate accounts passed into each transaction.&lt;/p&gt;

&lt;p&gt;This architecture allows Solana to process many transactions in parallel because the runtime already knows which accounts a transaction will touch.&lt;/p&gt;

&lt;p&gt;Rent Exemption&lt;/p&gt;

&lt;p&gt;Accounts on Solana are not free.&lt;/p&gt;

&lt;p&gt;Every account must maintain a minimum SOL balance based on how much data it stores.&lt;/p&gt;

&lt;p&gt;This is called rent exemption.&lt;/p&gt;

&lt;p&gt;Why?&lt;/p&gt;

&lt;p&gt;Because validators need storage resources to keep accounts on-chain.&lt;/p&gt;

&lt;p&gt;For a basic empty account, the minimum balance is roughly:&lt;/p&gt;

&lt;p&gt;0.00089 SOL&lt;/p&gt;

&lt;p&gt;Larger accounts require more lamports.&lt;/p&gt;

&lt;p&gt;You can calculate rent exemption using:&lt;/p&gt;

&lt;p&gt;solana rent &lt;/p&gt;

&lt;p&gt;Or through the RPC method:&lt;/p&gt;

&lt;p&gt;getMinimumBalanceForRentExemption&lt;/p&gt;

&lt;p&gt;If an account doesn’t maintain enough balance, it may eventually be cleaned up by the network.&lt;/p&gt;

&lt;p&gt;Example Account Output&lt;/p&gt;

&lt;p&gt;Here’s what a typical account might look like:&lt;/p&gt;

&lt;p&gt;{&lt;br&gt;
  "lamports": 2039280,&lt;br&gt;
  "owner": "11111111111111111111111111111111",&lt;br&gt;
  "executable": false,&lt;br&gt;
  "rentEpoch": 18446744073709551615,&lt;br&gt;
  "data": ["", "base64"]&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;Now you can actually read this:&lt;/p&gt;

&lt;p&gt;It holds some SOL&lt;br&gt;
It’s controlled by the System Program&lt;br&gt;
It is not executable&lt;br&gt;
It stores no custom data&lt;br&gt;
It is rent exempt&lt;/p&gt;

&lt;p&gt;That’s the account model in action.&lt;/p&gt;

&lt;p&gt;Why Solana Uses This Design&lt;/p&gt;

&lt;p&gt;At first, separating programs from state can feel awkward.&lt;/p&gt;

&lt;p&gt;But it gives Solana major advantages:&lt;/p&gt;

&lt;p&gt;better parallel transaction execution&lt;br&gt;
predictable state access&lt;br&gt;
flexible storage patterns&lt;br&gt;
improved scalability&lt;/p&gt;

&lt;p&gt;Instead of programs hiding internal storage, all state is explicit and passed into transactions directly.&lt;/p&gt;

&lt;p&gt;That design is one of the reasons Solana can achieve very high throughput.&lt;/p&gt;

&lt;p&gt;Final Thoughts&lt;/p&gt;

&lt;p&gt;The Solana account model is the foundation of everything on the network.&lt;/p&gt;

&lt;p&gt;Once you understand:&lt;/p&gt;

&lt;p&gt;accounts&lt;br&gt;
ownership&lt;br&gt;
data storage&lt;br&gt;
rent exemption&lt;br&gt;
stateless programs&lt;/p&gt;

&lt;p&gt;…you can understand how tokens, NFTs, DeFi protocols, and nearly every Solana application works internally.&lt;/p&gt;

&lt;p&gt;For Web2 developers, the biggest mental shift is this:&lt;/p&gt;

&lt;p&gt;On Solana, programs behave more like APIs interacting with databases than traditional objects storing their own internal state.&lt;/p&gt;

&lt;p&gt;And honestly, once that clicks, the entire ecosystem becomes much easier to understand.&lt;/p&gt;

&lt;p&gt;For more details, check out the official documentation from Solana Foundation and the developer resources on Solana Docs and DEV Community.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
