ワンクリックで
view-contract-enforcer
Enforce request-validation, permission, service-handoff, and response-contract boundaries in views without using jig.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Enforce request-validation, permission, service-handoff, and response-contract boundaries in views without using jig.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
When the user wants to codify a repeatable code generation pattern into a jig recipe — design variables, choose operations (create/inject/patch/replace), write Jinja templates, and validate the result. Use when someone says "I keep writing this same boilerplate", "make a recipe for X", or wants to turn a manual edit into an automated pattern.
When the user needs to chain multiple jig recipes into a multi-step workflow with conditional execution and shared variables. Use when a pattern spans multiple files that need coordinated creation and modification, like scaffolding an entire endpoint or a full feature slice.
Scaffold queryset/manager/selector layers and wire view reads through selector entrypoints with jig.
Generate two-step rollout-safe Django migrations plus model-field patching using jig.
Insert consistent method/step structured logging lines into target functions using jig.
Write deterministic service tests with stable fixtures and boundary mocks without using jig.
| name | view-contract-enforcer |
| description | Enforce request-validation, permission, service-handoff, and response-contract boundaries in views without using jig. |
Use this skill when adding or updating API views. Implement the file edits directly. Do not return a checklist-only response.
view_namehttp_methodrequest_schema_nameresponse_schema_nameservice_symbolurl_pathurl_nametest_nametest_urlschemas.py, views.py, urls.py, and tests/test_views.py.schemas.py:request_schema_name, with correlation_id = serializers.CharField(required=False, allow_blank=True)response_schema_name, with id = serializers.IntegerField() and status = serializers.CharField()views.py:.schemasservice_symbol from .services@api_view([http_method]) using the provided method literalview_namerequest_contract = RequestSchemaName(data=request.data) using the provided request schema classrequest_contract.is_valid(raise_exception=True)payload = request_contract.validated_dataresult = service_symbol(pk=pk, payload=payload) using the provided service symbolresponse_contract = ResponseSchemaName(result) using the provided response schema classResponse(response_contract.data, status=200)urls.py, add a path entry using api/ plus the provided url_path, pointing to the provided view_name, with the provided url_name.tests/test_views.py, add the provided test_name method that posts to the provided test_url with {"correlation_id": "h2h"} and asserts the status code is in [200, 400, 401, 404].request_contract, payload, and response_contract.