Skip to main content

phpipam-api

An incomplete phpIPAM API implementation in python.

import phpipam_api

ipam = phpipam_api.PhpipamAPI("https://phpipam.example.com/", "myapp", "apiuser", "p4s5word")

Usage:

data = ipam.<controller>.<operation>(<arguments>)

All functions return a dictionary object or a list of dictionary objects. Refer to the API Doc for data layout. If an error is encountered, an exception is raised.

Controllers

Functions shared by all controllers:

  • get() returns all obejcts in in controller
  • byID(object_id=<object id>) get specific obejct by ID
  • create(data=<data>)
  • edit(data=<data>)
  • delete(object_id=<object id>)

sections

  • getSubnets(section_id=<section id>)

subnets

  • search(search=<query>) search for subnet by CIDR
  • getIP(subnet_id=<subnet id>, ip=<ip>) get address object from subnet by IP
  • getAddresses(subnet_id=<subnet id>) get all addresses in subnet

addresses

  • getByIP(subnet_id=<subnet id>, ip=<ip>)
  • getByTag(tag_id=<tag id>)
  • search(ip=<ip>)
  • getFirstFree(subnet_id=<subnet id>)
  • getTags()
  • getTag(tag_id=<tag id>)
  • createFirstFree(subnet_id=<subnet id>)

vlan

l2domains

vrf

devices

  • getAddresses(device_id=<device id>)
  • getSubnets(device_id=<device id>)

prefix

requires

  • dateutil
  • requests

License: MIT

Download files

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

Source Distribution

phpipam-api-1.0.0.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

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

phpipam_api-1.0.0-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file phpipam-api-1.0.0.tar.gz.

File metadata

  • Download URL: phpipam-api-1.0.0.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.9.1

File hashes

Hashes for phpipam-api-1.0.0.tar.gz
Algorithm Hash digest
SHA256 cade592d2c30ab7d12f258f31c22308173c9958466e5097889c2842d340bf855
MD5 55ab26a1e22f95e2b85df0d5a08facc8
BLAKE2b-256 e018ebf25fa1c150f378a8f27c1e0b1d0ebafdd8cfe0bde17977edc72f594e30

See more details on using hashes here.

File details

Details for the file phpipam_api-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: phpipam_api-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.9.1

File hashes

Hashes for phpipam_api-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 573f9ecdc5b00349f9ea81fb9f460c10807db9b6c6e65fbaea17f13f2d3267f0
MD5 9289d35ceec6f672ba95da453cabb2b8
BLAKE2b-256 a994ce17156c7c2ca37c25759517c07c8235afc73be18d46fd70165c0f45b10a

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 Sentry Error logging StatusPage Status page