-
Notifications
You must be signed in to change notification settings - Fork 44
Documenting "withContactCounts" for campaign API #293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 7.1
Are you sure you want to change the base?
Changes from all commits
2cbb1f7
a46e7b5
4c3004b
c40d7c3
c3e09a6
2458a9b
6e7abdb
d39dc2d
62c5ae2
b154c3d
9dfe3e7
96d6268
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -159,6 +159,7 @@ Transifex | |
| Translator | ||
| TRUE | ||
| true | ||
| TTL | ||
| Twilio | ||
| unassign | ||
| unpublish | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -150,6 +150,12 @@ | |||||||||||||||||||||||
| * - ``events`` | ||||||||||||||||||||||||
| - array | ||||||||||||||||||||||||
| - Array of Event entities for the Campaign - see below | ||||||||||||||||||||||||
| * - ``contactCount`` | ||||||||||||||||||||||||
| - int | ||||||||||||||||||||||||
| - Number of Contacts in the Campaign. This property is only returned by endpoints that support the ``withContactCounts=true`` query parameter (for example, ``GET /campaigns``) and is not available from ``GET /campaigns/{id}`` | ||||||||||||||||||||||||
|
Check warning on line 155 in docs/rest_api/campaigns.rst
|
||||||||||||||||||||||||
| * - ``contactCountFetchedAt`` | ||||||||||||||||||||||||
| - datetime/null | ||||||||||||||||||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. question: I believe when the type is empty, it'll be automatically set to 'null'? Would it be the same if we only mention 'datetime' instead of 'datetime/null'? I think, if we want to say `datetime/null', we might want as well to add 'null' to other types, e.g., 'integer/null', etc.
Suggested change
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is the type that the programmers should expect. It could be a datetime but it can also be null. If they well always expect datetime then the null value can cause errors. I think we should be explicit to avoid surprises.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does this then only applied for datetime type or for other types as well?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd have to go check every property to answer. In this PR I only care about those 2 I've added. |
||||||||||||||||||||||||
| - Timestamp of the Contact count retrieval. This property is only returned by endpoints that support the ``withContactCounts=true`` query parameter (for example, ``GET /campaigns``) and is not available from ``GET /campaigns/{id}`` | ||||||||||||||||||||||||
|
Check warning on line 158 in docs/rest_api/campaigns.rst
|
||||||||||||||||||||||||
|
|
||||||||||||||||||||||||
|
|
||||||||||||||||||||||||
| **Event Properties** | ||||||||||||||||||||||||
|
|
@@ -246,6 +252,8 @@ | |||||||||||||||||||||||
| - Only return currently published entities | ||||||||||||||||||||||||
| * - ``minimal`` | ||||||||||||||||||||||||
| - Return only array of entities without additional lists in it | ||||||||||||||||||||||||
| * - ``withContactCounts`` | ||||||||||||||||||||||||
| - Include Contact count for each Campaign. Accepts ``true`` or ``false``, with ``false`` as the default. The system caches Contact counts for 12 hours by default. Set the ``campaign_contact_count_cache_ttl`` parameter in ``config/local.php`` to configure the cache TTL - value in seconds | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
| - Include Contact count for each Campaign. Accepts ``true`` or ``false``, with ``false`` as the default. The system caches Contact counts for 12 hours by default. Set the ``campaign_contact_count_cache_ttl`` parameter in ``config/local.php`` to configure the cache TTL - value in seconds | |
| - Include Contact count for each Campaign. Accepts ``true`` or ``false``, with ``false`` as the default. The system caches Contact counts for 12 hours by default. |
Copilot
AI
Mar 25, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is trailing whitespace on the blank lines inside this note block (after the introductory sentence and after .. vale off). Please remove the extra spaces to avoid whitespace/formatting lint failures.
| * ``contactCount``: number of Contacts in the Campaign - integer | |
| * ``contactCountFetchedAt``: timestamp of the Contact count retrieval - ISO 8601 format | |
| .. vale off | |
| * ``contactCount``: number of Contacts in the Campaign - integer | |
| * ``contactCountFetchedAt``: timestamp of the Contact count retrieval - ISO 8601 format | |
| .. vale off |
Uh oh!
There was an error while loading. Please reload this page.