Skip to main content

Reusable business logic engines for Codex platform (CRM, finance, HR, inventory)

Project description

codex-services

PyPI version Python CI License

Pure-Python business logic engines for booking, scheduling, and CRM workflows. No ORM, no framework dependencies — drop into any Python project or use as a building block inside the Codex ecosystem.


Install

pip install codex-services

# With holiday calendar support
pip install "codex-services[calendar]"

Requires Python 3.12 or newer.

Development

uv sync --extra dev
uv run pytest
uv run mypy src/
uv run pre-commit run --all-files
uv build --no-sources

Quick Start

from codex_services.booking.slot_master import find_slots, BookingEngineRequest, ServiceRequest, BookingMode
from datetime import date

request = BookingEngineRequest(
    service_requests=[
        ServiceRequest(service_id="haircut", duration_minutes=60, possible_master_ids=["m1", "m2"]),
    ],
    booking_date=date.today(),
    mode=BookingMode.SINGLE_DAY,
)

result = find_slots(request, masters_availability=[...])
if result.has_solutions:
    print(result.best.starts_at)

Modules

Module Extra Description
codex_services.booking.slot_master Recursive chain-finder for multi-service bookings with scoring and waitlist
codex_services.booking._shared Low-level slot arithmetic — windows, gaps, busy interval merging
codex_services.calendar [calendar] Calendar grid generator for UI rendering with holiday awareness

Documentation

Full docs with architecture, API reference, and data flow diagrams:

https://codexdlc.github.io/codex-services/

Part of the Codex ecosystem

Package Role
codex-core Foundation — immutable DTOs, PII masking, env settings
codex-platform Infrastructure — Redis, Streams, ARQ workers, Notifications
codex-ai LLM layer — unified async interface for OpenAI, Gemini, Anthropic
codex-services Business logic — Booking engine, CRM, Calendar

Each library is fully standalone — install only what your project needs. Together they form the backbone of codex-bot (Telegram AI-agent infrastructure built on aiogram) and codex-django (Django integration layer).

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

codex_services-0.1.3.tar.gz (128.1 kB view details)

Uploaded Source

Built Distribution

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

codex_services-0.1.3-py3-none-any.whl (32.3 kB view details)

Uploaded Python 3

File details

Details for the file codex_services-0.1.3.tar.gz.

File metadata

  • Download URL: codex_services-0.1.3.tar.gz
  • Upload date:
  • Size: 128.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for codex_services-0.1.3.tar.gz
Algorithm Hash digest
SHA256 e1f67eee7b58d48830beed6d3f5f8d606a90a0fe64778861993c86c3550f5326
MD5 a2b431930dff235e63b3c4789370f857
BLAKE2b-256 205863506c75dcfd1a341c516c521bc6e87f2b3d9ab7c29b5618fadabe85e1ae

See more details on using hashes here.

Provenance

The following attestation bundles were made for codex_services-0.1.3.tar.gz:

Publisher: publish.yml on CodexDLC/codex-services

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file codex_services-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: codex_services-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 32.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for codex_services-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 cc6f94b65dc86b145cf696441a0130c60f5a18657b65be03bf42cf205f4ed1d1
MD5 0e5ea4480d5d4d5280d0d1b7ab53ebd1
BLAKE2b-256 8bdb0e03c75b46358a1dd4abf64bfc16082e89b972d5fb57df4bffa1d65da1aa

See more details on using hashes here.

Provenance

The following attestation bundles were made for codex_services-0.1.3-py3-none-any.whl:

Publisher: publish.yml on CodexDLC/codex-services

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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