Enabling service uniqueness checks to allow the same value at different resellers

256 views 3

How to configure the service uniqueness checks to only apply within a uniqueness group, often a reseller.


This feature makes it possible to allow checks of uniqueness within e.g. customers of a reseller, while allowing identical values for customers of some other reseller.

Configuring service uniqueness checks for a limited group of services

  1. Configure the uniqueness check in the Provisioning Description by giving it a JSON argument containing two properties called uniqueness_per_account_group and uniqueness_per_account_group_property.
    • As an example:
    • <onBeforeAddService type="Atomia.Provisioning.ActionHooks.BeforeAddService.UniquenessCheck, Atomia.Provisioning.ActionHooks.BeforeAddService" argument="" />


      <onBeforeAddService type="Atomia.Provisioning.ActionHooks.BeforeAddService.UniquenessCheck, Atomia.Provisioning.ActionHooks.BeforeAddService" argument="{ 'uniqueness_per_account_group': true, 'uniqueness_per_account_group_property': 'AccountGroupUniqueness' }" />
  2. Make sure that accounts have different values for this account_property (in the example AccountGroupUniqueness), if duplicates should be allowed for different subsets of the accounts.
  3. If accounts don’t have the property, the default behaviour is used. I.e. if a collision is detected, an error is thrown.
  4. If you have a reseller company A that has separate resources from a reseller company B, then make sure that accounts under company A have this value (“company A”) for the AccountGroupUniqueness attribute, and users under company B should instead have “company B” as the value.
  5. To get these properties set when creating new accounts you have to do the following:
    1. Add a reseller_configuration_custom_attribute row with name AccountGroupUniqueness and the corresponding value for the two resellers.
    2. Add the following item to <resellerAttributesToCopyToCustomer> in the Billing API web.config: <resellerAttribute name=”AccountGroupUniqueness “/>

The new accounts get the new attributes by default, as these attributes are copied to account.custom_attribute, and all account.custom_attribute rows are copied to Automation Server as account_property rows. Therefore, they get distinct uniqueness groups.

Keep in mind

For existing accounts you will have to create the account_property-rows matching the corresponding resellers manually.

Was this helpful?