diff --git a/CHANGELOG.md b/CHANGELOG.md index cc3283cb..0597c6b9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +#### 1.7.0 (February 2, 2016) +* Deprecated "Team" reports. With the arrival of "Teams" with the new Plus Plan, the previous "Team" report has been renamed "Company" report +* Added new reports methods: `getCompanyReport`, `getCustomersHelpedCompanyReport`, `getCompanyDrillDownReport` +* Aliased old Team reports: `getTeamReport` -> `getCompanyReport`, `getCustomersHelpedTeamReport` -> `getCustomersHelpedCompanyReport`, `getTeamDrillDownReport` -> `getCompanyDrillDownReport` + #### 1.6.5 (January 27, 2016) * Fixed a bug that threw an error when trying to delete a conversation after fetching it. diff --git a/README.md b/README.md index 983c5d82..37d05ab3 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Help Scout PHP Wrapper [![Build Status](https://travis-ci.org/helpscout/helpscou ================================================================================ > PHP Wrapper for the Help Scout API and Webhooks implementation. More information on our [developer site](http://developer.helpscout.net). -Version 1.6.5 Released +Version 1.7.0 Released --------------------- Please see the [Changelog](https://github.com/helpscout/helpscout-api-php/blob/master/CHANGELOG.md) for details. @@ -181,9 +181,9 @@ API Client Methods * getResolutionTimeProductivityReport() * getResponseTimeProductivityReport() * getProductivityDrillDownReport() -* getTeamReport() +* getCompanyReport() * getCustomersHelpedTeamReport() -* getTeamDrillDownReport() +* getCompanyDrillDownReport() * getUserReport() * getUserConversationHistoryReport() * getUserCustomersHelpedReport() @@ -192,6 +192,7 @@ API Client Methods * getUserResolutionsReport() * getUserHappinessReport() * getUserRatingsReport() +* getCustomersHelpedCompanyReport() Example Usage: Reports ------------------------ diff --git a/src/HelpScout/descriptions/reports/team.php b/src/HelpScout/descriptions/reports/team.php index 544b1a42..e28f2110 100644 --- a/src/HelpScout/descriptions/reports/team.php +++ b/src/HelpScout/descriptions/reports/team.php @@ -1,114 +1,129 @@ array( - 'httpMethod' => 'GET', - 'uri' => 'reports/team.json', - 'parameters' => array( - 'start' => array( - 'location' => 'query', - 'required' => true - ), - 'end' => array( - 'location' => 'query', - 'required' => true - ), - 'previousStart' => array( - 'location' => 'query' - ), - 'previousEnd' => array( - 'location' => 'query' - ), - 'mailboxes' => array( - 'location' => 'query' - ), - 'tags' => array( - 'location' => 'query' - ), - 'types' => array( - 'location' => 'query' - ), - 'folders' => array( - 'location' => 'query' - ) +$companyReport = array( + 'httpMethod' => 'GET', + 'uri' => 'reports/company.json', + 'parameters' => array( + 'start' => array( + 'location' => 'query', + 'required' => true + ), + 'end' => array( + 'location' => 'query', + 'required' => true + ), + 'previousStart' => array( + 'location' => 'query' + ), + 'previousEnd' => array( + 'location' => 'query' + ), + 'mailboxes' => array( + 'location' => 'query' + ), + 'tags' => array( + 'location' => 'query' + ), + 'types' => array( + 'location' => 'query' + ), + 'folders' => array( + 'location' => 'query' ) - ), + ) +); - 'getCustomersHelpedTeamReport' => array( - 'httpMethod' => 'GET', - 'uri' => 'reports/team/customers-helped.json', - 'parameters' => array( - 'start' => array( - 'location' => 'query', - 'required' => true - ), - 'end' => array( - 'location' => 'query', - 'required' => true - ), - 'previousStart' => array( - 'location' => 'query' - ), - 'previousEnd' => array( - 'location' => 'query' - ), - 'mailboxes' => array( - 'location' => 'query' - ), - 'tags' => array( - 'location' => 'query' - ), - 'types' => array( - 'location' => 'query' - ), - 'folders' => array( - 'location' => 'query' - ), - 'viewBy' => array( - 'location' => 'query' - ) +$customersHelpedCompanyReport = array( + 'httpMethod' => 'GET', + 'uri' => 'reports/company/customers-helped.json', + 'parameters' => array( + 'start' => array( + 'location' => 'query', + 'required' => true + ), + 'end' => array( + 'location' => 'query', + 'required' => true + ), + 'previousStart' => array( + 'location' => 'query' + ), + 'previousEnd' => array( + 'location' => 'query' + ), + 'mailboxes' => array( + 'location' => 'query' + ), + 'tags' => array( + 'location' => 'query' + ), + 'types' => array( + 'location' => 'query' + ), + 'folders' => array( + 'location' => 'query' + ), + 'viewBy' => array( + 'location' => 'query' ) - ), + ) +); - 'getTeamDrillDownReport' => array( - 'httpMethod' => 'GET', - 'uri' => 'reports/team/drilldown.json', - 'parameters' => array( - 'start' => array( - 'location' => 'query', - 'required' => true - ), - 'end' => array( - 'location' => 'query', - 'required' => true - ), - 'mailboxes' => array( - 'location' => 'query' - ), - 'tags' => array( - 'location' => 'query' - ), - 'types' => array( - 'location' => 'query' - ), - 'folders' => array( - 'location' => 'query' - ), - 'page' => array( - 'location' => 'query' - ), - 'rows' => array( - 'location' => 'query' - ), - 'range' => array( - 'location' => 'query', - 'required' => true - ), - 'rangeId' => array( - 'location' => 'query' - ) +$companyDrillDownReport = array( + 'httpMethod' => 'GET', + 'uri' => 'reports/company/drilldown.json', + 'parameters' => array( + 'start' => array( + 'location' => 'query', + 'required' => true + ), + 'end' => array( + 'location' => 'query', + 'required' => true + ), + 'mailboxes' => array( + 'location' => 'query' + ), + 'tags' => array( + 'location' => 'query' + ), + 'types' => array( + 'location' => 'query' + ), + 'folders' => array( + 'location' => 'query' + ), + 'page' => array( + 'location' => 'query' + ), + 'rows' => array( + 'location' => 'query' + ), + 'range' => array( + 'location' => 'query', + 'required' => true + ), + 'rangeId' => array( + 'location' => 'query' ) ) +); + +return array( + + 'getCompanyReport' => $companyReport, + + // Deprecated, use `getCompanyReport` + 'getTeamReport' => $companyReport, + + 'getCustomersHelpedCompanyReport' => $customersHelpedCompanyReport, + + // Deprecated, use `getCustomersHelpedCompanyReport + 'getCustomersHelpedTeamReport' => $customersHelpedCompanyReport, + + 'getCompanyDrillDownReport' => $companyDrillDownReport, + + // Deprecated, use `getCompanyDrillDownReport` + 'getTeamDrillDownReport' => $companyDrillDownReport );