Condition
A condition is an individual criterion used by a List Rule.
Example Request
curl https://api.planningcenteronline.com/people/v2/lists/{list_id}/rules/{rule_id}/conditions
Example Object
{
"type": "Condition",
"id": "1",
"attributes": {
"application": "string",
"comparison": "string",
"created_at": "2000-01-01T12:00:00Z",
"definition_class": "string",
"definition_identifier": "string",
"description": "string",
"settings": "string",
"updated_at": "2000-01-01T12:00:00Z"
},
"relationships": {
"created_by": {
"data": {
"type": "Person",
"id": "1"
}
}
}
}
Attributes
| Name | Type | Description |
|---|---|---|
application |
string |
|
comparison |
string |
|
created_at |
date_time |
|
definition_class |
string |
|
definition_identifier |
string |
|
description |
string |
|
id |
primary_key |
|
settings |
string |
|
updated_at |
date_time |
Relationships
| Name | Type | Association Type | Note |
|---|---|---|---|
| created_by | Person | to_one |
Can Include
| Parameter | Value | Description | Assignable |
|---|---|---|---|
| include | created_by | include associated created_by |
create and update |
Order By
| Parameter | Value | Type | Description |
|---|---|---|---|
| order | application | string | prefix with a hyphen (-application) to reverse the order |
| order | comparison | string | prefix with a hyphen (-comparison) to reverse the order |
| order | created_at | string | prefix with a hyphen (-created_at) to reverse the order |
| order | definition_class | string | prefix with a hyphen (-definition_class) to reverse the order |
| order | definition_identifier | string | prefix with a hyphen (-definition_identifier) to reverse the order |
| order | description | string | prefix with a hyphen (-description) to reverse the order |
| order | settings | string | prefix with a hyphen (-settings) 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 |
|---|---|---|---|---|
| application | where[application] |
string | Query on a specific application |
?where[application]=string |
| comparison | where[comparison] |
string | Query on a specific comparison |
?where[comparison]=string |
| created_at | where[created_at] |
date_time | Query on a specific created_at |
?where[created_at]=2000-01-01T12:00:00Z |
| definition_class | where[definition_class] |
string | Query on a specific definition_class |
?where[definition_class]=string |
| definition_identifier | where[definition_identifier] |
string | Query on a specific definition_identifier |
?where[definition_identifier]=string |
| description | where[description] |
string | Query on a specific description |
?where[description]=string |
| settings | where[settings] |
string | Query on a specific settings |
?where[settings]=string |
| 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/lists/{list_id}/rules/{rule_id}/conditions |
Reading
| HTTP Method | Endpoint |
|---|---|
| GET | /people/v2/lists/{list_id}/rules/{rule_id}/conditions/{id} |
Associations
| HTTP Method | Endpoint | Returns | Details | Filter By |
|---|---|---|---|---|
| GET | https://api.planningcenteronline.com/people/v2/lists/{list_id}/rules/{rule_id}/conditions/{condition_id}/created_by |
Person |
Belongs To
| HTTP Method | Endpoint | Association | Details | Filter By |
|---|---|---|---|---|
| GET | https://api.planningcenteronline.com/people/v2/lists/{list_id}/rules/{rule_id}/conditions |
Rule |