diff --git a/_index/index.html b/_index/index.html index e057ac1..6b28e36 100644 --- a/_index/index.html +++ b/_index/index.html @@ -127,6 +127,7 @@
Design-first API development toolkit enforcing OpenAPI contracts as the single source of truth.
diff --git a/config.yml b/config.yml index 79a19b5..d927854 100644 --- a/config.yml +++ b/config.yml @@ -27,6 +27,7 @@ repos: description: Design-first API development toolkit enforcing OpenAPI contracts as the single source of truth. section: libraries docs: + wiki: site lib: site mcp: { bundle: docs/mcp, server: openapi_first, port: 8004 } diff --git a/openapi-first/lib/app/index.html b/openapi-first/lib/app/index.html index 4280106..a62ecff 100644 --- a/openapi-first/lib/app/index.html +++ b/openapi-first/lib/app/index.html @@ -385,21 +385,6 @@ - - @@ -705,21 +690,6 @@ - - @@ -791,7 +761,7 @@ that enforces OpenAPI as the single source of truth for a FastAPI service. Python handler function. - Handlers are plain Python callables (no FastAPI decorators). - FastAPI route registration is derived exclusively from the spec. -- FastAPI's autogenerated OpenAPI schema is fully overridden. +- FastAPI's autogenerated OpenAPI schema is fully overridden.Responsibilities:
1 @@ -855,60 +825,6 @@ that enforces OpenAPI as the single source of truth for a FastAPI service.
+
+
+Notes+Responsibilities: +
Guarantees: +
+
+
Example+ +
@@ -1004,7 +972,7 @@ handlers).
- Functions+ diff --git a/openapi-first/lib/client/index.html b/openapi-first/lib/client/index.html index 792e48c..5672607 100644 --- a/openapi-first/lib/client/index.html +++ b/openapi-first/lib/client/index.html @@ -589,21 +589,6 @@ - -OpenAPI-first HTTP client ( Parameters: +
Raises: +
| |
Initialize the OpenAPI client.
- - -Parameters:
-| Name | -Type | -Description | -Default | -
|---|---|---|---|
spec |
-
- dict[str, Any]
- |
-
-
-
- Parsed OpenAPI 3.x specification. - |
- - required - | -
base_url |
-
- str | None
- |
-
-
-
- Base URL of the target service. If omitted, the first entry in the OpenAPI |
-
- None
- |
-
client |
-
- Client | None
- |
-
-
-
- Optional preconfigured httpx client instance. - |
-
- None
- |
-
Raises:
-| Type | -Description | -
|---|---|
- OpenAPIClientError
- |
-
-
-
- If no servers are defined, spec has no paths, operationIds are missing/duplicate, or required parameters are missing. - |
-
operationId, which becomes the handler function name
output_dir: Path,
*,
use_models: bool = False,
- models_module: str = "models"
+ models_module: str = "models"
) -> list[Path]
diff --git a/openapi-first/lib/errors/index.html b/openapi-first/lib/errors/index.html
index cd96197..af3b3ac 100644
--- a/openapi-first/lib/errors/index.html
+++ b/openapi-first/lib/errors/index.html
@@ -512,21 +512,6 @@
-
-
Raised when an OpenAPI operation cannot be resolved to a handler.
-Scenarios:
-1 -2 -3 | |
Guarantees:
-1 -2 -3 | |
Initialize the error.
- -Parameters:
Scenarios:
+1 +2 +3 | |
Guarantees:
+1 +2 +3 | |
operationId.
import my_service.routes as routes
api = app.OpenAPIFirstApp(
- openapi_path="openapi.yaml",
+ openapi_path="openapi.yaml",
routes_module=routes,
- title="My Service",
- version="1.0.0",
+ title="My Service",
+ version="1.0.0",
)
OperationId-driven HTTP client:
@@ -811,7 +811,7 @@ handlers explicitly viaoperationId.
7Responsibilities:
1 @@ -737,60 +722,6 @@ that enforces OpenAPI as the single source of truth for a FastAPI service.
+
+
+Notes+Responsibilities: +
Guarantees: +
+
+
Example+ +
@@ -886,7 +869,7 @@ handlers).
- Functions+ diff --git a/openapi-first/lib/openapi_first/client/index.html b/openapi-first/lib/openapi_first/client/index.html index 06e57df..ab07556 100644 --- a/openapi-first/lib/openapi_first/client/index.html +++ b/openapi-first/lib/openapi_first/client/index.html @@ -587,21 +587,6 @@ - -OpenAPI-first HTTP client ( Parameters: +
Raises: +
| |
Initialize the OpenAPI client.
- - -Parameters:
-| Name | -Type | -Description | -Default | -
|---|---|---|---|
spec |
-
- dict[str, Any]
- |
-
-
-
- Parsed OpenAPI 3.x specification. - |
- - required - | -
base_url |
-
- str | None
- |
-
-
-
- Base URL of the target service. If omitted, the first entry in the OpenAPI |
-
- None
- |
-
client |
-
- Client | None
- |
-
-
-
- Optional preconfigured httpx client instance. - |
-
- None
- |
-
Raises:
-| Type | -Description | -
|---|---|
- OpenAPIClientError
- |
-
-
-
- If no servers are defined, spec has no paths, operationIds are missing/duplicate, or required parameters are missing. - |
-
operationId, which becomes the handler function name
output_dir: Path,
*,
use_models: bool = False,
- models_module: str = "models"
+ models_module: str = "models"
) -> list[Path]
diff --git a/openapi-first/lib/openapi_first/errors/index.html b/openapi-first/lib/openapi_first/errors/index.html
index 864e023..df01301 100644
--- a/openapi-first/lib/openapi_first/errors/index.html
+++ b/openapi-first/lib/openapi_first/errors/index.html
@@ -587,21 +587,6 @@
-
-
Raised when an OpenAPI operation cannot be resolved to a handler.
-Scenarios:
-1 -2 -3 | |
Guarantees:
-1 -2 -3 | |
Initialize the error.
- -Parameters:
Scenarios:
+1 +2 +3 | |
Guarantees:
+1 +2 +3 | |
operationId.
import my_service.routes as routes
api = app.OpenAPIFirstApp(
- openapi_path="openapi.yaml",
+ openapi_path="openapi.yaml",
routes_module=routes,
- title="My Service",
- version="1.0.0",
+ title="My Service",
+ version="1.0.0",
)
OperationId-driven HTTP client:
@@ -698,7 +698,7 @@ handlers explicitly viaoperationId.
7from openapi_first.loader import load_openapi
from openapi_first.client import OpenAPIClient
-spec = load_openapi("openapi.yaml")
+spec = load_openapi("openapi.yaml")
client = OpenAPIClient(spec)
response = client.get_health()
diff --git a/openapi-first/lib/openapi_first/templates/crud_app/data/index.html b/openapi-first/lib/openapi_first/templates/crud_app/data/index.html
index 7f18b4d..b78cf53 100644
--- a/openapi-first/lib/openapi_first/templates/crud_app/data/index.html
+++ b/openapi-first/lib/openapi_first/templates/crud_app/data/index.html
@@ -794,7 +794,7 @@ It is suitable for demos, tests, and scaffolding only.
-