clean up review

This commit is contained in:
Ravi Prasad
2025-06-03 22:56:34 -05:00
parent 24ec6675c9
commit 03177f58f2
12 changed files with 95242 additions and 13 deletions
+125 -4
View File
@@ -103,6 +103,58 @@
}
}
},
"/api/playeradvancedstats/scrape": {
"get": {
"tags": [
"PlayerStats"
],
"summary": "Scrape player advanced stats from BR website",
"parameters": [
{
"type": "integer",
"description": "Season (e.g. 2025)",
"name": "season",
"in": "query",
"required": true
},
{
"type": "boolean",
"description": "Whether playoffs?",
"name": "isPlayoff",
"in": "query"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"400": {
"description": "Bad Request",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal Server Error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
},
"/api/playershotchart": {
"get": {
"security": [
@@ -157,9 +209,9 @@
}
}
},
"/api/playershotchart/fetch": {
"/api/playershotchart/scrape": {
"get": {
"description": "Imports shot-chart data for the given playerId and stores/updates in DB",
"description": "Scrapes seasons [startSeason…endSeason] for the given playerId",
"consumes": [
"application/json"
],
@@ -169,14 +221,28 @@
"tags": [
"PlayerShotChart"
],
"summary": "Fetch a single player's shot-chart data from external API",
"summary": "Scrape a player's shot-chart from BR website",
"parameters": [
{
"type": "string",
"description": "Player ID (e.g., hardeja01)",
"description": "Player ID (e.g. derozde01)",
"name": "playerId",
"in": "query",
"required": true
},
{
"type": "integer",
"description": "Start season (e.g. 2024)",
"name": "startSeason",
"in": "query",
"required": true
},
{
"type": "integer",
"description": "End season (e.g. 2021)",
"name": "endSeason",
"in": "query",
"required": true
}
],
"responses": {
@@ -299,6 +365,58 @@
}
}
}
},
"/api/playertotals/scrape": {
"get": {
"tags": [
"PlayerTotals"
],
"summary": "Scrape player total stats from BR website",
"parameters": [
{
"type": "integer",
"description": "Season (e.g. 2025)",
"name": "season",
"in": "query",
"required": true
},
{
"type": "boolean",
"description": "Whether playoffs?",
"name": "isPlayoff",
"in": "query"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"400": {
"description": "Bad Request",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal Server Error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
}
},
"definitions": {
@@ -435,6 +553,7 @@
"type": "integer"
},
"id": {
"description": "Autoincrement primary key — works in SQLite and any other DB.",
"type": "integer"
},
"lead": {
@@ -450,9 +569,11 @@
"type": "integer"
},
"playerId": {
"description": "────────── \"identity\" columns (the dedup key) ──────────",
"type": "string"
},
"playerName": {
"description": "────────── the rest of the payload ──────────",
"type": "string"
},
"qtr": {