SDKs

The Bias server SDKs are generated from the Bias OpenAPI specification. They wrap every API resource in a typed, idiomatic interface so you get autocompletion, compile-time checks, and consistent error handling without hand-writing HTTP calls.

Every SDK shares the same conventions: bearer-token authentication, cursor pagination, object expansion, and typed errors.

Available SDKs

LanguagePackageReference
TypeScript@biaspay/sdkTypeScript SDK
PythonbiaspayPython SDK
RustbiasRust SDK

If you are developing in a language that does not yet have an SDK, you can call the REST API directly, or let us know and we will consider adding one.

TypeScript

The TypeScript SDK is published on npm as @biaspay/sdk. Construct a client with your API key and call resource methods directly.

import { Bias } from "@biaspay/sdk";

const bias = new Bias(process.env.BIAS_API_KEY);

const customer = await bias.customers.create({
    name: "Acme, Inc.",
    email: "billing@acme.example",
});

See the TypeScript SDK for pagination, expansion, streaming, and error handling.

Python

pip install biaspay
from biaspay import Bias

client = Bias(api_key="sk_...")  # or set the BIAS_API_KEY environment variable

customer = client.customers.create(name="Acme, Inc.", email="billing@acme.example")

See the Python SDK for pagination, expansion, async, streaming, and error handling.

Rust

[dependencies]
bias = "1"
tokio = { version = "1", features = ["macros", "rt-multi-thread"] }
#[tokio::main]
async fn main() -> bias::Result<()> {
    let client = bias::Client::new(std::env::var("BIAS_API_KEY").unwrap());

    let customer = client
        .customers()
        .create(
            bias::CustomerCreateParams::builder()
                .name("Acme, Inc.")
                .email("billing@acme.example")
                .build(),
        )
        .await?;

    println!("created {:?}", customer);
    Ok(())
}

See the Rust SDK for pagination, streaming, error handling, and cargo features.