# Sponsored Charge Points

Contains sponsored charge point relationships between charge point operators and teams. 
Links charge points to sponsoring teams and tracks sponsorship details including payouts 
and subscription settings. 

**SQL:** `sponsored_charge_points`

## Schema

| Column Name           | Data Type     | Description                                                                     |
|:----------------------|:--------------|:--------------------------------------------------------------------------------|
| **Primary ID**        |               |                                                                                 |
| id                    | INTEGER       | primary_key                                                                     |
| **Other IDs**         |               |                                                                                 |
| charge_point_id       | INTEGER       | References the associated charge point's unique identifier                      |
| team_id               | INTEGER       | References the sponsoring team's unique identifier                              |
| price_group_id        | INTEGER       | References the price group applied to this sponsored charge point               |
| **Timestamps**        |               |                                                                                 |
| created_at            | TIMESTAMP_NTZ | Timestamp when the sponsorship record was created                               |
| accepted_at           | TIMESTAMP_NTZ | Timestamp when the sponsorship was accepted by both parties                     |
| updated_at            | TIMESTAMP_NTZ | Timestamp of the last update to this sponsorship record                         |
| deleted_at            | TIMESTAMP_NTZ | Timestamp when the sponsorship was terminated, null if active                   |
| team_deleted_at       | TIMESTAMP_NTZ | Timestamp when the sponsoring team was deleted, null if active                  |
| **Attributes**        |               |                                                                                 |
| payout                | NUMBER        | The monetary amount paid to the charge point operator for this sponsorship      |
| note                  | VARCHAR       | Additional comments or details about the sponsorship arrangement                |
| pay_for_subscriptions | BOOLEAN       | Indicates whether subscription-based charging is covered under this sponsorship |

## Data Inclusion Criteria
* team_id is in among the operator's teams

## Data flow
| Upstream tables         | Downstream tables |
|:------------------------|:------------------|
| `charge_points` | none              |
| `teams`         |                   |

## Alignment
### Monta API
* This table aligns with the [get/sponsored-charge-points](https://developer.monta.com/api/v1/sponsored-charge-points/get) endpoint of the Monta API
