Palo Alto Networks Pan-OS
The Palo Alto Networks Pan-OS connector enables streamlined integration and automation of network security tasks within the Swimlane Turbine platform.
Palo Alto Networks Pan-OS is a comprehensive suite for network security, offering advanced threat prevention, firewall functionalities, and unified policy management. This connector enables Swimlane Turbine users to automate configuration changes, policy management, and security enforcement across their network infrastructure. By integrating with Pan-OS, security teams can streamline their workflows, enforce consistent security policies, and respond to threats with agility and precision, all within the Swimlane Turbine platform.
Prerequisites
To effectively utilize the Palo Alto Networks Pan-OS connector for Swimlane Turbine, ensure you have the following prerequisites:
- API Key Authentication with the following parameters:
- URL: The base URL of the Palo Alto Networks Pan-OS instance.
- API Key: A valid API key to authenticate requests to the Pan-OS instance.
Actions Setup
Commit Changes
The following are examples of commit commands. Note that the 'cmd' input is a valid XML.
Commit:
type=commit
cmd=<commit></commit>Force Commit:
type=commit
cmd=<commit><force></force></commit>Partial commit while excluding shared objects and device and network configuration:
type=commit
action=partial
cmd=<commit><partial><device-and-network>excluded</device-and-network><shared-object>excluded</shared-object></partial></commit>Partial commit admin-level changes on a firewall or Panorama while excluding shared objects:
type=commit
action=partial
cmd=<commit><partial><device-and-network>excluded</device-and-network><shared-object>excluded</shared-object><admin><member>socadmin</member></admin></partial></commitCapabilities
This connector provides the following Capabilities:
- Commit Changes
- Create a Security Policy Rule
- Create an Address Object
- Create the Address Group
- Create URL Filtering Security Profile
- Delete an Address Object
- Delete Custom URL Category
- Delete URL Filtering Security Profile
- Edit an Address Object
- Edit Custom Url Category
- Edit Dynamic User Group
- Generic Task
- Get Log
- List Addresses
- List Custom URL Categories ... and so on
Palo alto Documentation
The Panorama and PAN-OS documentation can be found within the instance of Palo Alto under the following endoints:
- REST API: https://yourinstance/restapi-doc
Additional Notes
- In the Edit an Address Object action, if you are modifying the description and adding a new tag called red to the address object. If the tag does not already exist, you must first create the tag before you can reference it in the address object.
- In the Create an Address Object action , you please pass in the request body that include the name, location and other properties to define the object.
Configurations
API Key Authentication
Authenticates using an API Key
Configuration Parameters
Parameter | Description | Type | Required |
|---|---|---|---|
url | A URL to the target host. | string | Required |
X-PAN-KEY | API key | string | Required |
error_status_code | The Status codes more than 300 can also be used. | boolean | Optional |
verify_ssl | Verify SSL certificate | boolean | Optional |
http_proxy | A proxy to route requests through. | string | Optional |
Actions
Commit Changes
Applies pending configuration changes to Palo Alto Networks Pan-OS devices, activating the latest settings.
Endpoint
- URL: /api/
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.type | string | Optional | Parameters for the Commit Changes action |
parameters.action | string | Optional | Parameters for the Commit Changes action |
parameters.cmd | string | Optional | The entire commit command in XML format |
Input Example
{"parameters":{"type":"commit","action":"partial","cmd":"<commit><partial><device-and-network>excluded</device-and-network><shared-object>excluded</shared-object><admin><member>socadmin</member></admin></partial></commit>"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 21:22:48 GMT","Content-Type":"application/xml; charset=UTF-8","Content-Length":"286","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=qs4tqup6tgokarqb2bau83kobp; path=/; secure; HttpOnly, PHPSESSID=qs4tqu...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Content-Type...
Create a Security Policy Rule
Creates a new security policy rule in Palo Alto Networks Pan-OS with specified parameters and data.
Endpoint
- URL: /restapi/v11.0/Policies/SecurityRules
- Method: POST
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | The location type where the security rule will be created. |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys. |
parameters.name | string | Optional | The name of the security rule. |
entry | array | Optional | The entry of the security rule. |
entry.@location | string | Optional | The location type where the security rule will be created. |
entry.@name | string | Optional | The name of the security rule. |
entry.@vsys | string | Optional | The name of the vsys when location type is vsys. |
entry.action | string | Optional | The action of the security rule. |
entry.application | object | Optional | The application of the security rule. |
entry.application.member | array | Optional | The member of the application. |
entry.category | object | Optional | The category of the security rule. |
entry.category.member | array | Optional | The member of the category. |
entry.destination | object | Optional | The destination of the security rule. |
entry.destination.member | array | Optional | The member of the destination. |
entry.from | object | Optional | The from of the security rule. |
entry.from.member | array | Optional | The member of the from. |
entry.source-hip | object | Optional | The source hip of the security rule. |
entry.source-hip.member | array | Optional | The member of the source hip. |
entry.destination-hip | object | Optional | The destination hip of the security rule. |
entry.destination-hip.member | array | Optional | The member of the destination hip. |
entry.service | object | Optional | The service of the security rule. |
entry.service.member | array | Optional | The member of the service. |
entry.source | object | Optional | The source of the security rule. |
entry.source.member | array | Optional | The member of the source. |
entry.source-user | object | Optional | The source user of the security rule. |
Input Example
{"parameters":{"location":"us","vsys":"vsys1","name":"rule-example1"},"json_body":{"entry":[{"@location":"vsys","@name":"rule-example1","@vsys":"vsys1","action":"allow","application":{"member":["email-collaboration-apps"]},"category":{"member":["any"]},"destination":{"member":["any"]},"from":{"member":["zone-edge1"]},"source-hip":{"member":["any"]},"destination-hip":{"member":["any"]},"service":{"member":["application-default"]},"source":{"member":["any"]},"source-user":{"member":["any"]},"to":{"member":["any"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@code | string | Output field: @code |
@status | string | Status value |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.@total-count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.@location | string | Result of the operation |
result.entry.@name | string | Name of the resource |
result.entry.@vsys | string | Result of the operation |
result.entry.fqdn | string | Result of the operation |
result.entry.ip-netmask | string | Result of the operation |
result.entry.@oldname | string | Name of the resource |
Output Example
{"status_code":200,"response_headers":{},"reason":"OK","json_body":{"@code":"19","@status":"success","result":{"@count":"3","@total-count":"3","entry":[]}}}
Create an Address Object
Executes a POST request to create an address object in Palo Alto Networks Pan-OS using the specified name and location.
Endpoint
- URL: /restapi/v11.0/Objects/Addresses
- Method: POST
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | Location. |
parameters.name | string | Required | Name. |
entry | array | Optional | Entry. |
entry.@location | string | Optional | Location. |
entry.@name | string | Optional | Name. |
entry.description | string | Optional | Description. |
entry.fqdn | string | Optional | FQDN. |
entry.tag | object | Optional | Tag. |
entry.tag.member | array | Optional | Member. |
Input Example
{"parameters":{"location":"shared","name":"web-servers-production"},"json_body":{"entry":[{"@location":"shared","@name":"web-servers-production","description":"what is this for?","fqdn":"docs.paloaltonetworks.com","tag":{"member":["blue"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
Output Example
{"status_code":201,"response_headers":{"Content-Type":"text/html; charset=utf-8","x-hsci-cache-time":"2024-12-06T12:01:22.328Z","Content-Encoding":"gzip"},"reason":"OK","json_body":{}}
Create the Address Group
Creates a new address group in Palo Alto Networks Pan-OS with specified parameters and data.
Endpoint
- URL: restapi/9.0/Objects/AddressGroups
- Method: POST
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | The location type where the address group will be created. |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys. |
parameters.name | string | Optional | The name of the address group. |
entry | array | Optional | Parameter for Create the Address Group |
entry.@name | string | Optional | The name of the address group. |
entry.static | object | Optional | The static member of the address group. |
entry.static.member | array | Optional | The member of the address group. |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys1","name":"TutorialAddressGroup"},"json_body":{"entry":[{"@name":"TutorialAddressGroup","static":{"member":["TutorialEntry"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
msg | string | Output field: msg |
Output Example
{"status_code":200,"response_headers":{},"reason":"OK","json_body":{"@status":"success","@code":"20","msg":"command succeeded"}}
Create URL Filtering Security Profile
Manage web access and traffic by creating a URL filtering security profile in Palo Alto Networks Pan-OS.
Endpoint
- URL: /restapi/v10.2/Objects/URLFilteringSecurityProfiles
- Method: POST
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | Parameters for the Create URL Filtering Security Profile action |
parameters.vsys | string | Optional | Parameters for the Create URL Filtering Security Profile action |
parameters.name | string | Optional | Parameters for the Create URL Filtering Security Profile action |
entry | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.@name | string | Optional | Name of the resource |
entry.description | string | Optional | Parameter for Create URL Filtering Security Profile |
entry.allow | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.allow.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.alert | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.alert.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.block | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.block.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.continue | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.continue.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.override | object | Optional | Unique identifier |
entry.override.member | array | Optional | Unique identifier |
entry.credential-enforcement | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.mode | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.mode.disabled | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.log-severity | string | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.allow | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.allow.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.alert | object | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.alert.member | array | Optional | Parameter for Create URL Filtering Security Profile |
entry.credential-enforcement.block | object | Optional | Parameter for Create URL Filtering Security Profile |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys","name":"A name"},"json_body":{"entry":{"@name":"string","description":"string","allow":{"member":["string"]},"alert":{"member":["string"]},"block":{"member":["string"]},"continue":{"member":["string"]},"override":{"member":["string"]},"credential-enforcement":{"mode":{"disabled":{}},"log-severity":"medium","allow":{"member":["string"]},"alert":{"member":["string"]},"block":{"member":["string"]},"continue":{"member":["string"]}},"enable-container-page":"yes","log-container-page-only":"yes","safe-search-enforcement":"no","log-http-hdr-xff":"no","log-http-hdr-user-agent":"no","log-http-hdr-referer":"no","http-header-insertion":{"entry":[{"@name":"string","type":{"entry":[{"@name":"string","headers":{"entry":[{"@name":"string","header":"string","value":"string","log":"no"}]},"domains":{"member":["string"]}}]}}]},"local-inline-cat":"no","cloud-inline-cat":"no","mlav-category-exception":{"member":["string"]}}}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 21:22:48 GMT","Content-Type":"application/xml; charset=UTF-8","Content-Length":"286","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=qs4tqup6tgokarqb2bau83kobp; path=/; secure; HttpOnly, PHPSESSID=qs4tqu...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Content-Type...
Delete an Address Object
Removes a specified address object from a location in Palo Alto Networks Pan-OS using the 'location' and 'name' parameters.
Endpoint
- URL: /restapi/v11.0/Objects/Addresses
- Method: DELETE
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | Location. |
parameters.name | string | Required | Name. |
Input Example
{"parameters":{"location":"shared","name":"web-server-production"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
Output Example
{"status_code":200,"response_headers":{"Content-Type":"text/html; charset=utf-8","x-hsci-cache-time":"2024-12-06T12:01:22.328Z","Content-Encoding":"gzip"},"reason":"OK","json_body":{}}
Delete Custom URL Category
Removes a custom URL category from a specified location in Palo Alto Networks Pan-OS, requiring the 'location' parameter.
Endpoint
- URL: /restapi/v10.2/Objects/CustomURLCategories
- Method: DELETE
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.name | string | Optional | The name of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","name":"Example Name","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 21:22:48 GMT","Content-Type":"application/xml; charset=UTF-8","Content-Length":"286","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=qs4tqup6tgokarqb2bau83kobp; path=/; secure; HttpOnly, PHPSESSID=qs4tqu...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Content-Type...
Delete URL Filtering Security Profile
Removes a specified URL filtering security profile from a designated location in Palo Alto Networks Pan-OS.
Endpoint
- URL: /restapi/v10.2/Objects/URLFilteringSecurityProfile
- Method: DELETE
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.name | string | Optional | The name of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","name":"Example Name","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 21:22:48 GMT","Content-Type":"application/xml; charset=UTF-8","Content-Length":"286","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=qs4tqup6tgokarqb2bau83kobp; path=/; secure; HttpOnly, PHPSESSID=qs4tqu...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Content-Type...
Edit an Address Object
Modifies an existing address object in Palo Alto Networks Pan-OS by using the provided name and location parameters.
Endpoint
- URL: /restapi/v11.0/Objects/Addresses
- Method: PUT
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | Location. |
parameters.name | string | Required | Name. |
entry | array | Optional | Parameter for Edit an Address Object |
entry.@location | string | Optional | Location. |
entry.@name | string | Optional | Name. |
entry.description | string | Optional | Description. |
entry.fqdn | string | Optional | FQDN. |
entry.tag | object | Optional | Tag. |
entry.tag.member | array | Optional | Member. |
Input Example
{"parameters":{"location":"shared","name":"web-servers-production"},"json_body":{"entry":[{"@location":"shared","@name":"web-servers-production","description":"publish servers","fqdn":"docs.paloaltonetworks.com","tag":{"member":["blue","red"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@code | string | Output field: @code |
@status | string | Status value |
msg | string | Output field: msg |
Output Example
{"status_code":200,"response_headers":{"Content-Type":"text/html; charset=utf-8","x-hsci-cache-time":"2024-12-06T12:01:22.328Z","Content-Encoding":"gzip"},"reason":"OK","json_body":{"@code":"20","@status":"success","msg":"command succeeded"}}
Edit Custom Url Category
Modify an existing custom URL category in Palo Alto Networks Pan-OS by specifying the location and name.
Endpoint
- URL: /restapi/v10.2/Objects/CustomURLCategories
- Method: PUT
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | Parameters for the Edit Custom Url Category action |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
parameters.name | string | Required | Parameters for the Edit Custom Url Category action |
entry | object | Optional | Parameter for Edit Custom Url Category |
entry.@name | string | Optional | Name of the resource |
entry.description | string | Optional | Parameter for Edit Custom Url Category |
entry.list | object | Optional | Parameter for Edit Custom Url Category |
entry.list.member | array | Optional | Parameter for Edit Custom Url Category |
entry.type | string | Optional | Type of the resource |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys","name":"A name"},"json_body":{"entry":{"@name":"string","description":"string","list":{"member":["string"]},"type":"URL List"}}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
Output Example
{}
Edit Dynamic User Group
Updates criteria or membership of an existing dynamic user group in Palo Alto Networks Pan-OS.
Endpoint
- URL: /restapi/v10.2/Objects/DynamicUserGroups
- Method: PUT
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | Parameters for the Edit Dynamic User Group action |
parameters.vsys | string | Optional | Parameters for the Edit Dynamic User Group action |
parameters.name | string | Optional | Parameters for the Edit Dynamic User Group action |
entry | object | Optional | Parameter for Edit Dynamic User Group |
entry.@name | string | Optional | Name of the resource |
entry.description | string | Optional | Parameter for Edit Dynamic User Group |
entry.filter | string | Optional | Parameter for Edit Dynamic User Group |
entry.tag | object | Optional | Parameter for Edit Dynamic User Group |
entry.tag.member | array | Optional | Parameter for Edit Dynamic User Group |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys","name":"A name"},"json_body":{"entry":{"@name":"string","description":"string","filter":"string","tag":{"member":["string"]}}}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"response_text":"string"}
Generic Task
Execute a customizable task in Palo Alto Networks Pan-OS, offering full control over request parameters for tailored operations.
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
endpoint | string | Optional | Path to the endpoint after url in asset. Use double brackets with path parameters for dynamic URLs. |
method | string | Optional | Method of the request such as: POST, GET, PUT, PATCH, DELETE. (Note, others are available to use) |
data_body | object | Optional | Body to send as data, this allows you to set the content-type in the headers manually. |
headers | object | Optional | Request headers to send with the individual request. |
Input Example
{"endpoint":"api/v3/users"}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | The HTTP response status code |
data | object | The JSON response body |
response_text | string | Output field: response_text |
reason | string | The HTTP reason, often times an error message can be here. OK means success. |
Output Example
{"response_text":"string"}
Get Log
Retrieves a specific log entry from Palo Alto Networks Pan-OS using the provided queue ID.
Endpoint
- URL: /api/
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.type | string | Optional | Parameters for the Get Log action |
parameters.action | string | Optional | Parameters for the Get Log action |
parameters.job-id | number | Optional | Parameters for the Get Log action |
Input Example
{"parameters":{"type":"log","action":"get","job-id":16}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 22:21:55 GMT","Content-Type":"application/xml; charset=UTF-8","Transfer-Encoding":"chunked","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=sqie6u23458jkdo2n0rt28jfgt; path=/; secure; HttpOnly, PHPSESSID=sqie6u...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Conte...
List Addresses
Retrieve a list of address objects from a specified location in Palo Alto Networks Pan-OS, requiring the 'location' parameter.
Endpoint
- URL: /restapi/v11.0/Objects/Addresses
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.ip-netmask | string | Result of the operation |
result.entry.tag | object | Result of the operation |
result.entry.tag.member | array | Result of the operation |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 20:32:48 GMT","Content-Type":"application/json; charset=UTF-8","Content-Length":"45","Connection":"keep-alive","Set-Cookie":"PHPSESSID=55kmh2bk7l06fmkrs0ptdrejeo; path=/; secure; HttpOnly, PHPSESSID=55kmh2...","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Cache-Control":"no-store, no-cache, must-revalidate","Pragma":"no-cache","Allow":"GET, HEAD, POST, PUT, DELETE, OPTIONS"},"reason":"OK","json_body":{"@status":"success","@code":"19","...
List Custom URL Categories
Retrieve a list of custom URL categories from Palo Alto Networks Pan-OS at the specified 'location'.
Endpoint
- URL: /restapi/v10.2/Objects/CustomURLCategories
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.@name | string | Name of the resource |
result.entry.@location | string | Result of the operation |
result.entry.@vsys | string | Result of the operation |
result.entry.description | string | Result of the operation |
result.entry.list | object | Result of the operation |
result.entry.list.member | array | Result of the operation |
result.entry.type | string | Type of the resource |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 20:32:48 GMT","Content-Type":"application/json; charset=UTF-8","Content-Length":"45","Connection":"keep-alive","Set-Cookie":"PHPSESSID=55kmh2bk7l06fmkrs0ptdrejeo; path=/; secure; HttpOnly, PHPSESSID=55kmh2...","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Cache-Control":"no-store, no-cache, must-revalidate","Pragma":"no-cache","Allow":"GET, HEAD, POST, PUT, DELETE, OPTIONS"},"reason":"OK","json_body":{"@status":"success","@code":"7","r...
List Dynamic User Groups
Retrieve a list of dynamic user groups from Palo Alto Networks Pan-OS at a specified location.
Endpoint
- URL: /restapi/v10.2/Objects/DynamicUserGroups
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.@name | string | Name of the resource |
result.entry.@location | string | Result of the operation |
result.entry.@vsys | string | Result of the operation |
result.entry.description | string | Result of the operation |
result.entry.list | object | Result of the operation |
result.entry.list.member | array | Result of the operation |
result.entry.type | string | Type of the resource |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 20:32:48 GMT","Content-Type":"application/json; charset=UTF-8","Content-Length":"45","Connection":"keep-alive","Set-Cookie":"PHPSESSID=55kmh2bk7l06fmkrs0ptdrejeo; path=/; secure; HttpOnly, PHPSESSID=55kmh2...","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Cache-Control":"no-store, no-cache, must-revalidate","Pragma":"no-cache","Allow":"GET, HEAD, POST, PUT, DELETE, OPTIONS"},"reason":"OK","json_body":{"@status":"success","@code":"7","r...
List SysLogs Profiles
Retrieves a list of Syslog Server Profiles from a specified location in Palo Alto Networks Pan-OS, requiring the 'location' parameter.
Endpoint
- URL: /restapi/v10.2/Network/TunnelInterfaces
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.name | string | Optional | The name of the entry |
Input Example
{"parameters":{"location":"string","name":"Example Name"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.@name | string | Name of the resource |
result.entry.@location | string | Result of the operation |
result.entry.server | object | Result of the operation |
result.entry.server.entry | array | Result of the operation |
result.entry.server.entry.@name | string | Name of the resource |
result.entry.server.entry.server | string | Result of the operation |
result.entry.server.entry.transport | string | Result of the operation |
result.entry.server.entry.port | number | Result of the operation |
result.entry.server.entry.format | string | Result of the operation |
result.entry.server.entry.facility | string | Result of the operation |
result.entry.format | object | Result of the operation |
result.entry.format.traffic | string | Result of the operation |
result.entry.format.threat | string | Result of the operation |
result.entry.format.wildfire | string | Result of the operation |
result.entry.format.url | string | URL endpoint for the request |
result.entry.format.data | string | Response data |
result.entry.format.gtp | string | Result of the operation |
result.entry.format.sctp | string | Result of the operation |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 20:32:48 GMT","Content-Type":"application/json; charset=UTF-8","Content-Length":"45","Connection":"keep-alive","Set-Cookie":"PHPSESSID=55kmh2bk7l06fmkrs0ptdrejeo; path=/; secure; HttpOnly, PHPSESSID=55kmh2...","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Cache-Control":"no-store, no-cache, must-revalidate","Pragma":"no-cache","Allow":"GET, HEAD, POST, PUT, DELETE, OPTIONS"},"reason":"OK","json_body":{"@status":"success","@code":"19","...
List URL Filtering Security Profiles
Retrieve a list of URL filtering security profiles from Palo Alto Networks Pan-OS using the specified location.
Endpoint
- URL: /restapi/v10.2/Objects/URLFilteringSecurityProfiles
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Required | The location of the entry |
parameters.name | string | Optional | The name of the entry |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys |
Input Example
{"parameters":{"location":"string","name":"Example Name","vsys":"string"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
result | object | Result of the operation |
result.@count | string | Result of the operation |
result.entry | array | Result of the operation |
result.entry.@name | string | Name of the resource |
result.entry.@location | string | Result of the operation |
result.entry.@vsys | string | Result of the operation |
result.entry.description | string | Result of the operation |
result.entry.allow | object | Result of the operation |
result.entry.allow.member | array | Result of the operation |
result.entry.alert | object | Result of the operation |
result.entry.alert.member | array | Result of the operation |
result.entry.block | object | Result of the operation |
result.entry.block.member | array | Result of the operation |
result.entry.continue | object | Result of the operation |
result.entry.continue.member | array | Result of the operation |
result.entry.override | object | Unique identifier |
result.entry.override.member | array | Unique identifier |
result.entry.credential-enforcement | object | Result of the operation |
result.entry.credential-enforcement.mode | object | Result of the operation |
result.entry.credential-enforcement.mode.disabled | object | Result of the operation |
result.entry.credential-enforcement.log-severity | string | Result of the operation |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 20:32:48 GMT","Content-Type":"application/json; charset=UTF-8","Content-Length":"45","Connection":"keep-alive","Set-Cookie":"PHPSESSID=55kmh2bk7l06fmkrs0ptdrejeo; path=/; secure; HttpOnly, PHPSESSID=55kmh2...","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Cache-Control":"no-store, no-cache, must-revalidate","Pragma":"no-cache","Allow":"GET, HEAD, POST, PUT, DELETE, OPTIONS"},"reason":"OK","json_body":{"@status":"success","@code":"19","...
Reference an Address Object in the Rule
Links an address object to a security rule in Palo Alto Networks Pan-OS using provided parameters and data.
Endpoint
- URL: restapi/v11.0/Policies/SecurityRules
- Method: PUT
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | The location type where the security rule will be created. |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys. |
parameters.name | string | Optional | The name of the address group. |
entry | array | Optional | Parameter for Reference an Address Object in the Rule |
entry.@location | string | Optional | The location type where the security rule will be created. |
entry.@name | string | Optional | The name of the security rule. |
entry.@vsys | string | Optional | The name of the vsys when location type is vsys. |
entry.action | string | Optional | The action of the security rule. |
entry.application | object | Optional | The application of the security rule. |
entry.application.member | array | Optional | The member of the application. |
entry.category | object | Optional | The category of the security rule. |
entry.category.member | array | Optional | The member of the category. |
entry.destination | object | Optional | The destination of the security rule. |
entry.destination.member | array | Optional | The member of the destination. |
entry.from | object | Optional | The from of the security rule. |
entry.from.member | array | Optional | The member of the from. |
entry.source-hip | object | Optional | The source hip of the security rule. |
entry.source-hip.member | array | Optional | The member of the source hip. |
entry.destination-hip | object | Optional | The destination hip of the security rule. |
entry.destination-hip.member | array | Optional | The member of the destination hip. |
entry.service | object | Optional | The service of the security rule. |
entry.service.member | array | Optional | The member of the service. |
entry.source | object | Optional | The source of the security rule. |
entry.source.member | array | Optional | The member of the source. |
entry.source-user | object | Optional | The source user of the security rule. |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys1","name":"TutorialAddressGroup"},"json_body":{"entry":[{"@location":"vsys","@name":"rule-example1","@vsys":"vsys1","action":"allow","application":{"member":["email-collaboration-apps"]},"category":{"member":["any"]},"destination":{"member":["any"]},"from":{"member":["zone-edge1"]},"source-hip":{"member":["any"]},"destination-hip":{"member":["any"]},"service":{"member":["application-default"]},"source":{"member":["web-servers-production"]},"source-user":{"member":["any"]},"to":{"member":["any"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
msg | string | Output field: msg |
Output Example
{"status_code":200,"response_headers":{},"reason":"OK","json_body":{"@status":"success","@code":"20","msg":"command succeeded"}}
Rename an Address Object
Renames an existing address object in Palo Alto Networks Pan-OS by specifying the current name, location, and new name.
Endpoint
- URL: /restapi/v11.0/Objects/Addresses:rename
- Method: POST
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | Location. |
parameters.name | string | Optional | Current name of the address object. |
parameters.newname | string | Optional | New name for the address object. |
Input Example
{"parameters":{"location":"shared","name":"web-servers-production","newname":"web-server-publish"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@code | string | Output field: @code |
@status | string | Status value |
msg | string | Output field: msg |
Output Example
{"status_code":200,"reason":"OK","json_body":{"@code":"20","@status":"success","msg":"command succeeded"}}
Run Logs
Initiates a log query in Palo Alto Networks Pan-OS, returning an ID for retrieval with parameters such as type and log direction.
Endpoint
- URL: /api/
- Method: GET
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.type | string | Required | Parameters for the Run Logs action |
parameters.log-type | string | Required | Parameters for the Run Logs action |
parameters.dir | string | Required | Parameters for the Run Logs action |
parameters.nlogs | number | Required | Parameters for the Run Logs action |
parameters.skip | number | Required | Parameters for the Run Logs action |
parameters.query | string | Optional | Parameters for the Run Logs action |
Input Example
{"parameters":{"type":"log","log-type":"traffic","dir":"forward","nlogs":20,"skip":0,"query":"receive_time geq '2012/06/22 08:00:00')"}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
response_text | string | Output field: response_text |
Output Example
{"status_code":200,"response_headers":{"Date":"Thu, 29 Dec 2022 22:13:37 GMT","Content-Type":"application/xml; charset=UTF-8","Content-Length":"134","Connection":"keep-alive","Cache-Control":"no-store, no-cache, must-revalidate","Expires":"Thu, 19 Nov 1981 08:52:00 GMT","Pragma":"no-cache","Set-Cookie":"PHPSESSID=1c391le6gkn8o2h175ipuq5nik; path=/; secure; HttpOnly, PHPSESSID=1c391l...","Content-Security-Policy":"frame-ancestors 'none'","Strict-Transport-Security":"max-age=86400","X-Content-Type...
Update Address Group
Updates an existing address group in Palo Alto Networks Pan-OS with specified parameters and data.
Endpoint
- URL: restapi/9.0/Objects/AddressGroups
- Method: PUT
Input
Argument Name | Type | Required | Description |
|---|---|---|---|
parameters.location | string | Optional | The location type where the address group will be created. |
parameters.vsys | string | Optional | The name of the vsys when location type is vsys. |
parameters.name | string | Optional | The name of the address group. |
entry | array | Optional | Parameter for Update Address Group |
entry.@name | string | Optional | The name of the address group. |
entry.static | object | Optional | The static member of the address group. |
entry.static.member | array | Optional | The member of the address group. |
Input Example
{"parameters":{"location":"vsys","vsys":"vsys1","name":"TutorialAddressGroup"},"json_body":{"entry":[{"@name":"TutorialAddressGroup","static":{"member":["TutorialEntry"]}}]}}
Output
Parameter | Type | Description |
|---|---|---|
status_code | number | HTTP status code of the response |
reason | string | Response reason phrase |
@status | string | Status value |
@code | string | Output field: @code |
msg | string | Output field: msg |
Output Example
{"status_code":200,"response_headers":{},"reason":"OK","json_body":{"@status":"success","@code":"20","msg":"command succeeded"}}
Response Headers
Header | Description | Example |
|---|---|---|
Allow | HTTP response header: Allow | GET, HEAD, POST, PUT, DELETE, OPTIONS |
Cache-Control | Directives for caching mechanisms | no-store, no-cache, must-revalidate |
Connection | HTTP response header: Connection | keep-alive |
Content-Encoding | HTTP response header: Content-Encoding | gzip |
Content-Length | The length of the response body in bytes | 134 |
Content-Security-Policy | HTTP response header: Content-Security-Policy | frame-ancestors 'none' |
Content-Type | The media type of the resource | application/json |
Date | The date and time at which the message was originated | Thu, 29 Dec 2022 22:13:37 GMT |
Expires | The date/time after which the response is considered stale | Thu, 19 Nov 1981 08:52:00 GMT |
Pragma | HTTP response header: Pragma | no-cache |
Set-Cookie | HTTP response header: Set-Cookie | PHPSESSID=1c391le6gkn8o2h175ipuq5nik; path=/; secure; HttpOnly, PHPSESSID=1c391le6gkn8o2h175ipuq5nik; path=/; secure; HttpOnly; SameSite=strict |
Strict-Transport-Security | HTTP response header: Strict-Transport-Security | max-age=86400 |
Transfer-Encoding | HTTP response header: Transfer-Encoding | chunked |
X-Content-Type-Options | HTTP response header: X-Content-Type-Options | nosniff |
X-Frame-Options | HTTP response header: X-Frame-Options | DENY |
x-hsci-cache-time | HTTP response header: x-hsci-cache-time | 2024-12-06T12:01:22.328Z |