- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
04-15-2024 07:42 AM - edited 04-16-2024 12:04 AM
{'code': 3, 'message': 'Invalid Body', 'details': [{'@type': 'CauseInfo', 'causes': [{'code': 9, 'module': 'pan_api', 'description': 'Invalid Body'}]}]}
I m able to create policy with POST method in panoram , however API doc for relase did not help as well.
Url:
https://192.168.1.1/restapi/v10.1/Policies/SecurityPreRules?location=device-group&device-group=FW_ru...
data sending:
{"entry":{'name': '1',
'location': 'device-group',
'device-group': 'FW_rules',
'to': {'member': ['any']},
'from': {'member': ['any']},
'source': {'member': ['any']},
'destination': {'member': ['any']},
'application': {'member': ['any']},
'service': {'member': ['application-default']},
'action': 'allow'}}
API DOC:
The security pre-rule you want to create
entry |
object (policies-security-pre-rules)
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
name
required
|
string
The name of the entry |
location
required
|
string
Enum: "shared" "device-group"
The location of the entry |
device-group |
string
The name of the Panorama device group to which you have assigned the firewalls, when |
input-format |
string
Default: "json"
Enum: "json" "xml"
Specify the input format to be JSON or XML. It is equivalent to set |
output-format |
string
Default: "json"
Enum: "json" "xml"
Specify the output format to be JSON or XML. It is equivalent to set |
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!