---
openapi: 3.1.0
components:
  schemas:
    AgeCategory:
      type: string
      enum:
      - JUNIOR
      - SENIOR
      - YOUTH
    Attribute:
      type: string
      enum:
      - CAPTAIN
    Broadcast:
      type: object
      properties:
        awayTeam:
          $ref: "#/components/schemas/Group"
        cancelled:
          type: boolean
        competition:
          $ref: "#/components/schemas/Competition"
        end:
          $ref: "#/components/schemas/Date"
        extId:
          type: string
        extIds:
          type: array
          items:
            type: string
        filter:
          type: array
          items:
            $ref: "#/components/schemas/FilterType"
        homeTeam:
          $ref: "#/components/schemas/Group"
        id:
          type: string
        image:
          $ref: "#/components/schemas/File"
        imageUrl:
          type: string
        name:
          type: string
        products:
          type: array
          items:
            type: string
        season:
          type: string
        siteId:
          type: string
        start:
          $ref: "#/components/schemas/Date"
        streamEnd:
          $ref: "#/components/schemas/Date"
        streamStart:
          $ref: "#/components/schemas/Date"
        teams:
          type: array
          items:
            $ref: "#/components/schemas/Group"
        venueExtId:
          type: string
        venueId:
          type: string
    BroadcastInfo:
      type: object
      properties:
        broadcastId:
          type: string
        broadcastExtId:
          type: string
        siteId:
          type: string
        season:
          type: string
        awayClubName:
          type: string
        awayShortName:
          type: string
        awayTeamName:
          type: string
        awayTeamLogoUrl:
          type: string
        awayTeamHex:
          type: string
        homeClubName:
          type: string
        homeShortName:
          type: string
        homeTeamName:
          type: string
        homeTeamLogoUrl:
          type: string
        homeTeamHex:
          type: string
        arenaName:
          type: string
        teams:
          type: array
          items:
            $ref: "#/components/schemas/Team"
        sponsors:
          type: array
          items:
            type: string
        referees:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        competitionName:
          type: string
        sport:
          $ref: "#/components/schemas/Sport"
        locale:
          type: string
        timeZone:
          type: string
        startTime:
          $ref: "#/components/schemas/Date"
    BroadcastStanding:
      type: object
      properties:
        broadcast:
          $ref: "#/components/schemas/Broadcast"
        standing:
          $ref: "#/components/schemas/MatchStanding"
    ClockEventType:
      type: string
      enum:
      - END
      - RESET
      - START
      - STOP
      - UNMANAGED
    ClockEventType1:
      type: string
      enum:
      - END
      - RESET
      - START
      - STOP
      - UNMANAGED
    ClockInfo:
      type: object
      properties:
        broadcastExtId:
          type: string
        broadcastId:
          type: string
        description:
          type: string
        eventType:
          $ref: "#/components/schemas/ClockEventType"
        id:
          $ref: "#/components/schemas/ObjectId"
          type: string
          example: Internal id
        minutes:
          type: integer
          format: int32
        period:
          type: integer
          format: int32
        season:
          type: string
        seconds:
          type: integer
          format: int32
        siteId:
          type: string
        startMinute:
          type: integer
          format: int32
        timeAscending:
          type: boolean
        timeInSecs:
          type: integer
          format: int32
        timeStamp:
          $ref: "#/components/schemas/Date"
        updatedTimeStamp:
          $ref: "#/components/schemas/Date"
    Competition:
      type: object
      properties:
        competitionGroupId:
          type: string
        end:
          $ref: "#/components/schemas/Date"
        extId:
          type: string
        id:
          $ref: "#/components/schemas/ObjectId"
        image:
          $ref: "#/components/schemas/Image"
        level1:
          type: string
        level2:
          type: string
        name:
          type: string
        playerLevel:
          $ref: "#/components/schemas/PlayerLevel"
        siteId:
          type: string
        start:
          $ref: "#/components/schemas/Date"
        type:
          type: string
    Date:
      type: string
      format: date
      examples:
      - 2022-03-10
    File:
      type: object
      properties:
        blobId:
          type: string
        id:
          type: string
        mimeType:
          type: string
    FilterType:
      type: string
      enum:
      - BO
      - EX
      - LL
      - PS
      - TA
    Gender:
      type: string
      enum:
      - FEMALE
      - MALE
      - MIXED
    Group:
      type: object
      properties:
        externalId:
          type: string
        id:
          type: string
        level1:
          type: string
        level2:
          type: string
        logo:
          $ref: "#/components/schemas/Image"
        name:
          type: string
        parentId:
          type: string
        primaryHex:
          type: string
        secondaryHex:
          type: string
        shortName:
          type: string
        teamExtId:
          type: string
        teamId:
          type: string
        teamName:
          type: string
    Image:
      type: object
      properties:
        blobId:
          type: string
        blobPath:
          type: string
        id:
          type: string
        mimeType:
          type: string
        url:
          type: string
    Line:
      type: object
      properties:
        name:
          type: string
        players:
          type: array
          items:
            $ref: "#/components/schemas/Person"
    Lineup:
      type: object
      properties:
        broadcastExtId:
          type: string
        broadcastFilter:
          type: array
          uniqueItems: true
          items:
            $ref: "#/components/schemas/FilterType"
        broadcastId:
          type: string
        broadcastStart:
          $ref: "#/components/schemas/Date"
        clubExtId:
          type: string
        clubId:
          type: string
        clubName:
          type: string
        coaches:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        competitionId:
          type: string
        goalies:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        id:
          $ref: "#/components/schemas/ObjectId"
          type: string
          example: Internal id
        lines:
          type: array
          items:
            $ref: "#/components/schemas/Line"
        playerLevel:
          $ref: "#/components/schemas/PlayerLevel"
        season:
          type: string
        shortName:
          type: string
        siteId:
          type: string
        substitutes:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        teamExtId:
          type: string
        teamId:
          type: string
        teamName:
          type: string
        teamType:
          $ref: "#/components/schemas/TeamType"
    LineupAttributes:
      type: object
      required:
      - role
      - siteId
      properties:
        num:
          type: integer
          format: int32
        position:
          $ref: "#/components/schemas/Position"
        role:
          $ref: "#/components/schemas/Role"
        clubId:
          type: string
        playerLevelName:
          type: string
        siteId:
          type: string
    LineupPerson:
      type: object
      properties:
        id:
          type: string
        extId:
          type: string
        firstName:
          type: string
        lastName:
          type: string
        lineupAttributes:
          type: array
          items:
            $ref: "#/components/schemas/LineupAttributes"
    MatchEvent:
      type: object
      required:
      - eventType
      properties:
        actionPlayer:
          $ref: "#/components/schemas/Person"
        assistingPlayers:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        awayGoals:
          type: integer
          format: int32
        awayTeam:
          $ref: "#/components/schemas/Group"
        broadcastExtId:
          type: string
        broadcastFilter:
          type: array
          items:
            $ref: "#/components/schemas/FilterType"
        broadcastId:
          type: string
        competitionId:
          type: string
        competitionName:
          type: string
        durationInSecs:
          type: integer
          format: int32
        eventType:
          $ref: "#/components/schemas/MatchEventType"
        extId:
          type: string
        homeGoals:
          type: integer
          format: int32
        homeTeam:
          $ref: "#/components/schemas/Group"
        id:
          $ref: "#/components/schemas/ObjectId"
          type: string
          example: Internal id
        level1:
          type: string
        level2:
          type: string
        minutes:
          type: integer
          format: int32
        name:
          type: string
        netSportStanding:
          $ref: "#/components/schemas/NetSportStanding"
        opponent:
          $ref: "#/components/schemas/Person"
        outcome:
          $ref: "#/components/schemas/Outcome"
        period:
          type: integer
          format: int32
        playerLevel:
          $ref: "#/components/schemas/PlayerLevel"
        playersAgainst:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        playersFor:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        points:
          type: integer
          format: int32
        positionX:
          type: integer
          format: int32
        positionY:
          type: integer
          format: int32
        resultChanged:
          type: boolean
        season:
          type: string
        seconds:
          type: integer
          format: int32
        siteId:
          type: string
        status:
          $ref: "#/components/schemas/MatchStatus"
        subType:
          $ref: "#/components/schemas/MatchEventSubType"
        teamType:
          $ref: "#/components/schemas/TeamType"
        timeInSecs:
          type: integer
          format: int32
        timeStamp:
          $ref: "#/components/schemas/Date"
        updatedTimeStamp:
          $ref: "#/components/schemas/Date"
    MatchEventSubType:
      type: string
      enum:
      - BALL_WIN
      - DEFENSIVE
      - GAME_WIN
      - MAJOR
      - MINOR
      - NUM_ADVANTAGE
      - NUM_ADVANTAGE_2
      - NUM_DISADVANTAGE
      - NUM_DISADVANTAGE_2
      - OFFENSIVE
      - OWN_GOAL
      - PENALTY_SHOT
      - SERVE_ACE
      - SERVE_DBL_FAULT
      - STEAL
      - TECHNICAL_FAULT
    MatchEventType:
      type: string
      enum:
      - BLOCK
      - FACEOFF
      - GOAL
      - MATCH_STANDING
      - PENALTY
      - POINT
      - POSSESSION
      - REBOUND
      - SHOOTOUT
      - SHOT
      - SUBSTITUTION
      - TURNOVER
    MatchStanding:
      type: object
      properties:
        id:
          type: string
        broadcastId:
          type: string
        broadcastExtId:
          type: string
        competitionId:
          type: string
        siteId:
          type: string
        season:
          type: string
        netSportStanding:
          $ref: "#/components/schemas/NetSportStanding"
        homeGoals:
          type: integer
          format: int32
        awayGoals:
          type: integer
          format: int32
        period:
          type: integer
          format: int32
        status:
          $ref: "#/components/schemas/MatchStatus"
        timeStamp:
          $ref: "#/components/schemas/Date"
        updatedTimeStamp:
          $ref: "#/components/schemas/Date"
    MatchStatus:
      type: string
      enum:
      - ENDED
      - NOT_STARTED
      - OT
      - PAUSED
      - RUNNING
      - STARTED
    NetSportStanding:
      type: object
      properties:
        awayNetGame:
          type: string
        awayNetMatch:
          type: integer
          format: int32
        awayNetSets:
          type: array
          items:
            type: integer
            format: int32
        homeNetGame:
          type: string
        homeNetMatch:
          type: integer
          format: int32
        homeNetSets:
          type: array
          items:
            type: integer
            format: int32
        serve:
          $ref: "#/components/schemas/TeamType"
    ObjectId:
      type: string
      format: ObjectId
      description: MongoDB ObjectId represented as a string.
    Officials:
      type: object
      properties:
        broadcastExtId:
          type: string
        broadcastId:
          type: string
        id:
          $ref: "#/components/schemas/ObjectId"
          type: string
          example: Internal id
        persons:
          type: array
          items:
            $ref: "#/components/schemas/Person"
        season:
          type: string
        siteId:
          type: string
    Outcome:
      type: string
      enum:
      - BLOCK
      - GOAL
      - MISS
      - POST
      - SAVE
    Person:
      type: object
      properties:
        attributes:
          type: array
          items:
            $ref: "#/components/schemas/Attribute"
        extId:
          type: string
        firstName:
          type: string
        id:
          type: string
        lastName:
          type: string
        num:
          type: integer
          format: int32
        position:
          $ref: "#/components/schemas/Position"
        role:
          $ref: "#/components/schemas/Role"
    Person1:
      type: object
      properties:
        id:
          $ref: "#/components/schemas/ObjectId"
          type: string
          example: Internal id
        siteId:
          type: string
        extId:
          type: string
        role:
          $ref: "#/components/schemas/Role"
        clubId:
          type: string
        playerLevelName:
          type: string
        firstName:
          type: string
        lastName:
          type: string
        num:
          type: integer
          format: int32
        position:
          $ref: "#/components/schemas/Position"
        image:
          $ref: "#/components/schemas/Image"
        created:
          $ref: "#/components/schemas/Date"
        updated:
          $ref: "#/components/schemas/Date"
    PlayerLevel:
      type: object
      properties:
        category:
          $ref: "#/components/schemas/AgeCategory"
        extId:
          type: string
        gender:
          $ref: "#/components/schemas/Gender"
        maxAge:
          type: integer
          format: int32
        name:
          type: string
    Position:
      type: string
      enum:
      - ASSIST
      - CF
      - D
      - F
      - GK
      - GK2
      - HEAD
      - L
      - LD
      - LINE
      - LW
      - M
      - MF
      - MISC
      - RD
      - RW
      - STAFF
    Role:
      type: string
      enum:
      - COACH
      - PLAYER
      - REFEREE
    Role1:
      type: string
      enum:
      - COACH
      - GOALIE
      - PLAYER
      - REFEREE
    SortOrder:
      type: string
      enum:
      - Ascending
      - Descending
    Sport:
      type: string
      enum:
      - BANDY
      - BASKETBALL
      - CHEER_LEADING
      - CURLING
      - FIELD_HOCKEY
      - FIGURE_SKATING
      - FLOORBALL
      - FOOTBALL
      - HANDBALL
      - HOCKEY
      - ICE_HOCKEY
      - LONG_TRACK
      - MARTIAL_ARTS
      - NETBALL
      - RINGETTE
      - RINKBALL
      - RUGBY
      - SHORT_TRACK
      - TABLE_TENNIS
      - TENNIS
      - VOLLEYBALL
    Team:
      type: object
      properties:
        clubName:
          type: string
        shortName:
          type: string
        teamHex:
          type: string
        teamLogoUrl:
          type: string
        teamName:
          type: string
    TeamType:
      type: string
      enum:
      - AWAY
      - HOME
      - ROSTER
      - TEAM
  securitySchemes:
    SecurityScheme:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Authentication
paths:
  /match-event:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/MatchEvent"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchEvent"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Match Event
      tags:
      - Match Event Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    get:
      parameters:
      - name: action-or-assisting-player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: action-or-assisting-player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: action-player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: action-player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: assisting-player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: assisting-player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: broadcast-ext-id
        in: query
        schema:
          type: string
      - name: broadcast-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: competition-id
        in: query
        schema:
          type: string
      - name: event-type
        in: query
        schema:
          type: array
          items:
            $ref: "#/components/schemas/MatchEventType"
      - name: external-id
        in: query
        schema:
          type: string
      - name: filter
        in: query
        schema:
          $ref: "#/components/schemas/FilterType"
      - name: from
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: minute
        in: query
        schema:
          type: integer
          format: int32
      - name: name
        in: query
        schema:
          type: string
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: period
        in: query
        schema:
          type: integer
          format: int32
      - name: player-against-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-against-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-for-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-for-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: replacement-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: replacement-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: result-changed
        in: query
        schema:
          type: boolean
      - name: season
        in: query
        schema:
          type: string
      - name: second
        in: query
        schema:
          type: integer
          format: int32
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      - name: team-type
        in: query
        schema:
          $ref: "#/components/schemas/TeamType"
      - name: to
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/MatchEvent"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Match Events
      tags:
      - Match Event Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
  /match-event/broadcast-info:
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/BroadcastInfo"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/BroadcastInfo"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Broadcast Info
      tags:
      - Broadcast Info Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/clock-info:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ClockInfo"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ClockInfo"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Match Event
      tags:
      - Clock Info Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    get:
      parameters:
      - name: broadcast-ext-id
        in: query
        schema:
          type: string
      - name: broadcast-id
        in: query
        schema:
          type: string
      - name: from
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: period
        in: query
        schema:
          type: integer
          format: int32
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      - name: to
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: type
        in: query
        schema:
          $ref: "#/components/schemas/ClockEventType1"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/ClockInfo"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Clock Infos
      tags:
      - Clock Info Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/ClockInfo"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ClockInfo"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Match Event
      tags:
      - Clock Info Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/clock-info/{id}:
    get:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ClockInfo"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Clock Info By Id
      tags:
      - Clock Info Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    delete:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: boolean
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Delete Clock Info By Id
      tags:
      - Clock Info Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/lineup:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Lineup"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Lineup"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Lineup
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    get:
      parameters:
      - name: broadcast-ext-id
        in: query
        schema:
          type: string
      - name: broadcast-filter
        in: query
        schema:
          $ref: "#/components/schemas/FilterType"
      - name: broadcast-id
        in: query
        schema:
          type: string
      - name: club-ext-id
        in: query
        schema:
          type: string
      - name: club-id
        in: query
        schema:
          type: string
      - name: club-name
        in: query
        schema:
          type: string
      - name: coach-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: coach-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: competition-id
        in: query
        schema:
          type: string
      - name: first-name
        in: query
        schema:
          type: string
      - name: from
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: goalie-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: goalie-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: group-id
        in: query
        schema:
          type: string
      - name: last-name
        in: query
        schema:
          type: string
      - name: name
        in: query
        schema:
          type: string
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: person-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: person-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: person-role
        in: query
        schema:
          type: array
          items:
            $ref: "#/components/schemas/Role1"
      - name: player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-level
        in: query
        schema:
          type: string
      - name: season
        in: query
        schema:
          type: string
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      - name: substitute-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: substitute-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: team-ext-id
        in: query
        schema:
          type: string
      - name: team-id
        in: query
        schema:
          type: string
      - name: team-name
        in: query
        schema:
          type: string
      - name: team-type
        in: query
        schema:
          $ref: "#/components/schemas/TeamType"
      - name: to
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: site-id
        in: header
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/Lineup"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Lineups
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Lineup"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Lineup"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Lineup
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/lineup/person:
    get:
      parameters:
      - name: broadcast-ext-id
        in: query
        schema:
          type: string
      - name: broadcast-filter
        in: query
        schema:
          $ref: "#/components/schemas/FilterType"
      - name: broadcast-id
        in: query
        schema:
          type: string
      - name: club-ext-id
        in: query
        schema:
          type: string
      - name: club-id
        in: query
        schema:
          type: string
      - name: club-name
        in: query
        schema:
          type: string
      - name: coach-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: coach-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: competition-id
        in: query
        schema:
          type: string
      - name: first-name
        in: query
        schema:
          type: string
      - name: from
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: goalie-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: goalie-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: group-id
        in: query
        schema:
          type: string
      - name: last-name
        in: query
        schema:
          type: string
      - name: name
        in: query
        schema:
          type: string
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: person-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: person-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: person-role
        in: query
        schema:
          type: array
          items:
            $ref: "#/components/schemas/Role1"
      - name: player-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: player-level
        in: query
        schema:
          type: string
      - name: season
        in: query
        schema:
          type: string
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      - name: substitute-ext-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: substitute-id
        in: query
        schema:
          type: array
          items:
            type: string
      - name: team-ext-id
        in: query
        schema:
          type: string
      - name: team-id
        in: query
        schema:
          type: string
      - name: team-name
        in: query
        schema:
          type: string
      - name: team-type
        in: query
        schema:
          $ref: "#/components/schemas/TeamType"
      - name: to
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: site-id
        in: header
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/LineupPerson"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Persons From Lineups
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
  /match-event/lineup/{id}:
    get:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Lineup"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Lineup By Id
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    delete:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: boolean
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Delete Lineup By Id
      tags:
      - Lineup Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/officials:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Officials"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Officials"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Officials
      tags:
      - Officials Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    get:
      parameters:
      - name: broadcast-ext-id
        in: query
        schema:
          type: string
      - name: broadcast-id
        in: query
        schema:
          type: string
      - name: first-name
        in: query
        schema:
          type: string
      - name: from
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: last-name
        in: query
        schema:
          type: string
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: person-ext-id
        in: query
        schema:
          type: string
      - name: person-id
        in: query
        schema:
          type: string
      - name: position
        in: query
        schema:
          $ref: "#/components/schemas/Position"
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      - name: to
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/Officials"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Officials
      tags:
      - Officials Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Officials"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Officials"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Officials
      tags:
      - Officials Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/officials/{id}:
    get:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Officials"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Officials By Id
      tags:
      - Officials Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    delete:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: boolean
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Delete Officials
      tags:
      - Officials Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/person:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/Person1"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Person1"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Person
      tags:
      - Person Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    get:
      parameters:
      - name: ext-id
        in: query
        schema:
          type: string
      - name: first-name
        in: query
        schema:
          type: string
      - name: last-name
        in: query
        schema:
          type: string
      - name: name
        in: query
        schema:
          type: string
      - name: number
        in: query
        schema:
          type: integer
          format: int32
      - name: page-index
        in: query
        schema:
          type: integer
          format: int32
      - name: page-size
        in: query
        schema:
          type: integer
          format: int32
      - name: position
        in: query
        schema:
          $ref: "#/components/schemas/Position"
      - name: role
        in: query
        schema:
          $ref: "#/components/schemas/Role"
      - name: site-id
        in: query
        schema:
          type: string
      - name: sort-column
        in: query
        schema:
          type: string
      - name: sort-order
        in: query
        schema:
          $ref: "#/components/schemas/SortOrder"
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/Person1"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Persons
      tags:
      - Person Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
  /match-event/person/{id}:
    get:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Person1"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Person By Id
      tags:
      - Person Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
  /match-event/standing:
    patch:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/MatchStanding"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchStanding"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Patch Match Standing
      tags:
      - Match Standing Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/MatchStanding"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchStanding"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Match Standing
      tags:
      - Match Standing Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/standings:
    get:
      parameters:
      - name: competition-id
        in: query
        schema:
          type: string
      - name: site-id
        in: query
        schema:
          type: string
      - name: start-date
        in: query
        schema:
          $ref: "#/components/schemas/Date"
      - name: site-id
        in: header
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/BroadcastStanding"
      summary: Get Broadcast Standings
      tags:
      - Match Standing Resource
  /match-event/torneopal/webhook:
    post:
      requestBody:
        content:
          application/json:
            schema:
              type: string
        required: true
      responses:
        "201":
          description: Created
      summary: On Message
      tags:
      - Torneopal Match Data Webhook Resource
  /match-event/v2:
    post:
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/MatchEvent"
        required: true
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchEvent"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
        "400":
          description: Bad Request
      summary: Create Match Event
      tags:
      - Match Event Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
  /match-event/{broadcastId}/standing:
    get:
      parameters:
      - name: broadcastId
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchStanding"
      summary: Get Match Standing For Broadcast Id
      tags:
      - Match Standing Resource
  /match-event/{id}:
    get:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/MatchEvent"
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Get Match Event
      tags:
      - Match Event Resource
      security:
      - SecurityScheme:
        - System
        - SuperAdmin
        - Admin
        - Member
        - Viewer
    delete:
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        "200":
          description: OK
          content:
            application/json:
              schema:
                type: boolean
        "401":
          description: Not Authorized
        "403":
          description: Not Allowed
      summary: Delete Match Event By Id
      tags:
      - Match Event Resource
      security:
      - SecurityScheme:
        - Admin
        - SuperAdmin
        - System
        - Member
info:
  title: Match-Event Service API
  version: 1.0.0-SNAPSHOT
