Skip to main content

Highly opinionated SimpleMDM Python library

Project description

SimpleMDM SDK Python

Python library for interacting with SimpleMDM's REST API. Pseudo-spiritual successor to SteveKueng/MacAdmin's SimpleMDMpy.

Note: Library is highly opinionated and may not be suitable for all use cases. Use at your own discretion.

Notable differences from SimpleMDMpy

  • Implicit conversion of parameters to strings when generating URLs.
    • ex. Passing device IDs as integers will no longer raises an error.
  • Single public class for all API endpoints
    • No need to pass API keys to individual endpoint classes.
  • Feature parity with SimpleMDM's API.
    • Currently validated against version 1.51.
  • Function names matching SimpleMDM's API.
    • ex. SimpleMDM.Accounts.show() instead of SimpleMDM.Accounts.get_account().
    • Easier referencing of SimpleMDM's API documentation.
  • Pydantic models for API responses.
    • Provides type hints and validation for API responses.
    • Configure strictness of validation with os.environ["SimpleMDMSDKModelExtra"] = "xxx" before importing the library.
  • Automatic ratelimit handling for all REST methods.
  • Enums for static properties in function parameters.
    • ex. SimpleMDM.AssignmentGroups.MunkiInstallType instead of strings.

Usage

from simplemdm_sdk import SimpleMDM

api_key = "your_api_key"
simplemdm = SimpleMDM(api_key)

# List all devices
devices = simplemdm.devices.list_all()
print(devices)

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

simplemdm_sdk-0.0.1.tar.gz (18.1 kB view details)

Uploaded Source

Built Distribution

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

simplemdm_sdk-0.0.1-py3-none-any.whl (31.9 kB view details)

Uploaded Python 3

File details

Details for the file simplemdm_sdk-0.0.1.tar.gz.

File metadata

  • Download URL: simplemdm_sdk-0.0.1.tar.gz
  • Upload date:
  • Size: 18.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for simplemdm_sdk-0.0.1.tar.gz
Algorithm Hash digest
SHA256 28e23de4397b163c84b619e065c438c6492db66fb721e899fb5779755f4ab96e
MD5 0bc4edbed560b960a44c454f25e9cc73
BLAKE2b-256 f23bb971b750bd013b69480b05261f97ec10364dd6ce89fe338f2d88aef8b3cb

See more details on using hashes here.

File details

Details for the file simplemdm_sdk-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: simplemdm_sdk-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 31.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for simplemdm_sdk-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 90d35dffb4114217a3a446ad93e8c16c6e6b813416b08d4d6b25c60ceac39a38
MD5 eed31042dae4cba5c856cf0e846c533a
BLAKE2b-256 e5db1a6abbd015e2d154645817b0169d4afd5e6b5133b00a3eff355cdf1f9e2f

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