- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
05-26-2013 12:38 AM
So I am trying to use the API to upload a custom-url-category, and my problem is that I have exced the length restriction of a HTML GET, So I tried doing a HTML PUT.
curl --insecure --form "type=config" --form "action=edit" --form "xpath=$xpath" --form "element=$element" --form "key=$pkey" "https://$panorama/api/"
But, I get 502 Bad Gateway - Does the PAN xml-api only GET??
05-26-2013 09:39 AM
you should be using --data and --data-urlencode vs. --form. URL-encode
everything except the key= parameter.
also see https://live.paloaltonetworks.com/message/16433#16433.
that will work with either the Perl or Python panxapi program.
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!