Stellar Plus
  • Welcome
  • Quick Start
  • Welcome
  • Quick Start
  • 🎓Tutorials
    • Issuing your first asset
    • Bulk Payments
    • E2E Certificate of Deposit demo
    • Creating a new contract client
  • 📄Reference
    • Account
      • Base
      • Default Account Handler
      • Freighter Account Handler
    • Asset
      • Classic Asset Handler
      • Stellar Asset Contract Handler
      • Soroban Token Handler
    • Network
    • Contract Clients
      • Certificate of Deposit Client
    • Core
      • Contract Engine
      • Pipelines
        • Build Transaction
        • Classic Signing Requirements
        • Fee Bump
        • Sign Transaction
        • Soroban Auth
        • Simulate Transaction
        • Soroban Get Transaction
        • Submit Transaction
        • Soroban Transaction
        • Classic Transaction
    • Utils
      • Plugins
        • Fee Bump Plugin
        • Channel Accounts Plugin
        • Auto Restore Plugin
        • Profiler Plugin
      • Pipeline
        • Conveyor Belt
        • Multi-belt Pipeline
    • RPC
      • Default RPC Handler
      • Validation Cloud RPC Handler
    • Horizon Handler
Powered by GitBook
On this page
  • Advantages of Using ValidationCloudRpcHandler
  • Getting Started
  • Usage
  • Reference

Was this helpful?

Edit on GitHub
  1. Reference
  2. RPC

Validation Cloud RPC Handler

PreviousDefault RPC HandlerNextHorizon Handler

Last updated 1 year ago

Was this helpful?

The ValidationCloudRpcHandler serves as an alternative for interacting with Stellar's Soroban smart contracts through a third-party RPC service provided by . It is a specialized adapter designed to facilitate interaction with Stellar's Soroban smart contracts. This is achieved through the use of a third-party Remote Procedure Call (RPC) service offered by Validation Cloud. This alternative method of interaction provides developers with the option to leverage dedicated infrastructure and advanced features for executing and managing smart contracts on the Stellar network.

In scenarios where no specific handler is provided, Stellar Plus core engines default to directly connecting to RPC url present in the networkConfig parameters through the usage of the .

Advantages of Using ValidationCloudRpcHandler

Opting for ValidationCloudRpcHandler presents several benefits, especially for developers seeking a streamlined and enhanced interaction with Soroban smart contracts:

  • Dedicated Infrastructure: Access to a specialized infrastructure tailored for high-load Soroban smart contract operations, providing enhanced performance stability and uptime.

  • Resource Consumption Monitoring: Includes tools for detailed observation of resource usage, facilitating the optimization of smart contract execution and resource allocation.

  • Simplified Integration Process: Streamlines the connection to Soroban smart contracts through a straightforward API, reducing setup complexity and technical overhead.

Getting Started

To begin utilizing the ValidationCloudRpcHandler Soroban smart contracts, developers need to follow these steps:

  1. Create an Account: Sign up for an account with to access their services.

  2. Opt for the Free Tier: Choose the free tier offering to explore the services without immediate investment.

  3. Generate an API Key: Obtain an API key specifically for the Soroban API. This key will authenticate and authorize your interactions with the smart contracts through Validation Cloud.

Usage

The ValidationCloudRpcHandler integrates seamlessly into the Soroban Transaction pipeline, allowing developers to easily switch between the default direct connection and Validation Cloud's service API. This is particularly useful for applications requiring enhanced performance, reliability, and feature set beyond what the Stellar network offers by default.

Example Code Snippet

const vcRpcHandler = new StellarPlus.RPC.ValidationCloudRpcHandler(
  network,
  '<YOUR API KEY>'
)

const codClient = new StellarPlus.Contracts.CertificateOfDeposit({
  networkConfig,
  contractParameters: {
    wasm: wasmBuffer,
  },
  options: {
    sorobanTransactionPipeline: {
      customRpcHandler: vcRpcHandler,
    },
  },
})

Reference

For a complete example using the Validation Cloud RPC integration, refer to the .

For a comprehensive understanding of RPC in the Soroban context, including technical details and usage examples, refer to the official Soroban documentation: .

📄
Validation Cloud
Default RPC Handler
Validation Cloud
E2E Certificate of Deposit demo tutorial
Soroban RPC Reference