Skip to main content

Whitespace PowerSuite - Non Collection Reason

  • What is it? This formula will return the reason why a collection wasn't made for a particular service at a given property.

Inputs

This formula requires 4 inputs to be passed through to it:

  • the UPRN of the property

    The mapped value must come from an address lookup question, using the propery_identifier variable option.

  • the Date From

    A date to use as the beginning of the search period, in YYYY-MM-DD format. This date can be populated from the Date Plus/Minus Days Logic

  • the Date To

    A date to use as the end of the search period, in YYYY-MM-DD format. This date can be populated from the Date Plus/Minus Days Logic. Whitespace PowerSuite Web Services will set the time on any date you pass into it to 00:00:00. In order to get the non collection reason for a collection due today you will need to set Date To to tomorrow.

  • the Service code

    This input should be set to a string which can be used to determine the correct log from the RoundCode property of an InCabLog record.

Return values

ValueDescription
The reason for non collectionIf there is one found for the Service, prefix specified.
N/AIf there is no reason available, or an error occurred.

Formula Logic

  1. A check is made to see if the integration has been enabled in the Settings > Integrations page. If the integration is not enabled the formula returns N/A.

  2. A call to Whitespace PowerSuite's GetInCabLogs endpoint is made, passing the UPRN, Date From and Date To inputs.

  3. The returned collections are iterated over until one has a RoundCode property that contains the Service Code (compared case-insensitively).

  4. If a matching log is found, the Reason property is returned. Otherwise, N/A is returned.