forked from yhnavein/swaggie
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.json
56 lines (56 loc) · 2.02 KB
/
schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{
"$id": "https://github.com/yhnavein/swaggie/blob/master/schema.json",
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Swaggie Settings Schema",
"definitions": {
"Globals": {
"additionalProperties": true,
"description": "Main settings of the application",
"properties": {
"out": {
"description": "The path to the file where the API would be generated. Use stdout if left empty.",
"type": "string"
},
"src": {
"description": "The url or path to the Open API spec file. Both JSON and YAML are supported",
"type": "string"
},
"template": {
"default": "axios",
"description": "Template that will be used for generating the API client. You can reference bundled templates by name or provide path to the custom template as well",
"examples": ["axios", "swr-axios", "fetch", "ng1", "ng2"],
"type": "string"
},
"baseUrl": {
"default": "",
"description": "Base URL that will be used as a default value in the clients",
"type": "string"
},
"preferAny": {
"default": false,
"description": "Use `any` type instead of `unknown`",
"type": "boolean"
},
"queryModels": {
"default": false,
"description": "Generate models for query string instead list of parameters",
"type": "boolean"
},
"servicePrefix": {
"default": "",
"description": "Prefix for service names. Useful when you have multiple APIs and you want to avoid name collisions",
"type": "string"
},
"dateFormat": {
"default": "Date",
"description": "It determines how Date fields will be handled and what type they will have in models",
"enum": ["Date", "string"],
"type": "string"
}
},
"required": ["out", "src"],
"type": "object"
}
},
"allOf": [{ "$ref": "#/definitions/Globals" }]
}