# Rules

## Get

> Retrieve a rule from the Rule List of a session server with the specified ID.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/PubItems/{id}/Rules/{ruleId}":{"get":{"tags":["3-Publishing/Filters//Rule"],"summary":"Get","description":"Retrieve a rule from the Rule List of a session server with the specified ID.","operationId":"f54b1e04-e5c5-42be-b05e-8fc10a063604","parameters":[{"name":"id","in":"path","description":"The ID of a session server for which to retrieve the Rule settings.","required":true,"schema":{"type":"integer","format":"int32"}},{"name":"ruleId","in":"path","description":"The ID of the Rule to retrieve.","required":true,"schema":{"type":"integer","format":"int32"}}],"responses":{"200":{"description":"Success","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/PubItemRule"}}}},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"PubItemRule":{"type":"object","properties":{"id":{"type":"integer","description":"<para type=\"description\">ID of the object.</para>","format":"int32"},"priority":{"type":"integer","description":"<para type=\"description\">Priority of the object.</para>","format":"int32"},"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Rule is enabled or not</para>"},"name":{"type":"string","description":"<para type=\"description\">Name of the Rule</para>","nullable":true},"description":{"type":"string","description":"<para type=\"description\">Description of the Rule</para>","nullable":true},"criteria":{"$ref":"#/components/schemas/PubItemCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">PubItem Rule</para>\r\n<para type=\"description\"></para>"},"PubItemCriteria":{"type":"object","properties":{"securityPrincipals":{"$ref":"#/components/schemas/SecurityPrincipalsCriteria"},"gateways":{"$ref":"#/components/schemas/GatewaysCriteria"},"oSs":{"$ref":"#/components/schemas/OSsCriteria"},"iPs":{"$ref":"#/components/schemas/IPsCriteria"},"hardwareIDs":{"$ref":"#/components/schemas/HardwareIDsCriteria"},"access":{"$ref":"#/components/schemas/AccessType"},"devices":{"$ref":"#/components/schemas/DevicesCriteria"},"themes":{"$ref":"#/components/schemas/ThemesCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">PubItem Criteria</para>\r\n<para type=\"description\"></para>"},"SecurityPrincipalsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Security Principals Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/SecurityPrincipalCriteriaEntry"},"description":"<para type=\"description\">User criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principals Criteria</para>\r\n<para type=\"description\"></para>"},"MatchingModeType":{"enum":[["0 = IsNotOneOfTheFollowing","1 = IsOneOfTheFollowing"]],"type":"string","description":"<para type=\"synopsis\">Matching mode type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"SecurityPrincipalCriteriaEntry":{"type":"object","properties":{"account":{"type":"string","description":"<para type=\"description\">The name of the user/group account the filter is added to.</para>","nullable":true},"type":{"$ref":"#/components/schemas/UserType"},"sid":{"type":"string","description":"<para type=\"description\">The SID of the user/group account the filter is added to.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principal Criteria Entry</para>\r\n<para type=\"description\"></para>"},"UserType":{"enum":[["1 = User","2 = Group","3 = ForeignSecurityPrincipal","4 = Computer"]],"type":"string","description":"<para type=\"synopsis\">User Type</para>\r\n<para type=\"description\"></para>","format":"int32"},"GatewaysCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Gateways Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/GatewayCriteriaEntry"},"description":"<para type=\"description\">Gateway criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateways Criteria</para>\r\n<para type=\"description\"></para>"},"GatewayCriteriaEntry":{"type":"object","properties":{"gatewayIP":{"type":"string","description":"<para type=\"description\">The gateway IP.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateway criteria entry</para>\r\n<para type=\"description\"></para>"},"OSsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the OSs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedOSes":{"$ref":"#/components/schemas/AllowedOperatingSystems"}},"additionalProperties":false,"description":"<para type=\"synopsis\">OS Criteria Settings</para>\r\n<para type=\"description\"></para>"},"AllowedOperatingSystems":{"type":"object","properties":{"chrome":{"type":"boolean","description":"<para type=\"description\">Whether Chrome is allowed or not.</para>"},"android":{"type":"boolean","description":"<para type=\"description\">Whether Android is allowed or not.</para>"},"webClient":{"type":"boolean","description":"<para type=\"description\">Whether Web Client is allowed or not.</para>"},"iOS":{"type":"boolean","description":"<para type=\"description\">Whether iOS is allowed or not.</para>"},"linux":{"type":"boolean","description":"<para type=\"description\">Whether Linux is allowed or not.</para>"},"mac":{"type":"boolean","description":"<para type=\"description\">Whether MAC OS is allowed or not.</para>"},"wyse":{"type":"boolean","description":"<para type=\"description\">Whether Wyse is allowed or not.</para>"},"windows":{"type":"boolean","description":"<para type=\"description\">Whether Windows is allowed or not.</para>"}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed Operating Systems</para>\r\n<para type=\"description\"></para>"},"IPsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the IPs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedIPs":{"$ref":"#/components/schemas/AllowedIPsCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPs Criteria</para>\r\n<para type=\"description\"></para>"},"AllowedIPsCriteria":{"type":"object","properties":{"iPv4s":{"type":"array","items":{"$ref":"#/components/schemas/IPv4CriteriaEntry"},"description":"<para type=\"description\">IPv4 criteria list</para>","nullable":true},"iPv6s":{"type":"array","items":{"$ref":"#/components/schemas/IPv6CriteriaEntry"},"description":"<para type=\"description\">IPv6 criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed IPs Criteria</para>\r\n<para type=\"description\"></para>"},"IPv4CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv4 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"IPv6CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv6 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"HardwareIDsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Hardware IDs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/HardwareIDCriteriaEntry"},"description":"<para type=\"description\">Hardware IDs criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware IDs Criteria</para>\r\n<para type=\"description\"></para>"},"HardwareIDCriteriaEntry":{"type":"object","properties":{"hardwareID":{"type":"string","description":"<para type=\"description\">The hardware ID.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware ID criteria entry</para>\r\n<para type=\"description\"></para>"},"AccessType":{"enum":[["0 = DenyCriteriaWhen","1 = AllowCriteriaWhen"]],"type":"string","description":"<para type=\"synopsis\">Access type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"DevicesCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Devices Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/ClientDeviceCriteriaEntry"},"description":"<para type=\"description\">Client criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Devices Criteria</para>\r\n<para type=\"description\"></para>"},"ClientDeviceCriteriaEntry":{"type":"object","properties":{"client":{"type":"string","description":"<para type=\"description\">The name of the client device.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Client device criteria entry</para>\r\n<para type=\"description\"></para>"},"ThemesCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Themes Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"ids":{"type":"array","items":{"type":"integer","format":"int32"},"description":"<para type=\"description\">Theme criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Themes Criteria</para>\r\n<para type=\"description\"></para>"},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```

{% openapi src="/files/oEgjY6sMA31ZVBC35aoj" path="/api/PubItems/{id}/Rules/{ruleId}" method="put" %}
[swagger 1.json](https://content.gitbook.com/content/jyGAUPrA6XIdGAfHCnJE/blobs/7mKwtvutT7xlWtmCVnxB/swagger%201.json)
{% endopenapi %}

## Remove

> Remove a rule from the Rule List of a session server with the specified ID.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/PubItems/{id}/Rules/{ruleId}":{"delete":{"tags":["3-Publishing/Filters//Rule"],"summary":"Remove","description":"Remove a rule from the Rule List of a session server with the specified ID.","operationId":"d5cf78a2-531f-4f48-be91-1bcb5f3c757e","parameters":[{"name":"id","in":"path","description":"The ID of a session server for which to modify the Rule settings.","required":true,"schema":{"type":"integer","format":"int32"}},{"name":"ruleId","in":"path","description":"The ID of the Rule to remove.","required":true,"schema":{"type":"integer","format":"int32"}}],"responses":{"204":{"description":"No Content"},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```

## List

> Retrieve the Rule List of a session server with the specified ID.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/PubItems/{id}/Rules":{"get":{"tags":["3-Publishing/Filters//Rule"],"summary":"List","description":"Retrieve the Rule List of a session server with the specified ID.","operationId":"f0a3009f-8f90-4158-ac52-4e16e18cecf9","parameters":[{"name":"id","in":"path","description":"The ID of a session server for which to retrieve the Rule settings.","required":true,"schema":{"type":"integer","format":"int32"}}],"responses":{"200":{"description":"Success","content":{"application/json; api-version=1.0":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PubItemRule"}}}}},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"PubItemRule":{"type":"object","properties":{"id":{"type":"integer","description":"<para type=\"description\">ID of the object.</para>","format":"int32"},"priority":{"type":"integer","description":"<para type=\"description\">Priority of the object.</para>","format":"int32"},"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Rule is enabled or not</para>"},"name":{"type":"string","description":"<para type=\"description\">Name of the Rule</para>","nullable":true},"description":{"type":"string","description":"<para type=\"description\">Description of the Rule</para>","nullable":true},"criteria":{"$ref":"#/components/schemas/PubItemCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">PubItem Rule</para>\r\n<para type=\"description\"></para>"},"PubItemCriteria":{"type":"object","properties":{"securityPrincipals":{"$ref":"#/components/schemas/SecurityPrincipalsCriteria"},"gateways":{"$ref":"#/components/schemas/GatewaysCriteria"},"oSs":{"$ref":"#/components/schemas/OSsCriteria"},"iPs":{"$ref":"#/components/schemas/IPsCriteria"},"hardwareIDs":{"$ref":"#/components/schemas/HardwareIDsCriteria"},"access":{"$ref":"#/components/schemas/AccessType"},"devices":{"$ref":"#/components/schemas/DevicesCriteria"},"themes":{"$ref":"#/components/schemas/ThemesCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">PubItem Criteria</para>\r\n<para type=\"description\"></para>"},"SecurityPrincipalsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Security Principals Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/SecurityPrincipalCriteriaEntry"},"description":"<para type=\"description\">User criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principals Criteria</para>\r\n<para type=\"description\"></para>"},"MatchingModeType":{"enum":[["0 = IsNotOneOfTheFollowing","1 = IsOneOfTheFollowing"]],"type":"string","description":"<para type=\"synopsis\">Matching mode type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"SecurityPrincipalCriteriaEntry":{"type":"object","properties":{"account":{"type":"string","description":"<para type=\"description\">The name of the user/group account the filter is added to.</para>","nullable":true},"type":{"$ref":"#/components/schemas/UserType"},"sid":{"type":"string","description":"<para type=\"description\">The SID of the user/group account the filter is added to.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Security Principal Criteria Entry</para>\r\n<para type=\"description\"></para>"},"UserType":{"enum":[["1 = User","2 = Group","3 = ForeignSecurityPrincipal","4 = Computer"]],"type":"string","description":"<para type=\"synopsis\">User Type</para>\r\n<para type=\"description\"></para>","format":"int32"},"GatewaysCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Gateways Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/GatewayCriteriaEntry"},"description":"<para type=\"description\">Gateway criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateways Criteria</para>\r\n<para type=\"description\"></para>"},"GatewayCriteriaEntry":{"type":"object","properties":{"gatewayIP":{"type":"string","description":"<para type=\"description\">The gateway IP.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Gateway criteria entry</para>\r\n<para type=\"description\"></para>"},"OSsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the OSs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedOSes":{"$ref":"#/components/schemas/AllowedOperatingSystems"}},"additionalProperties":false,"description":"<para type=\"synopsis\">OS Criteria Settings</para>\r\n<para type=\"description\"></para>"},"AllowedOperatingSystems":{"type":"object","properties":{"chrome":{"type":"boolean","description":"<para type=\"description\">Whether Chrome is allowed or not.</para>"},"android":{"type":"boolean","description":"<para type=\"description\">Whether Android is allowed or not.</para>"},"webClient":{"type":"boolean","description":"<para type=\"description\">Whether Web Client is allowed or not.</para>"},"iOS":{"type":"boolean","description":"<para type=\"description\">Whether iOS is allowed or not.</para>"},"linux":{"type":"boolean","description":"<para type=\"description\">Whether Linux is allowed or not.</para>"},"mac":{"type":"boolean","description":"<para type=\"description\">Whether MAC OS is allowed or not.</para>"},"wyse":{"type":"boolean","description":"<para type=\"description\">Whether Wyse is allowed or not.</para>"},"windows":{"type":"boolean","description":"<para type=\"description\">Whether Windows is allowed or not.</para>"}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed Operating Systems</para>\r\n<para type=\"description\"></para>"},"IPsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the IPs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"allowedIPs":{"$ref":"#/components/schemas/AllowedIPsCriteria"}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPs Criteria</para>\r\n<para type=\"description\"></para>"},"AllowedIPsCriteria":{"type":"object","properties":{"iPv4s":{"type":"array","items":{"$ref":"#/components/schemas/IPv4CriteriaEntry"},"description":"<para type=\"description\">IPv4 criteria list</para>","nullable":true},"iPv6s":{"type":"array","items":{"$ref":"#/components/schemas/IPv6CriteriaEntry"},"description":"<para type=\"description\">IPv6 criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Allowed IPs Criteria</para>\r\n<para type=\"description\"></para>"},"IPv4CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv4 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"IPv6CriteriaEntry":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">IPv6 Criteria Entry</para>\r\n<para type=\"description\"></para>"},"HardwareIDsCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Hardware IDs Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/HardwareIDCriteriaEntry"},"description":"<para type=\"description\">Hardware IDs criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware IDs Criteria</para>\r\n<para type=\"description\"></para>"},"HardwareIDCriteriaEntry":{"type":"object","properties":{"hardwareID":{"type":"string","description":"<para type=\"description\">The hardware ID.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Hardware ID criteria entry</para>\r\n<para type=\"description\"></para>"},"AccessType":{"enum":[["0 = DenyCriteriaWhen","1 = AllowCriteriaWhen"]],"type":"string","description":"<para type=\"synopsis\">Access type options</para>\r\n<para type=\"description\"></para>","format":"int32"},"DevicesCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Devices Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"members":{"type":"array","items":{"$ref":"#/components/schemas/ClientDeviceCriteriaEntry"},"description":"<para type=\"description\">Client criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Devices Criteria</para>\r\n<para type=\"description\"></para>"},"ClientDeviceCriteriaEntry":{"type":"object","properties":{"client":{"type":"string","description":"<para type=\"description\">The name of the client device.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Client device criteria entry</para>\r\n<para type=\"description\"></para>"},"ThemesCriteria":{"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the Themes Criteria is enabled or not</para>"},"matchingMode":{"$ref":"#/components/schemas/MatchingModeType"},"ids":{"type":"array","items":{"type":"integer","format":"int32"},"description":"<para type=\"description\">Theme criteria list</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Themes Criteria</para>\r\n<para type=\"description\"></para>"},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```

## Add

> Add an Rule to the Rule List of a session server with the specified ID.

```json
{"openapi":"3.0.1","info":{"title":"Parallels RAS - REST API v1.0","version":"1.0"},"paths":{"/api/PubItems/{id}/Rules":{"post":{"tags":["3-Publishing/Filters//Rule"],"summary":"Add","description":"Add an Rule to the Rule List of a session server with the specified ID.","operationId":"777717d1-eb20-45bc-8f59-b2f69fb8aa32","parameters":[{"name":"id","in":"path","description":"The ID of a session server for which to modify the Rule settings.","required":true,"schema":{"type":"integer","format":"int32"}}],"requestBody":{"description":"Gateway IP configuration.","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/AddRule"}}}},"responses":{"201":{"description":"Created"},"401":{"description":"Unauthorized","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"409":{"description":"Conflict","content":{"application/json; api-version=1.0":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"AddRule":{"required":["ruleName"],"type":"object","properties":{"enabled":{"type":"boolean","description":"<para type=\"description\">Whether the new rule will be enabled or disabled.</para>"},"ruleName":{"maxLength":255,"minLength":1,"type":"string","description":"<para type=\"description\">The name of the rule to add to the Criteria.</para>","nullable":true},"description":{"type":"string","description":"<para type=\"description\">Description for the new rule.</para>","nullable":true}},"additionalProperties":false,"description":"<para type=\"synopsis\">Add a rule to the Rule list</para>\r\n<para type=\"description\"></para>"},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.parallels.com/landing/ras-rest-api-guide/api-reference/publishing/rules.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
