mirror of
https://github.com/samuelthomas2774/nxapi.git
synced 2026-04-24 23:16:53 -05:00
Add SplatNet 3 JSON schema generation
This commit is contained in:
parent
6276cef356
commit
b7299cb001
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -3,4 +3,4 @@ dist
|
|||
data
|
||||
docker-compose.override.yml
|
||||
.env
|
||||
.vscode/schema
|
||||
.vscode/schema/generated
|
||||
|
|
|
|||
21
.vscode/generate-schemas.sh
vendored
21
.vscode/generate-schemas.sh
vendored
|
|
@ -1,19 +1,10 @@
|
|||
#!/bin/sh
|
||||
|
||||
mkdir -p .vscode/schema/{moon,splatnet2,nooklink}
|
||||
mkdir -p .vscode/schema/generated
|
||||
|
||||
npx ts-json-schema-generator --path src/api/moon-types.ts --type DailySummary --no-type-check > .vscode/schema/moon/dailysummary.schema.json
|
||||
npx ts-json-schema-generator --path src/api/moon-types.ts --type MonthlySummary --no-type-check > .vscode/schema/moon/monthlysummary.schema.json
|
||||
npx ts-json-schema-generator --path src/api/moon-types.ts --expose all --no-type-check > .vscode/schema/generated/moon-types.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --expose all --no-type-check > .vscode/schema/generated/splatnet2-types.schema.json
|
||||
npx ts-json-schema-generator --path src/api/nooklink-types.ts --expose all --no-type-check > .vscode/schema/generated/nooklink-types.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet3-types.ts --expose all --no-type-check > .vscode/schema/generated/splatnet3-types.schema.json
|
||||
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type Records --no-type-check > .vscode/schema/splatnet2/records.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type NicknameAndIcon --no-type-check > .vscode/schema/splatnet2/ni.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type Timeline --no-type-check > .vscode/schema/splatnet2/timeline.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type HeroRecords --no-type-check > .vscode/schema/splatnet2/hero.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type Results --no-type-check > .vscode/schema/splatnet2/results-summary.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type ResultWithPlayerNicknameAndIcons --no-type-check > .vscode/schema/splatnet2/result.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type CoopResults --no-type-check > .vscode/schema/splatnet2/coop-summary.schema.json
|
||||
npx ts-json-schema-generator --path src/api/splatnet2-types.ts --type CoopResultWithPlayerNicknameAndIcons --no-type-check > .vscode/schema/splatnet2/coop-result.schema.json
|
||||
|
||||
npx ts-json-schema-generator --path src/api/nooklink-types.ts --type Newspaper --no-type-check > .vscode/schema/nooklink/newspaper.schema.json
|
||||
|
||||
npx ts-json-schema-generator --path src/common/remote-config.ts --type NxapiRemoteConfig --no-type-check > .vscode/schema/remote-config.schema.json
|
||||
npx ts-json-schema-generator --path src/common/remote-config.ts --type NxapiRemoteConfig --no-type-check > .vscode/schema/generated/remote-config.schema.json
|
||||
|
|
|
|||
4
.vscode/schema/moon/dailysummary.schema.json
vendored
Normal file
4
.vscode/schema/moon/dailysummary.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/moon-types.schema.json#/definitions/DailySummary"
|
||||
}
|
||||
4
.vscode/schema/moon/monthlysummary.schema.json
vendored
Normal file
4
.vscode/schema/moon/monthlysummary.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/moon-types.schema.json#/definitions/MonthlySummary"
|
||||
}
|
||||
4
.vscode/schema/nooklink/newspaper.schema.json
vendored
Normal file
4
.vscode/schema/nooklink/newspaper.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/nooklink-types.schema.json#/definitions/Newspaper"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/coop-result.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/coop-result.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/CoopResultWithPlayerNicknameAndIcons"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/coop-summary.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/coop-summary.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/CoopResults"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/hero.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/hero.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/HeroRecords"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/ni.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/ni.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/NicknameAndIcon"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/records.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/records.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/Records"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/result.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/result.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/ResultWithPlayerNicknameAndIcons"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/results-summary.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/results-summary.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/Results"
|
||||
}
|
||||
4
.vscode/schema/splatnet2/timeline.schema.json
vendored
Normal file
4
.vscode/schema/splatnet2/timeline.schema.json
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"$ref": "../generated/splatnet2-types.schema.json#/definitions/Timeline"
|
||||
}
|
||||
12
.vscode/schema/splatnet3/coop-result.schema.json
vendored
Normal file
12
.vscode/schema/splatnet3/coop-result.schema.json
vendored
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"result": {
|
||||
"$ref": "../generated/splatnet3-types.schema.json#/definitions/CoopHistoryDetail"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"result"
|
||||
]
|
||||
}
|
||||
12
.vscode/schema/splatnet3/result.schema.json
vendored
Normal file
12
.vscode/schema/splatnet3/result.schema.json
vendored
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"result": {
|
||||
"$ref": "../generated/splatnet3-types.schema.json#/definitions/VsHistoryDetail"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"result"
|
||||
]
|
||||
}
|
||||
11
.vscode/settings.json
vendored
11
.vscode/settings.json
vendored
|
|
@ -50,9 +50,18 @@
|
|||
"url": "./.vscode/schema/nooklink/newspaper.schema.json"
|
||||
},
|
||||
|
||||
{
|
||||
"fileMatch": ["**/splatnet3-result-*.json"],
|
||||
"url": "./.vscode/schema/splatnet3/result.schema.json"
|
||||
},
|
||||
{
|
||||
"fileMatch": ["**/splatnet3-coop-result-*.json"],
|
||||
"url": "./.vscode/schema/splatnet3/coop-result.schema.json"
|
||||
},
|
||||
|
||||
{
|
||||
"fileMatch": ["**/resources/common/remote-config.json", "**/data/remote-config.json"],
|
||||
"url": "./.vscode/schema/remote-config.schema.json"
|
||||
"url": "./.vscode/schema/generated/remote-config.schema.json"
|
||||
},
|
||||
],
|
||||
"typescript.tsdk": "node_modules/typescript/lib",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user