Skip to content

Commit b06cf0e

Browse files
committed
feat: add JSON schema for project model with required properties and tags
1 parent 58ea3c9 commit b06cf0e

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

data/models/schemas/project.json

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-07/schema#",
3+
"type": "object",
4+
"required": ["name", "repositories"],
5+
"properties": {
6+
"name": {
7+
"type": "string",
8+
"description": "The name of the project"
9+
},
10+
"repositories": {
11+
"type": "array",
12+
"minItems": 1,
13+
"items": {
14+
"type": "object",
15+
"required": ["provider", "owner", "name"],
16+
"properties": {
17+
"provider": {
18+
"type": "string",
19+
"enum": ["github"],
20+
"description": "The repository hosting provider"
21+
},
22+
"owner": {
23+
"type": "string",
24+
"description": "The owner/organization of the repository"
25+
},
26+
"name": {
27+
"type": "string",
28+
"description": "The name of the repository"
29+
}
30+
}
31+
}
32+
},
33+
"tags": {
34+
"type": "array",
35+
"items": {
36+
"type": "string",
37+
"enum": ["by-algerian", "solve-algerian-problem"]
38+
},
39+
"minItems": 1,
40+
"description": "Tags associated with the project"
41+
}
42+
}
43+
}

0 commit comments

Comments
 (0)