npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@rapidaai/nodejs

v1.0.20

Published

NodeJS sdk for rapidaai platform

Readme

Rapida Node.js SDK

The official Node.js SDK for the Rapida Voice AI platform. This SDK provides comprehensive API clients for building voice-enabled applications with Rapida's microservices.

Installation

npm install @rapidaai/nodejs
# or
yarn add @rapidaai/nodejs
# or
pnpm add @rapidaai/nodejs

Quick Start

import { 
  ConnectionConfig, 
  GetAssistant, 
  GetAssistantRequest 
} from '@rapidaai/nodejs';

// Create a connection to Rapida services
const config = new ConnectionConfig({
  assistantHost: 'localhost:9007',
  integrationHost: 'localhost:9004',
  endpointHost: 'localhost:9005',
  documentHost: 'localhost:9010',
});

// Use the assistant service
const request = new GetAssistantRequest();
request.setId('your-assistant-id');

const response = await GetAssistant(config, request);
console.log(response);

Available Clients

The SDK provides clients for the following Rapida services:

Core Services

  • Assistant API - Manage assistants, conversations, and voice deployments
  • Integration API - LLM provider integrations (OpenAI, Anthropic, Gemini, etc.)
  • Endpoint API - Endpoint management and invocation
  • Knowledge API - Knowledge base and document management
  • Deployment API - Assistant deployment configuration
  • Document API - Document processing and indexing

Auth & Account Services

  • Web API - Authentication, users, organizations, projects, vaults
  • Auth Client - User authentication flows (OAuth, email/password)
  • Connect Client - OAuth provider connections

Utility Services

  • Talk Client - Telephony and real-time communication
  • WebRTC Client - WebRTC signaling and media
  • Notification Client - Notification management
  • Invocation Client - Custom endpoint invocation

API Reference

Connection Configuration

const config = new ConnectionConfig({
  // Service endpoints
  assistantHost: 'localhost:9007',
  integrationHost: 'localhost:9004',
  endpointHost: 'localhost:9005',
  documentHost: 'localhost:9010',
  webHost: 'localhost:9001',
  
  // Authentication
  auth: {
    principal: 'user-or-service',
    apiKey: 'your-api-key', // optional
    token: 'jwt-token', // optional
  }
});

Example: Create an Assistant

import {
  CreateAssistantRequest,
  CreateAssistant,
  ConnectionConfig,
} from '@rapidaai/nodejs';

const config = new ConnectionConfig({
  assistantHost: 'localhost:9007',
});

const request = new CreateAssistantRequest();
request.setName('My Voice Assistant');
request.setDescription('A great voice assistant');
request.setLanguage('en');

const response = await CreateAssistant(config, request);
console.log('Assistant created:', response.getId());

Example: Retrieve Knowledge Base

import {
  GetAllKnowledgeRequest,
  GetAllKnowledge,
  ConnectionConfig,
} from '@rapidaai/nodejs';

const config = new ConnectionConfig({
  documentHost: 'localhost:9010',
});

const request = new GetAllKnowledgeRequest();
const response = await GetAllKnowledge(config, request);
console.log('Knowledge bases:', response.getKnowledgesList());

Build Output

The SDK is built in three formats:

  • ESM - dist/index.mjs - For use with import statements
  • CJS - dist/index.cjs - For use with require() statements
  • DTS - dist/index.d.ts / dist/index.d.mts - TypeScript type definitions

All formats are automatically selected based on your module resolution in package.json.

Known Limitations

The following features are not yet available in the proto definitions and will return "not implemented" errors:

  • GetAllDeployment() - Marketplace API proto definitions not available
  • GetAllProvider(), GetAllToolProvider() - Provider API proto definitions not available
  • CreateToolCredential() - Tool credential management not yet implemented
  • Content type utilities - Core Content proto type not available in common_pb

These will be implemented once the corresponding proto definitions are generated and available.

Development

Building from Source

npm install
npm run build

Running Tests

npm test
npm run test:watch
npm run test:coverage

Cleaning Build Output

npm run clean

Architecture

The SDK is structured around gRPC services with the following key components:

  • Connection Config - Manages service client connections
  • Proto Clients - Auto-generated gRPC service clients
  • Client Functions - High-level async functions wrapping gRPC calls
  • Types - TypeScript interfaces and proto message types

All inter-service communication uses gRPC with multiplexed HTTP/2, gRPC-Web, and HTTP support on single ports per service.

Contributing

Contributions are welcome! Please ensure all changes pass the build and tests:

npm run build
npm test
npm run test:coverage

License

MIT

Support

For issues, feature requests, or questions: