{"schemaVersion":"1.0","sourceCommit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca","sourceVisibility":"private","article":{"id":"api-mansoq-radiology-webhookviewset-ab3fb32d","title":"Webhook API reference · mansoq-radiology","summary":"Static source contract for Webhook: 1 declared or inherited operation mappings, schema/field evidence and authorization/refusal references. Deployment and behavioral review remain explicit.","module":"IT & integrations","roles":["IT administrator","Developer","Integration engineer"],"facilities":["All configured facility types"],"kind":"reference","minutes":3,"prerequisites":["Use the API contract from the installed deployment and an authorized synthetic test environment.","Confirm facility/organization scope, action permissions and optional app enablement.","This reference is static source evidence; complete payload, authorization, failure and end-to-end review remains recorded as pending."],"steps":[],"sections":[{"title":"Declared route and availability","body":"This resource is declared in **mansoq-radiology** at `/api/{installed_plugin_prefix}/webhooks/`. plugin/local mount; actual prefix and enablement require deployment verification A registered path and an indexed handler do not prove deployment availability, user permission or production readiness."},{"title":"Operation map","body":"| Method | Path | Action | Evidence |\n| --- | --- | --- | --- |\n| POST | `/api/{installed_plugin_prefix}/webhooks/study/` | save_webhook | @action declaration |"},{"title":"save_webhook · POST","body":"**POST /api/{installed_plugin_prefix}/webhooks/study/** — action `save_webhook`. static contract extracted; runtime/permission/payload behavior review pending.\n\nPath and deployment-context parameters:\n\n| Location | Parameter | Type | Required |\n| --- | --- | --- | --- |\n| deployment mount | installed_plugin_prefix | deployment-selected mount prefix | true |\n\nDirectly observed request reads (these do not constitute a complete accepted-payload or requiredness guarantee):\n\n| Location | Field | Declared/inferred read type | Requiredness evidence |\n| --- | --- | --- | --- |\n| body | `service_request_id` | not declared at read site | direct indexing; validation may be upstream |\n| body | `study_id` | not declared at read site | not established |\n\n**Authorization:** no literal permission name was resolved in the bounded handler/helper traversal. Authentication, inherited policies, object/facility scoping and middleware still require review; this does not mean public access.\n\n**Explicit response statuses in observed code:** status.HTTP_200_OK, status.HTTP_400_BAD_REQUEST. Other branches/framework exception handling may differ.\n\n**Declared refusal/error evidence:** AuthenticationFailed: Invalid API key."},{"title":"Integration review checklist","body":"Confirm the installed route and full schema; review authentication, organization/facility scoping, all accepted fields, value-state and date/time semantics, idempotency, pagination, response/exception branches and the allowed correction/reversal workflow. Test positive and negative cases with synthetic data. This source reference does not establish external certification or replace an illustrated user procedure."}],"troubleshooting":[{"problem":"A declared route is unavailable or a request is rejected","solution":"Compare the installed revision, actual API schema, optional plugin mount, HTTP-method restrictions and recorded validation/permission evidence. Do not bypass a refusal or send a production transaction to test documentation."}],"sources":[{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/urls.py","line":16,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":32,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":39,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}],"related":["it-api-contract","it-api-auth","security-rcm-roles"],"verification":"Static API contract — behavior review pending","version":"f6e9f05f76d4","apiReferenceIds":["backend-resource-6b4dd3a0ab3fb32d","backend-resource-6b4dd3a0ab3fb32d:POST:save_webhook"]},"backend":{"resources":[{"id":"backend-resource-6b4dd3a0ab3fb32d","localPrefix":"webhooks","viewset":"WebhookViewSet","classId":"repositories/teleicu/mansoq-radiology:mansoq_radiology.api.webhooks.WebhookViewSet","basename":"webhooks","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/urls.py","line":16,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},"conditions":[],"repository":"repositories/teleicu/mansoq-radiology","classSource":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":32,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},"description":"","path":"/api/{installed_plugin_prefix}/webhooks/","mountStatus":"plugin/local mount; actual prefix and enablement require deployment verification","operationIds":["backend-resource-6b4dd3a0ab3fb32d:POST:save_webhook"],"unresolvedViewset":false,"reviewStatus":"registered resource enumerated; behavioral review pending"}],"operations":[{"id":"backend-resource-6b4dd3a0ab3fb32d:POST:save_webhook","resourceId":"backend-resource-6b4dd3a0ab3fb32d","repository":"repositories/teleicu/mansoq-radiology","boundary":"optional-plugin/local-service","method":"POST","path":"/api/{installed_plugin_prefix}/webhooks/study/","declaredPattern":"/api/{installed_plugin_prefix}/webhooks/study/","action":"save_webhook","viewset":"WebhookViewSet","classId":"repositories/teleicu/mansoq-radiology:mansoq_radiology.api.webhooks.WebhookViewSet","detail":false,"allowedByDeclaredHttpMethods":true,"mountStatus":"plugin/local mount; actual prefix and enablement require deployment verification","routeEvidence":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/urls.py","line":16,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},"handlerSource":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":39,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},"registrationConditions":[],"evidenceKind":"@action declaration","methodEvidenceIds":["repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py:39:save_webhook"],"schemaIds":{},"classPermissionEvidence":[],"filterEvidence":[],"reviewStatus":"static contract extracted; runtime/permission/payload behavior review pending","pathParameters":[{"name":"installed_plugin_prefix","in":"deployment mount","type":"deployment-selected mount prefix","required":true,"source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/urls.py","line":16,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}}]}],"methodEvidence":[{"id":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py:39:save_webhook","name":"save_webhook","owner":"repositories/teleicu/mansoq-radiology:mansoq_radiology.api.webhooks.WebhookViewSet","summary":"","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":39,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"},"signatureParameters":[],"parametersRead":[{"name":"service_request_id","in":"body","type":"not declared at read site","required":"direct indexing; validation may be upstream","readStyle":"indexed","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":63,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}},{"name":"study_id","in":"body","type":"not declared at read site","required":"not established","readStyle":"get","dynamicName":false,"source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":70,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}}],"permissionChecks":[],"declaredErrors":[{"exception":"AuthenticationFailed","message":"Invalid API key","dynamicMessage":false,"source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":44,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}}],"explicitResponseStatuses":[{"value":null,"symbol":"status.HTTP_200_OK","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":88,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}},{"value":null,"symbol":"status.HTTP_400_BAD_REQUEST","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":56,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}},{"value":null,"symbol":"status.HTTP_200_OK","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":77,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}},{"value":null,"symbol":"status.HTTP_400_BAD_REQUEST","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":49,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}},{"value":null,"symbol":"status.HTTP_200_OK","source":{"path":"repositories/teleicu/mansoq-radiology/src/mansoq_radiology/api/webhooks.py","line":65,"commit":"f6e9f05f76d443b26ebd2369f67d3c3bd52257ca"}}],"conditions":[],"schemaIds":[],"schemaUsages":[],"unconditionalRaise":false,"reviewStatus":"static declaration extracted; behavioral/security review pending"}],"schemas":[],"frameworkSettings":[]},"frontend":{"operations":[],"schemas":[]},"services":{"operations":[]},"boundaries":[]}