Skip to content

Commit 9b07589

Browse files
feat: requirement schema (WIP)
Signed-off-by: anthonyharrison <[email protected]>
1 parent 9265fba commit 9b07589

File tree

1 file changed

+84
-0
lines changed

1 file changed

+84
-0
lines changed
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
{
2+
"$schema": "https://json-schema.org/draft/2020-12/schema",
3+
"$id": "http://localhost:8080/schema/2.0/cyclonedx-requirement-2.0.schema.json",
4+
"type": "null",
5+
"title": "CycloneDX Transparency Expression Language: Requirement",
6+
"$comment" : "CycloneDX JSON schema is published under the terms of the Apache License 2.0.",
7+
"$defs": {
8+
"reqId":{
9+
"description": "A unique ID that usually a follows a specific naming convention.",
10+
"title": "Requirement Identifier",
11+
"type": "string",
12+
},
13+
"reqText":{
14+
"description": "A statement describing the actual need.",
15+
"title": "Requirement Text",
16+
"type": "string",
17+
},
18+
"reqNotes":{
19+
"description": "Additional information to provide context, rationale or justification for the requirement.",
20+
"title": "Requirement Notes",
21+
"type": "string",
22+
},
23+
"reqType":{
24+
"description": "The type of requirement (functional or non-functional). Will often drive the type of verification process to be followed."
25+
"title": "Requirement Type",
26+
"type": "string",
27+
"enum" :[
28+
"feature",
29+
"security".
30+
"safety",
31+
"quality",
32+
"maintainability",
33+
"reliability",
34+
"usability"
35+
]
36+
},
37+
"reqPriority": {
38+
"description": "The importance of the requirement."
39+
"title": "Requirement Priority"
40+
"type": "string",
41+
"enum": [
42+
"Key",
43+
"Mandatory",
44+
"Priority 1",
45+
"Priority 2",
46+
"Priority 3",
47+
"Priority 4",
48+
"Priority 5",
49+
"Priority 6",
50+
"Priority 7",
51+
"Priority 8",
52+
"Priority 9"
53+
]
54+
},
55+
"reqProperties": {
56+
"type": "array",
57+
"title": "Properties",
58+
"description": "Provides the ability to include additional attributes not officially supported in the standard.",
59+
"items": {
60+
"$ref": "#/$defs/reqProperty"
61+
}
62+
},
63+
"reqProperty": {
64+
"type": "object",
65+
"title": "Lightweight name-value pair",
66+
"description": "Provides the ability to document properties in a name-value store.",
67+
"required": [
68+
"name",
69+
"value"
70+
],
71+
"properties": {
72+
"name": {
73+
"type": "string",
74+
"title": "Name",
75+
"description": "The name of the property."
76+
},
77+
"value": {
78+
"type": "string",
79+
"title": "Value",
80+
"description": "The value of the property."
81+
}
82+
}
83+
}
84+
}

0 commit comments

Comments
 (0)