Skip to content

Repository files navigation

Zero Friction Unified Python SDK

This repository provides one installable Python package for the Zero Friction API suite. It combines eight generated API clients under sdk/ with the hand-maintained zero_friction/ package, which provides shared configuration, authentication, and a unified client surface.

Installation

Install the SDK directly from GitHub:

pip install "git+https://github.com/TECHLETES/zero_friction.git@main"

For stable consumers, prefer an explicit release tag once available, for example:

pip install "git+https://github.com/TECHLETES/zero_friction.git@v1"

For repository development, use the supported uv workflow:

uv sync
cp .env.template .env
uv run pre-commit install --install-hooks

Do not commit .env or real credentials. The SDK reads these environment variables for authentication:

ZF_API_KEY=
ZF_TENANT_ID=
ZF_ORG_ID=
ZF_CLIENT_ID=
ZF_CLIENT_SECRET=

Usage

from zero_friction.core.config import ZeroFrictionConfig
from zero_friction.core.sdk_client import SDKClient

config = ZeroFrictionConfig()
sdk = SDKClient(config=config)

contract = sdk.masterdata_client.contracts_api.get_contracts_contractuuid(
    contractuuid="fc77b9c6-42bc-4fe7-b0a2-0f0309449a98",
    **config.as_kwargs(),
)
print(contract)

Repository layout

sdk/                 Generated, independently installable API clients
openapi_specs/       Zero Friction OpenAPI specification snapshots
zero_friction/       Unified client and shared SDK logic
tests/               Repository tests
scripts/             Adoption and pre-commit helper scripts
.devcontainer/       Reproducible development container setup
.github/workflows/   CI, labeling, and staging checks

SDK regeneration and releases

Do not regenerate the clients directly on main. OpenAPI specification updates are made on a dedicated branch, all affected clients are regenerated with the pinned OpenAPI Generator version, and dependent repositories are validated against that branch before the changes are merged.

The current SDK is the v1 baseline. A validated full regeneration from the newer Zero Friction OpenAPI specifications is intended to become v1.1 after merge to main.

See docs/8_sdk_generation.md for the complete generation, compatibility-testing, branch and release workflow.

Development checks

Dependencies are declared in pyproject.toml and locked in uv.lock:

uv lock
uv sync
uv run pre-commit run --all-files
uv run pytest

The template tooling also provides Black, Ruff, mypy, Bandit, detect-secrets, and pip-audit. Generated clients are preserved as product code and excluded from root-package lint/type-check coverage settings.

See docs/quickstart.md and the documents under docs/ for the development, secret-management, dependency, quality, devcontainer, and SDK generation workflows.

About

Zero Friction SDK for Python

Topics

Resources

Code of conduct

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages