Campus
A Campus is a location belonging to an Organization
Example Request
curl https://api.planningcenteronline.com/people/v2/campuses
Example Object
{
"type": "Campus",
"id": "1",
"attributes": {
"avatar_url": "string",
"church_center_enabled": true,
"city": "string",
"contact_email_address": "string",
"country": "string",
"created_at": "2000-01-01T12:00:00Z",
"date_format": 1,
"description": "string",
"geolocation_set_manually": true,
"latitude": 1.42,
"longitude": 1.42,
"name": "string",
"phone_number": "string",
"state": "string",
"street": "string",
"time_zone": "string",
"time_zone_raw": "string",
"twenty_four_hour_time": true,
"updated_at": "2000-01-01T12:00:00Z",
"website": "string",
"zip": "string"
},
"relationships": {
"organization": {
"data": {
"type": "Organization",
"id": "1"
}
}
}
}
Attributes
| Name | Type | Description |
|---|---|---|
avatar_url |
string |
|
church_center_enabled |
boolean |
|
city |
string |
|
contact_email_address |
string |
|
country |
string |
|
created_at |
date_time |
|
date_format |
integer |
|
description |
string |
|
geolocation_set_manually |
boolean |
|
id |
primary_key |
|
latitude |
float |
|
longitude |
float |
|
name |
string |
|
phone_number |
string |
|
state |
string |
|
street |
string |
|
time_zone |
string |
|
time_zone_raw |
string |
Only available when requested with the |
twenty_four_hour_time |
boolean |
|
updated_at |
date_time |
|
website |
string |
|
zip |
string |
Relationships
| Name | Type | Association Type | Note |
|---|---|---|---|
| organization | Organization | to_one |
Can Include
| Parameter | Value | Description | Assignable |
|---|---|---|---|
| include | lists | include associated lists |
|
| include | service_times | include associated service_times |
create and update |
Order By
| Parameter | Value | Type | Description |
|---|---|---|---|
| order | created_at | string | prefix with a hyphen (-created_at) to reverse the order |
| order | name | string | prefix with a hyphen (-name) to reverse the order |
| order | updated_at | string | prefix with a hyphen (-updated_at) to reverse the order |
Query By
| Name | Parameter | Type | Description | Example |
|---|---|---|---|---|
| created_at | where[created_at] |
date_time | Query on a specific created_at |
?where[created_at]=2000-01-01T12:00:00Z |
| id | where[id] |
primary_key | Query on a specific id |
?where[id]=primary_key |
| updated_at | where[updated_at] |
date_time | Query on a specific updated_at |
?where[updated_at]=2000-01-01T12:00:00Z |
Pagination
| Name | Parameter | Type | Description |
|---|---|---|---|
| per_page | per_page | integer | how many records to return per page (min=1, max=100, default=25) |
| offset | offset | integer | get results from given offset |
Endpoints
Listing
| HTTP Method | Endpoint |
|---|---|
| GET | /people/v2/campuses |
Reading
| HTTP Method | Endpoint |
|---|---|
| GET | /people/v2/campuses/{id} |
Creating
| HTTP Method | Endpoint | Assignable Attributes |
|---|---|---|
| POST | /people/v2/campuses |
|
Notes:
Must be an Organization Administrator
Updating
| HTTP Method | Endpoint | Assignable Attributes |
|---|---|---|
| PATCH | /people/v2/campuses/{id} |
|
Notes:
Must be an Organization Administrator
Deleting
| HTTP Method | Endpoint |
|---|---|
| DELETE | /people/v2/campuses/{id} |
Notes:
Must be an Organization Administrator
Associations
| HTTP Method | Endpoint | Returns | Details | Filter By |
|---|---|---|---|---|
| GET | https://api.planningcenteronline.com/people/v2/campuses/{campus_id}/lists |
List | ||
| GET | https://api.planningcenteronline.com/people/v2/campuses/{campus_id}/service_times |
ServiceTime |
Belongs To
| HTTP Method | Endpoint | Association | Details | Filter By |
|---|---|---|---|---|
| GET | https://api.planningcenteronline.com/people/v2/forms/{form_id}/campus |
Form | ||
| GET | https://api.planningcenteronline.com/people/v2/lists/{list_id}/campus |
List | ||
| GET | https://api.planningcenteronline.com/people/v2/campuses |
Organization | ||
| GET | https://api.planningcenteronline.com/people/v2/people/{person_id}/primary_campus |
Person |