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

slotflow

v0.1.1

Published

Node.js SDK for the Slotflow API — scheduling infrastructure for AI agents

Readme

Slotflow Node.js SDK

npm version License: MIT

Official Node.js/TypeScript SDK for the Slotflow API — scheduling infrastructure for AI agents.

Slotflow lets your AI agent check availability, book appointments, and manage the full booking lifecycle for real humans — without breaking the agent workflow.

Installation

npm install slotflow

Quick Start

import { SlotflowClient } from "slotflow";

const client = new SlotflowClient({
  token: "sk_live_your_api_key",
});

// 1. Create a human whose time can be booked
const human = await client.humans.createHuman({
  name: "Sarah Chen",
  email: "[email protected]",
  role: "sales_rep",
  timezone: "America/New_York",
});

// 2. Find available slots
const { slots } = await client.slots.getAvailableSlots({
  humanId: human.data.id,
  date_from: "2026-03-15",
  date_to: "2026-03-20",
  duration: 30,
});

// 3. Book a slot
const booking = await client.bookings.createBooking({
  human_id: human.data.id,
  starts_at: slots[0].start,
  duration: 30,
  attendee_name: "Alex Rivera",
  attendee_email: "[email protected]",
  metadata: {
    lead_id: "lead_8294",
    conversation_id: "conv_1847",
    source: "ai_sdr",
  },
});

Features

  • Full TypeScript support — typed requests, responses, and errors
  • All API resources — humans, availability, schedule overrides, slots, bookings, webhooks
  • Automatic retries — built-in retry with configurable attempts (default: 2)
  • Timeouts — configurable per-client and per-request (default: 60s)
  • Error handling — typed error classes for 402, 404, 409, 422 responses
  • Custom fetch — bring your own fetch implementation for any runtime

API Resources

| Resource | Methods | |---|---| | client.humans | createHuman, getHuman, listHumans, deleteHuman | | client.availability | setAvailability | | client.scheduleOverrides | createOverride, listOverrides, deleteOverride | | client.slots | getAvailableSlots | | client.bookings | createBooking, listBookings, cancelBooking | | client.webhooks | createWebhook, listWebhooks, deleteWebhook |

Error Handling

import { SlotflowClient, Slotflow } from "slotflow";

try {
  await client.bookings.createBooking({ /* ... */ });
} catch (error) {
  if (error instanceof Slotflow.ConflictError) {
    // 409 — slot was just booked by someone else, retry with next slot
  }
  if (error instanceof Slotflow.PaymentRequiredError) {
    // 402 — booking limit reached
  }
  if (error instanceof Slotflow.NotFoundError) {
    // 404 — human not found
  }
  if (error instanceof Slotflow.UnprocessableEntityError) {
    // 422 — validation error (outside working hours, invalid duration, etc.)
  }
}

Configuration

const client = new SlotflowClient({
  token: "sk_live_your_api_key",

  // Override the default timeout (seconds)
  timeoutInSeconds: 30,

  // Override the default retry count
  maxRetries: 3,

  // Custom fetch implementation (e.g. for edge runtimes)
  fetch: myCustomFetch,
});

Per-request overrides:

await client.bookings.listBookings({}, {
  timeoutInSeconds: 10,
  maxRetries: 0,
});

Requirements

Links

License

MIT