Skip to main content

Convenience wrapper for exonware-xwapi - provides 'import xwapi' alias

Project description

xwapi

Engine-agnostic API framework for the eXonware stack. xwapi exposes xwentity and xwaction as HTTP endpoints, standardizes error contracts, supports production middleware, and now includes a durable action pipeline plus API token lifecycle/metering.

Longer guide: README_LONG.md.

Company: eXonware.com · Author: eXonware Backend Team · Email: connect@exonware.com

Status Python License


Install

Install When to use
pip install exonware-xwapi Core runtime
pip install exonware-xwapi[lazy] Lazy dependency loading
pip install exonware-xwapi[full] Full production dependency set

Quick start

from exonware.xwapi import XWAPI
from exonware.xwentity import XWEntity


class User(XWEntity):
    name: str
    email: str
    age: int


api = XWAPI(entities=[User], title="My API", version="1.0.0")
app = api.create_app(engine="fastapi")

New production features

  • Engine-agnostic error contract: xwapi_error_to_http_parts plus adapters keeps XWAPIError transport-neutral.
  • Outbox + singleton worker pipeline: ActionPipelineManager, AOutboxStore/InMemoryOutboxStore, and BackgroundWorker.
  • API token lifecycle: create/list/revoke tokens, usage tracking, balance/recharge, idempotent metering.
  • Provider abstractions: IAuthProvider, IStorageProvider, IPaymentProvider with in-memory and library adapters.
  • API token middleware: bearer verification, optional scope enforcement, deny-unmapped policy, usage metering via Idempotency-Key.
  • Admin/operations endpoints: server status/health/pipeline controls and token admin endpoints.
  • Production guardrails: environment-based admin token enforcement and admin read-protection support.

eXonware integration

xwapi now explicitly integrates with:

  • xwsystem (serialization, logging/utilities)
  • xwaction (action registration and execution)
  • xwentity (entity-driven API surfaces)
  • xwschema (schema validation/generation integration points)
  • xwdata (data/serialization integration paths)

Docs and tests


Async support

  • Core runtime includes async methods across facade, token manager, middleware paths, and server actions.
  • Async APIs are recommended for I/O-heavy and concurrent workloads.

MIT - see LICENSE. Homepage: https://exonware.com Version: 0.9.0.3 | Updated: 01-Apr-2026

Built with ❤️ by eXonware.com - Revolutionizing Python Development Since 2025

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xwapi-0.9.0.3.tar.gz (160.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xwapi-0.9.0.3-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file xwapi-0.9.0.3.tar.gz.

File metadata

  • Download URL: xwapi-0.9.0.3.tar.gz
  • Upload date:
  • Size: 160.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for xwapi-0.9.0.3.tar.gz
Algorithm Hash digest
SHA256 4ea7f0633a63480a84f35852b885b7f674fa78fc051dd6f637cfb1ab7efecdd7
MD5 430ccaa0c14945483e073ec41563cdc9
BLAKE2b-256 4a9816afbd49e342ee994aa421ccec9c2bd0e9fe4d9b9b0b97a72f58737a6f79

See more details on using hashes here.

File details

Details for the file xwapi-0.9.0.3-py3-none-any.whl.

File metadata

  • Download URL: xwapi-0.9.0.3-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for xwapi-0.9.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 6a56871b1c7c24f3633d9399c856bc85ee8ce3dad87e1fe053480e2974ef95a2
MD5 29dc79ab1d110e108e4b43d9c2141c6a
BLAKE2b-256 f345fea4c92f25e3ef51598cf0956de4af50d3e8ffdd20a6100c65d0e8448654

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page