Linkbreakers SDKRust

Linkbreakers Rust SDK

Integrate link management and QR code tracking into your Rust applications. Memory-safe with async/await support, zero-cost abstractions, and WebAssembly compilation.

crates.ioGitHubv1.0.0linkbreakers
Install via Cargo
One command
Open source
GitHub
API coverage
Complete

Why use the Rust SDK

Integrate Linkbreakers into your Rust stack with type-safe, production-ready methods.

Full API coverage

Every Linkbreakers dashboard feature is available through the SDK — links, workflows, QR codes, analytics, domains, and visitor tracking.

Type-safe and documented

Generated from the OpenAPI specification with full type definitions, IDE autocomplete, and inline documentation.

Production-ready

Built-in error handling, retry logic support, and authentication management. Open source on GitHub with active maintenance.

Quick start

Install the SDK, authenticate, and make your first API call.

Install
Cargo
[dependencies]
linkbreakers = "1.0"
Create a tracked link
use linkbreakers::{Configuration, LinksApi, CreateLinkRequest};

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let config = Configuration {
        base_path: "https://api.linkbreakers.com".to_string(),
        bearer_access_token: Some(
            std::env::var("LINKBREAKERS_SECRET_KEY")?
        ),
        ..Default::default()
    };

    let api = LinksApi::new(config);
    let request = CreateLinkRequest {
        destination: "https://example.com".to_string(),
        name: Some("Campaign Link".to_string()),
        tags: Some(vec!["marketing".to_string()]),
        ..Default::default()
    };

    let response = api.links_service_create(request).await?;
    println!("Short URL: {}", response.link.unwrap().shortlink.unwrap());
    Ok(())
}
List links
let links = api.links_service_list(None, Some(20), None).await?;

for link in links.links.unwrap_or_default() {
    println!("{}: {}",
        link.name.unwrap_or_default(),
        link.shortlink.unwrap_or_default());
}
Error handling
match api.links_service_create(request).await {
    Ok(response) => {
        let link = response.link.unwrap();
        println!("Created: {}", link.shortlink.unwrap());
    }
    Err(e) => eprintln!("API error: {}", e),
}

Common use cases

What teams build with the Linkbreakers Rust SDK.

Performance-critical backend services

WebAssembly applications

Cross-platform desktop apps with Tauri

Part of the Linkbreakers developer ecosystem

The Rust SDK is one of five official SDKs. Linkbreakers also offers an MCP server for AI assistants and a CLI for terminal workflows.

Ready to build with the Rust SDK?

Sign up for Linkbreakers, create an API token, and start integrating in minutes.

Create your workspace