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

@sens-tools/api-service

v0.0.17

Published

A TypeScript-based API service library for SENS

Readme

@sens-tools/api-service

A TypeScript-based API service library that provides a flexible and modular way to interact with various API services. The library is designed to be extensible and can be used with or without tRPC integration.

Features

  • Modular service architecture
  • Type-safe API interactions
  • Optional tRPC integration
  • Support for multiple service types (common, timeseries, etc.)
  • Built with TypeScript for better developer experience

Installation

npm install @sens-tools/api-service
# or
yarn add @sens-tools/api-service
# or
pnpm add @sens-tools/api-service

Optional Dependencies

If you plan to use the tRPC functionality, you'll need to install the following peer dependencies:

npm install @trpc/client @trpc/server @trpc/react-query @tanstack/react-query
# or
yarn add @trpc/client @trpc/server @trpc/react-query @tanstack/react-query
# or
pnpm add @trpc/client @trpc/server @trpc/react-query @tanstack/react-query

Usage

Basic Usage

import { IotaApiServiceFactory } from '@sens-tools/api-service';

const apiConfig = {
  // Your configuration here
};

const apiService = new IotaApiServiceFactory(apiConfig);

// Access different services
const deviceService = apiService.device;
const deviceTypeService = apiService.deviceType;
const tenantService = apiService.tenant;
const timeseriesService = apiService.timeseries;

With tRPC

import { IotaApiServiceFactory } from '@sens-tools/api-service';

const apiConfig = {
  // Your configuration here
};

const apiService = new IotaApiServiceFactory(apiConfig);
const router = apiService.createRouter();

// Use the router with your tRPC setup

Configuration

The package accepts configuration through the ConfigInputIota interface. Detailed configuration options will be documented here.

Development

# Install dependencies
pnpm install

# Start development server
pnpm dev

# Build
pnpm build

# Lint
pnpm lint

# Format
pnpm format

Release Workflow

This project uses Changesets for versioning and releases. Here's how it works:

Making Changes

  1. Create a feature branch:

    git checkout -b feature/new-feature
  2. Make your changes and commit them:

    git add .
    git commit -m "feat: new feature"
  3. Create a changeset:

    pnpm changeset
    • Select the type of change (patch/minor/major)
    • Write a description of your changes
    • This creates a markdown file in the .changeset directory
  4. Push your changes:

    git push origin feature/new-feature

Release Process

The release process is fully automated:

  1. When your PR is merged to main, the GitHub Action checks for changesets
  2. If changesets are found, it creates a "Version Packages" PR
  3. After reviewing and merging this PR:
    • The package version is bumped
    • A changelog is generated
    • A new release is published to npm
    • A GitHub release is created

Manual Release (if needed)

If you need to trigger a release manually:

# Create a changeset
pnpm changeset

# Version packages
pnpm version

# Publish
pnpm release

CI/CD Pipeline

Our CI/CD pipeline ensures code quality and reliability through the following stages:

Build Stage

  • TypeScript compilation
  • Linting with ESLint
  • Code formatting with Prettier
  • Bundle size checks

Test Stage

  • Unit tests with Jest
  • Integration tests
  • Code coverage reports
  • Performance benchmarks

Quality Assurance

  • Security scanning with Snyk
  • Dependency audit
  • Documentation generation
  • API compatibility checks

Deployment

  • Version bumping
  • Changelog generation
  • NPM package publishing
  • GitHub release creation

The pipeline runs automatically on:

  • Every push to main branch
  • Every pull request
  • Every release tag

TODOs

  • [ ] Add comprehensive documentation for configuration options
  • [ ] Add examples for different use cases
  • [ ] Add unit tests
  • [ ] Add integration tests
  • [ ] Add CI/CD pipeline
  • [ ] Add contribution guidelines
  • [ ] Add changelog
  • [ ] Add license information
  • [ ] Add code of conduct
  • [ ] Add issue templates
  • [ ] Add pull request templates

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

License

This project is proprietary software. See LICENSE.md for details.