Skip to main content
The SW Combine SDK is a TypeScript library that lets you integrate your applications with the Star Wars Combine API. It covers all 60+ endpoints across characters, factions, the galaxy, inventory, market, news, events, and more — with full type safety, automatic token refresh, and built-in pagination.

Quick Start

Install the SDK and make your first API call in minutes.

Authentication

Set up OAuth 2.0 and obtain access tokens for authenticated endpoints.

API Resources

Explore all available resources: characters, factions, galaxy, inventory, and more.

Core Concepts

Understand client modes, pagination, error handling, and rate limits.

Why use this SDK?

The SW Combine SDK handles the complexity of the API so you can focus on building your application.

Type-Safe

Full TypeScript definitions with IntelliSense support for every endpoint, parameter, and response.

OAuth 2.0 Built-in

Complete OAuth flow with automatic token refresh — no manual token management required.

Auto-Pagination

Every list endpoint returns Page<T> with for await...of support to iterate all results.

Automatic Retries

Exponential backoff for network errors and rate limit responses, with respect for Retry-After headers.

Get started in three steps

1

Install the package

npm install swcombine-sdk
2

Initialize the client

import { SWCombine } from 'swcombine-sdk';

const client = new SWCombine({
  token: process.env.SWC_ACCESS_TOKEN!,
});
3

Make your first API call

const { uid, handle } = await client.character.getByHandle({
  handle: 'your-character-handle',
});

console.log(uid);    // "1:12345"
console.log(handle); // "your-character-handle"
Need an access token? See the Authentication guide to set up OAuth 2.0 and obtain your first token.