Skip to main content

Nautobot API Sandbox

This is a simple program to test my programming knowledge and learn more about API, Nautobot, and developing in general.

https://demo.nautobot.com/

Getting Started

  1. Install package: sudo pip install nautobot_api_sandbox

  2. Run package: nautobot_api_sandbox

  3. Enter Demo token: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

    This will start the Nautobot API Sandbox command-line interface. Follow the instructions in the application to interact with the Nautobot API.

    📝 NOTE: You don't need to add '()' or "" quotes. Simply type the command + name (e.g., create_tenant tpayne, show_devices atl01).

    To update: pip install --upgrade nautobot_api_sandbox

Development Prerequisites

Before getting started, make sure you have the following installed on your machine:

  • Python 3.9 or later
  • Poetry

Development

  1. Clone the repository: git clone git@github.com:tPayne0647/nautobot-api-sandbox.git
  2. Navigate to the project directory: cd nautobot-api-sandbox
  3. Install the project dependencies using Poetry: poetry install
  4. Install the development dependencies: poetry install --dev
  5. Activate the virtual environment created by Poetry: poetry shell
  6. Run the program: python -m nautobot_api_sandbox.nautobot_api_sandbox_ui

To run the tests: poetry run pytest

Any help or tips would be greatly appreciated!!

CLick UI command examples

must be in poetry enviroment

  • python nautobot_api_sandbox/click_ui.py show-sites
  • python nautobot_api_sandbox/click_ui.py show-devices SITE_NAME
  • python nautobot_api_sandbox/click_ui.py create-tenant TENANT_NAME
  • python nautobot_api_sandbox/click_ui.py delete-tenant TENANT_NAME
  • python nautobot_api_sandbox/click_ui.py show-tenants
  • python nautobot_api_sandbox/click_ui.py get-tenant TENANT_NAME
  • python nautobot_api_sandbox/click_ui.py COMMAND --help

Remember to replace SITE_NAME or TENANT_NAME with the name of the site or tenant. You dont need to add quotation marks!

Currently Working On / Want to Add

  • Valid unittest? Need more tests...
  • Make sure using logging correctly
  • Integrate click? really want to rework UI
  • Exception handling
  • Fix delete_tenant RequestError 409
  • Update readme instructions
  • Poetry integration
  • Publish package

This is a work in progress!!!

Metadata

Release files for nautobot-api-sandbox 0.1.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nautobot-api-sandbox 0.1.6
File Size Uploaded Provenance Actions
nautobot_api_sandbox-0.1.6.tar.gz 4.9 kB Without provenance Details for nautobot_api_sandbox-0.1.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nautobot-api-sandbox 0.1.6
File Interpreter ABI Platform Actions
nautobot_api_sandbox-0.1.6-py3-none-any.whl Python 3 none any Details for nautobot_api_sandbox-0.1.6-py3-none-any.whl

Total release size: 11.8 kB

Release files / nautobot_api_sandbox-0.1.6.tar.gz

Download URL nautobot_api_sandbox-0.1.6.tar.gz
Size 4.9 kB
Tags Source
SHA-256 checksum
How to use checksums
ec2586cde8a662ca8933803ccbc25bd6d9b41b2ec30c4ae2c41e9fb0366ed2e7
BLAKE2b-256 checksum
How to use checksums
8d53e7aee7b4355066afcc2ee25da841e16e56ac5caaba80483b642b82bc9942
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.5.1 CPython/3.9.16 Linux/5.15.90.1-microsoft-standard-WSL2

Release files / nautobot_api_sandbox-0.1.6-py3-none-any.whl

Download URL nautobot_api_sandbox-0.1.6-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ab7af76e8b259a0203bfeedde84bd5e50dfd3c400145831246f7558750417fdf
BLAKE2b-256 checksum
How to use checksums
3cf75f5203273226c94e6c592dd1ffa643f77c0b199daff847d2d44000f22a3f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.5.1 CPython/3.9.16 Linux/5.15.90.1-microsoft-standard-WSL2

Security for nautobot-api-sandbox 0.1.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page