Team Price Groups (🧭 FUTURE)

✨ NEW TABLE - December 2025

🛠️ Partner API Alignment Migration

🧭 This table represents the post-migration state for team_price_groups.

1️⃣ Migrate to this table by April 2026

2️⃣ Between April 2026 and July 2026, remove FUTURE__ prefix Contains team pricing group configurations and their application metrics across charge points, sites, and team members. Provides comprehensive counts and aggregations for both total and non-deleted entities to support pricing strategy analysis and billing operations. Filters data to include only teams associated with the main operator.

SQL: FUTURE__team_price_groups

Schema

Column NameData TypeDescription
Primary ID
idINTEGERPrimary key
Other IDs
team_idINTEGERForeign key reference to the team associated with this price group
operator_idINTEGERForeign key reference to the operator managing this price group
external_idVARCHARExternal system identifier for the price group used for integration purposes
Timestamps
created_atTIMESTAMP_NTZTimestamp when the price group record was originally created
updated_atTIMESTAMP_NTZTimestamp when the price group record was last modified
deleted_atTIMESTAMP_NTZTimestamp when the price group was soft deleted, null if still active
Filters
is_main_operator_matchBOOLEANIndicates whether this price group belongs to the main operator (true) or a different operator (false)
Attributes
typeVARCHARClassification or category of the price group configuration
nameVARCHARHuman-readable name assigned to the price group for identification
team_member_countINTEGERNumber of team members currently associated with this price group
charge_point_countINTEGERNumber of charge points currently associated with this price group
applied_to_charge_points_totalINTEGERTotal count of charge points where this price group is applied, including deleted entities
applied_to_sites_totalINTEGERTotal count of sites where this price group is applied, including deleted entities
applied_to_team_members_totalINTEGERTotal count of team members where this price group is applied, including deleted entities
applied_to_charge_points_non_deletedINTEGERCount of active charge points where this price group is applied, excluding soft-deleted entities
applied_to_sites_non_deletedINTEGERCount of active sites where this price group is applied, excluding soft-deleted entities
applied_to_team_members_non_deletedINTEGERCount of active team members where this price group is applied, excluding soft-deleted entities
charge_point_count_totalINTEGERAggregate count of all charge points associated with this price group, including deleted entities
site_count_totalINTEGERAggregate count of all sites associated with this price group, including deleted entities
team_member_count_totalINTEGERAggregate count of all team members associated with this price group, including deleted entities
charge_point_count_non_deletedINTEGERAggregate count of active charge points associated with this price group, excluding soft-deleted entities
site_count_non_deletedINTEGERAggregate count of active sites associated with this price group, excluding soft-deleted entities
team_member_count_non_deletedINTEGERAggregate count of active team members associated with this price group, excluding soft-deleted entities
legacy_count_valid_rowsINTEGERNumber of valid data rows used in calculations for this price group record (used to match with legacy version of model)

Changes from last Version

Summary

  • Filter Changes: Removed implicit deleted filter; now exposes deleted records with deleted_at column
  • Aggregation Fields: Adds extensive aggregation columns tracking applied/count metrics for charge points, sites, and team members (both total and non-deleted)

Added columns (16)

  • operator_id
  • deleted_at
  • applied_to_charge_points_total
  • applied_to_sites_total
  • applied_to_team_members_total
  • applied_to_charge_points_non_deleted
  • applied_to_sites_non_deleted
  • applied_to_team_members_non_deleted
  • charge_point_count_total
  • site_count_total
  • team_member_count_total
  • charge_point_count_non_deleted
  • site_count_non_deleted
  • team_member_count_non_deleted
  • count_valid_rows
  • is_main_operator_match

Removed columns (0)

Renamed columns (3)

  • team_price_group_id -> id
  • team_price_group_type -> type
  • team_price_group_name -> name

Inclusion Criteria

  • the team_id must exist in the operator's FUTURE__teams.id

Data flow

Upstream tablesDownstream tables
FUTURE__teamsFUTURE__charge_member_costs

Alignment

Partner API

  • Aligns with Partner API get/price-groups endpoint
  • The API requires a teamID be passed
  • The API excludes rows where deleted_at is not null

The team_price_groups table

  • Use the new column count_valid_rows to align with the legacy table
where count_valid_rows > 0