---
title: "Linkbreakers Python SDK - Official Python Client Library"
description: "The official Linkbreakers Python SDK for data pipelines, backend services, and automation scripts. Pythonic interfaces with type hints for FastAPI, Django, Flask, and data engineering workflows."
canonical: "https://linkbreakers.com/sdk/python"
---

# Linkbreakers Python SDK - Official Python Client Library

> The official Linkbreakers Python SDK for data pipelines, backend services, and automation scripts. Pythonic interfaces with type hints for FastAPI, Django, Flask, and data engineering workflows.

Linkbreakers SDKPython

# Linkbreakers Python SDK

Integrate lead capture, visitor data and analytics into your Python applications. Ideal for data pipelines, backend services, and automation scripts.

[Start free with Linkbreakers](https://app.linkbreakers.com?showcase=sdk-python&ref=landing-sdk-python)[Read the quickstart guide](https://linkbreakers.com/help/article/python-sdk-quickstart)

[PyPI](https://pypi.org/project/linkbreakers/)[GitHub](https://github.com/linkbreakers-com/linkbreakers-python)[v1.183.3](https://pypi.org/project/linkbreakers/1.183.3/)linkbreakers

Install via pip

One command

Open source

GitHub

API coverage

Complete

## Why use the Python SDK

Integrate Linkbreakers into your Python 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

pip

pip install linkbreakers

Create a tracked link

from linkbreakers import Configuration, LinksApi
import os

config = Configuration(
    access_token=os.environ['LINKBREAKERS_SECRET_KEY'],
    host='https://api.linkbreakers.com'
)

api = LinksApi(config)
response = api.links_service_create(
    create_link_request={
        'destination': 'https://example.com',
        'name': 'Campaign Link',
        'tags': ['marketing'],
    }
)

print(f"Short URL: {response.link.shortlink}")

Bulk link creation from CSV

import csv

with open('products.csv') as f:
    for row in csv.DictReader(f):
        response = api.links_service_create(
            create_link_request={
                'destination': row['url'],
                'name': row['product_name'],
                'tags': ['product-catalog', row['category']],
            }
        )
        print(f"{row['product_name']}: {response.link.shortlink}")

Retrieve workspace analytics

from linkbreakers import MetricsApi, EventsApi

metrics_api = MetricsApi(config)
events_api = EventsApi(config)

metrics = metrics_api.metrics_service_get_workspace_metrics()
print(f"Total scans: {metrics.total_scans}")
print(f"Unique visitors: {metrics.unique_visitors}")

## Common use cases

What teams build with the Linkbreakers Python SDK.

FastAPI and Django backend integrations

Data pipelines with Pandas and Jupyter notebooks

Automation scripts for bulk link creation

## Part of the Linkbreakers developer ecosystem

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

[MCP ServerAI assistants via OAuth](https://linkbreakers.com/mcp)[CLITerminal and any LLM](https://linkbreakers.com/cli)[REST APIFull API reference](https://linkbreakers.com/help/api)[EcosystemFull overview](https://linkbreakers.com/help/article/linkbreakers-developer-ecosystem-overview)

## Ready to build with the Python SDK?

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

[Create your workspace](https://app.linkbreakers.com?showcase=sdk-python&ref=landing-sdk-python)

---

Source: https://linkbreakers.com/sdk/python
