Skip to content

Because you've got better things to do than write another RPC poller.

License

Notifications You must be signed in to change notification settings

SolixDB/package

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SolixDB

npm npm-downloads github

Overview

solixdb is a lightweight, configurable, and high-performance indexing package for Solana. Use it to listen for on-chain events and stream them directly into your database of choice.

Installation

For use in your Node.js application

npm install --save solixdb

Minimal Example

import { SolanaIndexer, JSONStorage } from 'solixdb';

// Initialize storage
const storage = new JSONStorage('./blockchain-data.json');

// Configure indexer
const indexer = new SolanaIndexer(
  {
    env: 'mainnet',
    type: 'transaction',
    accounts: ['TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'],
    pollInterval: 5000,
  },
  storage
);

// Start indexing
await indexer.start();

// Query indexed data
const transactions = await indexer.query({});
console.log(`Indexed ${transactions.length} transactions`);

// Stop indexer
await indexer.stop();

Contributing

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

License

MIT License

About

Because you've got better things to do than write another RPC poller.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 2

  •  
  •