SolanaFM Developer Portal Deep Dive

Joseph Appolos
20 min readMar 7, 2023

The Developer Portal is a recently launched product by SolanaFM that represents a significant advancement in its mission.

Article Banner

Introduction

Blockchain technology is a distributed ledger that promises a revolutionary new way of storing, sharing, and verifying data. It allows the creation of a decentralized and transparent network, where trust is built through consensus and cryptography rather than relying on central authorities. Blockchain has the potential to transform virtually every industry, from finance and supply chain management to healthcare and voting systems. With its unique combination of security, transparency, and decentralization, blockchain has captured the imagination of developers, entrepreneurs, and investors worldwide.

Several recent developments have spurred high adoption of blockchain technology. Decentralized Finance (DeFi) refers to a set of financial applications and services built on blockchain technology and operate without intermediaries such as banks. DeFi platforms allow users to lend, borrow, and trade digital assets in a decentralized and permissionless manner. NFTs (Non-Fungible Tokens) are a type of digital asset stored on the blockchain, representing ownership of a unique item, such as artwork or collectibles. Central Bank Digital Currencies (CBDCs) are gaining traction worldwide, exploring the idea of creating their digital currencies on the blockchain.

Solana is one of the most exciting blockchain platforms in the world right now, known for its high performance and speed. It can process over 65,000 transactions per second (TPS), low-fee transactions, and high scalability features that have facilitated its rapid growth and adoption. Solana has emerged as a powerful platform for decentralized applications (dApps), attracting developers and entrepreneurs worldwide. With a large ecosystem of an active community, participants, and contributors, Solana provides new opportunities for developers to build innovative dApps that can operate at lightning-fast speeds and at low cost. As blockchain technology continues to evolve and mature, we can expect to see even more innovative and impactful use cases emerge.

One platform that provides the perfect solution for unlocking the full potential of Solana’s powerful capabilities is SolanaFM, the most user-friendly blockchain explorer, API, and analytics platform offering Solana indexing solutions. Recently, SolanaFM launched its developer portal, which provides a range of tools and resources for developers to create new and innovative dApps on the Solana blockchain. In this article, we will explore the SolanaFM developer portal, including its technical aspects, what it offers developers, how easy it is to build using the Developer Portal, how it contributes to the growth and development of the Solana ecosystem, and much more.

What is SolanaFM?

As the Solana ecosystem continues to grow, the demand for on-chain data analysis and queries also skyrocketed. However, users such as investors, developers, and data analysts face difficulties accessing the original Solana data due to limited functions and restrictions on API calls in current block explorers. SolanaFM has positioned itself to fill this gap in the market.

SolanaFM is a platform that indexes data from the Solana blockchain ecosystem. It was introduced in late 2020, just months after Solana was launched. The phrase “indexing,” which is the primary function of SolanaFM, refers to a three-step process.

Firstly, the indexer collects the original data from all nodes on the blockchain network. Nodes are essentially computers participating in the blockchain network and storing a copy of the blockchain data.

Secondly, the indexer processes the original data and converts it into a format that can be easily queried by users. This means the data is organized and structured to allow users to easily search and retrieve specific pieces of information.

Finally, the indexer stores the processed data in a database, allowing users to quickly and easily access the needed data. This database acts as a central store for all data on the Solana blockchain network that has been indexed and processed by SolanaFM.

In simpler terms, SolanaFM is like a librarian that collects all the books (data) from different libraries (nodes), organizes them in a way that makes it easy for people to find specific information, and stores them in a central location (database) where people can easily access them. By doing this, SolanaFM provides a valuable service to developers and users who need to access data from the Solana blockchain network quickly and efficiently.

SolanaFM’s landing page

The SolanaFM Developer Portal

The Developer Portal is a recently launched product by SolanaFM that represents a significant advancement in its mission. This product is designed to serve as a centralized hub, offering developers a one-stop shop for all their Anchor IDL (and any other IDL) indexing needs. By consolidating all the necessary tools and resources in a single location, the Developer Portal streamlines the development process and helps save developers valuable time and effort. With the Developer Portal, developers can easily access documentation, support, and other resources to help them create, test, and deploy their applications quickly and efficiently.

Editor’s Note: Anchor is one of the most popular languages for writing Solana smart contracts among developers. It is a robust framework designed to provide a reliable solution for efficiently building secure Solana programs. One of the main advantages of using Anchor is its ability to automate various boilerplate tasks, such as (de)serialization of accounts and instruction data which empowers developers to focus on building their program more quickly. The framework also provides robust security features that make it easier for developers to build secure programs. Anchor automates certain security checks, including account ownership validation, and allows for adding custom security checks that are kept separate from the business logic. This approach enhances the security of the programs and ensures that they remain organized and easy to maintain.

The Developer Portal is a valuable tool that gives developers easy access to index and query on-chain data. Its main objective is to offer a reliable infrastructure for data indexing, freeing up developers and teams to focus on developing high-quality products for their users.

By streamlining the indexing and querying process, the Developer Portal eliminates the need for developers to spend valuable time and resources on tedious and time-consuming tasks of setting up & maintaining their data infrastructure. With the Portal’s user-friendly interface, developers can quickly and efficiently access the data they need, making it easier to create innovative solutions in the Solana ecosystem.

What can you do on the Developer Portal?

The Developer Portal provides developers with several capabilities to facilitate their indexing process and ensure a smoother experience. Some of them are:

1. On-Demand Indexing

Blockchain technology stores encrypted data blocks in a decentralized network chained together and keeps records of new transactions and information from the previous block. However, blockchain data lacks a default mechanism for high-level identification or querying due to its time-ordered structure. Indexing allows users to search for specific data or keywords, similar to search engines like Google or Bing. Examples of data retrieved from blockchain indexing include historic token swaps, liquidity provision, token prices, the total volume across all trading pairs, and pool TVL.

Decentralized infrastructures present several obstacles to indexing and querying accurate information, such as a lack of a query language and the immutable nature of the blockchain, which makes it challenging to read data directly, and necessitates processing large amounts of data when building a dApp. Secondly, data entanglement (where specific blockchains spread historical records across different parts of the node, some of which are restricted) and limited APIs that can only offer simple queries like range or top-k queries.

By using SolanaFM’s developer portal, developers can simply upload any anchor-based Interface Definition Language (IDL) to retrieve all transaction data related to the IDL, including information down to the instruction level. The portal parses and decodes all transactions to human-readable data, allowing developers to quickly search, analyze, and use the data without having to go through the tedious process of manually decoding the transactions themselves.

Uploading an IDL and indexing it on the developer portal

You can retrieve IDLs from SolanaFM or SolDev to index any program’s data on demand through the developer portal. The process takes less than 30 seconds — each indexer captures all transactions within the IDL’s instructions.

Obtaining an IDL from solana.fm

Users can upload and index IDLs for different networks (Mainnet or Devnet) on the developer portal by simply switching the network via the dropdown beside their wallet connection. Additionally, SolanaFM performs validation checks, including verifying the IDL with the latest successful on-chain transaction (for that program), which can be confirmed using the Transaction Hash field in the modal.

2. API Queries

The developer portal provides a fast, efficient, and scalable suite of APIs for data extracted from your indexed program(s). API stands for Application Programming Interface. It is a set of protocols, routines, and tools for building software applications that specify how software components should interact with each other.

The portal API offers a user-friendly experience by utilizing the robust Rust programming language and following the widely-used REST API structure to provide developers with seamless integration of Solana into their applications.

The platform issues API keys for increased access and efficiency of the portal. API Keys play an essential role in managing and controlling access to APIs. By incorporating API Keys in your API calls, you can enhance the rate limits of your API. For instance, in the developer portal’s API, users can start with a default rate of 5 requests per second. However, upon using API Keys, users can increase their limit up to 15 requests per second. This enables users to send more requests to the API, consequently enabling them to fetch more data and perform operations faster.

Generating an API key on the portal

To generate an API key, head over to the API Key page, input a preferred name, select the expiry date, and click “Generate API Key.” NOTE: The API Key alias is optional; a name will be generated for you if it’s not filled in.

Here’s an example of extracting data from the developer portal in the image below as we investigate the transactions invoking the placePerpOrderV2 instruction in Zeta Markets.

Extracting data from Zeta Markets via API call

3. Webhooks

Webhooks are one way that apps can send automated messages or information to other apps. It facilitates communication between different systems. For example, webhooks enable your staking app to communicate with wallets (e.g., Backpack wallet) when users link their accounts, allow your app to verify NFTs that are used for users’ passports on MagicEden, enable a staking platform to view and authenticate LP token holders on Raydium, etc.

A webhook is an automatic message sent from one system to another when a specific event happens, like a purchase or a new user sign-up. The message includes information about the event and is sent using an internet protocol called HTTP.

The developer portal empowers you to create custom webhook subscriptions that can capture the exact data you need. Whether it’s transaction information or user behavior data, the portal provides complete flexibility in the IDLs indexed and the webhooks specified, allowing you to create highly personalized data streams that can be used to power your applications in the most efficient way possible. Developers can now seamlessly integrate their applications with the Solana blockchain network and leverage the data captured through webhook subscriptions to develop more robust and personalized features, ultimately enhancing the overall user experience.

Creating A Webhook Listener on the Developer Portal

A webhook listener is an URL endpoint that receives incoming webhooks and triggers a predefined action in response. When a webhook is fired from a source system, it is sent to the listener URL, which then processes the webhook payload and performs a specific action based on the information received. The listener acts as a bridge between the source and the destination systems, allowing for automated communication and data transfer.

To create a webhook subscription on the developer portal, you need to first add a webhook by clicking on the “Manage Webhooks” button and selecting “add.” Next, input your webhook URL. Once you have added a webhook, click on the “Add Subscriptions” button to select the program you want to subscribe to. Note that you can create a subscription for either Mainnet or Devnet by changing the network at the top and adding the subscription accordingly. Finally, under the “Adding a Webhook” section, pick Webhook URLs and the events/instructions available in the selected IDL.

creating a webhook on the developer portal

By creating webhook subscriptions, you can capture the data that is crucial to you. The process offers complete flexibility in the IDLs you index, which allows you to create accurate and tailored data streams to drive your applications. Below is an image result for sample results of instructions given to a webhook listener

Adding subscriptions to a webhook

4. Devnet Support

If you’re not ready to launch your program on the Mainnet, don’t worry. The Portal has got you covered with full support for Devnet programs. You can use Devnet to test your program and identify any critical bugs before launching on the Mainnet. By selecting the “Devnet” option on the portal, you can upload your Devnet IDL and access all the tools and features available to ensure your program runs smoothly.

When developing on a blockchain platform, it’s essential to test your IDL activity before launching it on the mainnet to avoid any potential issues. The Devnet environment provides a sandbox for developers to experiment with their IDL activity without the risk of affecting the main network. Developers can use the Devnet to access transaction data for thorough testing, verifying that their IDL works as intended and is suitable for deployment to the mainnet. This approach enables developers to identify and address any issue before launching on the mainnet, resulting in a more seamless and safe transfer to the production environment.

Switching from mainnet to devnet before uploading an IDL

5. Historical Indexing (Backfill)

Backfilling is a powerful feature on the developer portal that allows you to retrieve historical data for your chosen IDL, making data analysis and backtesting a breeze. With this feature, you can specify data ranges to be outlined and ensure that you have access to all the necessary information. To create a backfill job, you only need to select the intended block range, and the portal will handle the rest, making the process hassle-free. This tool is perfect for gaining insight into past market trends and behaviors, giving you the confidence to make informed decisions. However, it’s worth noting that backfilling is only accessible via Early Access.

Creating a Backfill Job

To create a Backfill Job, navigate to the ‘Backfill’ tab. From there, you can enter the block range you want to index. It’s important to note that users are currently limited to a range of 700,000 blocks per backfill job. You can contact the support team on Discord or Twitter if you need unlimited access. Once you’ve selected your block range, you’ll need to choose a previously uploaded IDL from the Indexer page. Remember that users are allowed to upload 3 IDLs per backfill job, which includes the selected previously uploaded IDL.

It’s recommended to upload older versions of your IDL if your program’s IDL has been updated since the latest version might fail to parse transactions from older blocks. This can prevent parse errors when backfilling. SolanaFM indexers will attempt to use all uploaded IDLs in the backfill job to parse the transaction; even if one fails, others will be used. However, it’s important to note that all the uploaded IDLs must share the same program hash, or the job will fail if all the IDLs fail to be verified with a transaction while the job is running.

Creating a backfill job on the developer portal

Benefits of Using the Developer Portal

The developer portals by SolanaFM provide a wide range of tools and resources that makes it easier for developers to build decentralized applications (dApps) on the Solana blockchain. The following are some of the benefits associated with using the platform, given how easy it has made the development of dApps on Solana.

  1. One key feature that makes the developer portal easy to use is its intuitive user interface. It was designed to simplify the development process by providing precise and easy-to-follow instructions and workflows. This makes it easier for developers to navigate through the different steps involved in developing a dApp, from indexing the blockchain to deploying them on the blockchain.
  2. The developer portal’s documentation and educational resources help make dApp development more manageable. These tools are created to aid developers in learning more about the portal, its capabilities, and how to use them to create effective dApps. By having all the information they need in one place, developers can save time and avoid having to search for information on different websites or forums.
  3. Code samples: The developer portal provides some code samples that developers can use on the platform. These code samples offer a starting point for developers to build on and can save time and effort. For example, their documentation’s “Querying our APIs” section provides several code samples on quarrying their API in different languages.
  4. Community support: SolanaFM has active developer communities (on Discord and Twitter), which the portal users can leverage. These communities support and guide developers as they build their dApps. Developers can ask questions, share ideas, get feedback on their projects, and seek support from other developers by using forums, chat rooms, dedicated channels on Discord, and other tools provided by SolanaFM.
  5. Easy Indexing and Efficiency: The SolanaFM developer portal makes it easy for developers to index and retrieve data from the Solana blockchain, enabling efficient development of dApps. With features like the Backfill Job tool, developers can quickly index large data blocks and filter them based on specific criteria. At the same time, the integrated Solana Explorer (by SolanaFM) provides a user-friendly interface for exploring and interacting with the blockchain.

Exploring the Possibilities: 5+ dApps that can be Built using the SolanaFM Developer Portal

Here are some potential dApps that can be built on the Solana blockchain with the aid of the SolanaFM developer portal, along with a brief explanation of how the portal’s technical features can help in their development.

1. Education Platform

A decentralized education platform can be built on the Solana blockchain that enables users to earn Solana-based tokens for learning new skills or completing courses. The platform can feature various courses from different fields of study, and users can earn tokens by completing assignments and assessments.

2. Freelance Platform

Freelancers can use a decentralized platform on Solana to offer their services and receive Solana-based tokens as payment. The platform can provide various categories such as writing, programming, graphic design, video editing, and more. Freelancers can showcase their skills and past works on the platform, and clients can browse through different categories to find suitable freelancers for their project needs. The platform can also include features like escrow payment, dispute resolution, and rating systems to ensure smooth transactions and quality work.

3. Real Estate dApp

A real estate dApp built on Solana can allow users to invest in various properties using Solana-based tokens. The dApp can provide a platform for investors to easily buy, sell, and trade real estate assets on the blockchain, potentially making the real estate market more accessible and transparent. Investors can choose from various investment options, such as rental properties, commercial real estate, and residential properties, and receive returns on their investments in Solana-based tokens. The dApp can also provide tools for investors to track their assets, monitor the performance of their properties, and receive alerts and notifications about important events, such as lease renewals or maintenance issues.

4. Decentralized Charity Platform

A decentralized charity platform can easily leverage the transparency and security of the Solana blockchain to enable users to donate Solana-based tokens to different charitable causes. This can provide a more efficient and cost-effective way of contributing to philanthropic causes, and users can have greater confidence that their donations are going to the intended recipients. The platform can also enable donors to track the impact of their donations, providing greater transparency and accountability. Additionally, the platform can support a range of causes, including healthcare, education, disaster relief, and more, enabling users to contribute to reasons that are important to them.

5. Decentralized Insurance Platform

A decentralized insurance platform can be created on the Solana blockchain, allowing users to use Solana-based tokens to purchase insurance policies. The platform could offer a range of insurance products, including health, auto, and property insurance. Since the platform would be decentralized, it could provide greater transparency and lower costs than traditional insurance providers. Smart contracts could be used to automate claims processing and ensure that payouts are made quickly and fairly.

6. Advertising Platform

An advertising platform can be built on the Solana blockchain, allowing advertisers to target specific audiences based on the past activities of their wallet and reward them for viewing ads. Users can earn Solana-based tokens for watching personalized and tailored ads relevant to their interests, while advertisers can reach their target audience more effectively. The platform can use data analytics and machine learning to improve ad targeting and engagement rates, and smart contracts can be used to ensure fair compensation for users.

7. Identity Verification Platform

By leveraging the Solana blockchain, a platform can be created for identity verification and credential authentication. Users’ true identities can be determined since their overall on-chain activity can be tracked after wallet creation, and numerous wallets can be authenticated (if they have any). Additionally, the platform will allow users to upload identity documents, educational certificates, and work experience and use Solana-based tokens to securely and accurately authenticate these credentials. The platform can offer additional features like background checks and reputation management to promote trustworthy user interactions.

Potential Crypto Bots that Can Be Built With the Aid of the Developer Portal

1. Liquidity Provision Bot: With the high throughput of Solana, it is possible to provide liquidity to multiple decentralized exchanges at once. A liquidity provision bot can be built on top of the platform to provide liquidity to several decentralized exchanges, which will enable traders to buy and sell cryptocurrencies at better prices. This bot can be programmed to monitor the liquidity pools on various exchanges, analyze the price movements, and provide liquidity accordingly.

2. Arbitrage Bot: Arbitrage trading involves taking advantage of price differences between different exchanges to make profits. An arbitrage bot can be built on the Solana blockchain to take advantage of price differences between various exchanges. The bot can be programmed to analyze the prices of different cryptocurrencies on multiple exchanges, identify price differences, and execute trades accordingly.

3. Social Trading Bot: Social trading is a new trend involving following successful traders’ trading activities and copying their trades. A social trading bot can be built on top of the Solana blockchain platform that enables traders to follow and copy the trades of successful traders on the different DEXes, CEXes, lending platforms, and perpetual and futures trading platforms. The bot can be programmed to analyze the trading activities of successful traders, identify profitable trades, and execute trades automatically for its users.

4. Market-Making Bot: These bots are commonly used in traditional financial markets to maintain liquidity and balance between buyers and sellers. A market-making bot can be built on the Solana blockchain platform to provide liquidity and balance to the Solana decentralized exchanges. The bot can be programmed to continuously monitor the order book of the decentralized exchanges and place buy and sell orders at specified prices.

5. Trading Bot: A trading bot can be built on top of the Solana blockchain platform that can execute trades automatically based on pre-defined trading strategies. The bot can be programmed to monitor the market, identify trading opportunities, and execute trades accordingly. The bot can be customized to implement various trading strategies, including technical analysis, trend-following, and mean-reversion strategies.

6. Portfolio Management Bot: A portfolio management bot can be built on the Solana blockchain platform to help users manage their cryptocurrency portfolios. The bot can be programmed to monitor the prices of various cryptocurrencies, calculate the value of the user’s portfolio, and automatically rebalance the portfolio based on pre-defined parameters. This bot can help users save time and reduce the risks associated with manual portfolio management.

7. News Aggregation Bot: Keeping up with the latest news and events in the cryptocurrency market can be challenging, especially for traders who are actively managing their portfolios. A news aggregation bot can be built on top of the Solana blockchain platform that aggregates news from various sources and delivers it to users in real time. The bot can be programmed to filter information based on keywords, sentiment analysis, and other criteria, which can help traders stay informed and make better-informed trading decisions.

8. Risk Management Bot: Cryptocurrency trading can be risky, and traders often have to deal with market volatility, price fluctuations, and other factors impacting their profitability. A risk management bot can be built on the Solana blockchain platform to help traders manage their risks effectively. The bot can be programmed to monitor the market, calculate the risk exposure of the user’s portfolio, and automatically execute trades to minimize the risks. This bot can help traders reduce their losses and maximize their profits.

9. Market Analysis Bot: Making informed trading decisions requires a thorough understanding of the market and the factors that drive price movements. A market analysis bot can be built on the Solana blockchain platform that uses advanced data analysis and machine learning algorithms to analyze the market and identify trading opportunities. The bot can be programmed to analyze market data such as order book depth, trading volume, and historical price data to generate insights and recommendations for traders. This bot can help traders make better-informed trading decisions and increase their profitability.

Areas of improvement

There are several ways or areas of improvement that the SolanaFM developer portal can consider:

a. Better documentation: The developer portal could improve its documentation to make it more comprehensive and user-friendly. It could provide more examples and use cases for developers to learn from, as well as more detailed guides on using different APIs and tools.

b. Improved debugging tools: The SolanaFM developer portal can enhance its debugging tools to facilitate developers in identifying and solving problems efficiently. One way to achieve this is by providing real-time logs, which can give developers a better understanding of the program flow and help identify issues quickly. The portal could also include an error tracking system that records errors and provides developers with detailed information on how to resolve them. Furthermore, the portal can incorporate advanced debugging tools, such as interactive debugging, that allow developers to step through their code and identify the root cause of the issue. With this feature, developers can quickly analyze their code line by line and locate any anomalies causing problems.

c. More comprehensive testing tools: The developer portal could offer more testing tools that allow developers to test their code in a sandbox environment before deploying it to the production network. This could include tools for unit testing, integration testing, and load testing.

d. Better developer support: The developer portal could offer better support to developers who have questions or need help with their code. This could include a dedicated support team, a community forum, or a chatbot that can provide immediate assistance. The support system on Discord needs to be improved because users will have to leave the portal to get support.

e. More sample codes: To aid developers in getting started on their projects, the developer portal could furnish additional sample code on their documentation page, such as templates, code snippets, and open-source projects that demonstrate best practices. This would assist developers in swiftly setting up and following industry standards.

f. Improved security features: The developer portal could provide more security features to help developers build secure applications. This could include tools for detecting and preventing common security vulnerabilities, as well as best practices for securing user data and preventing unauthorized access to applications.

g. More integration with other tools and platforms: To enhance the development experience for SolanaFM users, the developer portal could provide more robust integrations with commonly used tools and platforms. These integrations might include seamless connections with popular development environments, such as Visual Studio Code or Atom, to allow developers to write code more efficiently. The portal could also offer integrations with widely-used project management tools like Trello or Asana, enabling developers to manage their work more effectively. Additionally, the developer portal could provide integrations with code review and collaboration tools like GitHub or GitLab, allowing for more streamlined collaboration among team members.

Conclusion

The SolanaFM developer portal is a treasure trove of tools, resources, and support for developers looking to build decentralized applications on the Solana blockchain. With its user-friendly interface, extensive indexing capability, and robust APIs, the portal makes it easy for developers of all levels to get started on their projects and bring their ideas to life.

Whether you’re a seasoned developer or just starting out, the SolanaFM developer portal has everything you need to create cutting-edge decentralized applications that push the boundaries of what’s possible. From sample code and templates to integration with popular development tools and platforms, the portal provides a seamless and streamlined experience that allows you to focus on what matters — building great applications that solve real-world problems. So why wait? Sign up today and join the thriving Solana developer community!

References

--

--