Skip to main content

No project description provided

Project description

README

This repository contains a wrapper around Panorama/PaloAlto API.

Documentation

Documentation can be found here It is automatically generated using pdoc

Why the need for this library ?

For simple resource retrieval, the existing API is enough, but the libraries available are not practical for it. Especially, we don't have much information on the data' schema.

The official python SDK of PaloAltoNetworks itself relies on a third party wrapper for their API.

This library provides clients (JSON/XML APIs) with a more popular approach when wrapping the API, making it easier to use for developers. It also provides types' wrappers using pydantic library to simplify their usage or utility functions to re-structure the data we receive. This provides the usual benefits of types like:

  • IDE completion: IDE will be able to provide you with completion as you type your code
  • Consistancy: a value that might be missing will always be defined either as None or as an empty list
  • Correctness: using mypy, you will be able to catch errors before they go to production.

NOTE: The json API is very limited and is, in fact, a mere translation of the xml using the same process as xmltodict library. Also, it is quite slow. For big read operations, it is better to retrieve big portions of the configuration at once and work completely locally.

Current State of the library

This library was developed over months by adding features when they were needed. It was tested against 9.x to 11.x paloalto and panorama devices.

There are a few caveats though:

  • Not everything is done now
  • The main focus is put on the XML API (there is no real reason to use the json API with this library)
  • The distinction between paloalto and panorama is not clearly defined everywhere. NOTE: we are trying to make the distinction transparent.
  • It currently focus on data retrieval more than insertion/update/deletion.
  • Methods should be re-arranged and re-grouped to simplify the usage of the library.
  • This does not support async/await currently.

Contributions are welcome:

  • Completing / Correcting types is more than welcome
  • Bug fixes are also very welcome
  • We would also like people opinions on how we can improve the library:
    • How should we organize the client classes and methods
    • How the creation/update/deletion should be taken care Don't hesitate to open an issue/discussion on this topic.

TODO

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pa_api_sdk-0.1.11.tar.gz (46.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pa_api_sdk-0.1.11-py3-none-any.whl (67.8 kB view details)

Uploaded Python 3

File details

Details for the file pa_api_sdk-0.1.11.tar.gz.

File metadata

  • Download URL: pa_api_sdk-0.1.11.tar.gz
  • Upload date:
  • Size: 46.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pa_api_sdk-0.1.11.tar.gz
Algorithm Hash digest
SHA256 fa42bb321e7cdf516edb03990b5e6d157cb2863aca4548f14c0d0ceb92316289
MD5 0605f77ddb648feffdd9c408061aa571
BLAKE2b-256 7e0d71db9206db8fe8271d5068ee348cbb4530c9d5b299af633594f78dbcc7aa

See more details on using hashes here.

File details

Details for the file pa_api_sdk-0.1.11-py3-none-any.whl.

File metadata

  • Download URL: pa_api_sdk-0.1.11-py3-none-any.whl
  • Upload date:
  • Size: 67.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pa_api_sdk-0.1.11-py3-none-any.whl
Algorithm Hash digest
SHA256 8ce2fb741d0db647a9142cae2de76f1bab514a632cfa62be56ee1b2bb5e62b58
MD5 be1f629324d1fd35d720ee03c02391f3
BLAKE2b-256 2852c2e82477c47582e66fe0fe4802fc478cda13a4c241f7ef2a462cb6ad8966

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page