Introducing the Better Auth Chargebee plugin: Use it to handle subscriptions, billing, and auth seamlessly.Try now
ChargebeechargebeeAPI

Java SDK

The official Chargebee Java SDK provides a convenient way to interact with the Chargebee API from your Java applications.

Installation

Requirements

  • Java 1.8 or later

Quick Start

Create a Resource

List & Pagination

Idempotent Requests

Use per-request options to pass an idempotency key:

Error Handling

The SDK provides a comprehensive exception hierarchy with strongly-typed error enums:

Webhooks

The SDK provides a WebhookEventHandler for processing webhook events with optional Basic Auth verification:

Without Basic Auth:

Retry & Rate Limits

Retries are disabled by default. Enable with RetryConfig on the client builder:

Per-request retry overrides:

Rate-limited responses (HTTP 429) are automatically retried after the Retry-After duration.

Migration Guide

v3 support ends December 31, 2026. See the v3 to v4 migration guide for upgrade instructions.