Update Proposed Security Policy Rule

Update Proposed Security Policy Rule
Update rule for proposed security policy

Updates a rule within a proposed security policy. Writable fields are display_name, description, action, and disabled. The request body must include the current revision value for optimistic concurrency control.

Notes

  • Only rules whose proposed_sync_action is CREATE or OVERWRITE are writable; attempting to update a rule with REORDER, SKIP, or DELETE returns an error.
  • The request body must include the current revision value for optimistic concurrency control.
  • Returns 200 on success
Request
URI
PUT
https://{api_host}/ssp/segmentation/{session-id}/results/proposed-security-policies/{policy-id}/rules/{rule-id}
COPY
Path Parameters
string
session-id
Required  

Unique identifier of the segmentation session.

string
policy-id
Required  

Unique identifier of the proposed security policy.

string
rule-id
Required  

Unique identifier of the rule.


Request Body

Rule update. Only display_name, description, action, and disabled are writable; all other fields are ignored. The revision field is required for optimistic concurrency control.

ProposedSecurityRule of type(s) application/json
Required  
This request body class requires all of the following: ProposedBaseRule , InlineProposedSecurityRule1
{
    "_revision": 0,
    "display_name": "SSP_US_AZ1_Prod_NTP",
    "action": "DROP",
    "disabled": false
}
Authentication
This operation uses the following authentication methods.
Responses
200

Successfully updated rule

Returns ProposedSecurityRule of type(s) application/json
This response body class contains all of the following: ProposedBaseRule , InlineProposedSecurityRule1
{
    "id": "SSP_Infra_NTP_Rule_6bf9a09f-cb7c-37bd-9d6b-72af7cb5c40c",
    "display_name": "SSP_US_AZ1_Prod_NTP",
    "description": "SSP created rule for NTP for SSP_Infra_US_AZ1_Prod_environment_NTP",
    "_revision": 0,
    "action": "DROP",
    "disabled": false,
    "proposed_sync_action": "OVERWRITE",
    "nsx_rule": {
        "resource_type": "Rule",
        "id": "SSP_Infra_NTP_Rule_6bf9a09f-cb7c-37bd-9d6b-72af7cb5c40c",
        "path": "/infra/domains/default/security-policies/SSP_Infra_Policy/rules/SSP_Infra_NTP_Rule_6bf9a09f-cb7c-37bd-9d6b-72af7cb5c40c",
        "display_name": "SSP_US_AZ1_Prod_NTP",
        "description": "SSP created rule for NTP for SSP_Infra_US_AZ1_Prod_environment_NTP",
        "sequence_number": 1500,
        "direction": "IN_OUT",
        "source_groups": [
            "/infra/domains/default/groups/5e2be46d-2cd7-350b-82da-09af3ba0c86f"
        ],
        "destination_groups": [
            "/infra/domains/default/groups/6bf9a09f-cb7c-37bd-9d6b-72af7cb5c40c"
        ],
        "action": "DROP",
        "services": [
            "/infra/services/NTP"
        ]
    }
}

400

Bad Request

Returns BadRequest of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


401

Unauthorized

Returns Unauthorized of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


403

Forbidden

Returns Forbidden of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


412

Precondition Failed

Returns PreconditionFailed of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


428

Precondition Required

Returns PreconditionRequired of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


429

Too Many Requests

Returns TooManyRequests of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


default

Unexpected error

Returns Error of type(s) application/json
{
    "error_code": 0,
    "module_name": "string",
    "error_message": "string"
}
integer
error_code
Required  

HTTP Status or Application error code.

string
module_name
Optional

Module where the error happened.

string
error_message
Required  

Message describing the error.


Code Samples
COPY
                    curl -X PUT -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{}' https://{api_host}/ssp/segmentation/{session-id}/results/proposed-security-policies/{policy-id}/rules/{rule-id}