Skip to main content

Morpheus API wrapper for Python 3

Project description

Morpheus Python Module

Installation

pip install pymorpheus

Usage

MorpheusClient() will either retrieve a token (with username and password args), or use an existing token (with token arg) Use sslverify=False to bypass certificate validation.

MorpheusClient.call() accepts the following vars:

  • Required (positional):
    • method: one of string: get, post, put, delete
    • path: api call path after /api/
  • Optional:
    • options: list of tuples eg. [('max','50')]
    • jsonpayload: JSON string of payload for POST/PUT methods

Reference at https://bertramdev.github.io/morpheus-apidoc

morpheus = MorpheusClient("https://yoururl", username="youruser", password="yourpass")
results = morpheus.call("get", path="instances")
print(results)
# JSON Output of results

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

pymorpheus-0.1.2.tar.gz (2.9 kB view details)

Uploaded Source

File details

Details for the file pymorpheus-0.1.2.tar.gz.

File metadata

  • Download URL: pymorpheus-0.1.2.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.1

File hashes

Hashes for pymorpheus-0.1.2.tar.gz
Algorithm Hash digest
SHA256 de5954272a9e684728e51bd07f37829f0b3fd1d64baad49137f11a077ddc7b7d
MD5 d78f1253a54a985f2029f1b8e7c7e938
BLAKE2b-256 9fc0ddd81be361fea805093d94b9c0986d3e7cef89a54c76aaec5e920ba25bbe

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