> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ticktock.bet/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Team

> Team profile + per-map stats from HLTV

## What it returns

Team identity (name, country, ranking, region) **plus** the per-map `map_stats` block:

| `map_stats[]` field                                                                                          | Meaning                                                                      |
| ------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------- |
| `map_name`                                                                                                   | `"all"` for the aggregate, otherwise the HLTV map slug (e.g. `de_inferno`)   |
| `maps_played`, `wins`, `draws`, `losses`, `win_rate`                                                         | Volume + W/L                                                                 |
| `total_kills`, `total_deaths`, `kd_ratio`, `rating`                                                          | Aggregate skill metrics                                                      |
| `rounds_played`, `rounds_won`, `round_win_rate`                                                              | Round-level                                                                  |
| `ct_round_win_pct`, `t_round_win_pct`                                                                        | Side splits                                                                  |
| `pistol_rounds`, `pistol_rounds_won`, `pistol_win_pct`                                                       | Pistol-round W/L                                                             |
| `pick_pct`, `ban_pct`                                                                                        | Map veto preference                                                          |
| `first_kill_win_pct`, `first_death_win_pct`                                                                  | First-kill conversion                                                        |
| `map_details.{first_kill_win_pct_ct, first_kill_win_pct_t, first_death_loss_pct_ct, first_death_loss_pct_t}` | Per-side first-duel splits                                                   |
| `top_player_opening_kills[]`                                                                                 | Per-roster opening-kill leaderboard (player\_id, nickname, opening\_kpr/dpr) |
| `players_opening`                                                                                            | Same data raw                                                                |
| `players_flash`                                                                                              | Per-player flash assists (when scraped)                                      |
| `opening_kpr`                                                                                                | Team-level opening KPR (sum of player successes / rounds)                    |

`map_stats` always includes the `"all"` aggregate plus one row per map the team has played in the requested window.

## Required scope

* **Minimum:** `cs2:teams:read`

## Query

| Param         | Default | Description                                              |
| ------------- | ------- | -------------------------------------------------------- |
| `time_filter` | `3m`    | Window for `map_stats`. Accepts `3m`, `6m`, `1y`, `all`. |

## Example

```bash theme={null}
curl -H "X-API-Key: $TT_KEY" \
  "https://ticktock.bet/cs2/v1/teams/11712?time_filter=6m"
```


## OpenAPI

````yaml openapi/cs2-api.json GET /cs2/v1/teams/{hltv_id}
openapi: 3.1.0
info:
  title: TickTock B2B API
  description: >-
    Unified CS2 API (``/cs2/v1/*``) plus sport-agnostic ``/v1/*`` meta
    endpoints. Tenant-authenticated via ``X-API-Key`` or ``x-access-token``
    header (REST), or ``api_key`` query parameter (WebSocket). Field visibility
    is gated by per-key scopes — see ``docs/CS2_API_REFERENCE.md`` for the
    catalog and migration.
  version: 1.0.0
servers:
  - url: https://ticktock.bet
    description: Production (same-origin proxy)
  - url: https://feed.ticktock.bet
    description: Production (B2B subdomain)
security: []
paths:
  /cs2/v1/teams/{hltv_id}:
    get:
      tags:
        - CS2
      summary: CS2 team profile + per-map stats
      description: >-
        Team identity + ranking, plus the per-map ``map_stats`` block from HLTV:
        maps_played, wins/draws/losses, win rate, K/D, rating, CT/T round-win %,
        pistol round %, pick/ban %, first-kill conversion, top-opening-kill
        players. ``map_stats`` always includes the ``"all"`` aggregate plus one
        row per map the team has played in the requested ``time_filter``.


        Include ``cs2:matches:internals`` to see ``is_active`` and ingestion
        timestamps.
      operationId: get_team_cs2_v1_teams__hltv_id__get
      parameters:
        - name: hltv_id
          in: path
          required: true
          schema:
            type: integer
            title: Hltv Id
        - name: time_filter
          in: query
          required: false
          schema:
            type: string
            description: 'Window for ``map_stats``: 3m, 6m, 1y, all.'
            default: 3m
            title: Time Filter
          description: 'Window for ``map_stats``: 3m, 6m, 1y, all.'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                additionalProperties: true
                title: Response Get Team Cs2 V1 Teams  Hltv Id  Get
              example:
                data:
                  hltv_id: 11712
                  name: Sashi
                  country_code: DK
                  world_ranking: 42
                  region: EMEA
                  time_filter: 3months
                  map_stats:
                    - map_name: all
                      maps_played: 87
                      wins: 51
                      losses: 33
                      win_rate: 0.586
                      rating: 1.06
                      ct_round_win_pct: 0.524
                      t_round_win_pct: 0.481
            application/xml: {}
        '401':
          description: >-
            Missing API key. Pass either `X-API-Key: <your-key>` or
            `$x$access-token: <your-key>` on REST calls (or `?api_key=` on
            WebSocket handshakes).
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Human-readable error message.
                required:
                  - detail
              example:
                detail: Missing X-API-Key or $x$access-token header
        '403':
          description: >-
            API key authenticated but lacks the scope required for this
            endpoint, or the path's sport is not in the key's `sport_allowlist`.
            Use `GET /v1/whoami` to inspect the granted scope set.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Human-readable error message.
                required:
                  - detail
              example:
                detail: >-
                  Required scope 'cs2:matches:detail' is not granted to this API
                  key. Contact your account manager to extend the key's scopes.
        '404':
          description: Resource not found.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Human-readable error message.
                required:
                  - detail
              example:
                detail: Match not found
        '422':
          description: >-
            Validation error — a query/path parameter failed validation. The
            body lists the offending fields.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
              example:
                detail:
                  - type: enum
                    loc:
                      - query
                      - time_filter
                    msg: 'Input should be one of: 3m, 6m, 1y, all'
                    input: 2w
        '429':
          description: >-
            Tenant rate limit exceeded. Default is 600 req/min per tenant;
            configurable per contract. WebSocket connections are not
            rate-limited at the request layer.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Human-readable error message.
                required:
                  - detail
              example:
                detail: Rate limit exceeded (600 req/min)
          headers:
            Retry-After:
              description: Seconds to wait before retrying.
              schema:
                type: integer
                example: 30
      security:
        - XAPIKeyHeader: []
        - XAccessTokenHeader: []
        - UOFAccessTokenHeader: []
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    XAPIKeyHeader:
      type: apiKey
      description: Tenant API key issued during onboarding
      in: header
      name: X-API-Key
    XAccessTokenHeader:
      type: apiKey
      description: UOF-standard alias for the tenant API key
      in: header
      name: x-access-token
    UOFAccessTokenHeader:
      type: apiKey
      description: Deprecated alias for x-access-token (backward compatibility)
      in: header
      name: $x$access-token

````