Reusable business logic engines for Codex platform (CRM, finance, HR, inventory)
Project description
codex-services
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
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e1f67eee7b58d48830beed6d3f5f8d606a90a0fe64778861993c86c3550f5326
|
|
| MD5 |
a2b431930dff235e63b3c4789370f857
|
|
| BLAKE2b-256 |
205863506c75dcfd1a341c516c521bc6e87f2b3d9ab7c29b5618fadabe85e1ae
|
Provenance
The following attestation bundles were made for codex_services-0.1.3.tar.gz:
Publisher:
publish.yml on CodexDLC/codex-services
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codex_services-0.1.3.tar.gz -
Subject digest:
e1f67eee7b58d48830beed6d3f5f8d606a90a0fe64778861993c86c3550f5326 - Sigstore transparency entry: 1239304522
- Sigstore integration time:
-
Permalink:
CodexDLC/codex-services@0fae44e757b44df44812d6e1e3651b13a1025bd4 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/CodexDLC
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@0fae44e757b44df44812d6e1e3651b13a1025bd4 -
Trigger Event:
push
-
Statement type:
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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc6f94b65dc86b145cf696441a0130c60f5a18657b65be03bf42cf205f4ed1d1
|
|
| MD5 |
0e5ea4480d5d4d5280d0d1b7ab53ebd1
|
|
| BLAKE2b-256 |
8bdb0e03c75b46358a1dd4abf64bfc16082e89b972d5fb57df4bffa1d65da1aa
|
Provenance
The following attestation bundles were made for codex_services-0.1.3-py3-none-any.whl:
Publisher:
publish.yml on CodexDLC/codex-services
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codex_services-0.1.3-py3-none-any.whl -
Subject digest:
cc6f94b65dc86b145cf696441a0130c60f5a18657b65be03bf42cf205f4ed1d1 - Sigstore transparency entry: 1239304526
- Sigstore integration time:
-
Permalink:
CodexDLC/codex-services@0fae44e757b44df44812d6e1e3651b13a1025bd4 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/CodexDLC
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@0fae44e757b44df44812d6e1e3651b13a1025bd4 -
Trigger Event:
push
-
Statement type: