--- id: odata-query version: "0.10.0" license: MIT license_treatment: permissive maintenance: dormant --- # odata-query — An OData query parser and transpiler. License: permissive · Maintenance: dormant · Downloads: 161.5K/mo ## What it is and what it does odata-query is a parser and transpiler for OData v4 filter strings—the standardized query format used in REST APIs. It reads an OData filter expression and converts it into native query objects for your ORM or database layer. The package supports Django QuerySets, SQLAlchemy ORM queries, and SQLAlchemy Core, making it useful when you need to expose OData-compliant filtering to API clients without writing custom query translation logic. The library depends on python-dateutil for date handling and sly for parsing. It's marked Production/Stable and supports Python 3.7 through 3.12, but has been dormant for over two years—no active maintenance or updates. Installation is straightforward with optional extras for Django and SQLAlchemy integration. Use it for: - Build a REST API that accepts OData filter strings and translates them to Django ORM queries without manual parsing. - Convert OData queries to SQLAlchemy expressions in a data service layer. - Parse OData filters to raw SQL for direct database queries in non-ORM scenarios. - Expose standardized query syntax to API clients while keeping backend query logic decoupled. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Parses OData v4 filter strings and transpiles them to Django QuerySets, SQLAlchemy queries, or raw SQL for database filtering. Yes, if you need OData v4 filter parsing for Django or SQLAlchemy and can tolerate dormant maintenance. The package is stable and has no known vulnerabilities, with low install friction. However, verify compatibility with your specific ORM versions before relying on it in production, since the last release was 777 days ago and no updates are forthcoming. ## Install pip install odata-query uv add odata-query poetry add odata-query ## Installing odata-query Before you install: Low friction: pure Python wheel with only two runtime dependencies (python-dateutil and sly). Maintenance is dormant—last release was 777 days ago—so expect no active bug fixes or feature updates, though the package is marked Production/Stable. License in practice: MIT license (permissive) means you can use this freely in commercial and open-source projects with minimal restrictions, provided you include the license notice. Quickstart: pip install odata-query from odata_query.django import apply_odata_query query = apply_odata_query(MyModel.objects, "name eq 'test'") results = query.all() Requires Python 3.7–3.12; optional extras (django, sqlalchemy) must be installed separately if you want ORM integration. Verify before relying: - Whether dormant status (777 days since last release) affects compatibility with recent Django/SQLAlchemy versions. - Whether the modular/extensible architecture mentioned in docs supports custom ORM backends beyond Django and SQLAlchemy. - Real-world performance and feature completeness for complex OData filter expressions. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: dormant - Downloads: 161.5K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags odata filter parser, odata to sql conversion, odata query transpiler, django odata filtering, sqlalchemy odata support, odata v4 query builder, odata-parser, query-transpiler [View on SkillFed](https://skillfed.io/packages/odata-query) · [View on PyPI](https://pypi.org/project/odata-query/)