mirror of
https://github.com/nprasad2077/NBA_Go.git
synced 2026-09-22 14:05:13 +00:00
125 lines
2.9 KiB
YAML
125 lines
2.9 KiB
YAML
basePath: /
|
|
info:
|
|
contact: {}
|
|
description: Stats service with API-key auth
|
|
title: NBA_Go API
|
|
version: "1.0"
|
|
paths:
|
|
/api/playeradvancedstats:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: Returns filtered and paginated player stats
|
|
parameters:
|
|
- description: Season (e.g., 2025)
|
|
in: query
|
|
name: season
|
|
type: integer
|
|
- description: Team abbreviation (e.g., MIL)
|
|
in: query
|
|
name: team
|
|
type: string
|
|
- description: Player ID (e.g., greenaj01)
|
|
in: query
|
|
name: playerId
|
|
type: string
|
|
- default: 1
|
|
description: Page number
|
|
in: query
|
|
name: page
|
|
type: integer
|
|
- default: 20
|
|
description: Page size
|
|
in: query
|
|
name: pageSize
|
|
type: integer
|
|
- description: Field to sort by (e.g., per, games, winShares)
|
|
in: query
|
|
name: sortBy
|
|
type: string
|
|
- description: Sort ascending (default false)
|
|
in: query
|
|
name: ascending
|
|
type: boolean
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties: true
|
|
type: object
|
|
security:
|
|
- ApiKeyAuth: []
|
|
summary: Get player stats
|
|
tags:
|
|
- PlayerStats
|
|
/api/playertotals:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: Filter and paginate player totals
|
|
parameters:
|
|
- description: Season (e.g. 2000)
|
|
in: query
|
|
name: season
|
|
type: integer
|
|
- description: Team abbreviation (e.g. LAL)
|
|
in: query
|
|
name: team
|
|
type: string
|
|
- description: Player ID (e.g. greenac01)
|
|
in: query
|
|
name: playerId
|
|
type: string
|
|
- default: 1
|
|
description: Page number
|
|
in: query
|
|
name: page
|
|
type: integer
|
|
- default: 20
|
|
description: Page size
|
|
in: query
|
|
name: pageSize
|
|
type: integer
|
|
- description: Field to sort by (e.g. points, assists)
|
|
in: query
|
|
name: sortBy
|
|
type: string
|
|
- description: Sort ascending (default false)
|
|
in: query
|
|
name: ascending
|
|
type: boolean
|
|
- description: Whether the stats are for playoffs
|
|
in: query
|
|
name: isPlayoff
|
|
type: boolean
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: OK
|
|
schema:
|
|
additionalProperties: true
|
|
type: object
|
|
"500":
|
|
description: Internal Server Error
|
|
schema:
|
|
additionalProperties:
|
|
type: string
|
|
type: object
|
|
security:
|
|
- ApiKeyAuth: []
|
|
summary: Get player total stats
|
|
tags:
|
|
- PlayerTotals
|
|
schemes:
|
|
- http
|
|
- https
|
|
securityDefinitions:
|
|
ApiKeyAuth:
|
|
in: header
|
|
name: X-API-Key
|
|
type: apiKey
|
|
swagger: "2.0"
|