Publish Environment Pair Config

Publish Environment Pair Config
Publish DFW policy changes for an environment pair (async)

Initiate an asynchronous DFW policy publish job for a specific environment pair.

The {pair-id} is the underscore-separated concatenation of source and destination environment UUIDs (e.g. src-env-uuid_dst-env-uuid). Obtain it from the pair_id field in POST /monitoring/environments/pair-summary results.

Supported action types:

  • POLICY_WITH_PROTECTION_RULE_CREATE: Create a new DFW security policy with an embedded protection rule scoped to the source and destination environment groups.
  • PROTECTION_RULE_UPDATE: Update the action of an existing protection rule in an environment policy.

Polling for completion: The 202 response includes a job_id. Poll GET /monitoring/environment-pairs/{pair-id}/publish-config/{job-id} until status is COMPLETED or FAILED. The status_url in the response points directly to that endpoint.

Side effects: POLICY_WITH_PROTECTION_RULE_CREATE writes a new DFW security policy to NSX Manager and triggers NSX realization. Do not call this endpoint in a polling loop.

Returns 409 Conflict if a publish job for this environment pair is already in progress.

Request
URI
POST
https://{api_host}/intelligence/monitoring/environment-pairs/{pair-id}/publish-config
COPY
Path Parameters
string
pair-id
Required  

Environment pair identifier (underscore-separated concatenation of source and destination environment UUIDs). Obtain from the pair_id field in POST /monitoring/environments/pair-summary results.

pair-id example
6c0a5b3c-6b9f-4d1e-afaf-ed3fb42bd57e_8ad292bc-e09b-49de-b011-03d9beab1a2a

Request Body

Site ID and ordered list of publish actions to execute for the environment pair

EnvPublishConfigRequest of type(s) application/json
Required  

Show optional properties

{
    "site_id": "77366441-9e69-47d1-9bbb-8c608f27f158",
    "publish_actions": [
        {
            "action_type": "POLICY_WITH_PROTECTION_RULE_CREATE",
            "protection_rule_action": "JUMP_TO_APPLICATION",
            "display_name": "Shared to Development Policy"
        },
        {
            "action_type": "PROTECTION_RULE_UPDATE",
            "rule_path": "/infra/domains/default/security-policies/Policy-abc/rules/Rule-xyz",
            "rule_action": "JUMP_TO_APPLICATION"
        }
    ]
}
{
    "site_id": "5cf83f93-f9dd-4898-a345-44513572c557",
    "publish_actions": [
        {
            "action_type": "POLICY_WITH_PROTECTION_RULE_CREATE",
            "protection_rule_action": "JUMP_TO_APPLICATION",
            "display_name": "US_West_debug - LTN_West_debug Inter-Environment Policy"
        }
    ]
}
string
site_id
Required  

Unique identifier of the site where all publish actions will be executed.

array of object
publish_actions
Required  
Constraints: minItems: 1 maxItems: 100

Ordered list of publish actions to execute. Each entry targets one resource.

  • POLICY_WITH_PROTECTION_RULE_CREATE: One entry per new security policy to create.
  • PROTECTION_RULE_UPDATE: One entry per existing protection rule to update.
Authentication
This operation uses the following authentication methods.
Responses
202

Accepted. An asynchronous publish job has been created.

Returns AsyncApiResponse of type(s) application/json
{
    "id": "6012d743-ee88-4f05-9f09-1db8abe47678",
    "status_url": "/intelligence/monitoring/environment-pairs/6c0a5b3c-6b9f-4d1e-afaf-ed3fb42bd57e_8ad292bc-e09b-49de-b011-03d9beab1a2a/publish-config/6012d743-ee88-4f05-9f09-1db8abe47678"
}
string
id
Optional

UUID identifier of the response.

string
status_url
Optional

The URL to check the status of the operation.


400

Bad Request. The request body failed validation (e.g. empty publish_actions, invalid paths).

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.


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.


409

Conflict. A publish job for this environment pair is already in progress.

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.


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

Error

Returns Error of type(s) application/json
"Error Object"
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 POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"site_id":"string","publish_actions":["object"]}' https://{api_host}/intelligence/monitoring/environment-pairs/{pair-id}/publish-config