File tree Expand file tree Collapse file tree 3 files changed +35
-1
lines changed Expand file tree Collapse file tree 3 files changed +35
-1
lines changed Original file line number Diff line number Diff line change @@ -32,6 +32,10 @@ classifiers = [
32
32
" Topic :: File Formats :: JSON :: JSON Schema" ,
33
33
]
34
34
dynamic = [" version" ]
35
+ dependencies = [
36
+ " pyyaml" ,
37
+ " referencing>=0.32.0" ,
38
+ ]
35
39
36
40
37
41
[project .urls ]
Original file line number Diff line number Diff line change 1
1
"""
2
- Fill me in !
2
+ Serve your JSON registries over HTTP, for humans and machines alike !
3
3
"""
4
+ from importlib .resources import files
5
+
6
+ import yaml
7
+
8
+ SPEC = yaml .safe_load (files (__package__ ).joinpath ("api.yaml" ).read_text ())
Original file line number Diff line number Diff line change
1
+ openapi : " 3.1.0"
2
+ info :
3
+ title : An HTTP API for JSON (Schema) Registries
4
+ description : |-
5
+ Wrap a referencing.Registry Python object into an HTTP API.
6
+ version : " 1.0"
7
+ paths :
8
+ /list :
9
+ get :
10
+ summary : Retrieve a list of all URIs available in the registry.
11
+ responses :
12
+ " 200 " :
13
+ content :
14
+ application/json :
15
+ schema :
16
+ const : 37
17
+ /contents :
18
+ get :
19
+ summary : Retrieve the contents of the given URI.
20
+ responses :
21
+ " 200 " :
22
+ content :
23
+ application/json :
24
+ schema :
25
+ const : 137
You can’t perform that action at this time.
0 commit comments