Network

NetworkConfig is used consistently across all Colibri tools—pipelines, processes, plugins, and utilities. Use the built-in configurations for common networks or define your own with full compatibility.

type NetworkConfig = {
  rpcUrl: string;
  networkPassphrase: string;
  type: NetworkType;
  archiveRpcUrl?: string;
  horizonUrl?: string;
  friendbotUrl?: string;
  allowHttp?: boolean;
};

Built-in Configurations

Create network configurations for TestNet, MainNet, or FutureNet:

TestNet

import { NetworkConfig } from "@colibri/core";

const network = NetworkConfig.TestNet();

console.log(network.rpcUrl); // "https://soroban-testnet.stellar.org:443"
console.log(network.horizonUrl); // "https://horizon-testnet.stellar.org"
console.log(network.friendbotUrl); // "https://friendbot.stellar.org"
console.log(network.networkPassphrase); // "Test SDF Network ; September 2015"

MainNet

FutureNet

Custom Configuration

Override default URLs when needed:

Configuration Options

Option
Type
Description

rpcUrl

string

Soroban RPC endpoint

archiveRpcUrl

string?

Archive RPC for historical data

horizonUrl

string?

Horizon API endpoint

friendbotUrl

string?

Friendbot URL (TestNet/FutureNet only)

allowHttp

boolean?

Allow non-HTTPS connections

Network Providers

Pre-configured setups for known infrastructure providers in the Stellar ecosystem with public infrastructure:

Colibri's CI pipeline checks that all listed provider servers are up and healthy before publishing new package versions, ensuring an up-to-date and reliable list.

Archive RPC

Archive RPC endpoints provide access to historical data beyond the standard RPC retention window (~17 days). Required for:

  • Historical event ingestion

  • Past ledger queries

  • Transaction history lookups

Checking Archive Availability

Network Types

Checking Network Type

Network Passphrases

Each network has a unique passphrase used for transaction signing:

Access via config:

Example of Usage with Pipelines

All pipelines accept a NetworkConfig:

Next Steps

  • Pipelines — Use network config in transactions

  • RPC Streamer — Stream events and ledgers from the network

  • Tools — Use Friendbot for TestNet funding

Last updated