@nexalink/coding-contracts 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,90 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://nexalink.care/contracts/coding-rule-result.schema.json",
4
+ "title": "CodingRuleResult",
5
+ "description": "One deterministic rule execution trace attached to a decision. Rules never rely on the model for validity, bundling, sequencing, modifiers, units, or time calculations; each trace records the rule identity, version, inputs, outcome, and explanation needed to replay the decision.",
6
+ "version": "1.0.0",
7
+ "x-wire-version": "coding-rule-result-v1",
8
+ "x-wire-constant": "CODING_RULE_RESULT_SCHEMA_VERSION",
9
+ "x-code": "rule_result",
10
+ "x-keys-code": "rule_result_keys",
11
+ "type": "object",
12
+ "additionalProperties": false,
13
+ "required": ["ruleId", "ruleVersion", "outcome"],
14
+ "properties": {
15
+ "ruleId": {
16
+ "type": "string",
17
+ "minLength": 1,
18
+ "maxLength": 120,
19
+ "x-code": "rule_result_id"
20
+ },
21
+ "ruleVersion": {
22
+ "type": "string",
23
+ "minLength": 1,
24
+ "maxLength": 40,
25
+ "x-code": "rule_result_version"
26
+ },
27
+ "outcome": {
28
+ "type": "string",
29
+ "enum": [
30
+ "satisfied",
31
+ "failed",
32
+ "rejected",
33
+ "escalated",
34
+ "conflicted",
35
+ "warning"
36
+ ],
37
+ "x-code": "rule_result_outcome"
38
+ },
39
+ "severity": {
40
+ "type": "string",
41
+ "enum": ["info", "warning", "blocking"],
42
+ "x-code": "rule_result_severity"
43
+ },
44
+ "inputs": {
45
+ "type": "array",
46
+ "maxItems": 30,
47
+ "x-code": "rule_result_inputs",
48
+ "items": {
49
+ "type": "object",
50
+ "additionalProperties": false,
51
+ "required": ["name", "value"],
52
+ "x-code": "rule_result_input",
53
+ "x-keys-code": "rule_result_input_keys",
54
+ "properties": {
55
+ "name": {
56
+ "type": "string",
57
+ "minLength": 1,
58
+ "maxLength": 80,
59
+ "x-code": "rule_result_input_name"
60
+ },
61
+ "value": {
62
+ "type": "string",
63
+ "minLength": 1,
64
+ "maxLength": 2000,
65
+ "x-code": "rule_result_input_value"
66
+ }
67
+ }
68
+ }
69
+ },
70
+ "reason": {
71
+ "type": "string",
72
+ "minLength": 1,
73
+ "maxLength": 120,
74
+ "x-code": "rule_result_reason"
75
+ },
76
+ "explanation": {
77
+ "type": "string",
78
+ "minLength": 1,
79
+ "maxLength": 1000,
80
+ "x-strip-nonempty": true,
81
+ "x-code": "rule_result_explanation"
82
+ },
83
+ "evidence": {
84
+ "type": "string",
85
+ "minLength": 1,
86
+ "maxLength": 2000,
87
+ "x-code": "rule_result_evidence"
88
+ }
89
+ }
90
+ }
@@ -0,0 +1,120 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://nexalink.care/contracts/coding-service-line.schema.json",
4
+ "title": "CodingServiceLine",
5
+ "description": "One existing (submitted) claim line on a CodingCase. Decisions reference these lines by lineId; the line action is chosen by the decision, never stored here.",
6
+ "version": "1.0.0",
7
+ "x-wire-version": "coding-service-line-v1",
8
+ "x-wire-constant": "CODING_SERVICE_LINE_SCHEMA_VERSION",
9
+ "x-code": "service_line",
10
+ "x-keys-code": "service_line_keys",
11
+ "type": "object",
12
+ "additionalProperties": false,
13
+ "required": ["lineId", "submittedCode"],
14
+ "properties": {
15
+ "lineId": {
16
+ "type": "string",
17
+ "minLength": 1,
18
+ "maxLength": 60,
19
+ "x-code": "service_line_id"
20
+ },
21
+ "submittedCode": {
22
+ "type": "object",
23
+ "additionalProperties": false,
24
+ "required": ["code", "codeSystem"],
25
+ "x-code": "service_line_submitted_code",
26
+ "x-keys-code": "service_line_submitted_code_keys",
27
+ "properties": {
28
+ "code": {
29
+ "type": "string",
30
+ "minLength": 1,
31
+ "maxLength": 64,
32
+ "x-strip-nonempty": true,
33
+ "x-code": "service_line_code"
34
+ },
35
+ "codeSystem": {
36
+ "type": "string",
37
+ "enum": [
38
+ "ICD-10-CM",
39
+ "ICD-10-PCS",
40
+ "CPT",
41
+ "HCPCS",
42
+ "NDC",
43
+ "CDT",
44
+ "OTHER"
45
+ ],
46
+ "x-code": "service_line_code_system"
47
+ },
48
+ "codeVersion": {
49
+ "type": "string",
50
+ "minLength": 1,
51
+ "maxLength": 40,
52
+ "x-code": "service_line_code_version"
53
+ }
54
+ }
55
+ },
56
+ "modifiers": {
57
+ "type": "array",
58
+ "maxItems": 8,
59
+ "x-code": "service_line_modifiers",
60
+ "items": {
61
+ "type": "string",
62
+ "minLength": 1,
63
+ "maxLength": 8,
64
+ "x-code": "service_line_modifiers"
65
+ }
66
+ },
67
+ "units": {
68
+ "type": "object",
69
+ "additionalProperties": false,
70
+ "x-code": "service_line_units",
71
+ "x-keys-code": "service_line_units_keys",
72
+ "properties": {
73
+ "count": {
74
+ "type": "integer",
75
+ "minimum": 0,
76
+ "maximum": 999999,
77
+ "x-code": "service_line_units_count"
78
+ },
79
+ "unitOfMeasure": {
80
+ "type": "string",
81
+ "minLength": 1,
82
+ "maxLength": 20,
83
+ "x-code": "service_line_units_measure"
84
+ }
85
+ }
86
+ },
87
+ "linkedDiagnoses": {
88
+ "type": "array",
89
+ "maxItems": 20,
90
+ "x-code": "service_line_linked_diagnoses",
91
+ "items": {
92
+ "type": "object",
93
+ "additionalProperties": false,
94
+ "required": ["diagnosisRef"],
95
+ "x-code": "service_line_linked_diagnosis",
96
+ "x-keys-code": "service_line_linked_diagnosis_keys",
97
+ "properties": {
98
+ "diagnosisRef": {
99
+ "type": "string",
100
+ "minLength": 1,
101
+ "maxLength": 60,
102
+ "x-code": "service_line_diagnosis_ref"
103
+ },
104
+ "sequence": {
105
+ "type": "integer",
106
+ "minimum": 1,
107
+ "maximum": 99,
108
+ "x-code": "service_line_diagnosis_sequence"
109
+ }
110
+ }
111
+ }
112
+ },
113
+ "serviceDate": {
114
+ "type": "string",
115
+ "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
116
+ "format": "date",
117
+ "x-code": "service_line_service_date"
118
+ }
119
+ }
120
+ }
package/versions.json CHANGED
@@ -1,8 +1,68 @@
1
1
  {
2
2
  "$comment": "GENERATED FILE. Schema registry derived from schemas/*.schema.json.",
3
3
  "packageName": "@nexalink/coding-contracts",
4
- "packageVersion": "0.2.0",
4
+ "packageVersion": "0.3.0",
5
5
  "schemas": {
6
+ "coding-case-context": {
7
+ "file": "coding-case-context.schema.json",
8
+ "semver": "1.0.0",
9
+ "wireVersion": "coding-case-context-v1"
10
+ },
11
+ "coding-case-payer": {
12
+ "file": "coding-case-payer.schema.json",
13
+ "semver": "1.0.0",
14
+ "wireVersion": "coding-case-payer-v1"
15
+ },
16
+ "coding-case-clinical": {
17
+ "file": "coding-case-clinical.schema.json",
18
+ "semver": "1.0.0",
19
+ "wireVersion": "coding-case-clinical-v1"
20
+ },
21
+ "coding-service-line": {
22
+ "file": "coding-service-line.schema.json",
23
+ "semver": "1.0.0",
24
+ "wireVersion": "coding-service-line-v1"
25
+ },
26
+ "coding-extension": {
27
+ "file": "coding-extension.schema.json",
28
+ "semver": "1.0.0",
29
+ "wireVersion": "coding-extension-v1"
30
+ },
31
+ "coding-case": {
32
+ "file": "coding-case.schema.json",
33
+ "semver": "1.0.0",
34
+ "wireVersion": "coding-case-v1"
35
+ },
36
+ "coding-batch": {
37
+ "file": "coding-batch.schema.json",
38
+ "semver": "1.0.0",
39
+ "wireVersion": "coding-batch-v1"
40
+ },
41
+ "coding-decision-line": {
42
+ "file": "coding-decision-line.schema.json",
43
+ "semver": "1.0.0",
44
+ "wireVersion": "coding-decision-line-v1"
45
+ },
46
+ "coding-evidence": {
47
+ "file": "coding-evidence.schema.json",
48
+ "semver": "1.0.0",
49
+ "wireVersion": "coding-evidence-v1"
50
+ },
51
+ "coding-rule-result": {
52
+ "file": "coding-rule-result.schema.json",
53
+ "semver": "1.0.0",
54
+ "wireVersion": "coding-rule-result-v1"
55
+ },
56
+ "coding-reviewer-action": {
57
+ "file": "coding-reviewer-action.schema.json",
58
+ "semver": "1.0.0",
59
+ "wireVersion": "coding-reviewer-action-v1"
60
+ },
61
+ "coding-decision": {
62
+ "file": "coding-decision.schema.json",
63
+ "semver": "1.0.0",
64
+ "wireVersion": "coding-decision-v1"
65
+ },
6
66
  "rcm-supporting-reference": {
7
67
  "file": "rcm-supporting-reference.schema.json",
8
68
  "semver": "1.0.0",