Company and Brand Consistency Standards

Overview

This endpoint analyzes the data we have gathered for your businesses and compiles it into a useful JSON for your use. On a by business basis, we analyze what the average rating is, how many positive/negative reviews you have and what your response rate to such reviews is, as well as your overall review quantity. Beyond just the reviews aspect, we also look at your profiles across your data sources and determined if the names and addresses match, if they've been claimed, and even if they have been created.

Request a Report

To change the report standards settings for a business you can make a post request where the parameters have the field name of the "problem" values with the new standard met criteria as an integer (e.g. review_count_greater_than_or_equal_to=20). Similarly, essential sources can be set via the post request as a comma separated list of integers. (essential_sources=1,2,7,18).

https://ad1.replypro.io/api/public/accounts/<account_id>/companies/<company_id>/businesses/<business_id>/reports?type=standards
https://ad1.replypro.io/api/public/accounts/<account_id>/companies/<company_id>/businesses/<business_id>/reports?positive_review_response_rate_greater_than=40&review_count_greater_than_or_equal_to=8&essential_sources=1,8,12,18,20,22,23
https://ad1.replypro.io/api/public/accounts/<account_id>/companies/<company_id>/businesses/<business_id>/reports?positive_review_response_rate_greater_than=true&review_count_greater_than_or_equal_to=true&essential_sources=true

πŸ“˜

GET currently only supports business level reports.

POST for this endpoint is currently supported for business and for company. Settings for a business are separate from a company and will supersede the settings for the company when set. By default all businesses are set to use the company settings unless changed.

DELETE for will remove the custom settings from the business/company. If you delete all company standards and/or essential sources they will revert to their default settings. If only a subset of problems are deleted then that subset of problems will no longer appear in reports for that business/company. Default settings cannot be deleted so a post request must be made at least once before any problems can be removed from the report.

{
  "next": null,
  "previous": null,
  "results": {
    "positive_review_count": 0,
    "profile_count": 1,
    "end_date": "01/25/2018",
    "location_count": 1,
    "start_date": "10/27/2017",
    "average_rating": "3.0",
    "dates_audited": "10/27/2017 - 01/25/2018",
    "negative_review_count": 2,
    "reviews": "https://ad1.replypro.io/api/public/accounts/1/companies/1/businesses/1/reviews?start_date=2017-10-27&end_date=2018-01-25",
    "company_standards": {
      1: [
        {
          "value": 0.0,
          "data_count": 0,
          "problem": "positive_review_response_rate_greater_than",
          "problem_display": "Did your location respond to at least 25% of" + 
                             "their positive reviews?",
          "description": "data_count contains the number of responses to" +
                         "positive rated reviews. Value contains the result" +
                         "of the calculation 'positive_review_count' /" +                                " 'data_count'.",
          "standard_met": false
        },
        {
          "value": 50.0,
          "data_count": 1,
          "problem": "negative_review_response_rate_greater_than",
          "problem_display": "Did your location respond to at least 80% of " +
                             "their negative reviews?",
          "description": "data_count contains the number of responses to " +
                         "negative rated reviews. Value contains the result " +
                         "of the calculation 'negative_review_count' /" +
                         " 'data_count'.",
          "standard_met": false
        },
        {
          "value": 2.0,
          "data_count": null,
          "problem": "review_count_greater_than_or_equal_to",
          "problem_display": "Did your location receive at least 5 new" +
                             "reviews?",
          "description": "The 'value' field contains the sum of " +
                         "'positive_review_count' and 'negative_review_count'." +
                         " The 'data_count' field is null.",
          "standard_met": false
        },
        {
          "value": 3.0,
          "data_count": 6.0,
          "problem": "average_rating_greater_than_or_equal_to",
          "problem_display": "Did your location average a 4 star rating" + 
                             " or above?",
          "description": "The 'value' field contains the result of the " +
                         "calculation: 'data_count' / ('positive_review_count'" +
                         " + 'negative_review_count'), The 'data_count' field" +
                         " contains a total sum of all the ratings for the "
                         "reviews in the audited date range.",
          "standard_met": false
        }
      ]
    },
    "brand_consistency_standards": {
      "results": {
        1: {
          "profile_field_values": {
            "address": [
              "123 W Street"
            ],
            "business_hours": {
              "value": {
                "monday": [["0700-1800"]],
                "tuesday": [["0700-1800"]],
                "wednesday": [["0700-1800"]],
                "thursday": [["0700-1800"]],
                "friday": [["0700-1800"]],
                "saturday": [["0900-1700"]],
                "sunday": [["1000-1400"], ["1000-1500"]]
              },
              "data_count": 2,
              "problem_display": "Are your business hours consistent across" +
                                 " all profiles?",
              "description": "The 'value' field contains the dictionary of " +
                             "the set of hours for each day across profiles. " +
                             "Each day has a list of lists of time ranges. " +
                             "Some days will have multiple time ranges as " +
                             "some businesses close mid day and reopen. The " +
                             "list of lists for each day should contain only " +
                             "one list of time ranges if its profiles are " +
                             "consistent across all data sources. The " +
                             "'data_count' field contains a total count of " +
                             "all profiles used for comparison",
              "standard_met": false
            },
            "name": [
              "Report Test Profile"
            ],
            "claimed": false,
            "phone": [
              "2081234567"
            ],
            "created": false,
            "missing_sources": [
              2,
              7
            ],
            "unclaimed_sources": [
              1
            ]
          }
        }
      }
    }
  }
}

Business Summary

The business summary is a collection of basic information about the location the report is for.

Field NameTypeDescription
average_ratingfloatShows the average rating of the business as a floating point value, max 2 decimal places.
dates_auditedstringA string representing the date range for the report. Returned in the format MM/DD/YYYY - MM/DD/YYYY
end_datestringLast date of the audit period. Returned in the format MM/DD/YYYY.
location_countintNumber of locations the report covers. Will always be 1.
negative_review_countintNumber of reviews that have a rating less than 4.0.
positive_review_countintNumber of reviews that have a rating of 4.0 or greater.
profile_countintNumber of profiles connected to the report business.
reviewshyperlinkThis is a URL to the reviews resource, designed to return the reviews used in the generation of this report.
start_datestringFirst date of the audit period. Returned in the format MM/DD/YYYY.

Company Standards

The company_standards section of the report contains a single key, business_id. Contained in this key is a list of results for each standard we analyze.

Field NameValueDescription
<business_id>arrayArray of JSON detailing the results for each standard.
data_countfloatThis field contains additional information necessary to calculate the data contained in value.
descriptionstringThis field describes what process we used to calculate the data in value, using only fields provided in the report JSON.
problemstringThe name of the method that generates this data. This value is used to update the value used as company standard.
problem_displaystringQuestion detailing what standard is being analyzed, e.g "Did your location respond to at least 80% of their negative reviews?"
standard_metbooleanDenotes whether or not the standard was met.
valuefloatResult of our calculation for the standard, e.g # of Reviews, Average Rating, Response Rate, etc.

Brand Consistency Standards

The brand_consistency_standards key inside the return JSON contains information about benchmarks relating to review data for the business. Each section of data is stored in a verbose key noting what the data relates to.

Field NameValueDescription
resultsJSON containing a single key:
<business_id>
This field contains a nested JSON of the results for the analysis
<business_id>JSON containing the profile_field_values keyThis key will be an empty array if there are no profiles for the business.
profile_field_valuesJSON containing the keys:
address, business_hours, claimed, created, name, phone
addressarrayList of addresses, that should have a length of 1.
business_hoursCompany Standards Report Format

Time ranges for each day are the business hours collected from the data source as a list of nine character strings for each day; e.g. "0200-2000", which would be 2 a.m. to 8 p.m.
The 'value' field contains the dictionary of the set of hours for each day across profiles. Each day has a list of lists of time ranges. Some days will have multiple time ranges as some businesses close mid day and reopen. The list of lists for each day should contain only one list of time ranges if its profiles are consistent across all data sources. The 'data_count' field contains a total count of all profiles used for comparison.
claimedbooleanDenotes whether the profile has been officially claimed on essential_sources. Default essential sources are: Yelp, Google, and Facebook.
createdbooleanDenotes whether the business has a profile on essential_sources. Default essential sources are: Yelp, Google, and Facebook.
missing_sourcesarrayThis contains the ids of the data sources (out of 1, 2, 7) that we do not have for you.
namearrayList of names, that should have a length of 1.
phonearrayList of phone numbers, that should have a length of 1.
unclaimed_sourcesarrayThis contains the ids of the data sources that you have not claimed yet.

πŸ“˜

Address, Name, or Phone have a length greater than 1?

If the list returned in address, name, or phone has more than one element, this means that there are discrepancies across your profiles for that particular field. To find out which sources have which data, you can make a request to the Profiles resource, using the individual strings given as filter values.

For reference on available filter options for a given resource, see Filters.

Custom Date Ranges

This endpoint defaults to returning a report looking over the previous 90 days of data. If you want to customize that date range, you can. Example requests for reports covering 30 days and a custome date range are shown below.

https://ad1.replypro.io/api/public/accounts/<account_id>/companies/<company_id>/businesses/<business_id>/reports?type=standards&days=30
https://ad1.replypro.io/api/public/accounts/<account_id>/companies/<company_id>/businesses/<business_id>/reports?type=standards&start_date=2018-01-22&end_date=2018-01-27