SDKs & Client Libraries

Official client libraries and SDKs to help you integrate with the Mahalo Health API more easily.

Available SDKs

We provide official SDKs for the following languages and platforms:

JavaScript / TypeScript

Stable

A fully-typed JavaScript/TypeScript SDK for Node.js and browser environments.

Latest: v1.5.2

Python

Stable

A Python SDK with async support for Python 3.7+ applications.

Latest: v1.3.0

Ruby

Stable

A Ruby gem for integrating with the Mahalo Health API in Ruby applications.

Latest: v1.2.1

Java

Beta

A Java SDK for integrating with the Mahalo Health API in Java applications.

Latest: v0.9.0

Getting Started

Here's how to get started with our SDKs:

Installation

# Using npm
npm install @mahalo-health/sdk

# Using yarn
yarn add @mahalo-health/sdk

# Using pnpm
pnpm add @mahalo-health/sdk

Basic Usage

import { MahaloClient } from '@mahalo-health/sdk';

// Initialize the client
const client = new MahaloClient({
  clientId: 'YOUR_CLIENT_ID',
  clientSecret: 'YOUR_CLIENT_SECRET',
  environment: 'production' // or 'sandbox' for testing
});

// Example: Fetch patients
async function getPatients() {
  try {
    const patients = await client.patients.list({
      limit: 10,
      offset: 0
    });
    
    console.log('Patients:', patients.data);
    console.log('Pagination:', patients.pagination);
  } catch (error) {
    console.error('Error fetching patients:', error);
  }
}

getPatients();

SDK Features

  • Automatic authentication and token management
  • Type-safe API interfaces (where language supports it)
  • Automatic pagination handling
  • Comprehensive error handling
  • Retry mechanisms for transient failures
  • Logging and debugging tools
  • Full coverage of all API endpoints

Community Libraries

In addition to our official SDKs, there are several community-maintained libraries for integrating with the Mahalo Health API:

LibraryLanguageMaintainerLink
mahalo-goGoCommunityGitHub
mahalo-phpPHPCommunityGitHub
mahalo-dotnet.NETCommunityGitHub

Note: Community libraries are not officially supported by Mahalo Health. Use at your own discretion.

OpenAPI Specification

If you prefer to generate your own client or need to integrate with a language we don't support yet, you can use our OpenAPI specification: