Skip to main content

TypeScript SDK

The official TypeScript SDK provides typed functions for every API endpoint with full autocomplete and compile-time type checking.

Installation

Published on npm — @journeybee/sdk:

Quick start

Authentication

Pass your API key to client.setConfig(). The SDK sends it as a Bearer token on every request automatically.

Request patterns

Every SDK function accepts an options object with typed path, query, and body fields depending on the endpoint.

List with pagination and filters

Get by UUID

Create

Update

Delete

Sub-resources

Error handling

SDK functions return { data, error, response }. Check error for failures:

Available functions

The SDK exports one function per API endpoint. Function names match the operationId in the API Reference: Plus sub-resource functions like addLeadTag, listLeadNotes, createPartnerContact, getDealCommission, addResourceBlock, addRoomBlock, addRoomTier, and more. See the API Reference for the complete list.