Service detection rules API - JSON models

JSON models of the Service detection rules API vary greatly, depending on the type of some objects. Here you can find JSON models for each variation.

Variations of the ServiceDetectionRule object

The ServiceDetectionRule object is the base for all service detection rules. The actual set of fields depends on the type of the rule.

FULL_WEB_REQUEST

OPAQUE_AND_EXTERNAL_WEB_REQUEST

FULL_WEB_SERVICE

Variations of the CompareOperation object

The CompareOperation object is the base for all comparison operations. The actual set of fields depends on the type of the comparison.

STRING_CONTAINS

The StringContainsCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn contains into does not contain.

If not set, then false is used.

optional
ignoreCase boolean

The condition is case sensitive (false) or case insensitive (true).

If not set, then false is used, making the condition case sensitive.

optional
values string[]

The value to compare to.

If several values are specified, the OR logic applies.

optional

STRING_EQUALS

The StringEqualsCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn equals into does not equal.

If not set, then false is used.

optional
ignoreCase boolean

The condition is case sensitive (false) or case insensitive (true).

If not set, then false is used, making the condition case sensitive.

optional
values string[]

The value to compare to.

If several values are specified, the OR logic applies.

optional

STARTS_WITH

The StartsWithCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn starts with into does not start with.

If not set, then false is used.

optional
ignoreCase boolean

The condition is case sensitive (false) or case insensitive (true).

If not set, then false is used, making the condition case sensitive.

optional
values string[]

The value to compare to.

If several values are specified, the OR logic applies.

optional

ENDS_WITH

The EndsWithCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn ends with into does not end with.

If not set, then false is used.

optional
ignoreCase boolean

The condition is case sensitive (false) or case insensitive (true).

If not set, then false is used, making the condition case sensitive.

optional
values string[]

The value to compare to.

If several values are specified, the OR logic applies.

optional

EXISTS

The ExistsCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn exists into does not exist.

If not set, then false is used.

optional

IP_IN_RANGE

The IpInRangeCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn IP is in range into IP is not in range.

If not set, then false is used.

optional
lower string

The lower boundary of the IP range.

required
upper string

The upper boundary of the IP range.

required

INT_EQUALS

The IntEqualsCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
negate boolean

Inverts the operation of the condition. Set to true to turn equals into does not equal.

If not set, then false is used.

optional
values integer[]

The value to compare to.

If several values are specified, the OR logic applies.

optional

LESS_THAN

The LessThanCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
value integer

The value to compare to.

required

GREATER_THAN

The GreaterThanCompareOperation object

The condition of the rule.

The actual set of fields depends on the type of the condition.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • EQUALS -> EqualsCompareOperation
  • STRING_CONTAINS -> StringContainsCompareOperation
  • STARTS_WITH -> StartsWithCompareOperation
  • ENDS_WITH -> EndsWithCompareOperation
  • EXISTS -> ExistsCompareOperation
  • IP_IN_RANGE -> IpInRangeCompareOperation
  • LESS_THAN -> LessThanCompareOperation
  • GREATER_THAN -> GreaterThanCompareOperation
  • INT_EQUALS -> IntEqualsCompareOperation
  • STRING_EQUALS -> StringEqualsCompareOperation
  • TAG -> TagCompareOperation
required
value integer

The value to compare to.

required

Variations of the Transformation object

The Transformation object is the base for all transformation operations. The actual set of fields depends on the type of the transformation.

BEFORE

The transformation of the BEFORE type.

The transformation keeps the value before the specified delimiter and removes everything after it.

Element Type Description Required
type string The type of the transformation. required
delimiter string The delimiter of the transformation. The transformation keeps everything before this delimiter and removes everything after it.

The delimiter itself is not kept.

If several delimiters appear in the initial value, only the first one is used.
required

AFTER

The transformation of the AFTER type.

The transformation removes everything before the specified delimiter and keeps the value after it.

Element Type Description Required
type string The type of the transformation. required
delimiter string The delimiter of the transformation. The transformation removes everything before this delimiter and keeps everything after it.

The delimiter itself is not kept.

If several delimiters appear in the initial value, only the first one is used.
required

BETWEEN

The transformation of the BETWEEN type.

The transformation keeps the value between the specified delimiters and removes everything outside them.

Element Type Description Required
type string The type of the transformation. required
after string The starting delimiter. The transformation removes everything before it. The delimiter itself is not kept. required

REPLACE_BETWEEN

The ReplaceBetweenTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required
after string

The starting delimiter. The transformation removes everything before it. The delimiter itself is not kept.

required
before string

The ending delimiter. The transformation removes everything after it. The delimiter itself is not kept.

required
replacement string

The value to be used instead of the detected value.

required

REMOVE_NUMBERS

The RemoveNumbersTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required
minDigitCount integer

Remove numbers that contain at least X digits.

required
includeHexNumbers boolean

Remove (true) or keep (false) hexadecimal numbers.

If not set, then false is used, keeping hexadecimal numbers.

optional

REMOVE_CREDIT_CARDS

The RemoveCreditCardNumbersTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required

REMOVE_IBANS

The RemoveIBANsTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required

REMOVE_IPS

The RemoveIPsTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required

SPLIT_SELECT

The SplitSelectTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required
delimiter string

The delimiter for splitting the detected value. The delimiter itself is not kept.

required
itemIndex integer

The index of the element in the split array to be used. Indexing starts with 1.

required

TAKE_SEGMENTS

The TakeSegmentsTransformation object

Configuration of transformation of the detected value.

If several transformations are specified, they are handled sequentially from top to bottom. Each transformation is applied to the result of the preceding transformation. For example, the second transformation is applied to the result of the first transformation.

The actual set of fields depends on the type of the transformation.

Element Type Description Required
type string

Defines the actual set of fields depending on the value. See one of the following objects:

  • BEFORE -> BeforeTransformation
  • AFTER -> AfterTransformation
  • BETWEEN -> BetweenTransformation
  • REPLACE_BETWEEN -> ReplaceBetweenTransformation
  • REMOVE_NUMBERS -> RemoveNumbersTransformation
  • REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation
  • REMOVE_IBANS -> RemoveIBANsTransformation
  • REMOVE_IPS -> RemoveIPsTransformation
  • SPLIT_SELECT -> SplitSelectTransformation
  • TAKE_SEGMENTS -> TakeSegmentsTransformation
required
segmentCount integer

The number of elements to be kept.

required
delimiter string

The delimiter for splitting the detected value. The delimiter itself is not kept.

required
takeFromEnd boolean

Keeps the first (false) or last (true) elements.

If not set, then false is used, keeping the first elements.

optional