Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,24 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [x.x.x] - Unreleased

### Added

- Support for PATCH /reports/{reportId}/definition endpoint
- New `update_report_definition()` method in Reports class to update report definitions
- New `ReportDefinition` model with support for filters, grouping, summarizing, and sorting criteria
- New `ReportFilterExpression` model with recursive structure for complex filter logic
- New `ReportFilterCriterion` model for individual filter conditions
- New `ReportColumnIdentifier` model for identifying columns in report criteria
- New `ReportGroupingCriterion` model for report grouping configuration
- New `ReportSummarizingCriterion` model for report summarizing configuration
- New `ReportSortingCriterion` model for report sorting configuration
- New `ReportAggregationType` enum (SUM, AVG, MIN, MAX, COUNT, FIRST, LAST)
- New `ReportBooleanOperator` enum (AND, OR) for filter expressions
- New `ReportFilterOperator` enum with 36 operators for filter criteria
- New `ReportSystemColumnType` enum with report-specific system columns including SHEET_NAME
- Type hints for all new report models and methods
- WireMock integration tests for report definition update endpoint including nested filter validation

## [3.7.2] - 2026-01-29

### Added
Expand Down
32 changes: 32 additions & 0 deletions docs-source/smartsheet_enums.rst
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,38 @@ PublishAccessibleBy
:undoc-members:
:show-inheritance:

ReportAggregationType
-----------------------------------------------------

.. automodule:: smartsheet.models.enums.report_aggregation_type
:members:
:undoc-members:
:show-inheritance:

ReportBooleanOperator
-----------------------------------------------------

.. automodule:: smartsheet.models.enums.report_boolean_operator
:members:
:undoc-members:
:show-inheritance:

ReportFilterOperator
----------------------------------------------------

.. automodule:: smartsheet.models.enums.report_filter_operator
:members:
:undoc-members:
:show-inheritance:

ReportSystemColumnType
------------------------------------------------------

.. automodule:: smartsheet.models.enums.report_system_column_type
:members:
:undoc-members:
:show-inheritance:

ScheduleType
---------------------------------------------

Expand Down
56 changes: 56 additions & 0 deletions docs-source/smartsheet_models.rst
Original file line number Diff line number Diff line change
Expand Up @@ -553,6 +553,14 @@ Report
:undoc-members:
:show-inheritance:

ReportSummarizingCriterion
--------------------------

.. automodule:: smartsheet.models.report_summarizing_criterion
:members:
:undoc-members:
:show-inheritance:

ReportCell
----------

Expand All @@ -569,6 +577,46 @@ ReportColumn
:undoc-members:
:show-inheritance:

ReportColumnIdentifier
----------------------

.. automodule:: smartsheet.models.report_column_identifier
:members:
:undoc-members:
:show-inheritance:

ReportDefinition
----------------

.. automodule:: smartsheet.models.report_definition
:members:
:undoc-members:
:show-inheritance:

ReportFilterCriterion
---------------------

.. automodule:: smartsheet.models.report_filter_criterion
:members:
:undoc-members:
:show-inheritance:

ReportFilterExpression
----------------------

.. automodule:: smartsheet.models.report_filter_expression
:members:
:undoc-members:
:show-inheritance:

ReportGroupingCriterion
-----------------------

.. automodule:: smartsheet.models.report_grouping_criterion
:members:
:undoc-members:
:show-inheritance:

ReportPublish
-------------

Expand All @@ -585,6 +633,14 @@ ReportRow
:undoc-members:
:show-inheritance:

ReportSortingCriterion
----------------------

.. automodule:: smartsheet.models.report_sorting_criterion
:members:
:undoc-members:
:show-inheritance:

ReportWidgetContent
-------------------

Expand Down
7 changes: 7 additions & 0 deletions smartsheet/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,17 @@
from .project_settings import ProjectSettings
from .recipient import Recipient
from .report import Report
from .report_summarizing_criterion import ReportSummarizingCriterion
from .report_cell import ReportCell
from .report_column import ReportColumn
from .report_column_identifier import ReportColumnIdentifier
from .report_definition import ReportDefinition
from .report_filter_criterion import ReportFilterCriterion
from .report_filter_expression import ReportFilterExpression
from .report_grouping_criterion import ReportGroupingCriterion
from .report_publish import ReportPublish
from .report_row import ReportRow
from .report_sorting_criterion import ReportSortingCriterion
from .result import Result
from .row import Row
from .row_email import RowEmail
Expand Down
4 changes: 4 additions & 0 deletions smartsheet/models/enums/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@
from .paper_type import PaperType
from .predecessor_type import PredecessorType
from .publish_accessible_by import PublishAccessibleBy
from .report_aggregation_type import ReportAggregationType
from .report_boolean_operator import ReportBooleanOperator
from .report_filter_operator import ReportFilterOperator
from .report_system_column_type import ReportSystemColumnType
from .schedule_type import ScheduleType
from .share_scope import ShareScope
from .share_type import ShareType
Expand Down
27 changes: 27 additions & 0 deletions smartsheet/models/enums/report_aggregation_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# pylint: disable=C0111,R0902,R0904,R0912,R0913,R0915,E1101
# Smartsheet Python SDK.
#
# Copyright 2018 Smartsheet.com, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"): you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from enum import Enum


class ReportAggregationType(Enum):
SUM = 1
AVG = 2
MIN = 3
MAX = 4
COUNT = 5
FIRST = 6
LAST = 7
22 changes: 22 additions & 0 deletions smartsheet/models/enums/report_boolean_operator.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# pylint: disable=C0111,R0902,R0904,R0912,R0913,R0915,E1101
# Smartsheet Python SDK.
#
# Copyright 2018 Smartsheet.com, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"): you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from enum import Enum


class ReportBooleanOperator(Enum):
AND = 1
OR = 2
56 changes: 56 additions & 0 deletions smartsheet/models/enums/report_filter_operator.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# pylint: disable=C0111,R0902,R0904,R0912,R0913,R0915,E1101
# Smartsheet Python SDK.
#
# Copyright 2018 Smartsheet.com, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"): you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from enum import Enum


class ReportFilterOperator(Enum):
EQUAL = 1
NOT_EQUAL = 2
GREATER_THAN = 3
LESS_THAN = 4
CONTAINS = 5
BETWEEN = 6
TODAY = 7
PAST = 8
FUTURE = 9
LAST_N_DAYS = 10
NEXT_N_DAYS = 11
IS_BLANK = 12
IS_NOT_BLANK = 13
IS_NUMBER = 14
IS_NOT_NUMBER = 15
IS_DATE = 16
IS_NOT_DATE = 17
IS_CHECKED = 18
IS_UNCHECKED = 19
IS_ONE_OF = 20
IS_NOT_ONE_OF = 21
LESS_THAN_OR_EQUAL = 22
GREATER_THAN_OR_EQUAL = 23
DOES_NOT_CONTAIN = 24
NOT_BETWEEN = 25
NOT_TODAY = 26
NOT_PAST = 27
NOT_FUTURE = 28
NOT_LAST_N_DAYS = 29
NOT_NEXT_N_DAYS = 30
HAS_ANY_OF = 31
HAS_NONE_OF = 32
HAS_ALL_OF = 33
NOT_ALL_OF = 34
MULTI_IS_EQUAL = 35
MULTI_IS_NOT_EQUAL = 36
25 changes: 25 additions & 0 deletions smartsheet/models/enums/report_system_column_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# pylint: disable=C0111,R0902,R0904,R0912,R0913,R0915,E1101
# Smartsheet Python SDK.
#
# Copyright 2018 Smartsheet.com, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"): you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
from enum import Enum


class ReportSystemColumnType(Enum):
MODIFIED_DATE = 1
MODIFIED_BY = 2
CREATED_DATE = 3
CREATED_BY = 4
SHEET_NAME = 5 # Valid for reports only
Loading
Loading