Barbara API SDK for Python
This article refers to SDK version v0.5.0. The current SDK version is N/A.
Overview
The Barbara API SDK for Python is the official client for the Barbara API: typed, synchronous and asynchronous, covering nodes, clusters, applications, and models. It lets you manage your Barbara fleet from your own scripts and services instead of clicking through the Barbara Panel by hand.
Package on PyPI · Source on GitHub
pip install barbara-api-sdk
This section of Academy has three kinds of material. Pick the one that matches what you need right now.
Guides
Step-by-step articles that teach one task at a time, starting from your first authenticated call.
| Guide | Description |
|---|---|
| Getting started | Install the SDK, authenticate, and run your first calls: list your nodes and read live telemetry. |
| Node identity & tags | Name, location, tags, groups, and automatic disk-pressure safety config. |
| Node networking | Ethernet, WiFi, Mobile, and VLAN interfaces, hostname, VPN, Proxy, Standalone Mode, IPTables, and NTP servers. |
| Node secrets | Create, list, and delete secrets on a node or cluster. |
| Docker credentials & volumes | Register registry credentials and manage docker volumes on a node. |
| Marketplace app deployment | Deploy a Marketplace application to a node: services, ports, and checking on the result. |
| Deploying your own apps | Register a user application, upload a version, and deploy it. |
| Model deployment | Register a model, upload a version, and deploy it to run inference at the edge. |
| Workload lifecycle | Start, stop, read logs, and check the status of an already-deployed workload. |
| App configuration | Node-level, workload-level, and reusable configuration, and when to use which. |
| Clusters & stacks | Create a cluster, manage node membership, and deploy a stack across every member. |
| Alerts | List active alerts, acknowledge them, and inspect the events behind one. |
Examples
Full walkthroughs of the runnable scripts shipped in the SDK's examples/ directory: what each script does, how to run it, and how to extend it.
| Example | Description |
|---|---|
| Hello World | The smallest working script: authenticate and list your nodes. |
| Node info & telemetry | Read a node's configuration and latest telemetry. |
| Barbara Core updates | Check nodes for an outdated Barbara Core, optionally update them. |
| Network audit | Report a fleet's network configuration in one shot. |
| Clone a node | Clone a node's workloads, configuration, and volumes onto another node. |
| Clone tool | Back up a node to disk, restore it onto a batch of targets, or clean it. |
| Deployment dashboard | A live terminal dashboard checking a fleet against a target state. |
Reference
Start at the Reference overview for domain concepts, authentication, and a full usage walkthrough, or jump straight to a resource. Every method, parameter, and return type is kept in sync with the SDK's docstrings.
| Resource | Description |
|---|---|
client.nodes | Node lifecycle, secrets, app configuration, docker credentials, and actions (reboot, provision, ...) |
client.nodes.network | Physical interfaces, VLANs, hostname, VPN, Proxy, Standalone Mode, IPTables, and NTP servers |
client.nodes.workloads | Applications deployed on a node |
client.clusters | Cluster lifecycle, global secrets, global configuration, and docker credentials |
client.clusters.workloads | Applications deployed across a cluster |
client.applications | Application catalog and versions |
client.models | Model catalog and versions |
client.configs | Reusable Config Repository documents |
client.groups | Node groups |
client.users | Company users (read-only) |
client.alerts | Alerts and alert events |
Plus the client, config & auth, exceptions, and models pages. For the underlying HTTP API itself, see the API Specification.