nsj-rest-lib2
Biblioteca para permitir a distribuição de rotas dinâmicas numa API, configuradas por meio de EDLs declarativos (em formato JSON).
What it is and what it does
RestLib2 is a Flask-based framework that generates REST APIs from declarative JSON entity definitions (called EDLs) without requiring traditional imperative programming. You describe your business entities and their relationships in JSON, and the framework automatically exposes them as REST endpoints with standard operations.
The package supports two deployment modes: versioning EDL files in a Git repository for CI/CD-driven compilation, or posting entity definitions directly to a control API for immediate dynamic compilation. It can load EDLs from disk, redis, or both. Configuration is minimal—set an environment variable for scope identification, call setup_dynamic_routes() in your Flask app's initialization, and the framework handles route registration, validation, and request handling.
Use it for:
- Rapidly prototype and deploy CRUD APIs for business entities without writing endpoint handlers.
- Build multi-tenant platforms where each tenant's data model is defined declaratively in JSON.
- Enable non-developers to define new API endpoints by editing JSON schemas.
- Manage versioned entity definitions in Git and automatically compile them during CI/CD pipelines.
- Deploy entity definitions dynamically at runtime via the control API without restarting the application.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Generates REST APIs dynamically from declarative JSON entity schemas without requiring imperative code, using Flask as the web framework.
Yes, with conditions. Install if you are building Flask applications that need rapid, declarative API generation from entity schemas and can accept an Alpha-stage library. The low install friction and active maintenance are favorable. However, verify the license terms in the GitHub repository first, and confirm that the dependency chain (redis, pydantic, nsj-rest-lib, nsj-multi-database-lib, black, pyyaml) aligns with your infrastructure. Not suitable for production use without thorough testing.
Install
nsj-rest-lib2 on PyPI
pip
pip install nsj-rest-lib2uv
uv add nsj-rest-lib2poetry
poetry add nsj-rest-lib2Installing nsj-rest-lib2
Before you install
Low install friction with a pure-Python wheel distribution. Marked as Alpha (Development Status :: 3), last released 154 days ago with active maintenance status.
License in practice
License treatment is unclear—no SPDX identifier or raw license text is declared in package metadata. Verify the actual license terms in the GitHub repository before adopting in proprietary or restricted-distribution projects.
Quickstart
pip install nsj-rest-lib2
from nsj_rest_lib2.controller.dynamic_controller import setup_dynamic_routes
setup_dynamic_routes(application, edls_path="@schemas/entities")
Requires Flask application and Python >= 3.4; depends on nsj-rest-lib, redis, nsj-multi-database-lib, pydantic, black, and pyyaml at runtime.
Verify before relying
- Whether the package works reliably with modern Python versions given the minimum requirement of >= 3.4.
- Performance characteristics and scalability limits for large numbers of entities or concurrent API requests.
- Production readiness and stability guarantees beyond Alpha status.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (>=3.4) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 6 — nsj-rest-lib, redis, nsj-multi-database-lib, pydantic, black, pyyaml |
| Maintenance | actively maintained — 154 days since the last release |
| First released | |
| Downloads | 133,469/month — #11,512 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: nsj_rest_lib2-0.0.41-py3-none-any.whl
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
nsj-rest-libnsj-rest-lib builds declarative REST APIs for…
unclear · top 15,000 on PyPI
nsj-sql-utils-libProvides Python utilities for database access,…
unclear · top 15,000 on PyPI
nsj-gcf-utilsProvides utility modules for building Google…
unclear · top 15,000 on PyPI
nsj-queue-libImplements transactional queues and workers…
unclear · top 15,000 on PyPI
dydanticDynamically generates Pydantic models from JSON…
permissive · top 5,000 on PyPI
Flask-JSONFlask-JSON adds convenient JSON response…
permissive · top 15,000 on PyPI
marshmallow-mongoengineGenerates marshmallow schemas automatically…
permissive · top 15,000 on PyPI
xsdataxsdata generates Python dataclasses from XML…
permissive · top 5,000 on PyPI
Flask-RESTfulFlask-RESTful provides decorators and utilities…
permissive · top 5,000 on PyPI
marshmallow-sqlalchemyGenerates marshmallow schemas from SQLAlchemy…
permissive · top 5,000 on PyPI