# API Documentation: Get PPS Information

## Endpoint  
**URL**:  
```
https://db.lilacdancecenter.com/api/pps_comps
https://db.lilacdancecenter.com/api/pps_events
```

**Method**:  
`GET`

---

## Query Parameters  
| Parameter    | Type    | Description                                  |
|--------------|---------|----------------------------------------------|
| `profile_id`  | Integer  | The profile_id of user the token belogs to. Required         |
| `token`   | String  | The user's tokens. Required.            |
| `comp_id` | Integer | Comp ID that the user wants PPS data for. Only for /pps_events |

Example Request:  
```
https://db.lilacdancecenter.com/api/pps_comps?profile_id=1&token=ThisIsAnAPIToken
```
```
https://db.lilacdancecenter.com/api/pps_events?profile_id=1&token=ThisIsAnAPIToken&comp_id=1178
```
---

## Response  
##### /pps_comps
The endpoint returns a JSON object of competition data from the beginning of the previous year (e.g. since 01-01-2025 assuming today is during 2026)
##### /pps_events
The endpoint returns a JSON object containing PPS data for the requested competition. 

### JSON Response Format  
##### /pps_comps
```json
{
  "1187":
    {
      "id":1187,
      "abbreviation":"ifb26",
      "comp_date":"2026-05-16T00:00:00.000-04:00",
      "location":"",
      "name":"Island Fantasy Ball (32nd year 2026",
      "source":"o2cm",
      "entry_count":171,
      "competitor_count":94
    },
    ...
}
```
##### /pps_events
```json
  This is in the format requested by USA Dance.
```