Service detection rules API - GET a rule
Shows the properties of the specified service detection rule.
The request produces an application/json
payload.
This request is an early adopter release and may be changed in non compatible way.
GET |
|
Parameters
Parameter | Type | Description | In | Required |
---|---|---|---|---|
id | string |
The ID of the required service detection rule. |
path | required |
Response codes
Code | Description |
---|---|
200 | Success. The response contains properties of the specified rule. |
404 | Failed. The rule with the specified ID doesn't exist. |
Response format
Refer to JSON models to find all JSON models that depend on the type of the model.
The FullWebServiceRule object
The service detection rule of the FULL_WEB_SERVICE
type.
Possible values for FRAMEWORK attribute type:
- JAX_WS_RI
- AXIS
- CXF
- JBOSS
- WEBSPHERE
- SPRING
- PROGRESS
- HESSIAN
- WEBMETHODS
- JERSEY
- RESTLET
- RESTEASY
- WINK
- TIBCO
- WEBLOGIC
Element | Type | Description |
---|---|---|
type | string | |
metadata | ConfigurationMetadata | Metadata useful for debugging. |
id | string | The ID of the service detection rule. |
order | string | The order of the rule in the rules list. The rules are evaluated from top to bottom. The first matching rule applies. |
name | string | The name of the rule. |
description | string | A short description of the rule. |
enabled | boolean | The rule is enabled( |
conditions | ConditionsFullWebServiceAttributeTypeDto[] | A list of conditions of the rule. If several conditions are specified, the AND logic applies. |
detectAsWebRequestService | boolean | Detect the matching requests as a web request service.
If |
webServiceName | WebServiceName | How to handle the detected name of the web service. |
webServiceNameSpace | WebServiceNameSpace | How to handle the detected name space of the web service. |
applicationId | ApplicationId | How to handle the detected ID of the application. |
contextRoot | ContextRoot | How to handle the detected context root of the service URL. |
serverName | ServerName | How to handle the detected server name of the service URL. |
The ServerName object
The contribution to the service ID calculation from the detected server name.
You have two mutually exclusive options:
- Override the detected value with a specified static value. Specify the new value in the valueOverride field.
- Dynamically transform the detected value. Specify the transformation parameters in the transformations field.
Element | Type | Description |
---|---|---|
valueOverride | string | The value to be used instead of the detected value. |
transformations | TransformationBase[] | Transformations to be applied to the detected value. |
The ContextRoot object
The contribution to the service ID calculation from the detected context root.
The context root is the first segment of the request URL after server name. For example, in the www.dexp.ae/support/help/extend-DESK/DESK-api/
URL the context root is support
.
You have two options:
- Keep a part of the detected URL. Specify the number of segments to be kept in the segmentsToCopyFromUrlPath field.
- Dynamically transform the detected URL. Specify the transformation parameters in the transformations field.
You can use one or both options. If you use both, the transformation applies to the modified URL.
Element | Type | Description |
---|---|---|
segmentsToCopyFromUrlPath | integer | The number of segments of the URL to be kept. The URL is divided by slashes ( For example, if you specify |
transformations | ContextRootTransformation[] | Transformations to be applied to the detected value. |
The ContextRootTransformation 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 |
---|---|---|
type | string | Defines the actual set of fields depending on the value: BEFORE -> BeforeTransformation REPLACE_BETWEEN -> ReplaceBetweenTransformation REMOVE_NUMBERS -> RemoveNumbersTransformation REMOVE_CREDIT_CARDS -> RemoveCreditCardNumbersTransformation REMOVE_IBANS -> RemoveIBANsTransformation REMOVE_IPS -> RemoveIPsTransformation |
The ApplicationId object
The contribution to the service ID calculation from the detected application ID.
You have two mutually exclusive options:
- Override the detected value with a specified static value. Specify the new value in the valueOverride field.
- Dynamically transform the detected value. Specify the transformation parameters in the transformations field.
Element | Type | Description |
---|---|---|
valueOverride | string | The value to be used instead of the detected value. |
transformations | TransformationBase[] | Transformations to be applied to the detected value. |
The WebServiceNameSpace object
The contribution to the service ID calculation from the detected web service name space.
You have two mutually exclusive options:
- Override the detected value with a specified static value. Specify the new value in the valueOverride field.
- Dynamically transform the detected value. Specify the transformation parameters in the transformations field.
Element | Type | Description |
---|---|---|
valueOverride | string | The value to be used instead of the detected value. |
transformations | TransformationBase[] | Transformations to be applied to the detected value. |
The WebServiceName object
The contribution to the service ID calculation from the detected web service name.
You have two mutually exclusive options:
- Override the detected value with a specified static value. Specify the new value in the valueOverride field.
- Dynamically transform the detected value. Specify the transformation parameters in the transformations field.
Element | Type | Description |
---|---|---|
valueOverride | string | The value to be used instead of the detected value. |
transformations | TransformationBase[] | Transformations to be applied to the detected value. |
The TransformationBase 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 |
---|---|---|
type | string | Defines the actual set of fields depending on the value: 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 |
The ConditionsFullWebServiceAttributeTypeDto object
A condition of the service detection rule.
Element | Type | Description |
---|---|---|
attributeType | string | The type of the attribute to be checked. |
compareOperations | CompareOperation[] | A list of conditions for the rule. If several conditions are specified, the AND logic applies. |
The CompareOperation object
The condition of the rule.
The actual set of fields depends on the type
of the condition.
Element | Type | Description |
---|---|---|
type | string | Defines the actual set of fields depending on the value: 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 |
The ConfigurationMetadata object
Metadata useful for debugging
Element | Type | Description |
---|---|---|
configurationVersions | integer[] | A Sorted list of the version numbers of the configuration. |
clusterVersion | string | DESK server version. |
{
"type": "FULL_WEB_SERVICE",
"name": "My sample rule",
"description": "REST API example\n",
"enabled": true,
"detectAsWebRequestService": false,
"conditions": [
{
"attributeType": "APPLICATION_ID",
"compareOperations": [
{
"type": "STRING_CONTAINS",
"invert": "false",
"ignoreCase": "false",
"values": [
"value1",
"value2"
]
}
]
}
],
"webServiceName": {
"valueOverride": "abc"
},
"webServiceNameSpace": {
"valueOverride": "abc"
},
"applicationId": {
"valueOverride": "abc"
},
"contextRoot": {
"segmentsToCopyFromUrlPath": 2,
"transformations": [
{
"type": "BEFORE",
"delimiter": "/"
}
]
},
"serverName": {
"transformations": [
{
"type": "BEFORE",
"delimiter": "-"
}
]
}
}