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

# Data model

# Services Data Model

This document provides complete documentation of the Planning Center Services data model in Parable, including all tables, fields, and relationships.

## Overview

The Services module contains **56 tables** (54 entity tables and 2 relationship tables) supporting worship planning, volunteer scheduling, song management, and service coordination across your entire ministry.

## Visual Data Model

<Tip>
  The diagram below shows the core entities and their relationships in the Services module. Use it as a visual reference while exploring the detailed table definitions below.
</Tip>

### Core Entity Relationships

<Frame>
  <img src="https://mintcdn.com/parable/dIkTtcPi0zjaWA0V/diagrams/planning-center/services-data-model-01.svg?fit=max&auto=format&n=dIkTtcPi0zjaWA0V&q=85&s=262e1cf35446fc24f7094bd1187002d3" alt="Services module data model" width="2989" height="2402" data-path="diagrams/planning-center/services-data-model-01.svg" />
</Frame>

[Open diagram in new tab →](/diagrams/planning-center/services-data-model-01.svg)

### Key Relationships Explained

**Service Planning Hierarchy:**

1. `SERVICE_TYPE` defines worship service types (Sunday AM, Sunday PM, Youth, etc.)
2. `PLAN`s are individual service plans within a service type
3. `PLAN_TIME`s define when rehearsals and services occur
4. `ITEM`s are the ordered elements within a plan (songs, media, announcements)

**Team Structure:**

* `TEAM`s organize volunteers by function (Worship, Production, Hospitality)
* `TEAM_POSITION`s define specific roles (Vocalist, Keys, Sound Engineer)
* `PLAN_PERSON` assigns people to positions for specific plans
* Status tracking: C=Confirmed, D=Declined, U=Unconfirmed

**Song Library:**

* `SONG`s are the core song catalog
* `ARRANGEMENT`s provide different versions (Slow, Upbeat, Acoustic)
* `KEY`s define available musical keys per arrangement
* `ITEM`s link songs/arrangements to specific plans

**Scheduling System:**

* `SCHEDULE`s assign people to specific plan times
* `BLOCKOUT`s indicate when volunteers are unavailable
* `BLOCKOUT_DATE`s specify exact dates blocked out
* `SIGNUP_SHEET`s facilitate volunteer self-scheduling

**Organization:**

* `SERIES` groups related plans (sermon series, special events)
* `FOLDER`s provide hierarchical organization
* `MEDIA` tracks video, audio, and presentation files

## Query Requirements

### Schema Prefix

**IMPORTANT:** All tables in the Planning Center Services module are in the `planning_center` schema. You MUST prefix all table names with `planning_center.` in your queries.

✅ CORRECT: `SELECT * FROM planning_center.services_plans`
❌ INCORRECT: `SELECT * FROM services_plans`

### Row Level Security (RLS)

This database uses Row Level Security (RLS) to automatically filter data based on:

* **tenant\_organization\_id**: You only see data for your current organization
* **system\_status**: You only see 'active' records by default

**DO NOT add these filters to your WHERE clause** - they are applied automatically:

* ❌ `WHERE tenant_organization_id = 1` (unnecessary)
* ❌ `WHERE system_status = 'active'` (unnecessary)

The RLS policies ensure you only access data you're authorized to see, making these filters redundant and potentially causing performance issues.

## Core Tables Overview

### Primary Entity Tables

* `services_service_types` - Service categories (Sunday morning, youth, special events)
* `services_plans` - Individual service plans with dates and details
* `services_teams` - Volunteer and worship teams
* `services_people` - People who serve in ministry
* `services_songs` - Song library and metadata
* `services_arrangements` - Song arrangements and keys
* `services_items` - Service elements and order
* `services_schedules` - Person scheduling information
* `services_plan_people` - People scheduled for specific plans
* `services_attachments` - Files, charts, and media

### Supporting Entity Tables

* `services_plan_times` - Service times (9am service, 11am service, etc.)
* `services_plan_templates` - Reusable service templates
* `services_team_positions` - Roles within teams (drummer, vocalist, etc.)
* `services_person_team_position_assignments` - Who can serve in what roles
* `services_needed_positions` - Unfilled positions for services
* `services_blockouts` - When people are unavailable
* `services_blockout_dates` - Specific unavailable dates
* `services_lives` - Live service control and streaming
* `services_media` - Media files and videos
* `services_folders` - Organizational structure

### Relationship Tables

* `services_song_relationships` - Links songs to tags and attachments
* `services_team_relationships` - Links teams to service types

## Table Definitions

### services\_service\_types

Service types define categories of services (Sunday Morning, Youth Service, etc.).

| Column                         | Type         | Description                                    |
| ------------------------------ | ------------ | ---------------------------------------------- |
| `id`                           | UUID         | Internal unique identifier                     |
| `service_type_id`              | VARCHAR(64)  | Planning Center service type ID                |
| `name`                         | VARCHAR(255) | Service type name                              |
| `sequence`                     | INTEGER      | Display order                                  |
| `permissions`                  | VARCHAR(50)  | Permission level                               |
| `attachment_types_enabled`     | BOOLEAN      | Whether attachment types are enabled           |
| `scheduled_publish`            | BOOLEAN      | Whether scheduled publishing is enabled        |
| `frequency`                    | VARCHAR(50)  | Service frequency (Weekly, Monthly, etc.)      |
| `archived_at`                  | TIMESTAMP    | When service type was archived                 |
| `created_at`                   | TIMESTAMP    | When created in Planning Center                |
| `updated_at`                   | TIMESTAMP    | Last update in Planning Center                 |
| `deleted_at`                   | TIMESTAMP    | When deleted in Planning Center                |
| `custom_item_types`            | JSONB        | Custom service item types configuration        |
| `standard_item_types`          | JSONB        | Standard item types (Header, Song, Media)      |
| `background_check_permissions` | VARCHAR(50)  | Background check requirement level             |
| `comment_permissions`          | VARCHAR(50)  | Who can comment on plans                       |
| `last_plan_from`               | VARCHAR(50)  | How last plan was created                      |
| `tenant_organization_id`       | INTEGER      | Organization identifier                        |
| `system_status`                | VARCHAR(50)  | Data status: 'active', 'transferring', 'stale' |
| `system_created_at`            | TIMESTAMP    | When record was created in Parable             |
| `system_updated_at`            | TIMESTAMP    | When record was last updated in Parable        |

### services\_plans

Individual service plans containing all details for a specific service date.

| Column                   | Type          | Description                         |
| ------------------------ | ------------- | ----------------------------------- |
| `id`                     | UUID          | Internal unique identifier          |
| `plan_id`                | VARCHAR(64)   | Planning Center plan ID             |
| `service_type_id`        | VARCHAR(64)   | Associated service type             |
| `title`                  | VARCHAR(255)  | Plan title                          |
| `series_title`           | VARCHAR(255)  | Sermon series title                 |
| `public`                 | BOOLEAN       | Whether plan is publicly visible    |
| `can_view_order`         | BOOLEAN       | Whether order is viewable           |
| `rehearsable`            | BOOLEAN       | Whether rehearsal is scheduled      |
| `multi_day`              | BOOLEAN       | Whether plan spans multiple days    |
| `items_count`            | INTEGER       | Total number of service items       |
| `plan_people_count`      | INTEGER       | Number of scheduled people          |
| `needed_positions_count` | INTEGER       | Number of unfilled positions        |
| `plan_notes_count`       | INTEGER       | Number of plan notes                |
| `service_time_count`     | INTEGER       | Number of service times             |
| `rehearsal_time_count`   | INTEGER       | Number of rehearsal times           |
| `other_time_count`       | INTEGER       | Number of other scheduled times     |
| `total_length`           | INTEGER       | Total service length in seconds     |
| `sort_date`              | TIMESTAMP     | Date used for chronological sorting |
| `last_time_at`           | TIMESTAMP     | Last service time                   |
| `dates`                  | VARCHAR(255)  | Human-readable date string          |
| `short_dates`            | VARCHAR(100)  | Abbreviated date string             |
| `files_expire_at`        | TIMESTAMP     | When attached files expire          |
| `planning_center_url`    | VARCHAR(2048) | Direct link to plan                 |
| `reminders_disabled`     | BOOLEAN       | Whether reminders are turned off    |
| `created_at`             | TIMESTAMP     | When created                        |
| `updated_at`             | TIMESTAMP     | Last update                         |
| `permissions`            | VARCHAR(50)   | User permissions for this plan      |
| `tenant_organization_id` | INTEGER       | Organization identifier             |
| `system_status`          | VARCHAR(50)   | Data status                         |
| `system_created_at`      | TIMESTAMP     | When created in Parable             |
| `system_updated_at`      | TIMESTAMP     | Last update in Parable              |

### services\_teams

Teams of volunteers and staff who serve in ministry.

| Column                          | Type         | Description                             |
| ------------------------------- | ------------ | --------------------------------------- |
| `id`                            | UUID         | Internal unique identifier              |
| `team_id`                       | VARCHAR(64)  | Planning Center team ID                 |
| `service_type_id`               | VARCHAR(64)  | Associated service type                 |
| `name`                          | VARCHAR(255) | Team name                               |
| `rehearsal_team`                | BOOLEAN      | Whether team attends rehearsals         |
| `secure_team`                   | BOOLEAN      | Whether team requires background checks |
| `sequence`                      | INTEGER      | Display order                           |
| `schedule_to`                   | VARCHAR(50)  | Scheduling type ('plan' or 'time')      |
| `default_status`                | VARCHAR(50)  | Default response status                 |
| `default_prepare_notifications` | BOOLEAN      | Default notification setting            |
| `assigned_directly`             | BOOLEAN      | Whether people are assigned directly    |
| `viewers_see`                   | INTEGER      | What viewers can see                    |
| `stage_color`                   | VARCHAR(50)  | Color for stage display                 |
| `stage_variant`                 | VARCHAR(50)  | Stage display variant                   |
| `archived_at`                   | TIMESTAMP    | When team was archived                  |
| `created_at`                    | TIMESTAMP    | When created                            |
| `updated_at`                    | TIMESTAMP    | Last update                             |
| `last_plan_from`                | VARCHAR(50)  | How last plan was created               |
| `tenant_organization_id`        | INTEGER      | Organization identifier                 |
| `system_status`                 | VARCHAR(50)  | Data status                             |
| `system_created_at`             | TIMESTAMP    | When created in Parable                 |
| `system_updated_at`             | TIMESTAMP    | Last update in Parable                  |

### services\_people

People who participate in services as volunteers, staff, or worship team members.

| Column                          | Type          | Description                   |
| ------------------------------- | ------------- | ----------------------------- |
| `id`                            | UUID          | Internal unique identifier    |
| `person_id`                     | VARCHAR(64)   | Planning Center person ID     |
| `first_name`                    | VARCHAR(100)  | First name                    |
| `last_name`                     | VARCHAR(100)  | Last name                     |
| `full_name`                     | VARCHAR(255)  | Complete name                 |
| `nickname`                      | VARCHAR(100)  | Preferred name                |
| `given_name`                    | VARCHAR(100)  | Given name                    |
| `middle_name`                   | VARCHAR(100)  | Middle name                   |
| `birthdate`                     | DATE          | Date of birth                 |
| `anniversary`                   | DATE          | Anniversary date              |
| `photo_url`                     | VARCHAR(2048) | Profile photo URL             |
| `photo_thumbnail_url`           | VARCHAR(2048) | Thumbnail photo URL           |
| `preferred_app`                 | VARCHAR(50)   | Preferred Planning Center app |
| `assigned_to_rehearsal_team`    | BOOLEAN       | Whether on rehearsal team     |
| `archived`                      | BOOLEAN       | Whether person is archived    |
| `site_administrator`            | BOOLEAN       | Whether site admin            |
| `permissions`                   | VARCHAR(50)   | General permissions           |
| `media_permissions`             | VARCHAR(50)   | Media access permissions      |
| `song_permissions`              | VARCHAR(50)   | Song access permissions       |
| `status`                        | VARCHAR(50)   | Active status                 |
| `notes`                         | TEXT          | Personal notes                |
| `passed_background_check`       | BOOLEAN       | Background check status       |
| `access_media_attachments`      | BOOLEAN       | Can access media              |
| `access_plan_attachments`       | BOOLEAN       | Can access plan files         |
| `access_song_attachments`       | BOOLEAN       | Can access song files         |
| `preferred_max_plans_per_day`   | INTEGER       | Daily scheduling limit        |
| `preferred_max_plans_per_month` | INTEGER       | Monthly scheduling limit      |
| `praise_charts_enabled`         | BOOLEAN       | PraiseCharts integration      |
| `ical_code`                     | VARCHAR(100)  | Calendar feed code            |
| `logged_in_at`                  | TIMESTAMP     | Last login time               |
| `created_at`                    | TIMESTAMP     | When created                  |
| `updated_at`                    | TIMESTAMP     | Last update                   |
| `archived_at`                   | TIMESTAMP     | When archived                 |
| `tenant_organization_id`        | INTEGER       | Organization identifier       |
| `system_status`                 | VARCHAR(50)   | Data status                   |
| `system_created_at`             | TIMESTAMP     | When created in Parable       |
| `system_updated_at`             | TIMESTAMP     | Last update in Parable        |

### services\_songs

Complete song library with metadata for worship planning.

| Column                       | Type         | Description                |
| ---------------------------- | ------------ | -------------------------- |
| `id`                         | UUID         | Internal unique identifier |
| `song_id`                    | VARCHAR(64)  | Planning Center song ID    |
| `title`                      | VARCHAR(255) | Song title                 |
| `author`                     | VARCHAR(255) | Song author/composer       |
| `copyright`                  | VARCHAR(500) | Copyright information      |
| `admin`                      | VARCHAR(255) | Administrator/publisher    |
| `ccli_number`                | INTEGER      | CCLI license number        |
| `hidden`                     | BOOLEAN      | Whether song is hidden     |
| `notes`                      | TEXT         | Song notes                 |
| `themes`                     | VARCHAR(500) | Song themes/tags           |
| `last_scheduled_at`          | TIMESTAMP    | When last used in service  |
| `last_scheduled_short_dates` | VARCHAR(100) | Short date of last use     |
| `created_at`                 | TIMESTAMP    | When created               |
| `updated_at`                 | TIMESTAMP    | Last update                |
| `tenant_organization_id`     | INTEGER      | Organization identifier    |
| `system_status`              | VARCHAR(50)  | Data status                |
| `system_created_at`          | TIMESTAMP    | When created in Parable    |
| `system_updated_at`          | TIMESTAMP    | Last update in Parable     |

### services\_arrangements

Different arrangements and keys for songs.

| Column                   | Type         | Description                     |
| ------------------------ | ------------ | ------------------------------- |
| `id`                     | UUID         | Internal unique identifier      |
| `arrangement_id`         | VARCHAR(64)  | Planning Center arrangement ID  |
| `song_id`                | VARCHAR(64)  | Associated song                 |
| `name`                   | VARCHAR(255) | Arrangement name                |
| `bpm`                    | DECIMAL(5,1) | Beats per minute                |
| `length`                 | INTEGER      | Length in seconds               |
| `meter`                  | VARCHAR(10)  | Time signature (4/4, 3/4, etc.) |
| `notes`                  | TEXT         | Arrangement notes               |
| `chord_chart`            | TEXT         | Chord chart content             |
| `lyrics`                 | TEXT         | Song lyrics                     |
| `sequence`               | JSONB        | Song section sequence           |
| `sequence_short`         | JSONB        | Abbreviated sequence            |
| `sequence_full`          | JSONB        | Full detailed sequence          |
| `chord_chart_key`        | VARCHAR(10)  | Musical key                     |
| `chord_chart_font`       | VARCHAR(50)  | Display font                    |
| `chord_chart_font_size`  | INTEGER      | Font size                       |
| `chord_chart_columns`    | INTEGER      | Column layout                   |
| `has_chords`             | BOOLEAN      | Whether chords exist            |
| `has_chord_chart`        | BOOLEAN      | Whether chart exists            |
| `lyrics_enabled`         | BOOLEAN      | Whether lyrics are enabled      |
| `number_chart_enabled`   | BOOLEAN      | Nashville number system         |
| `numeral_chart_enabled`  | BOOLEAN      | Roman numeral system            |
| `print_margin`           | VARCHAR(20)  | Print margins                   |
| `print_orientation`      | VARCHAR(20)  | Portrait/landscape              |
| `print_page_size`        | VARCHAR(20)  | Paper size                      |
| `archived_at`            | TIMESTAMP    | When archived                   |
| `created_at`             | TIMESTAMP    | When created                    |
| `updated_at`             | TIMESTAMP    | Last update                     |
| `tenant_organization_id` | INTEGER      | Organization identifier         |
| `system_status`          | VARCHAR(50)  | Data status                     |
| `system_created_at`      | TIMESTAMP    | When created in Parable         |
| `system_updated_at`      | TIMESTAMP    | Last update in Parable          |

### services\_items

Individual elements within a service plan.

| Column                        | Type         | Description                      |
| ----------------------------- | ------------ | -------------------------------- |
| `id`                          | UUID         | Internal unique identifier       |
| `item_id`                     | VARCHAR(64)  | Planning Center item ID          |
| `plan_id`                     | VARCHAR(64)  | Associated plan                  |
| `title`                       | VARCHAR(255) | Item title                       |
| `sequence`                    | INTEGER      | Order in service                 |
| `length`                      | INTEGER      | Duration in seconds              |
| `item_type`                   | VARCHAR(50)  | Type (song, header, media, item) |
| `service_position`            | VARCHAR(50)  | Position (pre, during, post)     |
| `description`                 | TEXT         | Item description                 |
| `key_name`                    | VARCHAR(10)  | Musical key                      |
| `html_details`                | TEXT         | Formatted details                |
| `custom_arrangement_sequence` | JSONB        | Custom sequence                  |
| `song_id`                     | VARCHAR(64)  | Associated song                  |
| `arrangement_id`              | VARCHAR(64)  | Associated arrangement           |
| `created_at`                  | TIMESTAMP    | When created                     |
| `updated_at`                  | TIMESTAMP    | Last update                      |
| `tenant_organization_id`      | INTEGER      | Organization identifier          |
| `system_status`               | VARCHAR(50)  | Data status                      |
| `system_created_at`           | TIMESTAMP    | When created in Parable          |
| `system_updated_at`           | TIMESTAMP    | Last update in Parable           |

### services\_plan\_people

People scheduled to serve in specific service plans.

| Column                         | Type          | Description                                     |
| ------------------------------ | ------------- | ----------------------------------------------- |
| `id`                           | UUID          | Internal unique identifier                      |
| `plan_person_id`               | VARCHAR(64)   | Planning Center plan person ID                  |
| `plan_id`                      | VARCHAR(64)   | Associated plan                                 |
| `person_id`                    | VARCHAR(64)   | Associated person                               |
| `team_id`                      | VARCHAR(64)   | Associated team                                 |
| `status`                       | VARCHAR(20)   | Status (C=Confirmed, U=Unconfirmed, D=Declined) |
| `team_position_name`           | VARCHAR(100)  | Position/role name                              |
| `photo_thumbnail`              | VARCHAR(2048) | Person's photo                                  |
| `decline_reason`               | TEXT          | Why declined                                    |
| `notes`                        | TEXT          | Scheduling notes                                |
| `prepare_notification`         | BOOLEAN       | Whether to send prep notification               |
| `can_accept_partial`           | BOOLEAN       | Can accept partial scheduling                   |
| `notification_sent_at`         | TIMESTAMP     | When notified                                   |
| `notification_read_at`         | TIMESTAMP     | When read notification                          |
| `notification_prepared_at`     | TIMESTAMP     | When notification prepared                      |
| `notification_changed_at`      | TIMESTAMP     | When notification changed                       |
| `notification_changed_by_name` | VARCHAR(255)  | Who changed notification                        |
| `notification_sender_name`     | VARCHAR(255)  | Who sent notification                           |
| `status_updated_at`            | TIMESTAMP     | When status changed                             |
| `scheduled_by_name`            | VARCHAR(255)  | Who scheduled this person                       |
| `created_at`                   | TIMESTAMP     | When created                                    |
| `updated_at`                   | TIMESTAMP     | Last update                                     |
| `tenant_organization_id`       | INTEGER       | Organization identifier                         |
| `system_status`                | VARCHAR(50)   | Data status                                     |
| `system_created_at`            | TIMESTAMP     | When created in Parable                         |
| `system_updated_at`            | TIMESTAMP     | Last update in Parable                          |

### services\_schedules

Individual scheduling records for people across all services.

| Column                               | Type         | Description                 |
| ------------------------------------ | ------------ | --------------------------- |
| `id`                                 | UUID         | Internal unique identifier  |
| `schedule_id`                        | VARCHAR(64)  | Planning Center schedule ID |
| `person_id`                          | VARCHAR(64)  | Associated person           |
| `service_type_id`                    | VARCHAR(64)  | Associated service type     |
| `plan_id`                            | VARCHAR(64)  | Associated plan             |
| `team_id`                            | VARCHAR(64)  | Associated team             |
| `organization_name`                  | VARCHAR(255) | Organization name           |
| `service_type_name`                  | VARCHAR(255) | Service type name           |
| `team_name`                          | VARCHAR(255) | Team name                   |
| `team_position_name`                 | VARCHAR(100) | Position name               |
| `person_name`                        | VARCHAR(255) | Person's full name          |
| `sort_date`                          | TIMESTAMP    | Date for sorting            |
| `dates`                              | VARCHAR(255) | Service dates               |
| `short_dates`                        | VARCHAR(100) | Short date format           |
| `status`                             | VARCHAR(20)  | Schedule status             |
| `decline_reason`                     | TEXT         | Reason if declined          |
| `can_accept_partial`                 | BOOLEAN      | Can accept partial          |
| `can_accept_partial_one_time`        | BOOLEAN      | One-time partial            |
| `can_rehearse`                       | BOOLEAN      | Available for rehearsal     |
| `plan_visible`                       | BOOLEAN      | Can see plan                |
| `plan_visible_to_me`                 | BOOLEAN      | Plan visible to user        |
| `position_display_times`             | VARCHAR(255) | When position shows         |
| `responds_to_name`                   | VARCHAR(255) | Who responds to             |
| `organization_time_zone`             | VARCHAR(100) | Time zone                   |
| `organization_twenty_four_hour_time` | BOOLEAN      | 24-hour format              |
| `tenant_organization_id`             | INTEGER      | Organization identifier     |
| `system_status`                      | VARCHAR(50)  | Data status                 |
| `system_created_at`                  | TIMESTAMP    | When created in Parable     |
| `system_updated_at`                  | TIMESTAMP    | Last update in Parable      |

### services\_attachments

Files attached to plans, songs, or other resources.

| Column                   | Type          | Description                   |
| ------------------------ | ------------- | ----------------------------- |
| `id`                     | UUID          | Internal unique identifier    |
| `attachment_id`          | VARCHAR(64)   | Planning Center attachment ID |
| `filename`               | VARCHAR(255)  | File name                     |
| `file_size`              | BIGINT        | Size in bytes                 |
| `content_type`           | VARCHAR(100)  | MIME type                     |
| `url`                    | VARCHAR(2048) | Download URL                  |
| `thumbnail_url`          | VARCHAR(2048) | Thumbnail URL                 |
| `linked_url`             | VARCHAR(2048) | External link                 |
| `pco_type`               | VARCHAR(50)   | Planning Center type          |
| `display_name`           | VARCHAR(255)  | Display name                  |
| `filetype`               | VARCHAR(50)   | File type                     |
| `remote_link`            | VARCHAR(2048) | Remote file link              |
| `page_order`             | VARCHAR(50)   | Page ordering                 |
| `licenses_purchased`     | INTEGER       | Number of licenses            |
| `licenses_remaining`     | INTEGER       | Remaining licenses            |
| `licenses_used`          | INTEGER       | Used licenses                 |
| `allow_mp3_download`     | BOOLEAN       | MP3 download allowed          |
| `web_streamable`         | BOOLEAN       | Can stream on web             |
| `downloadable`           | BOOLEAN       | Can be downloaded             |
| `transposable`           | BOOLEAN       | Can transpose                 |
| `streamable`             | BOOLEAN       | Can stream                    |
| `has_preview`            | BOOLEAN       | Preview available             |
| `attachable_type`        | VARCHAR(50)   | What it's attached to         |
| `attachable_id`          | VARCHAR(64)   | Parent resource ID            |
| `created_at`             | TIMESTAMP     | When created                  |
| `updated_at`             | TIMESTAMP     | Last update                   |
| `tenant_organization_id` | INTEGER       | Organization identifier       |
| `system_status`          | VARCHAR(50)   | Data status                   |
| `system_created_at`      | TIMESTAMP     | When created in Parable       |
| `system_updated_at`      | TIMESTAMP     | Last update in Parable        |

## Relationship Tables

### services\_song\_relationships

Links songs to tags and attachments.

| Column                   | Type        | Description                             |
| ------------------------ | ----------- | --------------------------------------- |
| `id`                     | UUID        | Internal unique identifier              |
| `song_id`                | VARCHAR(64) | Song ID                                 |
| `relationship_type`      | VARCHAR(50) | Type of relationship (Tag, Attachment)  |
| `relationship_id`        | VARCHAR(64) | Related entity ID                       |
| `tenant_organization_id` | INTEGER     | Organization identifier                 |
| `system_status`          | VARCHAR(50) | Data status                             |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable |

### services\_team\_relationships

Links teams to service types and parent teams.

| Column                   | Type        | Description                             |
| ------------------------ | ----------- | --------------------------------------- |
| `id`                     | UUID        | Internal unique identifier              |
| `team_id`                | VARCHAR(64) | Team ID                                 |
| `relationship_type`      | VARCHAR(50) | Type of relationship                    |
| `relationship_id`        | VARCHAR(64) | Related entity ID                       |
| `tenant_organization_id` | INTEGER     | Organization identifier                 |
| `system_status`          | VARCHAR(50) | Data status                             |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable |

## Planning & Scheduling

### services\_plan\_person\_times

Junction table linking plan people to specific plan times.

| Column                   | Type        | Description                                                                  |
| ------------------------ | ----------- | ---------------------------------------------------------------------------- |
| `id`                     | UUID        | Internal unique identifier                                                   |
| `plan_person_time_id`    | VARCHAR(64) | Planning Center entity ID                                                    |
| `created_at`             | TIMESTAMP   | When the plan person time was created in Planning Center                     |
| `status`                 | VARCHAR(50) | Status of the person's availability for this time (accepted, declined, etc.) |
| `updated_at`             | TIMESTAMP   | When the plan person time was last updated in Planning Center                |
| `plan_time_id`           | VARCHAR(64) | Reference to the plan time                                                   |
| `plan_id`                | VARCHAR(64) | Reference to the plan                                                        |
| `plan_person_id`         | VARCHAR(64) | Reference to the person scheduled for the plan                               |
| `tenant_organization_id` | INTEGER     | Organization identifier                                                      |
| `system_status`          | VARCHAR(50) | Data status                                                                  |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable                                           |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable                                      |

### services\_plan\_templates

Templates for creating new service plans with predefined structure.

| Column                   | Type         | Description                                           |
| ------------------------ | ------------ | ----------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                            |
| `plan_template_id`       | VARCHAR(64)  | Planning Center entity ID                             |
| `can_view_order`         | BOOLEAN      | Whether the order of service can be viewed            |
| `created_at`             | TIMESTAMP    | When the template was created in Planning Center      |
| `item_count`             | INTEGER      | Number of items in the template                       |
| `multi_day`              | BOOLEAN      | Whether the template spans multiple days              |
| `name`                   | VARCHAR(255) | Name of the plan template                             |
| `note_count`             | INTEGER      | Number of notes in the template                       |
| `prefers_order_view`     | BOOLEAN      | Whether order view is preferred over schedule view    |
| `rehearsable`            | BOOLEAN      | Whether the plan can be rehearsed                     |
| `team_count`             | INTEGER      | Number of teams involved in the template              |
| `updated_at`             | TIMESTAMP    | When the template was last updated in Planning Center |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type                         |
| `created_by_id`          | VARCHAR(64)  | Person who created the template                       |
| `updated_by_id`          | VARCHAR(64)  | Person who last updated the template                  |
| `tenant_organization_id` | INTEGER      | Organization identifier                               |
| `system_status`          | VARCHAR(50)  | Data status                                           |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable               |

### services\_plan\_times

Specific times associated with service plans (rehearsals, services, other events).

| Column                             | Type         | Description                                                          |
| ---------------------------------- | ------------ | -------------------------------------------------------------------- |
| `id`                               | UUID         | Internal unique identifier                                           |
| `plan_time_id`                     | VARCHAR(64)  | Planning Center entity ID                                            |
| `created_at`                       | TIMESTAMP    | When the plan time was created in Planning Center                    |
| `ends_at`                          | TIMESTAMP    | When the plan time ends                                              |
| `live_ends_at`                     | TIMESTAMP    | Actual end time of the live event                                    |
| `live_starts_at`                   | TIMESTAMP    | Actual start time of the live event                                  |
| `name`                             | VARCHAR(255) | Name of the plan time (e.g., "Sunday Morning", "Saturday Rehearsal") |
| `recorded`                         | BOOLEAN      | Whether the plan time was recorded                                   |
| `starts_at`                        | TIMESTAMP    | When the plan time starts                                            |
| `team_reminders`                   | JSONB        | Reminder settings for teams                                          |
| `time_type`                        | VARCHAR(50)  | Type of time (rehearsal, service, other)                             |
| `updated_at`                       | TIMESTAMP    | When the plan time was last updated in Planning Center               |
| `assigned_teams`                   | JSONB        | Teams assigned to this plan time                                     |
| `split_team_rehearsal_assignments` | JSONB        | Split team rehearsal assignment details                              |
| `tenant_organization_id`           | INTEGER      | Organization identifier                                              |
| `system_status`                    | VARCHAR(50)  | Data status                                                          |
| `system_created_at`                | TIMESTAMP    | When record was created in Parable                                   |
| `system_updated_at`                | TIMESTAMP    | When record was last updated in Parable                              |

### services\_needed\_positions

Positions needed for service plans that require scheduling.

| Column                   | Type         | Description                                 |
| ------------------------ | ------------ | ------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                  |
| `needed_position_id`     | VARCHAR(64)  | Planning Center entity ID                   |
| `quantity`               | INTEGER      | Number of people needed for this position   |
| `scheduled_to`           | VARCHAR(255) | Type of time this position is scheduled for |
| `team_position_name`     | VARCHAR(255) | Name of the team position                   |
| `team_id`                | VARCHAR(64)  | Reference to the team                       |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                       |
| `time_id`                | VARCHAR(64)  | Reference to the plan time                  |
| `tenant_organization_id` | INTEGER      | Organization identifier                     |
| `system_status`          | VARCHAR(50)  | Data status                                 |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable          |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable     |

### services\_signup\_sheets

Signup sheets for volunteer positions on service plans.

| Column                   | Type         | Description                                       |
| ------------------------ | ------------ | ------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                        |
| `signup_sheet_id`        | VARCHAR(64)  | Planning Center entity ID                         |
| `display_times`          | VARCHAR(50)  | How times should be displayed on the signup sheet |
| `group_key`              | VARCHAR(64)  | Key for grouping related signup sheets            |
| `position_name`          | VARCHAR(255) | Name of the position being signed up for          |
| `sort_date`              | TIMESTAMP    | Date used for sorting signup sheets               |
| `sort_index`             | INTEGER      | Index for sorting within a group                  |
| `team_name`              | VARCHAR(255) | Name of the team                                  |
| `title`                  | VARCHAR(255) | Title of the signup sheet                         |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                             |
| `team_position_id`       | VARCHAR(64)  | Reference to the team position                    |
| `team_id`                | VARCHAR(64)  | Reference to the team                             |
| `scheduled_people`       | JSONB        | People already scheduled for this position        |
| `signup_sheet_metadata`  | JSONB        | Additional metadata about the signup sheet        |
| `tenant_organization_id` | INTEGER      | Organization identifier                           |
| `system_status`          | VARCHAR(50)  | Data status                                       |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable           |

### services\_signup\_sheet\_metadata

Metadata about specific times on signup sheets.

| Column                     | Type         | Description                              |
| -------------------------- | ------------ | ---------------------------------------- |
| `id`                       | UUID         | Internal unique identifier               |
| `signup_sheet_metadata_id` | VARCHAR(64)  | Planning Center entity ID                |
| `conflicts`                | JSONB        | Scheduling conflicts for this time       |
| `ends_at`                  | TIMESTAMP    | When the time period ends                |
| `starts_at`                | TIMESTAMP    | When the time period starts              |
| `time_name`                | VARCHAR(255) | Name of the time period                  |
| `time_type`                | VARCHAR(255) | Type of time (rehearsal, service, other) |
| `plan_time_id`             | VARCHAR(64)  | Reference to the plan time               |
| `tenant_organization_id`   | INTEGER      | Organization identifier                  |
| `system_status`            | VARCHAR(50)  | Data status                              |
| `system_created_at`        | TIMESTAMP    | When record was created in Parable       |
| `system_updated_at`        | TIMESTAMP    | When record was last updated in Parable  |

### services\_scheduled\_people

People scheduled on signup sheets.

| Column                   | Type         | Description                                               |
| ------------------------ | ------------ | --------------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                                |
| `scheduled_person_id`    | VARCHAR(64)  | Planning Center entity ID                                 |
| `full_name`              | VARCHAR(255) | Full name of the scheduled person                         |
| `status`                 | VARCHAR(50)  | Status of the person's signup (confirmed, declined, etc.) |
| `thumbnail`              | VARCHAR(255) | URL to the person's profile photo thumbnail               |
| `person_id`              | VARCHAR(64)  | Reference to the person                                   |
| `signup_sheet_id`        | VARCHAR(64)  | Reference to the signup sheet                             |
| `tenant_organization_id` | INTEGER      | Organization identifier                                   |
| `system_status`          | VARCHAR(50)  | Data status                                               |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                        |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable                   |

### services\_available\_signups

Available signup opportunities for people in the organization.

| Column                   | Type         | Description                               |
| ------------------------ | ------------ | ----------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                |
| `available_signup_id`    | VARCHAR(64)  | Planning Center entity ID                 |
| `organization_name`      | VARCHAR(255) | Name of the organization                  |
| `planning_center_url`    | TEXT         | URL to view the signup in Planning Center |
| `service_type_name`      | VARCHAR(255) | Name of the service type                  |
| `signups_available`      | BOOLEAN      | Whether signups are currently available   |
| `organization_id`        | VARCHAR(64)  | Reference to the organization             |
| `person_id`              | VARCHAR(64)  | Reference to the person                   |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type             |
| `tenant_organization_id` | INTEGER      | Organization identifier                   |
| `system_status`          | VARCHAR(50)  | Data status                               |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable        |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable   |

### services\_attendances

Attendance records linking people to plan times through check-ins.

| Column                      | Type        | Description                                    |
| --------------------------- | ----------- | ---------------------------------------------- |
| `id`                        | UUID        | Internal unique identifier                     |
| `attendance_id`             | VARCHAR(64) | Planning Center entity ID                      |
| `plan_id`                   | VARCHAR(64) | Reference to the plan                          |
| `check_ins_event_id`        | VARCHAR(64) | Reference to the check-ins event               |
| `check_ins_event_period_id` | VARCHAR(64) | Reference to the check-ins event period        |
| `checked_in_at`             | TIMESTAMP   | When the person checked in                     |
| `plan_person_id`            | VARCHAR(64) | Reference to the person scheduled for the plan |
| `plan_time_id`              | VARCHAR(64) | Reference to the plan time                     |
| `tenant_organization_id`    | INTEGER     | Organization identifier                        |
| `system_status`             | VARCHAR(50) | Data status                                    |
| `system_created_at`         | TIMESTAMP   | When record was created in Parable             |
| `system_updated_at`         | TIMESTAMP   | When record was last updated in Parable        |

### services\_blockouts

Recurring or one-time blockout periods when people are unavailable.

| Column                   | Type         | Description                                           |
| ------------------------ | ------------ | ----------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                            |
| `blockout_id`            | VARCHAR(64)  | Planning Center entity ID                             |
| `created_at`             | TIMESTAMP    | When the blockout was created in Planning Center      |
| `description`            | TEXT         | Detailed description of the blockout                  |
| `ends_at`                | TIMESTAMP    | When the blockout period ends                         |
| `group_identifier`       | VARCHAR(64)  | Identifier for grouping related blockouts             |
| `organization_name`      | VARCHAR(255) | Name of the organization                              |
| `reason`                 | TEXT         | Reason for the blockout                               |
| `repeat_frequency`       | VARCHAR(255) | How often the blockout repeats                        |
| `repeat_interval`        | VARCHAR(255) | Interval for repeating blockouts                      |
| `repeat_period`          | VARCHAR(255) | Period of repetition                                  |
| `repeat_until`           | DATE         | Date when the blockout repetition ends                |
| `settings`               | VARCHAR(255) | Additional blockout settings                          |
| `share`                  | BOOLEAN      | Whether the blockout is shared with schedulers        |
| `starts_at`              | TIMESTAMP    | When the blockout period begins                       |
| `time_zone`              | VARCHAR(255) | Time zone for the blockout                            |
| `updated_at`             | TIMESTAMP    | When the blockout was last updated in Planning Center |
| `person_id`              | VARCHAR(64)  | Reference to the person with the blockout             |
| `organization_id`        | VARCHAR(64)  | Reference to the organization                         |
| `tenant_organization_id` | INTEGER      | Organization identifier                               |
| `system_status`          | VARCHAR(50)  | Data status                                           |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable               |

### services\_blockout\_dates

Individual dates within a blockout period.

| Column                   | Type        | Description                                          |
| ------------------------ | ----------- | ---------------------------------------------------- |
| `id`                     | UUID        | Internal unique identifier                           |
| `blockout_date_id`       | VARCHAR(64) | Planning Center entity ID                            |
| `ends_at`                | TIMESTAMP   | When the blockout date ends (local time)             |
| `ends_at_utc`            | TIMESTAMP   | When the blockout date ends (UTC)                    |
| `group_identifier`       | VARCHAR(64) | Identifier for grouping related blockout dates       |
| `reason`                 | TEXT        | Reason for this specific blockout date               |
| `share`                  | BOOLEAN     | Whether this blockout date is shared with schedulers |
| `starts_at`              | TIMESTAMP   | When the blockout date begins (local time)           |
| `starts_at_utc`          | TIMESTAMP   | When the blockout date begins (UTC)                  |
| `time_zone`              | VARCHAR(64) | Time zone for the blockout date                      |
| `person_id`              | VARCHAR(64) | Reference to the person with the blockout            |
| `blockout_id`            | VARCHAR(64) | Reference to the parent blockout                     |
| `tenant_organization_id` | INTEGER     | Organization identifier                              |
| `system_status`          | VARCHAR(50) | Data status                                          |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable                   |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable              |

### services\_blockout\_exceptions

Exceptions to recurring blockouts (dates when the blockout doesn't apply).

| Column                   | Type        | Description                                            |
| ------------------------ | ----------- | ------------------------------------------------------ |
| `id`                     | UUID        | Internal unique identifier                             |
| `blockout_exception_id`  | VARCHAR(64) | Planning Center entity ID                              |
| `created_at`             | TIMESTAMP   | When the exception was created in Planning Center      |
| `date`                   | DATE        | Date when the blockout exception applies               |
| `updated_at`             | TIMESTAMP   | When the exception was last updated in Planning Center |
| `blockout_id`            | VARCHAR(64) | Reference to the blockout                              |
| `tenant_organization_id` | INTEGER     | Organization identifier                                |
| `system_status`          | VARCHAR(50) | Data status                                            |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable                     |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable                |

### services\_scheduling\_preferences

Scheduling preferences between household members.

| Column                     | Type         | Description                                                                        |
| -------------------------- | ------------ | ---------------------------------------------------------------------------------- |
| `id`                       | UUID         | Internal unique identifier                                                         |
| `scheduling_preference_id` | VARCHAR(64)  | Planning Center entity ID                                                          |
| `preference`               | VARCHAR(255) | Type of scheduling preference (schedule together, avoid scheduling together, etc.) |
| `household_member_id`      | VARCHAR(64)  | Reference to the household member                                                  |
| `tenant_organization_id`   | INTEGER      | Organization identifier                                                            |
| `system_status`            | VARCHAR(50)  | Data status                                                                        |
| `system_created_at`        | TIMESTAMP    | When record was created in Parable                                                 |
| `system_updated_at`        | TIMESTAMP    | When record was last updated in Parable                                            |

### services\_time\_preference\_options

Available time preference options for scheduling team members.

| Column                      | Type         | Description                                         |
| --------------------------- | ------------ | --------------------------------------------------- |
| `id`                        | UUID         | Internal unique identifier                          |
| `time_preference_option_id` | VARCHAR(64)  | Planning Center entity ID                           |
| `created_at`                | TIMESTAMP    | When the option was created in Planning Center      |
| `day_of_week`               | VARCHAR(50)  | Day of the week for this preference                 |
| `description`               | VARCHAR(255) | Description of the time preference                  |
| `minute_of_day`             | INTEGER      | Minute of the day (0-1439) when this time occurs    |
| `sort_index`                | VARCHAR(50)  | Index for sorting preference options                |
| `starts_at`                 | TIMESTAMP    | When the time preference starts                     |
| `time_type`                 | VARCHAR(50)  | Type of time (rehearsal, service, other)            |
| `updated_at`                | TIMESTAMP    | When the option was last updated in Planning Center |
| `tenant_organization_id`    | INTEGER      | Organization identifier                             |
| `system_status`             | VARCHAR(50)  | Data status                                         |
| `system_created_at`         | TIMESTAMP    | When record was created in Parable                  |
| `system_updated_at`         | TIMESTAMP    | When record was last updated in Parable             |

### services\_live\_controllers

People who can control live services.

| Column                   | Type         | Description                                             |
| ------------------------ | ------------ | ------------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                              |
| `live_controller_id`     | VARCHAR(64)  | Planning Center entity ID                               |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type                           |
| `created_at`             | TIMESTAMP    | When the controller was created in Planning Center      |
| `full_name`              | VARCHAR(255) | Full name of the controller                             |
| `photo_thumbnail_url`    | TEXT         | URL to the controller's profile photo thumbnail         |
| `updated_at`             | TIMESTAMP    | When the controller was last updated in Planning Center |
| `person_id`              | VARCHAR(64)  | Reference to the person                                 |
| `tenant_organization_id` | INTEGER      | Organization identifier                                 |
| `system_status`          | VARCHAR(50)  | Data status                                             |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                      |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable                 |

### services\_lives

Live service sessions with control capabilities.

| Column                   | Type         | Description                                           |
| ------------------------ | ------------ | ----------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                            |
| `live_id`                | VARCHAR(64)  | Planning Center entity ID                             |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                                 |
| `can_chat`               | BOOLEAN      | Whether chat is enabled for this live session         |
| `can_control`            | BOOLEAN      | Whether the current user can control the live session |
| `can_control_video_feed` | BOOLEAN      | Whether the current user can control the video feed   |
| `can_take_control`       | BOOLEAN      | Whether the current user can take control             |
| `chat_room_channel`      | VARCHAR(255) | Channel identifier for the chat room                  |
| `dates`                  | VARCHAR(255) | Formatted date(s) for the live session                |
| `live_channel`           | VARCHAR(255) | Channel identifier for the live session               |
| `series_title`           | VARCHAR(255) | Title of the series                                   |
| `title`                  | VARCHAR(255) | Title of the live session                             |
| `controller_id`          | VARCHAR(64)  | Reference to the person controlling the session       |
| `current_item_time_id`   | VARCHAR(64)  | Reference to the current item time                    |
| `items`                  | JSONB        | Items in the live session                             |
| `next_item_time_id`      | VARCHAR(64)  | Reference to the next item time                       |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type                         |
| `tenant_organization_id` | INTEGER      | Organization identifier                               |
| `system_status`          | VARCHAR(50)  | Data status                                           |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable               |

### services\_series

Service series for grouping related plans.

| Column                   | Type         | Description                                         |
| ------------------------ | ------------ | --------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                          |
| `series_id`              | VARCHAR(64)  | Planning Center entity ID                           |
| `artwork_content_type`   | VARCHAR(64)  | Content type of the artwork file                    |
| `artwork_file_name`      | VARCHAR(255) | Original filename of the artwork                    |
| `artwork_file_size`      | INTEGER      | Size of the artwork file in bytes                   |
| `artwork_for_dashboard`  | TEXT         | URL to artwork sized for dashboard                  |
| `artwork_for_mobile`     | TEXT         | URL to artwork sized for mobile devices             |
| `artwork_for_plan`       | TEXT         | URL to artwork sized for plan view                  |
| `artwork_original`       | TEXT         | URL to original artwork file                        |
| `created_at`             | TIMESTAMP    | When the series was created in Planning Center      |
| `has_artwork`            | BOOLEAN      | Whether the series has associated artwork           |
| `title`                  | VARCHAR(255) | Title of the series                                 |
| `updated_at`             | TIMESTAMP    | When the series was last updated in Planning Center |
| `tenant_organization_id` | INTEGER      | Organization identifier                             |
| `system_status`          | VARCHAR(50)  | Data status                                         |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                  |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable             |

### services\_public\_views

Public view settings for service plans.

| Column                   | Type        | Description                             |
| ------------------------ | ----------- | --------------------------------------- |
| `id`                     | UUID        | Internal unique identifier              |
| `public_view_id`         | VARCHAR(64) | Planning Center entity ID               |
| `amazon`                 | BOOLEAN     | Whether to show Amazon Music links      |
| `headers`                | BOOLEAN     | Whether to show section headers         |
| `item_lengths`           | BOOLEAN     | Whether to show item lengths            |
| `itunes`                 | BOOLEAN     | Whether to show iTunes links            |
| `media_items`            | BOOLEAN     | Whether to show media items             |
| `regular_items`          | BOOLEAN     | Whether to show regular items           |
| `series_and_plan_titles` | BOOLEAN     | Whether to show series and plan titles  |
| `series_artwork`         | BOOLEAN     | Whether to show series artwork          |
| `service_times`          | BOOLEAN     | Whether to show service times           |
| `song_items`             | BOOLEAN     | Whether to show song items              |
| `spotify`                | BOOLEAN     | Whether to show Spotify links           |
| `vimeo`                  | BOOLEAN     | Whether to show Vimeo links             |
| `youtube`                | BOOLEAN     | Whether to show YouTube links           |
| `tenant_organization_id` | INTEGER     | Organization identifier                 |
| `system_status`          | VARCHAR(50) | Data status                             |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable |

### services\_contributors

People who have contributed to a plan (edits, additions, etc.).

| Column                   | Type         | Description                                       |
| ------------------------ | ------------ | ------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                        |
| `contributor_id`         | VARCHAR(64)  | Planning Center entity ID                         |
| `contributable_action`   | VARCHAR(255) | Type of action performed (created, updated, etc.) |
| `contributable_category` | VARCHAR(255) | Category of contribution                          |
| `contributable_type`     | VARCHAR(255) | Type of entity contributed to                     |
| `created_at`             | TIMESTAMP    | When the contribution was made                    |
| `full_name`              | VARCHAR(255) | Full name of the contributor                      |
| `photo_thumbnail_url`    | TEXT         | URL to the contributor's profile photo thumbnail  |
| `updated_at`             | TIMESTAMP    | When the contribution was last updated            |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                             |
| `person_id`              | VARCHAR(64)  | Reference to the person                           |
| `tenant_organization_id` | INTEGER      | Organization identifier                           |
| `system_status`          | VARCHAR(50)  | Data status                                       |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable           |

### services\_plan\_notes

Notes attached to service plans.

| Column                   | Type         | Description                                       |
| ------------------------ | ------------ | ------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                        |
| `plan_note_id`           | VARCHAR(64)  | Planning Center entity ID                         |
| `category_name`          | VARCHAR(255) | Name of the note category                         |
| `content`                | TEXT         | Content of the note                               |
| `created_at`             | TIMESTAMP    | When the note was created in Planning Center      |
| `updated_at`             | TIMESTAMP    | When the note was last updated in Planning Center |
| `created_by_id`          | VARCHAR(64)  | Person who created the note                       |
| `plan_note_category_id`  | VARCHAR(64)  | Reference to the note category                    |
| `teams`                  | JSONB        | Teams that can view this note                     |
| `tenant_organization_id` | INTEGER      | Organization identifier                           |
| `system_status`          | VARCHAR(50)  | Data status                                       |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable           |

### services\_plan\_note\_categories

Categories for organizing plan notes.

| Column                   | Type         | Description                                           |
| ------------------------ | ------------ | ----------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                            |
| `plan_note_category_id`  | VARCHAR(64)  | Planning Center entity ID                             |
| `created_at`             | TIMESTAMP    | When the category was created in Planning Center      |
| `deleted_at`             | TIMESTAMP    | When the category was deleted in Planning Center      |
| `name`                   | VARCHAR(255) | Name of the category                                  |
| `sequence`               | INTEGER      | Display order for the category                        |
| `updated_at`             | TIMESTAMP    | When the category was last updated in Planning Center |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type                         |
| `teams`                  | JSONB        | Teams that can use this category                      |
| `tenant_organization_id` | INTEGER      | Organization identifier                               |
| `system_status`          | VARCHAR(50)  | Data status                                           |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable               |

### services\_item\_note\_categories

Categories for organizing item notes.

| Column                   | Type         | Description                                           |
| ------------------------ | ------------ | ----------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                            |
| `item_note_category_id`  | VARCHAR(64)  | Planning Center entity ID                             |
| `created_at`             | TIMESTAMP    | When the category was created in Planning Center      |
| `deleted_at`             | TIMESTAMP    | When the category was deleted in Planning Center      |
| `frequently_used`        | BOOLEAN      | Whether this category is frequently used              |
| `name`                   | VARCHAR(255) | Name of the category                                  |
| `sequence`               | INTEGER      | Display order for the category                        |
| `updated_at`             | TIMESTAMP    | When the category was last updated in Planning Center |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type                         |
| `tenant_organization_id` | INTEGER      | Organization identifier                               |
| `system_status`          | VARCHAR(50)  | Data status                                           |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable               |

## Team Management

### services\_team\_positions

Positions within service teams.

| Column                   | Type         | Description                                       |
| ------------------------ | ------------ | ------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                        |
| `team_position_id`       | VARCHAR(64)  | Planning Center entity ID                         |
| `name`                   | VARCHAR(255) | Name of the position                              |
| `negative_tag_groups`    | JSONB        | Tag groups that exclude people from this position |
| `sequence`               | INTEGER      | Display order for the position                    |
| `tag_groups`             | JSONB        | Tag groups required for this position             |
| `tags`                   | JSONB        | Tags associated with this position                |
| `team_id`                | VARCHAR(64)  | Reference to the team                             |
| `attachment_types`       | JSONB        | Types of attachments allowed for this position    |
| `tag_ids`                | JSONB        | IDs of tags associated with this position         |
| `tenant_organization_id` | INTEGER      | Organization identifier                           |
| `system_status`          | VARCHAR(50)  | Data status                                       |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable           |

### services\_person\_team\_position\_assignments

Assignments of people to specific team positions.

| Column                               | Type            | Description                                             |
| ------------------------------------ | --------------- | ------------------------------------------------------- |
| `id`                                 | UUID            | Internal unique identifier                              |
| `person_team_position_assignment_id` | VARCHAR(64)     | Planning Center entity ID                               |
| `created_at`                         | TIMESTAMP       | When the assignment was created in Planning Center      |
| `preferred_weeks`                    | VARCHAR(255)\[] | Array of preferred week frequencies                     |
| `schedule_preference`                | VARCHAR(50)     | Scheduling preference for this assignment               |
| `updated_at`                         | TIMESTAMP       | When the assignment was last updated in Planning Center |
| `person_id`                          | VARCHAR(64)     | Reference to the person                                 |
| `team_position_id`                   | VARCHAR(64)     | Reference to the team position                          |
| `time_preference_options`            | JSONB           | Preferred times for this assignment                     |
| `tenant_organization_id`             | INTEGER         | Organization identifier                                 |
| `system_status`                      | VARCHAR(50)     | Data status                                             |
| `system_created_at`                  | TIMESTAMP       | When record was created in Parable                      |
| `system_updated_at`                  | TIMESTAMP       | When record was last updated in Parable                 |

### services\_team\_leaders

Leaders assigned to service teams.

| Column                         | Type        | Description                                       |
| ------------------------------ | ----------- | ------------------------------------------------- |
| `id`                           | UUID        | Internal unique identifier                        |
| `team_leader_id`               | VARCHAR(64) | Planning Center entity ID                         |
| `send_responses_for_accepts`   | BOOLEAN     | Whether to send notifications when people accept  |
| `send_responses_for_blockouts` | BOOLEAN     | Whether to send notifications about blockouts     |
| `send_responses_for_declines`  | BOOLEAN     | Whether to send notifications when people decline |
| `person_id`                    | VARCHAR(64) | Reference to the person who is the team leader    |
| `team_id`                      | VARCHAR(64) | Reference to the team                             |
| `tenant_organization_id`       | INTEGER     | Organization identifier                           |
| `system_status`                | VARCHAR(50) | Data status                                       |
| `system_created_at`            | TIMESTAMP   | When record was created in Parable                |
| `system_updated_at`            | TIMESTAMP   | When record was last updated in Parable           |

### services\_split\_team\_rehearsal\_assignments

Rehearsal time assignments for split teams.

| Column                               | Type        | Description                               |
| ------------------------------------ | ----------- | ----------------------------------------- |
| `id`                                 | UUID        | Internal unique identifier                |
| `split_team_rehearsal_assignment_id` | VARCHAR(64) | Planning Center entity ID                 |
| `schedule_special_service_times`     | BOOLEAN     | Whether to schedule special service times |
| `team_id`                            | VARCHAR(64) | Reference to the team                     |
| `time_preference_options`            | JSONB       | Time preferences for this assignment      |
| `tenant_organization_id`             | INTEGER     | Organization identifier                   |
| `system_status`                      | VARCHAR(50) | Data status                               |
| `system_created_at`                  | TIMESTAMP   | When record was created in Parable        |
| `system_updated_at`                  | TIMESTAMP   | When record was last updated in Parable   |

## Song & Music Management

### services\_arrangement\_sections

Sections within song arrangements (verse, chorus, bridge, etc.).

| Column                   | Type        | Description                                         |
| ------------------------ | ----------- | --------------------------------------------------- |
| `id`                     | UUID        | Internal unique identifier                          |
| `arrangement_section_id` | VARCHAR(64) | Planning Center entity ID                           |
| `sections`               | JSONB       | Array of section definitions with names and content |
| `tenant_organization_id` | INTEGER     | Organization identifier                             |
| `system_status`          | VARCHAR(50) | Data status                                         |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable                  |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable             |

### services\_keys

Musical keys associated with song arrangements.

| Column                   | Type         | Description                                      |
| ------------------------ | ------------ | ------------------------------------------------ |
| `id`                     | UUID         | Internal unique identifier                       |
| `key_id`                 | VARCHAR(64)  | Planning Center entity ID                        |
| `alternate_keys`         | JSONB        | Alternative keys for this arrangement            |
| `created_at`             | TIMESTAMP    | When the key was created in Planning Center      |
| `ending_key`             | VARCHAR(13)  | Musical key at the end of the song               |
| `ending_minor`           | BOOLEAN      | Whether the ending key is minor                  |
| `name`                   | VARCHAR(255) | Display name for the key                         |
| `starting_key`           | VARCHAR(3)   | Musical key at the start of the song             |
| `starting_minor`         | BOOLEAN      | Whether the starting key is minor                |
| `updated_at`             | TIMESTAMP    | When the key was last updated in Planning Center |
| `arrangement_id`         | VARCHAR(64)  | Reference to the arrangement                     |
| `tenant_organization_id` | INTEGER      | Organization identifier                          |
| `system_status`          | VARCHAR(50)  | Data status                                      |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable               |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable          |

### services\_song\_schedules

Schedule information for when songs are used in plans.

| Column                   | Type         | Description                                |
| ------------------------ | ------------ | ------------------------------------------ |
| `id`                     | UUID         | Internal unique identifier                 |
| `song_schedule_id`       | VARCHAR(64)  | Planning Center entity ID                  |
| `arrangement_name`       | VARCHAR(255) | Name of the arrangement used               |
| `key_name`               | VARCHAR(3)   | Musical key used                           |
| `plan_dates`             | VARCHAR(50)  | Formatted dates when the song is scheduled |
| `plan_sort_date`         | TIMESTAMP    | Date used for sorting song schedules       |
| `service_type_name`      | VARCHAR(255) | Name of the service type                   |
| `arrangement_id`         | VARCHAR(64)  | Reference to the arrangement               |
| `key_id`                 | VARCHAR(64)  | Reference to the key                       |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                      |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type              |
| `item_id`                | VARCHAR(64)  | Reference to the plan item                 |
| `tenant_organization_id` | INTEGER      | Organization identifier                    |
| `system_status`          | VARCHAR(50)  | Data status                                |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable         |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable    |

### services\_song\_attachments

Junction table linking songs to their attachments.

| Column                   | Type        | Description                             |
| ------------------------ | ----------- | --------------------------------------- |
| `id`                     | UUID        | Internal unique identifier              |
| `song_id`                | VARCHAR(64) | Reference to the song                   |
| `attachment_id`          | VARCHAR(64) | Reference to the attachment             |
| `tenant_organization_id` | INTEGER     | Organization identifier                 |
| `system_status`          | VARCHAR(50) | Data status                             |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable |

### services\_song\_tags

Junction table linking songs to their tags.

| Column                   | Type        | Description                             |
| ------------------------ | ----------- | --------------------------------------- |
| `id`                     | UUID        | Internal unique identifier              |
| `song_id`                | VARCHAR(64) | Reference to the song                   |
| `tag_id`                 | VARCHAR(64) | Reference to the tag                    |
| `tenant_organization_id` | INTEGER     | Organization identifier                 |
| `system_status`          | VARCHAR(50) | Data status                             |
| `system_created_at`      | TIMESTAMP   | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP   | When record was last updated in Parable |

### services\_media

Media items (videos, images, audio) used in services.

| Column                   | Type         | Description                                        |
| ------------------------ | ------------ | -------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                         |
| `media_id`               | VARCHAR(64)  | Planning Center entity ID                          |
| `created_at`             | TIMESTAMP    | When the media was created in Planning Center      |
| `creator_name`           | VARCHAR(255) | Name of the person who created the media           |
| `image_url`              | TEXT         | URL to the media image                             |
| `length`                 | INTEGER      | Length of the media in seconds                     |
| `media_type`             | VARCHAR(255) | Type of media (video, image, audio)                |
| `media_type_name`        | VARCHAR(255) | Display name for the media type                    |
| `preview_content_type`   | VARCHAR(255) | Content type of the preview file                   |
| `preview_file_name`      | TEXT         | Filename of the preview                            |
| `preview_file_size`      | INTEGER      | Size of the preview file in bytes                  |
| `preview_updated_at`     | TIMESTAMP    | When the preview was last updated                  |
| `preview_url`            | TEXT         | URL to the preview file                            |
| `themes`                 | VARCHAR(255) | Themes associated with the media                   |
| `thumbnail_content_type` | VARCHAR(255) | Content type of the thumbnail                      |
| `thumbnail_file_name`    | TEXT         | Filename of the thumbnail                          |
| `thumbnail_file_size`    | INTEGER      | Size of the thumbnail file in bytes                |
| `thumbnail_updated_at`   | TIMESTAMP    | When the thumbnail was last updated                |
| `thumbnail_url`          | TEXT         | URL to the thumbnail                               |
| `title`                  | TEXT         | Title of the media                                 |
| `updated_at`             | TIMESTAMP    | When the media was last updated in Planning Center |
| `attachments`            | JSONB        | Attachments associated with this media             |
| `tenant_organization_id` | INTEGER      | Organization identifier                            |
| `system_status`          | VARCHAR(50)  | Data status                                        |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                 |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable            |

### services\_media\_schedules

Schedule information for when media is used in plans.

| Column                   | Type         | Description                                 |
| ------------------------ | ------------ | ------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                  |
| `media_schedule_id`      | VARCHAR(64)  | Planning Center entity ID                   |
| `media_id`               | VARCHAR(64)  | Reference to the media                      |
| `plan_dates`             | VARCHAR(255) | Formatted dates when the media is scheduled |
| `plan_short_dates`       | VARCHAR(255) | Short formatted dates                       |
| `plan_sort_date`         | TIMESTAMP    | Date used for sorting media schedules       |
| `service_type_name`      | VARCHAR(255) | Name of the service type                    |
| `plan_id`                | VARCHAR(64)  | Reference to the plan                       |
| `service_type_id`        | VARCHAR(64)  | Reference to the service type               |
| `tenant_organization_id` | INTEGER      | Organization identifier                     |
| `system_status`          | VARCHAR(50)  | Data status                                 |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable          |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable     |

## Communication & Notifications

### services\_email\_templates

Templates for automated emails sent from Planning Center Services.

| Column                   | Type         | Description                                               |
| ------------------------ | ------------ | --------------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                                |
| `email_template_id`      | VARCHAR(64)  | Planning Center entity ID                                 |
| `created_at`             | TIMESTAMP    | When the template was created in Planning Center          |
| `html_body`              | TEXT         | HTML content of the email template                        |
| `kind`                   | VARCHAR(255) | Type of email template (schedule request, reminder, etc.) |
| `subject`                | VARCHAR(255) | Subject line for the email                                |
| `updated_at`             | TIMESTAMP    | When the template was last updated in Planning Center     |
| `template_owner_id`      | VARCHAR(64)  | Reference to the owner of the template                    |
| `tenant_organization_id` | INTEGER      | Organization identifier                                   |
| `system_status`          | VARCHAR(50)  | Data status                                               |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                        |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable                   |

### services\_emails

Email addresses associated with people in Services.

| Column                   | Type         | Description                                |
| ------------------------ | ------------ | ------------------------------------------ |
| `id`                     | UUID         | Internal unique identifier                 |
| `email_id`               | VARCHAR(64)  | Planning Center entity ID                  |
| `address`                | VARCHAR(255) | Email address                              |
| `is_primary`             | BOOLEAN      | Whether this is the person's primary email |
| `tenant_organization_id` | INTEGER      | Organization identifier                    |
| `system_status`          | VARCHAR(50)  | Data status                                |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable         |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable    |

### services\_phone\_numbers

Phone numbers associated with people in Services.

| Column                   | Type         | Description                                               |
| ------------------------ | ------------ | --------------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                                |
| `phone_number_id`        | VARCHAR(64)  | Planning Center entity ID                                 |
| `carrier`                | VARCHAR(255) | Mobile carrier name                                       |
| `created_at`             | TIMESTAMP    | When the phone number was created in Planning Center      |
| `location`               | VARCHAR(255) | Type of phone number (mobile, home, work)                 |
| `number`                 | VARCHAR(255) | Phone number                                              |
| `primary_number`         | BOOLEAN      | Whether this is the person's primary phone number         |
| `updated_at`             | TIMESTAMP    | When the phone number was last updated in Planning Center |
| `e164`                   | VARCHAR(255) | Phone number in E.164 format                              |
| `person_id`              | VARCHAR(64)  | Reference to the person                                   |
| `tenant_organization_id` | INTEGER      | Organization identifier                                   |
| `system_status`          | VARCHAR(50)  | Data status                                               |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                        |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable                   |

### services\_text\_settings

Text messaging settings for people in Services.

| Column                        | Type        | Description                                     |
| ----------------------------- | ----------- | ----------------------------------------------- |
| `id`                          | UUID        | Internal unique identifier                      |
| `text_setting_id`             | VARCHAR(64) | Planning Center entity ID                       |
| `carrier`                     | VARCHAR(64) | Mobile carrier name                             |
| `display_number`              | VARCHAR(64) | Formatted phone number for display              |
| `general_emails_enabled`      | BOOLEAN     | Whether general email notifications are enabled |
| `normalized_number`           | VARCHAR(64) | Normalized phone number                         |
| `reminders_enabled`           | BOOLEAN     | Whether reminder texts are enabled              |
| `scheduling_replies_enabled`  | BOOLEAN     | Whether scheduling reply texts are enabled      |
| `scheduling_requests_enabled` | BOOLEAN     | Whether scheduling request texts are enabled    |
| `tenant_organization_id`      | INTEGER     | Organization identifier                         |
| `system_status`               | VARCHAR(50) | Data status                                     |
| `system_created_at`           | TIMESTAMP   | When record was created in Parable              |
| `system_updated_at`           | TIMESTAMP   | When record was last updated in Parable         |

## Administration & Settings

### services\_organizations

Organization-wide settings for Planning Center Services.

| Column                                | Type             | Description                                               |
| ------------------------------------- | ---------------- | --------------------------------------------------------- |
| `id`                                  | UUID             | Internal unique identifier                                |
| `organization_id`                     | VARCHAR(64)      | Planning Center entity ID                                 |
| `allow_mp3_download`                  | BOOLEAN          | Whether MP3 downloads are allowed                         |
| `calendar_starts_on_sunday`           | BOOLEAN          | Whether the calendar week starts on Sunday                |
| `ccli`                                | VARCHAR(64)      | CCLI license number                                       |
| `ccli_auto_reporting_enabled`         | BOOLEAN          | Whether automatic CCLI reporting is enabled               |
| `ccli_connected`                      | BOOLEAN          | Whether CCLI integration is connected                     |
| `ccli_reporting_enabled`              | BOOLEAN          | Whether CCLI reporting is enabled                         |
| `created_at`                          | TIMESTAMP        | When the organization was created in Planning Center      |
| `date_format`                         | VARCHAR(64)      | Preferred date format                                     |
| `extra_file_storage_allowed`          | BOOLEAN          | Whether extra file storage is allowed                     |
| `file_storage_exceeded`               | BOOLEAN          | Whether file storage limit has been exceeded              |
| `file_storage_extra_charges`          | DOUBLE PRECISION | Extra charges for file storage                            |
| `file_storage_extra_enabled`          | BOOLEAN          | Whether extra file storage is enabled                     |
| `file_storage_size`                   | BIGINT           | Total file storage size in bytes                          |
| `file_storage_size_used`              | BIGINT           | Used file storage size in bytes                           |
| `legacy_id`                           | VARCHAR(64)      | Legacy organization identifier                            |
| `music_stand_enabled`                 | BOOLEAN          | Whether Music Stand app is enabled                        |
| `name`                                | VARCHAR(255)     | Organization name                                         |
| `owner_name`                          | VARCHAR(255)     | Name of the organization owner                            |
| `people_allowed`                      | INTEGER          | Number of people allowed in the organization              |
| `people_remaining`                    | INTEGER          | Number of people slots remaining                          |
| `projector_enabled`                   | BOOLEAN          | Whether projector features are enabled                    |
| `rehearsal_mix_enabled`               | BOOLEAN          | Whether rehearsal mix features are enabled                |
| `rehearsal_pack_connected`            | BOOLEAN          | Whether Rehearsal Pack is connected                       |
| `required_to_set_download_permission` | VARCHAR(255)     | Download permission requirements                          |
| `secret`                              | VARCHAR(255)     | Organization secret key                                   |
| `time_zone`                           | VARCHAR(255)     | Organization time zone                                    |
| `twenty_four_hour_time`               | BOOLEAN          | Whether to use 24-hour time format                        |
| `updated_at`                          | TIMESTAMP        | When the organization was last updated in Planning Center |
| `tenant_organization_id`              | INTEGER          | Organization identifier                                   |
| `system_status`                       | VARCHAR(50)      | Data status                                               |
| `system_created_at`                   | TIMESTAMP        | When record was created in Parable                        |
| `system_updated_at`                   | TIMESTAMP        | When record was last updated in Parable                   |

### services\_folders

Folders for organizing service plans and songs.

| Column                   | Type         | Description                                         |
| ------------------------ | ------------ | --------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                          |
| `folder_id`              | VARCHAR(64)  | Planning Center entity ID                           |
| `container`              | VARCHAR(255) | Type of items this folder contains                  |
| `created_at`             | TIMESTAMP    | When the folder was created in Planning Center      |
| `name`                   | VARCHAR(255) | Name of the folder                                  |
| `updated_at`             | TIMESTAMP    | When the folder was last updated in Planning Center |
| `ancestors`              | JSONB        | Parent folders in the hierarchy                     |
| `parent`                 | VARCHAR(64)  | Reference to the parent folder                      |
| `campus`                 | VARCHAR(64)  | Reference to the campus                             |
| `service_types`          | JSONB        | Service types associated with this folder           |
| `tenant_organization_id` | INTEGER      | Organization identifier                             |
| `system_status`          | VARCHAR(50)  | Data status                                         |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                  |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable             |

### services\_tags

Tags for categorizing songs, people, and other entities.

| Column                   | Type         | Description                             |
| ------------------------ | ------------ | --------------------------------------- |
| `id`                     | UUID         | Internal unique identifier              |
| `tag_id`                 | VARCHAR(64)  | Planning Center entity ID               |
| `name`                   | VARCHAR(255) | Name of the tag                         |
| `tag_group_id`           | VARCHAR(64)  | Reference to the tag group              |
| `tenant_organization_id` | INTEGER      | Organization identifier                 |
| `system_status`          | VARCHAR(50)  | Data status                             |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable      |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable |

### services\_tag\_groups

Groups for organizing related tags.

| Column                      | Type         | Description                                           |
| --------------------------- | ------------ | ----------------------------------------------------- |
| `id`                        | UUID         | Internal unique identifier                            |
| `tag_group_id`              | VARCHAR(64)  | Planning Center entity ID                             |
| `allow_multiple_selections` | BOOLEAN      | Whether multiple tags from this group can be selected |
| `name`                      | VARCHAR(255) | Name of the tag group                                 |
| `required`                  | BOOLEAN      | Whether a tag from this group is required             |
| `service_type_folder_name`  | VARCHAR(255) | Associated service type folder name                   |
| `tags_for`                  | VARCHAR(255) | What type of entity these tags apply to               |
| `folder_id`                 | VARCHAR(64)  | Reference to the folder                               |
| `tags`                      | JSONB        | Tags within this group                                |
| `tenant_organization_id`    | INTEGER      | Organization identifier                               |
| `system_status`             | VARCHAR(50)  | Data status                                           |
| `system_created_at`         | TIMESTAMP    | When record was created in Parable                    |
| `system_updated_at`         | TIMESTAMP    | When record was last updated in Parable               |

### services\_attachment\_type\_groups

Groups for organizing attachment types.

| Column                     | Type         | Description                                      |
| -------------------------- | ------------ | ------------------------------------------------ |
| `id`                       | UUID         | Internal unique identifier                       |
| `attachment_type_group_id` | VARCHAR(64)  | Planning Center entity ID                        |
| `name`                     | VARCHAR(255) | Name of the attachment type group                |
| `readonly`                 | BOOLEAN      | Whether this group is read-only (system-defined) |
| `tenant_organization_id`   | INTEGER      | Organization identifier                          |
| `system_status`            | VARCHAR(50)  | Data status                                      |
| `system_created_at`        | TIMESTAMP    | When record was created in Parable               |
| `system_updated_at`        | TIMESTAMP    | When record was last updated in Parable          |

### services\_attachment\_types

Types of attachments that can be associated with plans, songs, and other entities.

| Column                     | Type         | Description                                      |
| -------------------------- | ------------ | ------------------------------------------------ |
| `id`                       | UUID         | Internal unique identifier                       |
| `attachment_type_id`       | VARCHAR(64)  | Planning Center entity ID                        |
| `aliases`                  | TEXT\[]      | Alternative names for this attachment type       |
| `built_in`                 | BOOLEAN      | Whether this is a built-in (system-defined) type |
| `capoed_chord_charts`      | BOOLEAN      | Whether to show capoed chord charts              |
| `chord_charts`             | BOOLEAN      | Whether chord charts are enabled                 |
| `exclusions`               | TEXT\[]      | File types to exclude                            |
| `lyrics`                   | BOOLEAN      | Whether lyrics are enabled                       |
| `name`                     | VARCHAR(255) | Name of the attachment type                      |
| `number_charts`            | BOOLEAN      | Whether number charts are enabled                |
| `numeral_charts`           | BOOLEAN      | Whether numeral charts are enabled               |
| `attachment_type_group_id` | VARCHAR(64)  | Reference to the attachment type group           |
| `tenant_organization_id`   | INTEGER      | Organization identifier                          |
| `system_status`            | VARCHAR(50)  | Data status                                      |
| `system_created_at`        | TIMESTAMP    | When record was created in Parable               |
| `system_updated_at`        | TIMESTAMP    | When record was last updated in Parable          |

### services\_report\_templates

Templates for generating reports.

| Column                   | Type         | Description                                       |
| ------------------------ | ------------ | ------------------------------------------------- |
| `id`                     | UUID         | Internal unique identifier                        |
| `report_template_id`     | VARCHAR(64)  | Planning Center entity ID                         |
| `body`                   | TEXT         | Template body content                             |
| `is_default`             | BOOLEAN      | Whether this is the default template for its type |
| `title`                  | VARCHAR(255) | Title of the report template                      |
| `type`                   | VARCHAR(50)  | Type of report (plan, item, etc.)                 |
| `tenant_organization_id` | INTEGER      | Organization identifier                           |
| `system_status`          | VARCHAR(50)  | Data status                                       |
| `system_created_at`      | TIMESTAMP    | When record was created in Parable                |
| `system_updated_at`      | TIMESTAMP    | When record was last updated in Parable           |

## Data Relationships

### Key Relationships

1. **Service Planning Hierarchy**
   * Service Types → Plans → Items
   * Plans → Plan Times → Plan People

2. **Team Structure**
   * Teams → Team Positions → Person Team Position Assignments
   * Teams → Plan People → Schedules

3. **Song Management**
   * Songs → Arrangements → Items
   * Songs → Attachments (chord charts, lead sheets)

4. **Scheduling Flow**
   * People → Schedules → Plan People
   * People → Blockouts → Blockout Dates

5. **Resource Attachments**
   * Plans → Attachments
   * Songs → Attachments
   * Items → Media

## Query Patterns

### Finding Scheduled Volunteers

```sql theme={null}
SELECT
    pp.person_id,
    p.full_name,
    pp.team_position_name,
    pl.title as plan_title,
    pl.sort_date
FROM planning_center.services_plan_people pp
JOIN planning_center.services_people p ON pp.person_id = p.person_id
JOIN planning_center.services_plans pl ON pp.plan_id = pl.plan_id
WHERE pp.status = 'C'  -- Confirmed
    AND pl.sort_date >= CURRENT_DATE
ORDER BY pl.sort_date, p.full_name;
```

### Analyzing Song Usage

```sql theme={null}
SELECT
    s.title,
    s.author,
    COUNT(DISTINCT i.plan_id) as times_used,
    MAX(pl.sort_date) as last_used
FROM planning_center.services_songs s
JOIN planning_center.services_items i ON s.song_id = i.song_id
JOIN planning_center.services_plans pl ON i.plan_id = pl.plan_id
GROUP BY s.song_id, s.title, s.author
ORDER BY times_used DESC;
```

## Data Integrity Rules

1. **Schema Qualification**: Always use `planning_center.` prefix for all table references
2. **Row Level Security**: RLS automatically handles multi-tenancy and status filtering - do not add manual filters
3. **Monetary Values**: Any cost or fee columns are stored in cents - divide by 100.0 for display
4. **Scheduling Status Flags**: Use fields like `status` and `decline_reason` to interpret plan assignments instead of checking `system_status`
5. **Direct ID Columns**: Core tables such as `services_plans` and `services_plan_people` expose direct IDs for performance-sensitive joins

## Common Mistakes to Avoid

1. **Missing Schema Prefix**
   * ❌ `FROM services_plan_people`
   * ✅ `FROM planning_center.services_plan_people`

2. **Adding Redundant RLS Filters**
   * ❌ `WHERE tenant_organization_id = 1 AND system_status = 'active'`
   * ✅ Trust RLS to handle this automatically

3. **Joining Without Schema**
   * ❌ `JOIN services_people p ON ...`
   * ✅ `JOIN planning_center.services_people p ON ...`

4. **Forgetting Duration Conversion**
   * ❌ `SELECT duration_seconds as minutes`
   * ✅ `SELECT duration_seconds / 60.0 as minutes`

## Performance Considerations

1. **Indexes**: All tables have optimized indexes on:
   * Primary keys and entity IDs
   * Join columns and foreign keys
   * Date columns for time-based queries

2. **Query Optimization**:
   * Always use the `planning_center.` schema prefix
   * RLS handles tenant and status filtering automatically
   * Filter scheduling status or declined responses when relevant
   * Consider CTEs for complex aggregations
   * Use direct ID columns when available instead of relationship tables

## Data Synchronization

All Services tables use the standard Parable synchronization pattern:

* **system\_status**: Tracks data lifecycle ('transferring' → 'active' → 'stale')
* **system\_created\_at**: When record entered Parable
* **system\_updated\_at**: Last Parable update
* **created\_at/updated\_at**: Original Planning Center timestamps

## Notes

* Status codes often use single letters: C=Confirmed, U=Unconfirmed, D=Declined
* All timestamps are stored in UTC
* JSONB fields store complex nested data structures
* File URLs may expire based on `files_expire_at` timestamps
* Person records link to the main People app for complete profiles
