To install Libra gRPC on Node.js, open your terminal and run:
npm install libra-grpc --save
var libra = ;// Init gRPC clientvar client = 'ac.testnet.libra.org:8000';// Get account statevar params =address: Buffer;client;// If a callback is not provided, a Promise is returnedclient;
Get account state
Get the latest state for an account.
var params =address: Buffer;client;
Get account transaction
Get the committed transaction by account and sequence number.
var params =account: Buffersequence_number: 1fetch_events: true;client;
Get event by account and path.
var params =access_path:address: Bufferstart_event_seq_num: 2ascending: truelimit: 10;client;
Get the committed transaction by range
var params =start_version: 1limit: 10fetch_events: true;client;
If you believe you're experiencing a bug with or want to report incorrect documentation, open an issue on our issue tracker. For a more real-time avenue of communication, check out the Discord or Telegram servers. There you'll find community members who can help answer about development questions.